|
|
Subscribe / Log in / New account

mtd: spi-nor: Add VIA/WonderMedia serial flash controller driver

From:  Alexey Charkov <alchark-AT-gmail.com>
To:  Mark Brown <broonie-AT-kernel.org>, Rob Herring <robh-AT-kernel.org>, Krzysztof Kozlowski <krzk+dt-AT-kernel.org>, Conor Dooley <conor+dt-AT-kernel.org>, Tudor Ambarus <tudor.ambarus-AT-linaro.org>, Pratyush Yadav <pratyush-AT-kernel.org>, Michael Walle <mwalle-AT-kernel.org>, Miquel Raynal <miquel.raynal-AT-bootlin.com>, Richard Weinberger <richard-AT-nod.at>, Vignesh Raghavendra <vigneshr-AT-ti.com>, Krzysztof Kozlowski <krzk-AT-kernel.org>
Subject:  [PATCH 0/3] mtd: spi-nor: Add VIA/WonderMedia serial flash controller driver
Date:  Sat, 10 May 2025 23:42:20 +0400
Message-ID:  <20250510-wmt-sflash-v1-0-02a1ac6adf12@gmail.com>
Cc:  linux-spi-AT-vger.kernel.org, devicetree-AT-vger.kernel.org, linux-kernel-AT-vger.kernel.org, linux-mtd-AT-lists.infradead.org, linux-arm-kernel-AT-lists.infradead.org, Alexey Charkov <alchark-AT-gmail.com>
Archive-link:  Article

Add a driver for the self-contained SPI NOR flash controller found on
VIA/WonderMedia SoCs, along with the respective DT binding and DTS.

The driver is a clean reimplementation based on the Linux SPI NOR
framework, although only chip probing routines are SPI NOR specific.
The rest of the controller operation is abstracted away behind a small
set of MMIO registers and a physical memory mapping for chip contents.
In fact, the vendor's implementation open-coded all driver operations
on top of the MTD framework directly, but had to rely on a static table
of supported flash chips indexed by ID due to the lack of auto-probing.

Signed-off-by: Alexey Charkov <alchark@gmail.com>
---
Alexey Charkov (3):
      dt-bindings: spi: Add VIA/WonderMedia serial flash controller
      mtd: spi-nor: Add a driver for the VIA/WonderMedia serial flash controller
      ARM: dts: vt8500: Add serial flash controller and its clock

 .../devicetree/bindings/spi/via,vt8500-sflash.yaml | 122 +++++
 MAINTAINERS                                        |   2 +
 arch/arm/boot/dts/vt8500/vt8500-bv07.dts           |  37 ++
 arch/arm/boot/dts/vt8500/vt8500.dtsi               |  34 ++
 arch/arm/boot/dts/vt8500/wm8505-ref.dts            |  37 ++
 arch/arm/boot/dts/vt8500/wm8505.dtsi               |  21 +
 arch/arm/boot/dts/vt8500/wm8650-mid.dts            |  37 ++
 arch/arm/boot/dts/vt8500/wm8650.dtsi               |  21 +
 arch/arm/boot/dts/vt8500/wm8750-apc8750.dts        |  37 ++
 arch/arm/boot/dts/vt8500/wm8750.dtsi               |  21 +
 arch/arm/boot/dts/vt8500/wm8850-w70v2.dts          |  37 ++
 arch/arm/boot/dts/vt8500/wm8850.dtsi               |  21 +
 arch/arm/boot/dts/vt8500/wm8950-apc-rock.dts       |  37 ++
 drivers/mtd/spi-nor/controllers/Kconfig            |  14 +
 drivers/mtd/spi-nor/controllers/Makefile           |   1 +
 drivers/mtd/spi-nor/controllers/wmt-sflash.c       | 525 +++++++++++++++++++++
 16 files changed, 1004 insertions(+)
---
base-commit: ed61cb3d78d585209ec775933078e268544fe9a4
change-id: 20250510-wmt-sflash-b0ba35f1a3ae

Best regards,
-- 
Alexey Charkov <alchark@gmail.com>




Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds