[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAK8P3a120ekWQzOLLfDF5jVHJ6XKpz5fKRrh8R-yk6S9PmoeTA@mail.gmail.com>
Date: Mon, 15 Aug 2022 14:44:42 +0200
From: Arnd Bergmann <arnd@...db.de>
To: Tony Lindgren <tony@...mide.com>
Cc: Daniel Lezcano <daniel.lezcano@...aro.org>,
Thomas Gleixner <tglx@...utronix.de>,
linux-kernel@...r.kernel.org, linux-omap@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
kernel test robot <lkp@...el.com>
Subject: Re: [PATCH] clocksource/drivers/timer-ti-dm: Fix compile test warning
On Mon, Aug 15, 2022 at 2:03 PM Tony Lindgren <tony@...mide.com> wrote:
>
> We can get a warning with COMPILE_TEST enabled for omap_timer_match
> for 'omap_timer_match' defined but not used.
>
> Fixes: ab0bbef3ae0f ("clocksource/drivers/timer-ti-dm: Make timer selectable for ARCH_K3")
> Reported-by: kernel test robot <lkp@...el.com>
> Signed-off-by: Tony Lindgren <tony@...mide.com>
> ---
> drivers/clocksource/timer-ti-dm.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clocksource/timer-ti-dm.c b/drivers/clocksource/timer-ti-dm.c
> --- a/drivers/clocksource/timer-ti-dm.c
> +++ b/drivers/clocksource/timer-ti-dm.c
> @@ -1040,7 +1040,7 @@ static const struct dmtimer_platform_data am6_pdata = {
> .timer_ops = &dmtimer_ops,
> };
>
> -static const struct of_device_id omap_timer_match[] = {
> +static const __maybe_unused struct of_device_id omap_timer_match[] = {
> {
> .compatible = "ti,omap2420-timer",
> },
I think a better way to address this is to remove the of_match_ptr()
usage from the driver. The only reason to use of_match_ptr() is to save
a few bytes on machines that don't have CONFIG_OF enabled, but this
driver is not used on such machines any more.
Arnd
Powered by blists - more mailing lists