[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAK8P3a0K973ggjPStn+qe1w_NqwV_C4up+k2mcG8uV5fV0+cnA@mail.gmail.com>
Date: Thu, 10 Mar 2022 11:29:47 +0100
From: Arnd Bergmann <arnd@...db.de>
To: Will Deacon <will@...nel.org>
Cc: Arnd Bergmann <arnd@...db.de>, YueHaibing <yuehaibing@...wei.com>,
Mark Rutland <mark.rutland@....com>,
Bharat Bhushan <bbhushan2@...vell.com>, bbudiredla@...vell.com,
Linux ARM <linux-arm-kernel@...ts.infradead.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 -next] perf/marvell: cn10k Fix build error without CONFIG_OF
On Thu, Mar 10, 2022 at 11:21 AM Will Deacon <will@...nel.org> wrote:
> On Thu, Mar 10, 2022 at 11:04:21AM +0100, Arnd Bergmann wrote:
> > On Thu, Mar 10, 2022 at 10:58 AM Will Deacon <will@...nel.org> wrote:
>
> I think the problem is when the #ifdefs are removed but the use of
> of_match_ptr() remains, leading to reports from the robot:
>
> https://lore.kernel.org/r/202201041700.01KZEzhb-lkp@intel.com
>
> Should we therefore remove of_match_ptr() altogether? It seems like it's
> leading people in the wrong direction here.
There may be valid uses for it, e.g. if the array referenced by it is
in a separate, and conditionally compiled file, or if the #ifdef block
covers more than just the table.
Removing 1563 instances of it also takes a lot of work. Almost
all of them are probably useless, and quite a lot of them are
actively wrong, because they refer to arrays without an #ifdef.
Maybe coccinelle can help here.
Arnd
Powered by blists - more mailing lists