Thread (9 messages) 9 messages, 4 authors, 2024-02-28

Re: Increasing build coverage for drivers/spi/spi-ppc4xx.c

From: Michael Ellerman <mpe@ellerman.id.au>
Date: 2024-02-28 05:38:10
Also in: linux-spi
Subsystem: linux for powerpc (32-bit and 64-bit), the rest · Maintainers: Madhavan Srinivasan, Michael Ellerman, Linus Torvalds

Christophe Leroy [off-list ref] writes:
Le 27/02/2024 à 15:00, Uwe Kleine-König a écrit :
quoted
On Tue, Feb 27, 2024 at 01:52:07PM +0000, Christophe Leroy wrote:
quoted
Le 27/02/2024 à 11:58, Uwe Kleine-König a écrit :
quoted
On Tue, Feb 27, 2024 at 10:25:15AM +0000, Christophe Leroy wrote:
quoted
Le 27/02/2024 à 09:46, Uwe Kleine-König a écrit :
quoted
recently the spi-ppc4xx.c driver suffered from build errors and warnings
that were undetected for longer than I expected. I think it would be
very beneficial if this driver was enabled in (at least) a powerpc
allmodconfig build.

The challenge to do so is that spi-ppc4xx.c uses dcri_clrset() which is
only defined for 4xx (as these select PPC_DCR_NATIVE).
...
quoted
The reason I'd like to see it in allmodconfig is that testing
allmodconfig on several archs is the check I do for my patch series.
I think for powerpc you should really check ppc32_allmodconfig in 
addition to allmodconfig
Yeah.

arch/powerpc is really ~7 separate sub architectures.

Building allmodconfig and ppc32_allmodconfig at least covers the bulk of
the code. But it doesn't include 4xx, or several other platforms.

I think the best/easiest option is just to enable this driver in the 44x
defconfig. At least that way the auto builders should catch any problems.

eg.
diff --git a/arch/powerpc/configs/ppc44x_defconfig b/arch/powerpc/configs/ppc44x_defconfig
index 8b595f67068c..95a1e7efb79f 100644
--- a/arch/powerpc/configs/ppc44x_defconfig
+++ b/arch/powerpc/configs/ppc44x_defconfig
@@ -67,6 +67,8 @@ CONFIG_I2C=m
 CONFIG_I2C_CHARDEV=m
 CONFIG_I2C_GPIO=m
 CONFIG_I2C_IBM_IIC=m
+CONFIG_SPI=y
+CONFIG_SPI_PPC4xx=y
 # CONFIG_HWMON is not set
 CONFIG_FB=m
 CONFIG_USB=m
cheers
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help