Skip to content

Commit 6f183d4

Browse files
committed
patch #10029: linuxspi: Report GPIO_GET_LINEHANDLE_IOCTL errors
Submitted by Alex Sverdlin: * linuxspi.c (linuxspi_open): Report ioctl error git-svn-id: svn://svn.savannah.nongnu.org/avrdude/trunk/avrdude@1493 81a1dc3b-b13d-400b-aceb-764788c761c2
1 parent d208503 commit 6f183d4

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

ChangeLog

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
2021-11-27 Joerg Wunsch <[email protected]>
2+
3+
Submitted by Alex Sverdlin:
4+
patch #10029: linuxspi: Report GPIO_GET_LINEHANDLE_IOCTL errors
5+
* linuxspi.c (linuxspi_open): Report ioctl error
6+
17
2021-11-27 Joerg Wunsch <[email protected]>
28

39
Submitted by Alex Sverdlin:

NEWS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@ Current:
119119
patch #9328: ft245r.c: add TPI support (patches 5-7)
120120
patch #10027: linuxspi: Add reset pulse, according to AVR programming algorithm
121121
patch #10028: linuxspi: close() only when necessary
122+
patch #10029: linuxspi: Report GPIO_GET_LINEHANDLE_IOCTL errors
122123

123124
* Internals:
124125
- New avrdude.conf keyword "family_id", used to verify SIB attributes

linuxspi.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,8 @@ static int linuxspi_open(PROGRAMMER *pgm, char *port)
170170
ret = ioctl(fd_gpiochip, GPIO_GET_LINEHANDLE_IOCTL, &req);
171171
if (ret == -1) {
172172
ret = -errno;
173+
avrdude_message(MSG_INFO, "%s error: Unable to get GPIO line %d\n",
174+
progname, pgm->pinno[PIN_AVR_RESET] & ~PIN_INVERSE);
173175
goto close_gpiochip;
174176
}
175177

0 commit comments

Comments
 (0)