Skip to content
Snippets Groups Projects
Commit eff01f21 authored by Joakim Nohlgård's avatar Joakim Nohlgård
Browse files

cpu/cc26x0: Cast gpio_t to unsigned int for comparison

parent abca77be
No related branches found
No related tags found
No related merge requests found
...@@ -34,7 +34,7 @@ static gpio_isr_ctx_t gpio_chan[GPIO_ISR_CHAN_NUMOF]; ...@@ -34,7 +34,7 @@ static gpio_isr_ctx_t gpio_chan[GPIO_ISR_CHAN_NUMOF];
int gpio_init(gpio_t pin, gpio_mode_t mode) int gpio_init(gpio_t pin, gpio_mode_t mode)
{ {
if ((pin < 0) || (pin > 31)) if ((unsigned int)pin > 31)
return -1; return -1;
/* enable GPIO clock */ /* enable GPIO clock */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment