Skip to content

Commit

Permalink
Fix assert in gpio_set_irq_enabled (#1864)
Browse files Browse the repository at this point in the history
* Fix assert in gpio_set_irq_enabled
  • Loading branch information
peterharperuk authored Aug 23, 2024
1 parent 7dc10d7 commit aa8cf17
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rp2_common/hardware_gpio/gpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ void gpio_set_irq_enabled(uint gpio, uint32_t events, bool enabled) {
// or callback should already be set (raw or using gpio_set_irq_callback)
// this protects against enabling the interrupt without callback set
assert(!enabled
|| (raw_irq_mask[get_core_num()] & (1u<<gpio))
|| (raw_irq_mask[get_core_num()] & (1ull<<gpio))
|| callbacks[get_core_num()]);

// Separate mask/force/status per-core, so check which core called, and
Expand Down

0 comments on commit aa8cf17

Please sign in to comment.