-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Closed
Labels
RegressionSomething, which was working, does not anymoreSomething, which was working, does not anymorebugThe issue is a bug, or the PR is fixing a bugThe issue is a bug, or the PR is fixing a bugplatform: Raspberry Pi PicoRaspberry Pi Pico (RPi Pico)Raspberry Pi Pico (RPi Pico)priority: lowLow impact/importance bugLow impact/importance bug
Description
Describe the bug
Prior to #71074 it was possible to use the uart_pl011 driver with the rpi_pico.
After this pull request the build fails.
To Reproduce
- Add the pl011 driver to a rpi_pico based board:
&uart0 {
compatible = "arm,pl011";
/delete-property/ resets;
pinctrl-0 = <&uart0_default>;
pinctrl-names = "default";
current-speed = <115200>;
status = "okay";
clocks = <&clk_peri>;
};
-
Try to build with
west build -
Switching to a commit prior to drivers: serial: rpi_pico: Migrate to pl011 driver #71074 works (e.g 5f6a68a)
Expected behavior
A clean build.
Impact
Driver is not usable.
Logs and console output
Build log:
/data/projects/u2c/firmware_dwt9946/build/app/zephyr/include/generated/devicetree_generated.h:6857:32: error: 'DT_N_S_soc_S_uart_40038000_P_clocks_IDX_0_VAL_ARM_PL011_CLOCK_CTLR_SUBSYS_CELL' undeclared here (not in a function)
6857 | #define DT_N_INST_1_arm_pl011 DT_N_S_soc_S_uart_40038000
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:72:26: note: in definition of macro '__DEBRACKET'
72 | #define __DEBRACKET(...) __VA_ARGS__
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:64:9: note: in expansion of macro '__GET_ARG2_DEBRACKET'
64 | __GET_ARG2_DEBRACKET(one_or_two_args _if_code, _else_code)
| ^~~~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:59:9: note: in expansion of macro '__COND_CODE'
59 | __COND_CODE(_XXXX##_flag, _if_1_code, _else_code)
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_macro.h:180:9: note: in expansion of macro 'Z_COND_CODE_1'
180 | Z_COND_CODE_1(_flag, _if_1_code, _else_code)
| ^~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree.h:4263:9: note: in expansion of macro 'COND_CODE_1'
4263 | COND_CODE_1(DT_HAS_COMPAT_STATUS_OKAY(DT_DRV_COMPAT), \
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:69:53: note: in expansion of macro '__DEBRACKET'
69 | #define __GET_ARG2_DEBRACKET(ignore_this, val, ...) __DEBRACKET val
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:64:9: note: in expansion of macro '__GET_ARG2_DEBRACKET'
64 | __GET_ARG2_DEBRACKET(one_or_two_args _if_code, _else_code)
| ^~~~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:59:9: note: in expansion of macro '__COND_CODE'
59 | __COND_CODE(_XXXX##_flag, _if_1_code, _else_code)
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_macro.h:180:9: note: in expansion of macro 'Z_COND_CODE_1'
180 | Z_COND_CODE_1(_flag, _if_1_code, _else_code)
| ^~~~~~~~~~~~~
/data/projects/u2c/zephyr/drivers/serial/uart_pl011.c:571:9: note: in expansion of macro 'COND_CODE_1'
571 | COND_CODE_1(DT_NODE_HAS_COMPAT(DT_INST_CLOCKS_CTLR(n), fixed_clock), (), \
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree.h:1362:9: note: in expansion of macro 'DT_CAT7'
1362 | DT_CAT7(node_id, _P_, pha, _IDX_, idx, _VAL_, cell)
| ^~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree/clocks.h:208:9: note: in expansion of macro 'DT_PHA_BY_IDX'
208 | DT_PHA_BY_IDX(node_id, clocks, idx, cell)
| ^~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree/clocks.h:327:9: note: in expansion of macro 'DT_CLOCKS_CELL_BY_IDX'
327 | DT_CLOCKS_CELL_BY_IDX(DT_DRV_INST(inst), idx, cell)
| ^~~~~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:105:36: note: in expansion of macro 'DT_N_INST_1_arm_pl011'
105 | #define UTIL_PRIMITIVE_CAT(a, ...) a##__VA_ARGS__
| ^
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:104:26: note: in expansion of macro 'UTIL_PRIMITIVE_CAT'
104 | #define UTIL_CAT(a, ...) UTIL_PRIMITIVE_CAT(a, __VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree.h:336:31: note: in expansion of macro 'UTIL_CAT'
336 | #define DT_INST(inst, compat) UTIL_CAT(DT_N_INST, DT_DASH(inst, compat))
| ^~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree.h:3413:27: note: in expansion of macro 'DT_INST'
3413 | #define DT_DRV_INST(inst) DT_INST(inst, DT_DRV_COMPAT)
| ^~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree/clocks.h:327:31: note: in expansion of macro 'DT_DRV_INST'
327 | DT_CLOCKS_CELL_BY_IDX(DT_DRV_INST(inst), idx, cell)
| ^~~~~~~~~~~
/data/projects/u2c/zephyr/include/zephyr/devicetree/clocks.h:348:9: note: in expansion of macro 'DT_INST_CLOCKS_CELL_BY_IDX'
348 | DT_INST_CLOCKS_CELL_BY_IDX(inst, 0, cell)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/drivers/serial/uart_pl011.c:573:58: note: in expansion of macro 'DT_INST_CLOCKS_CELL'
573 | .clock_id = (clock_control_subsys_t)DT_INST_CLOCKS_CELL(n, \
| ^~~~~~~~~~~~~~~~~~~
/data/projects/u2c/zephyr/drivers/serial/uart_pl011.c:618:17: note: in expansion of macro 'CLOCK_INIT'
618 | CLOCK_INIT(n) \
| ^~~~~~~~~~
/data/projects/u2c/zephyr/drivers/serial/uart_pl011.c:636:9: note: in expansion of macro 'PL011_CONFIG_PORT'
636 | PL011_CONFIG_PORT(n) \
| ^~~~~~~~~~~~~~~~~
/data/projects/u2c/firmware_dwt9946/build/app/zephyr/include/generated/devicetree_generated.h:8316:50: note: in expansion of macro 'PL011_INIT'
8316 | #define DT_FOREACH_OKAY_INST_arm_pl011(fn) fn(0) fn(1)
| ^~
/data/projects/u2c/zephyr/include/zephyr/sys/util_internal.h:105:36: note: in expansion of macro 'DT_FOREACH_OKAY_INST_arm_pl011'
105 | #define UTIL_PRIMITIVE_CAT(a, ...) a##__VA_ARGS__
| ^
/data/projects/u2c/zephyr/drivers/serial/uart_pl011.c:659:1: note: in expansion of macro 'DT_INST_FOREACH_STATUS_OKAY'
659 | DT_INST_FOREACH_STATUS_OKAY(PL011_INIT)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
Environment (please complete the following information):
- Toolchain: zephyr sdk 0.16.3
- Zephyr Commit: 950382c
Metadata
Metadata
Assignees
Labels
RegressionSomething, which was working, does not anymoreSomething, which was working, does not anymorebugThe issue is a bug, or the PR is fixing a bugThe issue is a bug, or the PR is fixing a bugplatform: Raspberry Pi PicoRaspberry Pi Pico (RPi Pico)Raspberry Pi Pico (RPi Pico)priority: lowLow impact/importance bugLow impact/importance bug