u-boot/arch/arm/include/asm/mach-imx
Marek Vasut 3f7afddc9c ARM: imx: bootaux: Fix LTO -Wlto-type-mismatch
Commit 56c2dbdaba ("imx: bootaux: cleanup code") introduces the
following LTO related warning:

"
arch/arm/mach-imx/imx_bootaux.c:24:31: warning: type of ‘hostmap’ does not match original declaration [-Wlto-type-mismatch]
   24 | const __weak struct rproc_att hostmap[] = { };
      |                               ^
arch/arm/mach-imx/imx8m/soc.c:1590:24: note: array types have different bounds
 1590 | const struct rproc_att hostmap[] = {
      |                        ^
arch/arm/mach-imx/imx8m/soc.c:1590:24: note: ‘hostmap’ was previously declared here
../aarch64-linux-gnu/bin/ld: warning: u-boot has a LOAD segment with RWX permissions
"

This is because the weak empty array of structures "hostmap" is eventually
replaced by non-empty array of structures with different number of elements.
Fix this by avoiding weak variable size array, instead use a weak function
which returns single pointer to the array.

Fixes: 56c2dbdaba ("imx: bootaux: cleanup code")
Signed-off-by: Marek Vasut <marex@denx.de>
Reviewed-by: Peng Fan <peng.fan@nxp.com>
2023-01-30 23:23:02 +01:00
..
boot_mode.h imx: add USB2_BOOT type 2022-07-26 11:29:00 +02:00
dma.h
gpio.h
hab.h mx6dq: hab: Fix chip version in hab.h code 2021-04-08 09:18:29 +02:00
image.h arm: imx8ulp: add container support 2021-08-09 14:46:50 +02:00
imx-nandbcb.h
imximage.cfg
iomux-v3.h imx: add basic i.MX9 support 2022-07-26 11:29:00 +02:00
module_fuse.h
mu_hal.h misc: imx: S400_API: Move S400 MU and API to a common place 2022-07-26 11:29:00 +02:00
mx5_video.h video: Drop references to CONFIG_VIDEO et al 2022-03-28 20:17:07 +02:00
mxc_i2c.h dm: i2c: use CONFIG_IS_ENABLED macro for DM_I2C/DM_I2C_GPIO 2021-02-21 06:08:00 +01:00
rdc-sema.h
regs-apbh.h
regs-bch.h
regs-common.h
regs-gpmi.h imx: gpmi: Add register needed to control nand bus timing 2022-10-09 10:42:26 +02:00
regs-lcdif.h
regs-usbphy.h
s400_api.h misc: S400_API: Rename imx8ulp_s400_msg to sentinel_msg 2022-07-26 11:29:01 +02:00
sata.h
spi.h
sys_proto.h ARM: imx: bootaux: Fix LTO -Wlto-type-mismatch 2023-01-30 23:23:02 +01:00
syscounter.h
video.h