zephyr/include/sys
Marc Herbert 61fe69dded sys: device_mmio.h replace <toolchain/common.h> with <toolchain.h>
In include/sys/device_mmio.h, replacing <toolchain/common.h>
fixes the following warning:

$ west build -b qemu_x86  tests/arch/x86/static_idt/

In file included from zephyr/include/toolchain.h:50,
             from zephyr/include/linker/section_tags.h:12,
             from zephyr/include/linker/sections.h:132,
             from zephyr/include/sys/device_mmio.h:19,
             from zephyr/include/drivers/interrupt_controller/loapic.h:14,
             from zephyr/include/drivers/interrupt_controller/sysapic.h:10,
             from zephyr/include/arch/x86/arch.h:231,
             from zephyr/include/arch/cpu.h:15,
             from zephyr/tests/arch/x86/static_idt/src/test_stubs.S:17:
zephyr/include/toolchain/gcc.h:61: error: BUILD_ASSERT redefined [-Werror]
   61 | #define BUILD_ASSERT(EXPR, MSG...) _Static_assert(EXPR, "" MSG)
      |
In file included from zephyr/include/sys/device_mmio.h:18,
             from zephyr/include/drivers/interrupt_controller/loapic.h:14,
             from zephyr/include/drivers/interrupt_controller/sysapic.h:10,
             from zephyr/include/arch/x86/arch.h:231,
             from zephyr/include/arch/cpu.h:15,
             from zephyr/tests/arch/x86/static_idt/src/test_stubs.S:17:
zephyr/include/toolchain/common.h:165: note: this is the location of the
  previous definition
  165 | #define BUILD_ASSERT(EXPR, MSG...) \

<toolchain.h> provides a compiler-specific BUILD_ASSERT.
<toolchain/common.h> provides a generic, fallback BUILD_ASSERT and
should probably never be included directly.

Thanks to Gerard Marull-Paretas for recommending this fix.

Related to commit af20208cd9 ("devices: mark device MMIO declarations
to boot/pinned sections") that added #include <linker/sections.h>

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
2022-01-07 12:47:31 -05:00
..
__assert.h assert: Add missing include 2021-12-14 11:47:13 -06:00
arch_interface.h drivers/pcie: Add a marco for fixed or MSI IRQ 2022-01-07 10:47:27 -05:00
atomic_arch.h
atomic_builtin.h
atomic_c.h
atomic.h kernel: atomics: support for 64-bit atomic operations 2021-11-15 09:59:01 -05:00
base64.h
bitarray.h lib/os: bitarray: introduce SYS_BITARRAY_DEFINE_STATIC() 2021-11-24 14:22:23 -05:00
byteorder.h
cbprintf_cxx.h sys: cbprintf: Fix unused arg warning 2021-12-14 11:47:13 -06:00
cbprintf_internal.h zephyr: fix errors when building with -Wundef 2021-12-14 11:47:13 -06:00
cbprintf.h lib: os: cbprintf: Add flags to CBPRINTF_MUST_RUNTIME_PACKAGE 2021-11-29 21:13:56 +01:00
check.h
crc.h
device_mmio.h sys: device_mmio.h replace <toolchain/common.h> with <toolchain.h> 2022-01-07 12:47:31 -05:00
dlist.h
errno_private.h
fdtable.h
heap_listener.h lib: os: add heap event listener 2021-12-18 07:49:15 -05:00
kobject.h sys: kobject: Fix header to avoid re-declaratiions 2021-10-02 14:34:14 -04:00
libc-hooks.h libc: minimal: Use new ZRESTRICT macro 2021-11-05 13:29:31 +01:00
list_gen.h
math_extras_impl.h
math_extras.h
mem_manage.h
mpsc_packet.h
mpsc_pbuf.h lib: os: mpsc_pbuf: Add const to mpsc_pbuf_free argument 2022-01-07 18:47:19 +01:00
multi_heap.h sys: multi_heap: add missing docstrings 2021-10-07 11:54:23 -04:00
mutex.h
notify.h doc: doxygen: replace option alias with kconfig 2021-06-29 10:26:28 -04:00
onoff.h
p4wq.h toolchain: migrate iterable sections calls to the external API 2021-08-12 17:47:04 -04:00
printk.h sys: printk: Fix LOG2 printk support in cpp code 2021-06-29 11:33:21 -04:00
rb.h
reboot.h lib: os: add gcc noreturn attribute for sys_reboot 2021-08-13 07:32:51 -04:00
ring_buffer.h ring_buffer: Link buffer data to the .noinit section 2021-08-21 21:32:45 -04:00
sem.h toolchain: migrate iterable sections calls to the external API 2021-08-12 17:47:04 -04:00
sflist.h
slist.h
speculation.h
sys_heap.h heap: add functions to get heap runtime statistics 2021-11-11 16:21:43 -05:00
sys_io.h include: common: Add sys_set_bits and set_clear_bits inline functions 2021-10-12 08:37:03 -04:00
time_units.h sys: time_units: Add SYS_FOREVER_US macro 2021-10-12 12:26:56 +02:00
timeutil.h
util_internal.h sys: util: improve IS_EMPTY() implementation 2021-11-11 09:31:57 -05:00
util_loops.h
util_macro.h sys: util: improve IS_EMPTY() implementation 2021-11-11 09:31:57 -05:00
util.h sys/util: Stricter bytecpy impl 2022-01-04 20:52:16 -05:00