-
Notifications
You must be signed in to change notification settings - Fork 6.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
drivers: build as static library #37512
Changes from all commits
1a39fa9
32ee069
a5a1bf3
0c54532
c7e41a0
1ddbe0e
0d6447c
e276247
740dc80
cff1391
e93cf92
564d81e
8004561
5eac434
8d4cc5f
8765e20
23f789f
cd761a5
0c89ba1
96de8bb
f53293e
3c5a1f3
39adc50
3939d1f
12fc20a
5bd9101
545b005
231255f
5aa4b73
32b0281
300b6c1
56aa254
0625eac
2d4cefb
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_include_directories(${ZEPHYR_BASE}/subsys/bluetooth) | ||
zephyr_library() | ||
zephyr_library_include_directories(${ZEPHYR_BASE}/subsys/bluetooth) | ||
add_subdirectory(hci) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_BT_H4 h4.c) | ||
zephyr_sources_ifdef(CONFIG_BT_H5 h5.c) | ||
zephyr_sources_ifdef(CONFIG_BT_SPI spi.c) | ||
zephyr_sources_ifdef(CONFIG_BT_RPMSG rpmsg.c) | ||
zephyr_sources_ifdef(CONFIG_BT_RPMSG_NRF53 rpmsg_nrf53.c) | ||
zephyr_sources_ifdef(CONFIG_BT_STM32_IPM ipm_stm32wb.c) | ||
zephyr_sources_ifdef(CONFIG_BT_USERCHAN userchan.c) | ||
zephyr_sources_ifdef(CONFIG_BT_ESP32 hci_esp32.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_ESP32 hci_esp32.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_H4 h4.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_H5 h5.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_RPMSG rpmsg.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_RPMSG_NRF53 rpmsg_nrf53.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_SPI spi.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_STM32_IPM ipm_stm32wb.c) | ||
zephyr_library_sources_ifdef(CONFIG_BT_USERCHAN userchan.c) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,16 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_CAN can_common.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_LOOPBACK can_loopback.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_MCP2515 can_mcp2515.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_STM32 can_stm32.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_STM32FD can_stm32fd.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_MCAN can_mcan.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_MCUX_FLEXCAN can_mcux_flexcan.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_RCAR can_rcar.c) | ||
zephyr_library() | ||
|
||
zephyr_sources_ifdef(CONFIG_USERSPACE can_handlers.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_SHELL can_shell.c) | ||
zephyr_sources_ifdef(CONFIG_CAN_NET can_net.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN can_common.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_LOOPBACK can_loopback.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_MCAN can_mcan.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_MCP2515 can_mcp2515.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_MCUX_FLEXCAN can_mcux_flexcan.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_STM32 can_stm32.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_STM32FD can_stm32fd.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_RCAR can_rcar.c) | ||
|
||
zephyr_library_sources_ifdef(CONFIG_USERSPACE can_handlers.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_SHELL can_shell.c) | ||
zephyr_library_sources_ifdef(CONFIG_CAN_NET can_net.c) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,49 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_BEETLE beetle_clock_control.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_LPC11U6X clock_control_lpc11u6x.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_CCM clock_control_mcux_ccm.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_CCM_REV2 clock_control_mcux_ccm_rev2.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_MCG clock_control_mcux_mcg.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_PCC clock_control_mcux_pcc.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_SCG clock_control_mcux_scg.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_SIM clock_control_mcux_sim.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_SYSCON clock_control_mcux_syscon.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_NPCX clock_control_npcx.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_NRF clock_control_nrf.c) | ||
zephyr_library() | ||
|
||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_BEETLE beetle_clock_control.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_ESP32 clock_control_esp32.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_LITEX clock_control_litex.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_LPC11U6X clock_control_lpc11u6x.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCHP_XEC clock_control_mchp_xec.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_CCM clock_control_mcux_ccm.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_CCM_REV2 clock_control_mcux_ccm_rev2.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_MCG clock_control_mcux_mcg.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_PCC clock_control_mcux_pcc.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_SCG clock_control_mcux_scg.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_SIM clock_control_mcux_sim.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_MCUX_SYSCON clock_control_mcux_syscon.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_NPCX clock_control_npcx.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_NRF clock_control_nrf.c) | ||
if(CONFIG_CLOCK_CONTROL_NRF_K32SRC_RC_CALIBRATION AND NOT CONFIG_CLOCK_CONTROL_NRF_FORCE_ALT) | ||
zephyr_sources(nrf_clock_calibration.c) | ||
zephyr_library_sources(nrf_clock_calibration.c) | ||
endif() | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_RV32M1_PCC clock_control_rv32m1_pcc.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_ESP32 clock_control_esp32.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_LITEX clock_control_litex.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_RCAR_CPG_MSSR clock_control_rcar_cpg_mssr.c) | ||
zephyr_sources_ifdef(CONFIG_CLOCK_CONTROL_MCHP_XEC clock_control_mchp_xec.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_RCAR_CPG_MSSR clock_control_rcar_cpg_mssr.c) | ||
zephyr_library_sources_ifdef(CONFIG_CLOCK_CONTROL_RV32M1_PCC clock_control_rv32m1_pcc.c) | ||
|
||
if(CONFIG_CLOCK_CONTROL_STM32_CUBE) | ||
if(CONFIG_SOC_SERIES_STM32MP1X) | ||
zephyr_sources(clock_stm32_ll_mp1.c) | ||
zephyr_library_sources(clock_stm32_ll_mp1.c) | ||
elseif(CONFIG_SOC_SERIES_STM32H7X) | ||
zephyr_sources(clock_stm32_ll_h7.c) | ||
zephyr_library_sources(clock_stm32_ll_h7.c) | ||
elseif(CONFIG_SOC_SERIES_STM32U5X) | ||
zephyr_sources(clock_stm32_ll_u5.c) | ||
zephyr_library_sources(clock_stm32_ll_u5.c) | ||
else() | ||
zephyr_sources(clock_stm32_ll_common.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32F0X clock_stm32f0_f3.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32F1X clock_stm32f1.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32F2X clock_stm32f2_f4_f7.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32F3X clock_stm32f0_f3.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32F4X clock_stm32f2_f4_f7.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32F7X clock_stm32f2_f4_f7.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32G0X clock_stm32g0.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32L0X clock_stm32l0_l1.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32L1X clock_stm32l0_l1.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32L4X clock_stm32l4_l5_wb_wl.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32L5X clock_stm32l4_l5_wb_wl.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32WBX clock_stm32l4_l5_wb_wl.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32G4X clock_stm32g4.c) | ||
zephyr_sources_ifdef(CONFIG_SOC_SERIES_STM32WLX clock_stm32l4_l5_wb_wl.c) | ||
zephyr_library_sources(clock_stm32_ll_common.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32F0X clock_stm32f0_f3.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32F1X clock_stm32f1.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32F2X clock_stm32f2_f4_f7.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32F3X clock_stm32f0_f3.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32F4X clock_stm32f2_f4_f7.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32F7X clock_stm32f2_f4_f7.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32G0X clock_stm32g0.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32G4X clock_stm32g4.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32L0X clock_stm32l0_l1.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32L1X clock_stm32l0_l1.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32L4X clock_stm32l4_l5_wb_wl.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32L5X clock_stm32l4_l5_wb_wl.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32WBX clock_stm32l4_l5_wb_wl.c) | ||
zephyr_library_sources_ifdef(CONFIG_SOC_SERIES_STM32WLX clock_stm32l4_l5_wb_wl.c) | ||
endif() | ||
endif() |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,16 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_UART_CONSOLE uart_console.c) | ||
zephyr_sources_ifdef(CONFIG_RAM_CONSOLE ram_console.c) | ||
zephyr_sources_ifdef(CONFIG_RTT_CONSOLE rtt_console.c) | ||
zephyr_sources_ifdef(CONFIG_IPM_CONSOLE_RECEIVER ipm_console_receiver.c) | ||
zephyr_sources_ifdef(CONFIG_IPM_CONSOLE_SENDER ipm_console_sender.c) | ||
zephyr_sources_ifdef(CONFIG_IPM_CONSOLE ipm_console.c) | ||
zephyr_sources_ifdef(CONFIG_UART_MCUMGR uart_mcumgr.c) | ||
zephyr_sources_ifdef(CONFIG_UART_PIPE uart_pipe.c) | ||
zephyr_sources_ifdef(CONFIG_XTENSA_SIM_CONSOLE xtensa_sim_console.c) | ||
zephyr_sources_ifdef(CONFIG_NATIVE_POSIX_CONSOLE native_posix_console.c) | ||
zephyr_sources_ifdef(CONFIG_UART_MUX uart_mux.c) | ||
zephyr_sources_ifdef(CONFIG_GSM_MUX gsm_mux.c) | ||
zephyr_sources_ifdef(CONFIG_SEMIHOST_CONSOLE semihost_console.c) | ||
zephyr_library() | ||
zephyr_library_sources_ifdef(CONFIG_GSM_MUX gsm_mux.c) | ||
zephyr_library_sources_ifdef(CONFIG_IPM_CONSOLE_RECEIVER ipm_console_receiver.c) | ||
zephyr_library_sources_ifdef(CONFIG_IPM_CONSOLE_SENDER ipm_console_sender.c) | ||
zephyr_library_sources_ifdef(CONFIG_IPM_CONSOLE ipm_console.c) | ||
zephyr_library_sources_ifdef(CONFIG_NATIVE_POSIX_CONSOLE native_posix_console.c) | ||
zephyr_library_sources_ifdef(CONFIG_RAM_CONSOLE ram_console.c) | ||
zephyr_library_sources_ifdef(CONFIG_RTT_CONSOLE rtt_console.c) | ||
zephyr_library_sources_ifdef(CONFIG_SEMIHOST_CONSOLE semihost_console.c) | ||
zephyr_library_sources_ifdef(CONFIG_UART_CONSOLE uart_console.c) | ||
zephyr_library_sources_ifdef(CONFIG_UART_MCUMGR uart_mcumgr.c) | ||
zephyr_library_sources_ifdef(CONFIG_UART_MUX uart_mux.c) | ||
zephyr_library_sources_ifdef(CONFIG_UART_PIPE uart_pipe.c) | ||
zephyr_library_sources_ifdef(CONFIG_XTENSA_SIM_CONSOLE xtensa_sim_console.c) |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -323,7 +323,7 @@ config XTENSA_CONSOLE_INIT_PRIORITY | |
|
||
config NATIVE_POSIX_CONSOLE_INIT_PRIORITY | ||
int "Init priority" | ||
default 60 | ||
default 99 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What does this change have to do with building drivers as a static library? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is due to linking order. For example, if both native POSIX console and UART console are enabled, the UART console driver takes over the printk hook which means there is nothing being printed to the terminal. Tests are failing due to empty outputs. |
||
depends on NATIVE_POSIX_CONSOLE | ||
help | ||
Device driver initialization priority. | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,15 @@ | ||
# Copyright (c) 2021 Nordic Semiconductor ASA | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_DISK_DRIVER_RAM ramdisk.c) | ||
zephyr_sources_ifdef(CONFIG_DISK_DRIVER_FLASH flashdisk.c) | ||
zephyr_sources_ifdef(CONFIG_SDMMC_OVER_SPI sdmmc_spi.c) | ||
zephyr_sources_ifdef(CONFIG_SDMMC_USDHC usdhc.c) | ||
zephyr_sources_ifdef(CONFIG_SDMMC_STM32 sdmmc_stm32.c) | ||
if(CONFIG_DISK_DRIVERS) | ||
|
||
zephyr_library() | ||
|
||
zephyr_library_sources_ifdef(CONFIG_DISK_DRIVER_FLASH flashdisk.c) | ||
zephyr_library_sources_ifdef(CONFIG_DISK_DRIVER_RAM ramdisk.c) | ||
|
||
zephyr_library_sources_ifdef(CONFIG_SDMMC_OVER_SPI sdmmc_spi.c) | ||
zephyr_library_sources_ifdef(CONFIG_SDMMC_STM32 sdmmc_stm32.c) | ||
zephyr_library_sources_ifdef(CONFIG_SDMMC_USDHC usdhc.c) | ||
|
||
endif() |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,23 @@ | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_DISPLAY_MCUX_ELCDIF display_mcux_elcdif.c) | ||
zephyr_sources_ifdef(CONFIG_GROVE_LCD_RGB grove_lcd_rgb.c) | ||
zephyr_sources_ifdef(CONFIG_SSD1306 ssd1306.c) | ||
zephyr_sources_ifdef(CONFIG_SSD16XX ssd16xx.c) | ||
zephyr_sources_ifdef(CONFIG_SDL_DISPLAY display_sdl.c) | ||
zephyr_sources_ifdef(CONFIG_DUMMY_DISPLAY display_dummy.c) | ||
zephyr_sources_ifdef(CONFIG_FRAMEBUF_DISPLAY display_framebuf.c) | ||
zephyr_sources_ifdef(CONFIG_ST7789V display_st7789v.c) | ||
zephyr_sources_ifdef(CONFIG_ST7735R display_st7735r.c) | ||
zephyr_sources_ifdef(CONFIG_GD7965 gd7965.c) | ||
zephyr_sources_ifdef(CONFIG_LS0XX ls0xx.c) | ||
zephyr_library() | ||
zephyr_library_sources_ifdef(CONFIG_DISPLAY_MCUX_ELCDIF display_mcux_elcdif.c) | ||
zephyr_library_sources_ifdef(CONFIG_DUMMY_DISPLAY display_dummy.c) | ||
zephyr_library_sources_ifdef(CONFIG_FRAMEBUF_DISPLAY display_framebuf.c) | ||
zephyr_library_sources_ifdef(CONFIG_GD7965 gd7965.c) | ||
zephyr_library_sources_ifdef(CONFIG_GROVE_LCD_RGB grove_lcd_rgb.c) | ||
zephyr_library_sources_ifdef(CONFIG_ILI9XXX display_ili9xxx.c) | ||
zephyr_library_sources_ifdef(CONFIG_ILI9340 display_ili9340.c) | ||
zephyr_library_sources_ifdef(CONFIG_ILI9341 display_ili9341.c) | ||
zephyr_library_sources_ifdef(CONFIG_ILI9488 display_ili9488.c) | ||
zephyr_library_sources_ifdef(CONFIG_LS0XX ls0xx.c) | ||
zephyr_library_sources_ifdef(CONFIG_SDL_DISPLAY display_sdl.c) | ||
zephyr_library_sources_ifdef(CONFIG_SSD1306 ssd1306.c) | ||
zephyr_library_sources_ifdef(CONFIG_SSD16XX ssd16xx.c) | ||
zephyr_library_sources_ifdef(CONFIG_ST7789V display_st7789v.c) | ||
zephyr_library_sources_ifdef(CONFIG_ST7735R display_st7735r.c) | ||
|
||
if (CONFIG_ILI9XXX) | ||
zephyr_sources(display_ili9xxx.c) | ||
endif() | ||
zephyr_sources_ifdef(CONFIG_ILI9340 display_ili9340.c) | ||
zephyr_sources_ifdef(CONFIG_ILI9341 display_ili9341.c) | ||
zephyr_sources_ifdef(CONFIG_ILI9488 display_ili9488.c) | ||
|
||
zephyr_sources_ifdef(CONFIG_MICROBIT_DISPLAY | ||
zephyr_library_sources_ifdef(CONFIG_MICROBIT_DISPLAY | ||
mb_display.c | ||
mb_font.c | ||
) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
# Copyright (c) 2020 Intel Corporation | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
zephyr_sources_ifdef(CONFIG_EDAC_IBECC edac_ibecc.c) | ||
zephyr_sources_ifdef(CONFIG_EDAC_SHELL shell.c) | ||
zephyr_library() | ||
|
||
zephyr_library_sources_ifdef(CONFIG_EDAC_IBECC edac_ibecc.c) | ||
zephyr_library_sources_ifdef(CONFIG_EDAC_SHELL shell.c) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this change have to do with building drivers as a static library?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
arm64_smp_init()
has the same init level and priority as the GICv3 interrupt controller. The linking order is affected by the interrupt controller driver being inside a static library, resulting in the interrupt controller being initialized later thanarm64_smp_init()
. There are hard faults runningarm64_smp_init()
as it is setting up IRQs for IPI. This change is simply to make sure the interrupt controller is initialized first.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gotcha, thanks. Could you mention in the commit message that you found this while converting the interrupt controller drivers to build in a static library?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is under a separate commit (1c15674) with explanation in the commit message.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The commit message doesn't mention why the link order changed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah... because that commit is before the changes on driver. I have updated the commit message to say that it is in preparation for the driver changes. Does this work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, thanks