From nobody Tue Dec 16 11:45:15 2025 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9816F22A4FC for ; Mon, 7 Apr 2025 07:27:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744010870; cv=none; b=WiHR4/SlpAasskNFolg4iWEDE9y8WiMQPtIAgwF1eYNV6A3QYTI4TL/H1h97mYlYgoK9dSW14Opaw/kfTRmCeI55hBmQZdPzo2+5DihRPg/8zBrjbyfOmWWjk2fVROQXbGoSFJbVq+QZBN6bQJ0QSBS7MT8wA4nCBwXX0Xa+llw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1744010870; c=relaxed/simple; bh=R1GWFoYuoKhtrKRR83vBYR9KoCi0p9VDekqu42J5Cps=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=sKRlwW2C5T8tbA2NBQLAQ5l1pT7Ega0gzVZvn+AzHfFVdFYcrR73VEhEfX04nN9R6n+6wj06RGEnKLgvjCZ4iooq2itoXKKT6uCzlneUc7FQ2TiAemd4Sqd7PYD/6KG7vKpYoFk9O3CpDiHUL1xmEJYophP6SxZVngHBvD7VCCc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=TAqQ7o68; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="TAqQ7o68" Received: by smtp.kernel.org (Postfix) with ESMTPSA id DD250C4CEDD; Mon, 7 Apr 2025 07:27:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1744010869; bh=R1GWFoYuoKhtrKRR83vBYR9KoCi0p9VDekqu42J5Cps=; h=From:To:Cc:Subject:Date:From; b=TAqQ7o68O0x+FZ0U221QbKnNfxIVtuJSPMzjCpWCK+2Zk+NF+DcE3985Wnk2rAFfF kZVbxdSq68ljoZyTfUbl3aSUcUj/+Orz6LU3nP9NPU5E75m/nB/MoHbcSfXkvJX4O0 r37NmgaaDDI2k0rp2g18TiqsJkFXGlWuh/NjTCBJT6s6MRJ6jLMma4o0HDFG/eZPIZ AhBSNVwLE8WJjlKfArX+/u+85RqEqMCGyOUv0XzFz3NxHPMSg7qAKltOQTWtZZWw5i wmOgXV3N/uyJPf1NRNkfyWHZW0y+RddW9+4dFyPLcmEXjGQGh7bXUgTqAxhC6FXpgv KfVoXAYNNW4pg== From: Arnd Bergmann To: Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Md Sadre Alam , Mark Brown , Varadarajan Narayanan , Sricharan Ramabadhran Cc: Arnd Bergmann , linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] spi: spi-qpic: fix common module build Date: Mon, 7 Apr 2025 09:27:14 +0200 Message-Id: <20250407072745.186831-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.5 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" From: Arnd Bergmann When the NAND driver is a loadable module, and the SPI driver is turned off, the common part is not built: ERROR: modpost: "qcom_nandc_unalloc" [drivers/spi/spi-qpic-snand.ko] undefi= ned! ERROR: modpost: "qcom_write_reg_dma" [drivers/spi/spi-qpic-snand.ko] undefi= ned! ERROR: modpost: "qcom_read_reg_dma" [drivers/spi/spi-qpic-snand.ko] undefin= ed! ERROR: modpost: "qcom_nandc_dev_to_mem" [drivers/spi/spi-qpic-snand.ko] und= efined! ERROR: modpost: "qcom_nandc_alloc" [drivers/spi/spi-qpic-snand.ko] undefine= d! ERROR: modpost: "qcom_submit_descs" [drivers/spi/spi-qpic-snand.ko] undefin= ed! ERROR: modpost: "qcom_clear_read_regs" [drivers/spi/spi-qpic-snand.ko] unde= fined! ERROR: modpost: "qcom_clear_bam_transaction" [drivers/spi/spi-qpic-snand.ko= ] undefined! ERROR: modpost: "qcom_read_data_dma" [drivers/spi/spi-qpic-snand.ko] undefi= ned! ERROR: modpost: "qcom_write_data_dma" [drivers/spi/spi-qpic-snand.ko] undef= ined! Simplify the Makefile to just build the common bits for either of the two, so it will be built-in whenever one of them is, or otherwise a loadable module if needed. Fixes: 7304d1909080 ("spi: spi-qpic: add driver for QCOM SPI NAND flash Int= erface") Signed-off-by: Arnd Bergmann --- drivers/mtd/nand/Makefile | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/mtd/nand/Makefile b/drivers/mtd/nand/Makefile index db516a45f0c5..44913ff1bf12 100644 --- a/drivers/mtd/nand/Makefile +++ b/drivers/mtd/nand/Makefile @@ -3,11 +3,8 @@ nandcore-objs :=3D core.o bbt.o obj-$(CONFIG_MTD_NAND_CORE) +=3D nandcore.o obj-$(CONFIG_MTD_NAND_ECC_MEDIATEK) +=3D ecc-mtk.o -ifeq ($(CONFIG_SPI_QPIC_SNAND),y) obj-$(CONFIG_SPI_QPIC_SNAND) +=3D qpic_common.o -else obj-$(CONFIG_MTD_NAND_QCOM) +=3D qpic_common.o -endif obj-y +=3D onenand/ obj-y +=3D raw/ obj-y +=3D spi/ --=20 2.39.5