• Arnd Bergmann's avatar
    ARM: at91: fix at91_suspend_entering_slow_clock link error · be36e000
    Arnd Bergmann authored
    When CONFIG_ARCH_AT91 is enabled, but none of the specific SoC support
    is in use, some at91 specific drivers fail to link:
    
    drivers/tty/serial/atmel_serial.o: In function `atmel_serial_suspend':
    atmel_serial.c:(.text.atmel_serial_suspend+0x1e): undefined reference to `at91_suspend_entering_slow_clock'
    drivers/usb/host/ohci-at91.o: In function `ohci_hcd_at91_drv_suspend':
    ohci-at91.c:(.text.ohci_hcd_at91_drv_suspend+0x12): undefined reference to `at91_suspend_entering_slow_clock'
    drivers/usb/gadget/udc/at91_udc.o: In function `at91udc_suspend':
    at91_udc.c:(.text.at91udc_suspend+0x26): undefined reference to `at91_suspend_entering_slow_clock'
    
    This changes the at91_suspend_entering_slow_clock hack once more, adding
    an alternative inline implementation that is used exactly in those cases
    that don't provide the normal implementation.
    
    Fixes: c1892c2379d2 ("ARM: at91: handle CONFIG_PM for armv7m configurations")
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@free-electrons.com>
    be36e000
samv7.c 559 Bytes