pinmux: Fix using wrong variable name
In the pinmux_dev driver for the Quark SE development board in pinmux_dev_set() the variable 'mode' was used, but it should have been 'func'. This was causing a compilation error: /home/vinicius/work/zephyr/boards/quark_se_devboard/pinmux.c: In function 'pinmux_dev_set': /home/vinicius/work/zephyr/boards/quark_se_devboard/pinmux.c:245:23: error: 'mode' undeclared (first use in this function) uint32_t mode_mask = mode << (pin_no << 1); Change-Id: I5b9df7c6b488dc5b8819fcf59bb3b994d9d4820b Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@intel.com>
This commit is contained in:
parent
4a4e82b0c5
commit
0efdb22ae5
|
@ -242,7 +242,7 @@ static uint32_t pinmux_dev_set(struct device *dev, uint32_t pin, uint8_t func)
|
|||
* pin. The value 2 repesents the bits needed for each pin's mode.
|
||||
*/
|
||||
uint32_t pin_mask = MASK_2_BITS << (pin_no << 1);
|
||||
uint32_t mode_mask = mode << (pin_no << 1);
|
||||
uint32_t mode_mask = func << (pin_no << 1);
|
||||
(*(mux_register)) = ((*(mux_register)) & ~pin_mask) | mode_mask;
|
||||
|
||||
return DEV_OK;
|
||||
|
|
Loading…
Reference in New Issue