[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAK8P3a3RuOTidFpW7diHekJ6POV20SBb5PhSF943Ju1xAtOxNw@mail.gmail.com>
Date: Fri, 13 May 2022 14:59:24 +0200
From: Arnd Bergmann <arnd@...db.de>
To: Greg Ungerer <gerg@...ux-m68k.org>
Cc: Geert Uytterhoeven <geert@...ux-m68k.org>,
"Linux/m68k" <linux-m68k@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Arnd Bergmann <arnd@...db.de>,
kernel test robot <lkp@...el.com>
Subject: Re: [PATCH] m68knommu: fix undefined reference to `mach_get_rtc_pll'
On Fri, May 13, 2022 at 2:25 PM Greg Ungerer <gerg@...ux-m68k.org> wrote:
> On 13/5/22 17:12, Geert Uytterhoeven wrote:
> > read_persistent_clock64() uses mach_hwclk(), which is provided by
> > both setup_mm.c and setup_no.c, so it's always available?> Albeit not populated by coldfire or nommu platform code, so I see
> > the point in depending on MMU (no nommu Amiga support yet ;-).
>
> Yes, exactly. And even worse is that on ColdFire platforms it
> is never set, so will be the startup value of NULL. It is called
> without checking for NULL in both of rtc_generic_get_time() and
> rtc_generic_set_time().
I think that's ok because rtc_generic_{get,set}_time is only called
from the rtc_generic driver, but that is not registered when mach_hwclk()
is NULL.
With your patch to add the CONFIG_MMU check, you can actually
remove the mach_hwclk() symbol from setup_no.c, and move the
remaining RTC related symbols from setup_mm.c into the #ifdef.
Arnd
Powered by blists - more mailing lists