From: Samuel Holland Date: Tue, 31 Oct 2023 04:57:40 +0000 (-0500) Subject: pinctrl: sunxi: Avoid using .bss for SPL X-Git-Url: http://git.dujemihanovic.xyz/login.html?a=commitdiff_plain;h=0070d57c339061e4725909b3081d70b83c2132d1;p=u-boot.git pinctrl: sunxi: Avoid using .bss for SPL sunxi platforms put .bss in DRAM, so .bss is not available in SPL before DRAM controller initialization. Therefore, this buffer must be placed in the .data section. Signed-off-by: Samuel Holland Reviewed-by: Andre Przywara --- diff --git a/drivers/pinctrl/sunxi/pinctrl-sunxi.c b/drivers/pinctrl/sunxi/pinctrl-sunxi.c index bdf6360f17..37ea93715d 100644 --- a/drivers/pinctrl/sunxi/pinctrl-sunxi.c +++ b/drivers/pinctrl/sunxi/pinctrl-sunxi.c @@ -50,7 +50,7 @@ static const char *sunxi_pinctrl_get_pin_name(struct udevice *dev, uint pin_selector) { const struct sunxi_pinctrl_desc *desc = dev_get_priv(dev); - static char pin_name[sizeof("PN31")]; + static char pin_name[sizeof("PN31")] __section(".data"); snprintf(pin_name, sizeof(pin_name), "P%c%d", pin_selector / SUNXI_GPIOS_PER_BANK + desc->first_bank + 'A',