openocd/src/jtag/drivers
Antonio Borneo 49d71d06d1 sysfsgpio: give time to udev to change gpio permission
When a gpio is exported by writing in /sys/class/gpio/export, the
corresponding gpio control files appear immediately in sysfs but
with default access permission for root user only. The daemon udev
requires some time to get notified of the new files before it can
change the permissions to allow access to unprivileged users.
Due to this race condition, sysfsgpio can fail with EACCES error
if OpenOCD is executed by any unprivileged user.

Give 0.5 seconds to udev to identify the new files and change the
permission.

Tested with udev rules:
	SUBSYSTEM=="gpio*", PROGRAM="/bin/sh -c 'find -L /sys/class/gpio/ -maxdepth 2 -exec chown root:uucp {} \; -exec chmod g=u {} \; || true'"

Change-Id: I1316c66ff103ffe23e5e4720f33372dc272a3766
Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-on: http://openocd.zylin.com/5302
Tested-by: jenkins
Reviewed-by: Tomas Vanek <vanekt@fbl.cz>
2019-12-19 20:42:01 +00:00
..
libjaylink@f73ad5e667 libjaylink: Update to latest Git version 2019-10-19 13:27:29 +01:00
OpenULINK Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
usb_blaster jtag: usb_blaster: Add missing 'default' to switch statement 2019-11-07 08:21:19 +00:00
versaloon Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
amt_jtagaccel.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
arm-jtag-ew.c Convert DEBUG_JTAG_IO to LOG_DEBUG_IO 2019-06-04 21:48:39 +01:00
at91rm9200.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
bcm2835gpio.c drivers/bcm2835gpio: fix build for ARM host 2019-05-15 05:33:59 +01:00
bitbang.c Convert DEBUG_JTAG_IO to LOG_DEBUG_IO 2019-06-04 21:48:39 +01:00
bitbang.h Add read buffer to bitbang, improving performance. 2018-01-25 16:44:06 +00:00
bitq.c Convert DEBUG_JTAG_IO to LOG_DEBUG_IO 2019-06-04 21:48:39 +01:00
bitq.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
buspirate.c jtag: drivers: buspirate: chunk SWD switch sequence transfer. 2019-06-13 12:39:38 +01:00
cmsis_dap_usb.c swd: remove unused API frequency() 2019-06-06 16:20:58 +01:00
driver.c jtag: make cmd_queue_scan_field_clone public 2018-10-16 11:58:17 +01:00
dummy.c command_registration: add empty usage field to chained commands 2019-04-07 08:17:36 +01:00
ep93xx.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
ft232r.c Convert DEBUG_JTAG_IO to LOG_DEBUG_IO 2019-06-04 21:48:39 +01:00
ftdi.c swd: remove unused API frequency() 2019-06-06 16:20:58 +01:00
gw16012.c drivers/gw16012: remove useless cast on gw16012_port 2019-10-18 09:22:34 +01:00
imx_gpio.c jtag/drivers/imx_gpio: fixed calls to command_print 2019-05-15 08:02:41 +01:00
jlink.c swd: remove unused API frequency() 2019-06-06 16:20:58 +01:00
jtag_usb_common.c jtag/drivers/jtag_usb_common: fix typo 2019-06-13 12:39:09 +01:00
jtag_usb_common.h jtag: drivers: provide initial support for usb path filtering 2019-02-07 07:51:30 +00:00
jtag_vpi.c jtag_vpi: ensured constant packet size & endianness 2019-12-16 23:27:32 +00:00
kitprog.c Fix warnings exposed by GCC8 2018-05-30 09:36:46 +01:00
libusb_common.h Convert to non-recursive make 2016-12-08 16:23:10 +00:00
libusb1_common.c jtag: drivers: provide initial support for usb path filtering 2019-02-07 07:51:30 +00:00
libusb1_common.h libusb: Add transfer type filter to get correct ep 2017-04-24 22:31:41 +01:00
libusb0_common.c libusb: add debug message on adapter not found due to wrong serial 2019-01-08 10:04:42 +00:00
libusb0_common.h libusb0: add compatibility define for transfer type bulk 2018-12-11 13:29:21 +00:00
Makefile.am jtag: drivers: provide initial support for usb path filtering 2019-02-07 07:51:30 +00:00
Makefile.rlink Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
minidriver_imp.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
mpsse.c Add wall clock timeout warning to mpsse_flush() 2019-10-15 08:58:56 +01:00
mpsse.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
opendous.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
openjtag.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
osbdm.c Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
parport.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
presto.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
remote_bitbang.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
rlink_call.m4 Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
rlink_dtc_cmd.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
rlink_ep1_cmd.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
rlink_init.m4 Remove FSF address from GPL notices 2016-05-24 22:30:01 +01:00
rlink_speed_table.c build: cleanup src/jtag/drivers directory 2012-02-06 10:59:07 +00:00
rlink_st7.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
rlink.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
rlink.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
stlink_usb.c stlink: Set speed before entering JTAG/SWD mode 2019-03-26 08:20:06 +00:00
sysfsgpio.c sysfsgpio: give time to udev to change gpio permission 2019-12-19 20:42:01 +00:00
ti_icdi_usb.c jtag: drivers: stlink: handle all versions with single config 2017-12-12 21:13:55 +00:00
ulink.c Convert DEBUG_JTAG_IO to LOG_DEBUG_IO 2019-06-04 21:48:39 +01:00
usb_common.c jtag/drivers/usb_common: return oocd error values 2019-01-08 10:02:43 +00:00
usb_common.h Make #include guard naming consistent 2016-05-24 22:30:55 +01:00
usbprog.c jtag: set default "jtag_only" to uninitialized transports 2019-06-06 16:45:31 +01:00
vsllink.c swd: remove unused API frequency() 2019-06-06 16:20:58 +01:00
xds110.c swd: remove unused API frequency() 2019-06-06 16:20:58 +01:00