zephyr/include
Peter A. Bigot d75495709d drivers: gpio: fix mis-use of slist API in callback processing
The iterator over registered callbacks failed to account for the
possibility that the callback would remove itself from the list.  If
this occurred any remaining callbacks would no longer be reachable from
the node.  Switch to the slist iterator that is safe for self-removal.

Note that the slist API remains unsafe for removal of subsequent nodes.
Even with the corrected code removal of the next callback registration
(cached in tmp) will result in it being called anyway, with the
remaining unremoved registrations not being called.  If the next
callback were removed and re-registered on a different device, the
callbacks would be invoked for the wrong device.

Resolve this by a documentation change describing the conditions under
which a change to callback registration from within a callback are
permitted.  Add a similar note regarding the effect of adding a
callback.  The current event invocation behavior for callbacks added
within an event is explicitly left unspecified, though in the current
slist implementation newly added callbacks will not be invoked until the
next event.

Closes #10186

Signed-off-by: Peter A. Bigot <pab@pabigot.com>
2019-02-05 12:33:25 -06:00
..
app_memory app_shmem: auto-initialize partitions 2019-01-30 23:15:51 -05:00
arch arch: arm: mpu: align NXP MPU implementation with ARM MPU 2019-02-05 09:28:59 -08:00
audio headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
bluetooth Bluetooth: Add identifiers for Bluetooth 5.1 2019-01-29 16:00:57 +02:00
cmsis_rtos_v1 headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
cmsis_rtos_v2 CMSIS RTOS V2: Introduce CMSIS RTOS V2 API header file 2018-12-20 12:23:22 +01:00
crypto headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
debug include: remove unused header file gdb_server.h 2019-01-22 07:45:22 -05:00
dfu headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
display doc: add missing cfb API 2019-01-03 12:38:28 -05:00
drivers display: Remove stale ILI9340 header file 2019-01-20 07:51:03 -05:00
dt-bindings interrupt_controller: RV32M1: add intmux driver / DT bindings 2019-01-25 11:59:46 -05:00
fs headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
linker app_shmem: auto-initialize partitions 2019-01-30 23:15:51 -05:00
logging logging: Extend log_output to support raw data 2019-01-29 17:24:37 +01:00
mgmt smp: shell: Add support for SMP in new shell. 2019-01-15 17:19:20 -05:00
misc misc: Add k_panic on assert 2019-02-02 15:58:33 -08:00
net doc: networking: move API reference to new section 2019-02-05 07:04:40 -05:00
nvs doc: group file system/storage APIs 2018-12-10 20:38:09 -05:00
posix lib: posix: fs: Convert to use generic fdtable 2018-11-04 22:04:11 +01:00
random headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
settings doc: regular misspelling scan 2018-12-26 13:27:14 -05:00
shell shell: Add handling of CONFIG_LOG_INPLACE_PROCESS option 2019-02-05 09:55:39 +01:00
toolchain arch/x86_64: New architecture added 2019-01-11 15:18:52 -05:00
usb usb: Add instance parameter to descriptors definitions 2019-02-01 19:11:32 -05:00
zephyr headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
adc.h include: adc: Fix async ADC API documentation 2018-12-04 15:52:18 -05:00
aio_comparator.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
atomic.h atomic: Add atomic_set_bit_to() API 2019-01-25 17:35:44 -05:00
base64.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
cache.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
can.h C++ : Fix error: template with C linkage 2019-01-25 11:19:56 -05:00
clock_control.h kernel: Using boolean expression on ASSERT macros 2018-09-28 06:28:41 +05:30
console.h doc: regular misspelling scan 2018-12-26 13:27:14 -05:00
counter.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
crc8.h crc: deprecate old headers and issue warning when used 2018-12-04 08:52:46 -06:00
crc16.h crc: move all crc APIs into one header 2018-12-04 08:52:46 -06:00
crc32.h crc: deprecate old headers and issue warning when used 2018-12-04 08:52:46 -06:00
crc.h crc: Move crc7 into CRC single header 2018-12-30 16:24:10 -05:00
device.h drivers: Modify drivers to use DEVICE_AND_API_INIT() 2019-01-15 10:39:34 -08:00
disk_access.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
display.h display: Added double buffer screen info to display API 2019-01-07 16:05:35 -05:00
dma.h doc: add peripherals reference 2019-01-30 18:38:48 -05:00
entropy.h drivers: entropy: Use likely()/unlikely() macros to speed up the API 2018-10-30 11:16:34 +01:00
exc_handle.h kernel: Fix type of Z_EXC_HANDLE 2018-11-16 09:18:27 -08:00
fcb.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
flash_map.h subsys: storage: flash_map: add API for check flash driver support 2018-09-27 16:24:21 +02:00
flash.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
fs.h doc: consolidated filesystem API reference 2019-02-05 07:04:40 -05:00
generated_dts_board.h cmake: Fix the generation of fixup files 2019-01-28 12:18:38 -05:00
gna.h doc: regular misspelling scan 2018-12-26 13:27:14 -05:00
gpio.h drivers: gpio: fix mis-use of slist API in callback processing 2019-02-05 12:33:25 -06:00
hwinfo.h drivers: Add hwinfo API 2019-02-03 12:07:20 -05:00
i2c.h C++ : Fix error: template with C linkage 2019-01-25 11:19:56 -05:00
i2s.h i2s: add i2s_configure() as a system call 2018-11-15 16:20:36 -05:00
init.h drivers: Modify drivers to use DEVICE_AND_API_INIT() 2019-01-15 10:39:34 -08:00
ipm.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
irq_nextlevel.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
irq_offload.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
irq.h kernel: add dynamic interrupt API 2018-11-10 11:01:22 -05:00
json.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
kernel_includes.h kernel.h: Header hygine, move clock/timer handling 2018-10-16 15:03:10 -04:00
kernel_version.h doc: add kernel version API to doxygen 2018-12-08 17:24:53 -05:00
kernel.h kernel: Document resolution of k_uptime_get*() 2019-02-04 17:56:55 -05:00
led_strip.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
led.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
pinmux.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
power.h power: Make power_state enum global 2019-02-04 13:36:29 +01:00
ptp_clock.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
pwm.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
ring_buffer.h lib: ring_buffer: add raw byte access mode 2018-10-09 13:58:44 -04:00
rtc.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
sched_priq.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
sensor.h C++ : Fix error: template with C linkage 2019-01-25 11:19:56 -05:00
shared_irq.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
spi.h docs: spi.h: removed dev doxygen comment from struct spi_config 2018-12-17 08:19:21 -06:00
spinlock.h kernel/spinlock: Force inlining 2019-02-01 15:57:21 -05:00
stats.h include: stats.h: Packed attribute was incorrect. 2018-12-07 10:32:41 -05:00
sw_isr_table.h arch: common: add function for updating IRQ table 2018-11-10 11:01:22 -05:00
sys_clock.h sys_clock: Change function signature 2018-12-11 14:37:10 -08:00
sys_io.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
syscall.h syscall: Return bool in a boolean function 2018-11-30 08:05:11 -08:00
toolchain.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
tracing.h debug: CTF Tracing with POSIX backend 2019-02-01 08:56:02 -05:00
tty.h doc: regular misspelling scan 2018-12-26 13:27:14 -05:00
uart.h api: uart: Add new asynchronous UART API. 2019-01-22 18:54:12 +01:00
watchdog.h drivers: watchdog: remove deprecated apis 2019-02-01 10:37:49 -06:00
zephyr.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00