[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230721080055.GB1908841@google.com>
Date: Fri, 21 Jul 2023 09:00:55 +0100
From: Lee Jones <lee@...nel.org>
To: Thierry Reding <thierry.reding@...il.com>
Cc: Arnd Bergmann <arnd@...nel.org>,
William Breathitt Gray <william.gray@...aro.org>,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>,
Biju Das <biju.das.jz@...renesas.com>,
Arnd Bergmann <arnd@...db.de>,
Peter Robinson <pbrobinson@...il.com>,
linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-pwm@...r.kernel.org
Subject: Re: [PATCH] mfd: rz-mtu3: link time dependencies
On Thu, 20 Jul 2023, Thierry Reding wrote:
> On Wed, Jul 19, 2023 at 11:02:23AM +0200, Arnd Bergmann wrote:
> > From: Arnd Bergmann <arnd@...db.de>
> >
> > The new set of drivers for RZ/G2L MTU3a tries to enable compile-testing the
> > individual client drivers even when the MFD portion is disabled but gets it
> > wrong, causing a link failure when the core is in a loadable module but the
> > other drivers are built-in:
> >
> > x86_64-linux-ld: drivers/pwm/pwm-rz-mtu3.o: in function `rz_mtu3_pwm_apply':
> > pwm-rz-mtu3.c:(.text+0x4bf): undefined reference to `rz_mtu3_8bit_ch_write'
> > x86_64-linux-ld: pwm-rz-mtu3.c:(.text+0x509): undefined reference to `rz_mtu3_disable'
> >
> > arm-linux-gnueabi-ld: drivers/counter/rz-mtu3-cnt.o: in function `rz_mtu3_cascade_counts_enable_get':
> > rz-mtu3-cnt.c:(.text+0xbec): undefined reference to `rz_mtu3_shared_reg_read'
> >
> > It seems better not to add the extra complexity here but instead just use
> > a normal hard dependency, so remove the #else portion in the header along
> > with the "|| COMPILE_TEST". This could also be fixed by having slightly more
> > elaborate Kconfig dependencies or using the cursed 'IS_REACHABLE()' helper,
> > but in practice it's already possible to compile-test all these drivers
> > by enabling the mtd portion.
> >
> > Fixes: 254d3a727421c ("pwm: Add Renesas RZ/G2L MTU3a PWM driver")
> > Fixes: 0be8907359df4 ("counter: Add Renesas RZ/G2L MTU3a counter driver")
> > Fixes: 654c293e1687b ("mfd: Add Renesas RZ/G2L MTU3a core driver")
> > Signed-off-by: Arnd Bergmann <arnd@...db.de>
> > ---
> > drivers/counter/Kconfig | 2 +-
> > drivers/pwm/Kconfig | 2 +-
> > include/linux/mfd/rz-mtu3.h | 66 -------------------------------------
> > 3 files changed, 2 insertions(+), 68 deletions(-)
>
> Assuming that Lee will pick this up:
>
> Acked-by: Thierry Reding <thierry.reding@...il.com>
Happy to. Can you do without a pull-request?
--
Lee Jones [李琼斯]
Powered by blists - more mailing lists