All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nikita Shubin via B4 Relay <devnull+nikita.shubin.maquefel.me@kernel.org>
To: Miquel Raynal <miquel.raynal@bootlin.com>,
	 Richard Weinberger <richard@nod.at>,
	Vignesh Raghavendra <vigneshr@ti.com>,
	 Arnd Bergmann <arnd@arndb.de>,
	Linus Walleij <linus.walleij@linaro.org>,
	 Christophe Kerello <christophe.kerello@foss.st.com>,
	 Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
	 Nikita Shubin <nikita.shubin@maquefel.me>,
	 Neil Armstrong <neil.armstrong@linaro.org>,
	 Chris Packham <chris.packham@alliedtelesis.co.nz>,
	 Johan Jonker <jbx6244@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	 Jonathan Cameron <Jonathan.Cameron@huawei.com>,
	 linux-kernel@vger.kernel.org, linux-mtd@lists.infradead.org,
	 Arnd Bergmann <arnd@arndb.de>
Subject: [PATCH v6 20/40] mtd: rawnand: add support for ts72xx
Date: Tue, 12 Dec 2023 11:20:37 +0300	[thread overview]
Message-ID: <20231212-ep93xx-v6-20-c307b8ac9aa8@maquefel.me> (raw)
In-Reply-To: <20231212-ep93xx-v6-0-c307b8ac9aa8@maquefel.me>

From: Nikita Shubin <nikita.shubin@maquefel.me>

Technologic Systems has it's own nand controller implementation in CPLD.

Signed-off-by: Nikita Shubin <nikita.shubin@maquefel.me>
---
 drivers/mtd/nand/raw/Kconfig                       |   7 +
 drivers/mtd/nand/raw/Makefile                      |   1 +
 drivers/mtd/nand/raw/technologic-nand-controller.c | 220 +++++++++++++++++++++
 3 files changed, 228 insertions(+)

diff --git a/drivers/mtd/nand/raw/Kconfig b/drivers/mtd/nand/raw/Kconfig
index cbf8ae85e1ae..3937c10dea1c 100644
--- a/drivers/mtd/nand/raw/Kconfig
+++ b/drivers/mtd/nand/raw/Kconfig
@@ -449,6 +449,13 @@ config MTD_NAND_RENESAS
 	  Enables support for the NAND controller found on Renesas R-Car
 	  Gen3 and RZ/N1 SoC families.
 
+config MTD_NAND_TS72XX
+	tristate "ts72xx NAND controller"
+	depends on ARCH_EP93XX && HAS_IOMEM
+	help
+	  Enables support for NAND controller on ts72xx SBCs.
+	  This is a legacy driver based on gen_nand.
+
 comment "Misc"
 
 config MTD_SM_COMMON
diff --git a/drivers/mtd/nand/raw/Makefile b/drivers/mtd/nand/raw/Makefile
index 25120a4afada..d0b0e6b83568 100644
--- a/drivers/mtd/nand/raw/Makefile
+++ b/drivers/mtd/nand/raw/Makefile
@@ -34,6 +34,7 @@ obj-$(CONFIG_MTD_NAND_MLC_LPC32XX)      += lpc32xx_mlc.o
 obj-$(CONFIG_MTD_NAND_SH_FLCTL)		+= sh_flctl.o
 obj-$(CONFIG_MTD_NAND_MXC)		+= mxc_nand.o
 obj-$(CONFIG_MTD_NAND_SOCRATES)		+= socrates_nand.o
+obj-$(CONFIG_MTD_NAND_TS72XX)           += technologic-nand-controller.o
 obj-$(CONFIG_MTD_NAND_TXX9NDFMC)	+= txx9ndfmc.o
 obj-$(CONFIG_MTD_NAND_MPC5121_NFC)	+= mpc5121_nfc.o
 obj-$(CONFIG_MTD_NAND_VF610_NFC)	+= vf610_nfc.o
diff --git a/drivers/mtd/nand/raw/technologic-nand-controller.c b/drivers/mtd/nand/raw/technologic-nand-controller.c
new file mode 100644
index 000000000000..63157e7b5572
--- /dev/null
+++ b/drivers/mtd/nand/raw/technologic-nand-controller.c
@@ -0,0 +1,220 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Technologic Systems TS72xx NAND controller driver
+ *
+ * Copyright (C) 2023 Nikita Shubin <nikita.shubin@maquefel.me>
+ *
+ * Derived from: plat_nand.c
+ *  Author: Vitaly Wool <vitalywool@gmail.com>
+ */
+
+#include <linux/bits.h>
+#include <linux/err.h>
+#include <linux/io.h>
+#include <linux/iopoll.h>
+#include <linux/module.h>
+#include <linux/platform_device.h>
+#include <linux/slab.h>
+
+#include <linux/mtd/mtd.h>
+#include <linux/mtd/platnand.h>
+
+#define TS72XX_NAND_CONTROL_ADDR_LINE	BIT(22)	/* 0xN0400000 */
+#define TS72XX_NAND_BUSY_ADDR_LINE	BIT(23)	/* 0xN0800000 */
+
+#define TS72XX_NAND_ALE			BIT(0)
+#define TS72XX_NAND_CLE			BIT(1)
+#define TS72XX_NAND_NCE			BIT(2)
+
+#define TS72XX_NAND_CTRL_CLE		(TS72XX_NAND_NCE | TS72XX_NAND_CLE)
+#define TS72XX_NAND_CTRL_ALE		(TS72XX_NAND_NCE | TS72XX_NAND_ALE)
+
+struct ts72xx_nand_data {
+	struct nand_controller	controller;
+	struct nand_chip	chip;
+	void __iomem		*base;
+	void __iomem		*ctrl;
+	void __iomem		*busy;
+};
+
+static inline struct ts72xx_nand_data *chip_to_ts72xx(struct nand_chip *chip)
+{
+	return container_of(chip, struct ts72xx_nand_data, chip);
+}
+
+static int ts72xx_nand_attach_chip(struct nand_chip *chip)
+{
+	switch (chip->ecc.engine_type) {
+	case NAND_ECC_ENGINE_TYPE_ON_HOST:
+		return -EINVAL;
+	case NAND_ECC_ENGINE_TYPE_SOFT:
+		if (chip->ecc.algo == NAND_ECC_ALGO_UNKNOWN)
+			chip->ecc.algo = NAND_ECC_ALGO_HAMMING;
+		chip->ecc.algo = NAND_ECC_ALGO_HAMMING;
+		fallthrough;
+	default:
+		return 0;
+	}
+}
+
+static void ts72xx_nand_ctrl(struct nand_chip *chip, u8 value)
+{
+	struct ts72xx_nand_data *data = chip_to_ts72xx(chip);
+	unsigned char bits = ioread8(data->ctrl) & ~GENMASK(2, 0);
+
+	iowrite8(bits | value, data->ctrl);
+}
+
+static int ts72xx_nand_exec_instr(struct nand_chip *chip,
+				const struct nand_op_instr *instr)
+{
+	struct ts72xx_nand_data *data = chip_to_ts72xx(chip);
+	unsigned int timeout_us;
+	u32 status;
+	int ret;
+
+	switch (instr->type) {
+	case NAND_OP_CMD_INSTR:
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_CTRL_CLE);
+		iowrite8(instr->ctx.cmd.opcode, data->base);
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_NCE);
+		break;
+
+	case NAND_OP_ADDR_INSTR:
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_CTRL_ALE);
+		iowrite8_rep(data->base, instr->ctx.addr.addrs, instr->ctx.addr.naddrs);
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_NCE);
+		break;
+
+	case NAND_OP_DATA_IN_INSTR:
+		ioread8_rep(data->base, instr->ctx.data.buf.in, instr->ctx.data.len);
+		break;
+
+	case NAND_OP_DATA_OUT_INSTR:
+		iowrite8_rep(data->base, instr->ctx.data.buf.in, instr->ctx.data.len);
+		break;
+
+	case NAND_OP_WAITRDY_INSTR:
+		timeout_us = instr->ctx.waitrdy.timeout_ms * 1000;
+		ret = readb_poll_timeout(data->busy, status, status & BIT(5), 0, timeout_us);
+		if (ret)
+			return ret;
+
+		break;
+	}
+
+	if (instr->delay_ns)
+		ndelay(instr->delay_ns);
+
+	return 0;
+}
+
+static int ts72xx_nand_exec_op(struct nand_chip *chip,
+			       const struct nand_operation *op, bool check_only)
+{
+	unsigned int i;
+	int ret;
+
+	if (check_only)
+		return 0;
+
+	for (i = 0; i < op->ninstrs; i++) {
+		ret = ts72xx_nand_exec_instr(chip, &op->instrs[i]);
+		if (ret)
+			return ret;
+	}
+
+	return 0;
+}
+
+static const struct nand_controller_ops ts72xx_nand_ops = {
+	.attach_chip = ts72xx_nand_attach_chip,
+	.exec_op = ts72xx_nand_exec_op,
+};
+
+static int ts72xx_nand_probe(struct platform_device *pdev)
+{
+	struct ts72xx_nand_data *data;
+	struct fwnode_handle *child;
+	struct mtd_info *mtd;
+	int err;
+
+	data = devm_kzalloc(&pdev->dev, sizeof(*data), GFP_KERNEL);
+	if (!data)
+		return -ENOMEM;
+
+	nand_controller_init(&data->controller);
+	data->controller.ops = &ts72xx_nand_ops;
+	data->chip.controller = &data->controller;
+
+	data->base = devm_platform_ioremap_resource(pdev, 0);
+	if (IS_ERR(data->base))
+		return PTR_ERR(data->base);
+	data->ctrl = data->base + TS72XX_NAND_CONTROL_ADDR_LINE;
+	data->busy = data->base + TS72XX_NAND_BUSY_ADDR_LINE;
+
+	child = fwnode_get_next_child_node(dev_fwnode(&pdev->dev), NULL);
+	if (!child)
+		return dev_err_probe(&pdev->dev, -ENXIO,
+				"ts72xx controller node should have exactly one child\n");
+
+	nand_set_flash_node(&data->chip, to_of_node(child));
+	mtd = nand_to_mtd(&data->chip);
+	mtd->dev.parent = &pdev->dev;
+	platform_set_drvdata(pdev, data);
+
+	/*
+	 * This driver assumes that the default ECC engine should be TYPE_SOFT.
+	 * Set ->engine_type before registering the NAND devices in order to
+	 * provide a driver specific default value.
+	 */
+	data->chip.ecc.engine_type = NAND_ECC_ENGINE_TYPE_SOFT;
+
+	/* Scan to find existence of the device */
+	err = nand_scan(&data->chip, 1);
+	if (err)
+		goto err_handle_put;
+
+	err = mtd_device_parse_register(mtd, NULL, NULL, NULL, 0);
+	if (err)
+		goto err_clean_nand;
+
+	return 0;
+
+err_clean_nand:
+	nand_cleanup(&data->chip);
+err_handle_put:
+	fwnode_handle_put(child);
+	return err;
+}
+
+static void ts72xx_nand_remove(struct platform_device *pdev)
+{
+	struct ts72xx_nand_data *data = platform_get_drvdata(pdev);
+	struct nand_chip *chip = &data->chip;
+	int ret;
+
+	ret = mtd_device_unregister(nand_to_mtd(chip));
+	WARN_ON(ret);
+	nand_cleanup(chip);
+}
+
+static const struct of_device_id ts72xx_id_table[] = {
+	{ .compatible = "technologic,ts7200-nand" },
+	{ /* sentinel */ }
+};
+MODULE_DEVICE_TABLE(of, ts72xx_id_table);
+
+static struct platform_driver ts72xx_nand_driver = {
+	.driver = {
+		.name = "ts72xx-nand",
+		.of_match_table = ts72xx_id_table,
+	},
+	.probe = ts72xx_nand_probe,
+	.remove_new = ts72xx_nand_remove,
+};
+module_platform_driver(ts72xx_nand_driver);
+
+MODULE_AUTHOR("Nikita Shubin <nikita.shubin@maquefel.me>");
+MODULE_DESCRIPTION("Technologic Systems TS72xx NAND controller driver");
+MODULE_LICENSE("GPL");

-- 
2.41.0


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

WARNING: multiple messages have this Message-ID (diff)
From: Nikita Shubin via B4 Relay  <devnull+nikita.shubin.maquefel.me@kernel.org>
To: Miquel Raynal <miquel.raynal@bootlin.com>,
	Richard Weinberger <richard@nod.at>,
	Vignesh Raghavendra <vigneshr@ti.com>,
	Arnd Bergmann <arnd@arndb.de>,
	Linus Walleij <linus.walleij@linaro.org>,
	Christophe Kerello <christophe.kerello@foss.st.com>,
	Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
	Nikita Shubin <nikita.shubin@maquefel.me>,
	Neil Armstrong <neil.armstrong@linaro.org>,
	Chris Packham <chris.packham@alliedtelesis.co.nz>,
	Johan Jonker <jbx6244@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Jonathan Cameron <Jonathan.Cameron@huawei.com>,
	linux-kernel@vger.kernel.org, linux-mtd@lists.infradead.org,
	Arnd Bergmann <arnd@arndb.de>
Subject: [PATCH v6 20/40] mtd: rawnand: add support for ts72xx
Date: Tue, 12 Dec 2023 11:20:37 +0300	[thread overview]
Message-ID: <20231212-ep93xx-v6-20-c307b8ac9aa8@maquefel.me> (raw)
In-Reply-To: <20231212-ep93xx-v6-0-c307b8ac9aa8@maquefel.me>

From: Nikita Shubin <nikita.shubin@maquefel.me>

Technologic Systems has it's own nand controller implementation in CPLD.

Signed-off-by: Nikita Shubin <nikita.shubin@maquefel.me>
---
 drivers/mtd/nand/raw/Kconfig                       |   7 +
 drivers/mtd/nand/raw/Makefile                      |   1 +
 drivers/mtd/nand/raw/technologic-nand-controller.c | 220 +++++++++++++++++++++
 3 files changed, 228 insertions(+)

diff --git a/drivers/mtd/nand/raw/Kconfig b/drivers/mtd/nand/raw/Kconfig
index cbf8ae85e1ae..3937c10dea1c 100644
--- a/drivers/mtd/nand/raw/Kconfig
+++ b/drivers/mtd/nand/raw/Kconfig
@@ -449,6 +449,13 @@ config MTD_NAND_RENESAS
 	  Enables support for the NAND controller found on Renesas R-Car
 	  Gen3 and RZ/N1 SoC families.
 
+config MTD_NAND_TS72XX
+	tristate "ts72xx NAND controller"
+	depends on ARCH_EP93XX && HAS_IOMEM
+	help
+	  Enables support for NAND controller on ts72xx SBCs.
+	  This is a legacy driver based on gen_nand.
+
 comment "Misc"
 
 config MTD_SM_COMMON
diff --git a/drivers/mtd/nand/raw/Makefile b/drivers/mtd/nand/raw/Makefile
index 25120a4afada..d0b0e6b83568 100644
--- a/drivers/mtd/nand/raw/Makefile
+++ b/drivers/mtd/nand/raw/Makefile
@@ -34,6 +34,7 @@ obj-$(CONFIG_MTD_NAND_MLC_LPC32XX)      += lpc32xx_mlc.o
 obj-$(CONFIG_MTD_NAND_SH_FLCTL)		+= sh_flctl.o
 obj-$(CONFIG_MTD_NAND_MXC)		+= mxc_nand.o
 obj-$(CONFIG_MTD_NAND_SOCRATES)		+= socrates_nand.o
+obj-$(CONFIG_MTD_NAND_TS72XX)           += technologic-nand-controller.o
 obj-$(CONFIG_MTD_NAND_TXX9NDFMC)	+= txx9ndfmc.o
 obj-$(CONFIG_MTD_NAND_MPC5121_NFC)	+= mpc5121_nfc.o
 obj-$(CONFIG_MTD_NAND_VF610_NFC)	+= vf610_nfc.o
diff --git a/drivers/mtd/nand/raw/technologic-nand-controller.c b/drivers/mtd/nand/raw/technologic-nand-controller.c
new file mode 100644
index 000000000000..63157e7b5572
--- /dev/null
+++ b/drivers/mtd/nand/raw/technologic-nand-controller.c
@@ -0,0 +1,220 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Technologic Systems TS72xx NAND controller driver
+ *
+ * Copyright (C) 2023 Nikita Shubin <nikita.shubin@maquefel.me>
+ *
+ * Derived from: plat_nand.c
+ *  Author: Vitaly Wool <vitalywool@gmail.com>
+ */
+
+#include <linux/bits.h>
+#include <linux/err.h>
+#include <linux/io.h>
+#include <linux/iopoll.h>
+#include <linux/module.h>
+#include <linux/platform_device.h>
+#include <linux/slab.h>
+
+#include <linux/mtd/mtd.h>
+#include <linux/mtd/platnand.h>
+
+#define TS72XX_NAND_CONTROL_ADDR_LINE	BIT(22)	/* 0xN0400000 */
+#define TS72XX_NAND_BUSY_ADDR_LINE	BIT(23)	/* 0xN0800000 */
+
+#define TS72XX_NAND_ALE			BIT(0)
+#define TS72XX_NAND_CLE			BIT(1)
+#define TS72XX_NAND_NCE			BIT(2)
+
+#define TS72XX_NAND_CTRL_CLE		(TS72XX_NAND_NCE | TS72XX_NAND_CLE)
+#define TS72XX_NAND_CTRL_ALE		(TS72XX_NAND_NCE | TS72XX_NAND_ALE)
+
+struct ts72xx_nand_data {
+	struct nand_controller	controller;
+	struct nand_chip	chip;
+	void __iomem		*base;
+	void __iomem		*ctrl;
+	void __iomem		*busy;
+};
+
+static inline struct ts72xx_nand_data *chip_to_ts72xx(struct nand_chip *chip)
+{
+	return container_of(chip, struct ts72xx_nand_data, chip);
+}
+
+static int ts72xx_nand_attach_chip(struct nand_chip *chip)
+{
+	switch (chip->ecc.engine_type) {
+	case NAND_ECC_ENGINE_TYPE_ON_HOST:
+		return -EINVAL;
+	case NAND_ECC_ENGINE_TYPE_SOFT:
+		if (chip->ecc.algo == NAND_ECC_ALGO_UNKNOWN)
+			chip->ecc.algo = NAND_ECC_ALGO_HAMMING;
+		chip->ecc.algo = NAND_ECC_ALGO_HAMMING;
+		fallthrough;
+	default:
+		return 0;
+	}
+}
+
+static void ts72xx_nand_ctrl(struct nand_chip *chip, u8 value)
+{
+	struct ts72xx_nand_data *data = chip_to_ts72xx(chip);
+	unsigned char bits = ioread8(data->ctrl) & ~GENMASK(2, 0);
+
+	iowrite8(bits | value, data->ctrl);
+}
+
+static int ts72xx_nand_exec_instr(struct nand_chip *chip,
+				const struct nand_op_instr *instr)
+{
+	struct ts72xx_nand_data *data = chip_to_ts72xx(chip);
+	unsigned int timeout_us;
+	u32 status;
+	int ret;
+
+	switch (instr->type) {
+	case NAND_OP_CMD_INSTR:
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_CTRL_CLE);
+		iowrite8(instr->ctx.cmd.opcode, data->base);
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_NCE);
+		break;
+
+	case NAND_OP_ADDR_INSTR:
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_CTRL_ALE);
+		iowrite8_rep(data->base, instr->ctx.addr.addrs, instr->ctx.addr.naddrs);
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_NCE);
+		break;
+
+	case NAND_OP_DATA_IN_INSTR:
+		ioread8_rep(data->base, instr->ctx.data.buf.in, instr->ctx.data.len);
+		break;
+
+	case NAND_OP_DATA_OUT_INSTR:
+		iowrite8_rep(data->base, instr->ctx.data.buf.in, instr->ctx.data.len);
+		break;
+
+	case NAND_OP_WAITRDY_INSTR:
+		timeout_us = instr->ctx.waitrdy.timeout_ms * 1000;
+		ret = readb_poll_timeout(data->busy, status, status & BIT(5), 0, timeout_us);
+		if (ret)
+			return ret;
+
+		break;
+	}
+
+	if (instr->delay_ns)
+		ndelay(instr->delay_ns);
+
+	return 0;
+}
+
+static int ts72xx_nand_exec_op(struct nand_chip *chip,
+			       const struct nand_operation *op, bool check_only)
+{
+	unsigned int i;
+	int ret;
+
+	if (check_only)
+		return 0;
+
+	for (i = 0; i < op->ninstrs; i++) {
+		ret = ts72xx_nand_exec_instr(chip, &op->instrs[i]);
+		if (ret)
+			return ret;
+	}
+
+	return 0;
+}
+
+static const struct nand_controller_ops ts72xx_nand_ops = {
+	.attach_chip = ts72xx_nand_attach_chip,
+	.exec_op = ts72xx_nand_exec_op,
+};
+
+static int ts72xx_nand_probe(struct platform_device *pdev)
+{
+	struct ts72xx_nand_data *data;
+	struct fwnode_handle *child;
+	struct mtd_info *mtd;
+	int err;
+
+	data = devm_kzalloc(&pdev->dev, sizeof(*data), GFP_KERNEL);
+	if (!data)
+		return -ENOMEM;
+
+	nand_controller_init(&data->controller);
+	data->controller.ops = &ts72xx_nand_ops;
+	data->chip.controller = &data->controller;
+
+	data->base = devm_platform_ioremap_resource(pdev, 0);
+	if (IS_ERR(data->base))
+		return PTR_ERR(data->base);
+	data->ctrl = data->base + TS72XX_NAND_CONTROL_ADDR_LINE;
+	data->busy = data->base + TS72XX_NAND_BUSY_ADDR_LINE;
+
+	child = fwnode_get_next_child_node(dev_fwnode(&pdev->dev), NULL);
+	if (!child)
+		return dev_err_probe(&pdev->dev, -ENXIO,
+				"ts72xx controller node should have exactly one child\n");
+
+	nand_set_flash_node(&data->chip, to_of_node(child));
+	mtd = nand_to_mtd(&data->chip);
+	mtd->dev.parent = &pdev->dev;
+	platform_set_drvdata(pdev, data);
+
+	/*
+	 * This driver assumes that the default ECC engine should be TYPE_SOFT.
+	 * Set ->engine_type before registering the NAND devices in order to
+	 * provide a driver specific default value.
+	 */
+	data->chip.ecc.engine_type = NAND_ECC_ENGINE_TYPE_SOFT;
+
+	/* Scan to find existence of the device */
+	err = nand_scan(&data->chip, 1);
+	if (err)
+		goto err_handle_put;
+
+	err = mtd_device_parse_register(mtd, NULL, NULL, NULL, 0);
+	if (err)
+		goto err_clean_nand;
+
+	return 0;
+
+err_clean_nand:
+	nand_cleanup(&data->chip);
+err_handle_put:
+	fwnode_handle_put(child);
+	return err;
+}
+
+static void ts72xx_nand_remove(struct platform_device *pdev)
+{
+	struct ts72xx_nand_data *data = platform_get_drvdata(pdev);
+	struct nand_chip *chip = &data->chip;
+	int ret;
+
+	ret = mtd_device_unregister(nand_to_mtd(chip));
+	WARN_ON(ret);
+	nand_cleanup(chip);
+}
+
+static const struct of_device_id ts72xx_id_table[] = {
+	{ .compatible = "technologic,ts7200-nand" },
+	{ /* sentinel */ }
+};
+MODULE_DEVICE_TABLE(of, ts72xx_id_table);
+
+static struct platform_driver ts72xx_nand_driver = {
+	.driver = {
+		.name = "ts72xx-nand",
+		.of_match_table = ts72xx_id_table,
+	},
+	.probe = ts72xx_nand_probe,
+	.remove_new = ts72xx_nand_remove,
+};
+module_platform_driver(ts72xx_nand_driver);
+
+MODULE_AUTHOR("Nikita Shubin <nikita.shubin@maquefel.me>");
+MODULE_DESCRIPTION("Technologic Systems TS72xx NAND controller driver");
+MODULE_LICENSE("GPL");

-- 
2.41.0


WARNING: multiple messages have this Message-ID (diff)
From: Nikita Shubin <nikita.shubin@maquefel.me>
To: Miquel Raynal <miquel.raynal@bootlin.com>,
	 Richard Weinberger <richard@nod.at>,
	Vignesh Raghavendra <vigneshr@ti.com>,
	 Arnd Bergmann <arnd@arndb.de>,
	Linus Walleij <linus.walleij@linaro.org>,
	 Christophe Kerello <christophe.kerello@foss.st.com>,
	 Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
	 Nikita Shubin <nikita.shubin@maquefel.me>,
	 Neil Armstrong <neil.armstrong@linaro.org>,
	 Chris Packham <chris.packham@alliedtelesis.co.nz>,
	 Johan Jonker <jbx6244@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	 Jonathan Cameron <Jonathan.Cameron@huawei.com>,
	 linux-kernel@vger.kernel.org, linux-mtd@lists.infradead.org,
	 Arnd Bergmann <arnd@arndb.de>
Subject: [PATCH v6 20/40] mtd: rawnand: add support for ts72xx
Date: Tue, 12 Dec 2023 11:20:37 +0300	[thread overview]
Message-ID: <20231212-ep93xx-v6-20-c307b8ac9aa8@maquefel.me> (raw)
In-Reply-To: <20231212-ep93xx-v6-0-c307b8ac9aa8@maquefel.me>

Technologic Systems has it's own nand controller implementation in CPLD.

Signed-off-by: Nikita Shubin <nikita.shubin@maquefel.me>
---
 drivers/mtd/nand/raw/Kconfig                       |   7 +
 drivers/mtd/nand/raw/Makefile                      |   1 +
 drivers/mtd/nand/raw/technologic-nand-controller.c | 220 +++++++++++++++++++++
 3 files changed, 228 insertions(+)

diff --git a/drivers/mtd/nand/raw/Kconfig b/drivers/mtd/nand/raw/Kconfig
index cbf8ae85e1ae..3937c10dea1c 100644
--- a/drivers/mtd/nand/raw/Kconfig
+++ b/drivers/mtd/nand/raw/Kconfig
@@ -449,6 +449,13 @@ config MTD_NAND_RENESAS
 	  Enables support for the NAND controller found on Renesas R-Car
 	  Gen3 and RZ/N1 SoC families.
 
+config MTD_NAND_TS72XX
+	tristate "ts72xx NAND controller"
+	depends on ARCH_EP93XX && HAS_IOMEM
+	help
+	  Enables support for NAND controller on ts72xx SBCs.
+	  This is a legacy driver based on gen_nand.
+
 comment "Misc"
 
 config MTD_SM_COMMON
diff --git a/drivers/mtd/nand/raw/Makefile b/drivers/mtd/nand/raw/Makefile
index 25120a4afada..d0b0e6b83568 100644
--- a/drivers/mtd/nand/raw/Makefile
+++ b/drivers/mtd/nand/raw/Makefile
@@ -34,6 +34,7 @@ obj-$(CONFIG_MTD_NAND_MLC_LPC32XX)      += lpc32xx_mlc.o
 obj-$(CONFIG_MTD_NAND_SH_FLCTL)		+= sh_flctl.o
 obj-$(CONFIG_MTD_NAND_MXC)		+= mxc_nand.o
 obj-$(CONFIG_MTD_NAND_SOCRATES)		+= socrates_nand.o
+obj-$(CONFIG_MTD_NAND_TS72XX)           += technologic-nand-controller.o
 obj-$(CONFIG_MTD_NAND_TXX9NDFMC)	+= txx9ndfmc.o
 obj-$(CONFIG_MTD_NAND_MPC5121_NFC)	+= mpc5121_nfc.o
 obj-$(CONFIG_MTD_NAND_VF610_NFC)	+= vf610_nfc.o
diff --git a/drivers/mtd/nand/raw/technologic-nand-controller.c b/drivers/mtd/nand/raw/technologic-nand-controller.c
new file mode 100644
index 000000000000..63157e7b5572
--- /dev/null
+++ b/drivers/mtd/nand/raw/technologic-nand-controller.c
@@ -0,0 +1,220 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Technologic Systems TS72xx NAND controller driver
+ *
+ * Copyright (C) 2023 Nikita Shubin <nikita.shubin@maquefel.me>
+ *
+ * Derived from: plat_nand.c
+ *  Author: Vitaly Wool <vitalywool@gmail.com>
+ */
+
+#include <linux/bits.h>
+#include <linux/err.h>
+#include <linux/io.h>
+#include <linux/iopoll.h>
+#include <linux/module.h>
+#include <linux/platform_device.h>
+#include <linux/slab.h>
+
+#include <linux/mtd/mtd.h>
+#include <linux/mtd/platnand.h>
+
+#define TS72XX_NAND_CONTROL_ADDR_LINE	BIT(22)	/* 0xN0400000 */
+#define TS72XX_NAND_BUSY_ADDR_LINE	BIT(23)	/* 0xN0800000 */
+
+#define TS72XX_NAND_ALE			BIT(0)
+#define TS72XX_NAND_CLE			BIT(1)
+#define TS72XX_NAND_NCE			BIT(2)
+
+#define TS72XX_NAND_CTRL_CLE		(TS72XX_NAND_NCE | TS72XX_NAND_CLE)
+#define TS72XX_NAND_CTRL_ALE		(TS72XX_NAND_NCE | TS72XX_NAND_ALE)
+
+struct ts72xx_nand_data {
+	struct nand_controller	controller;
+	struct nand_chip	chip;
+	void __iomem		*base;
+	void __iomem		*ctrl;
+	void __iomem		*busy;
+};
+
+static inline struct ts72xx_nand_data *chip_to_ts72xx(struct nand_chip *chip)
+{
+	return container_of(chip, struct ts72xx_nand_data, chip);
+}
+
+static int ts72xx_nand_attach_chip(struct nand_chip *chip)
+{
+	switch (chip->ecc.engine_type) {
+	case NAND_ECC_ENGINE_TYPE_ON_HOST:
+		return -EINVAL;
+	case NAND_ECC_ENGINE_TYPE_SOFT:
+		if (chip->ecc.algo == NAND_ECC_ALGO_UNKNOWN)
+			chip->ecc.algo = NAND_ECC_ALGO_HAMMING;
+		chip->ecc.algo = NAND_ECC_ALGO_HAMMING;
+		fallthrough;
+	default:
+		return 0;
+	}
+}
+
+static void ts72xx_nand_ctrl(struct nand_chip *chip, u8 value)
+{
+	struct ts72xx_nand_data *data = chip_to_ts72xx(chip);
+	unsigned char bits = ioread8(data->ctrl) & ~GENMASK(2, 0);
+
+	iowrite8(bits | value, data->ctrl);
+}
+
+static int ts72xx_nand_exec_instr(struct nand_chip *chip,
+				const struct nand_op_instr *instr)
+{
+	struct ts72xx_nand_data *data = chip_to_ts72xx(chip);
+	unsigned int timeout_us;
+	u32 status;
+	int ret;
+
+	switch (instr->type) {
+	case NAND_OP_CMD_INSTR:
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_CTRL_CLE);
+		iowrite8(instr->ctx.cmd.opcode, data->base);
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_NCE);
+		break;
+
+	case NAND_OP_ADDR_INSTR:
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_CTRL_ALE);
+		iowrite8_rep(data->base, instr->ctx.addr.addrs, instr->ctx.addr.naddrs);
+		ts72xx_nand_ctrl(chip, TS72XX_NAND_NCE);
+		break;
+
+	case NAND_OP_DATA_IN_INSTR:
+		ioread8_rep(data->base, instr->ctx.data.buf.in, instr->ctx.data.len);
+		break;
+
+	case NAND_OP_DATA_OUT_INSTR:
+		iowrite8_rep(data->base, instr->ctx.data.buf.in, instr->ctx.data.len);
+		break;
+
+	case NAND_OP_WAITRDY_INSTR:
+		timeout_us = instr->ctx.waitrdy.timeout_ms * 1000;
+		ret = readb_poll_timeout(data->busy, status, status & BIT(5), 0, timeout_us);
+		if (ret)
+			return ret;
+
+		break;
+	}
+
+	if (instr->delay_ns)
+		ndelay(instr->delay_ns);
+
+	return 0;
+}
+
+static int ts72xx_nand_exec_op(struct nand_chip *chip,
+			       const struct nand_operation *op, bool check_only)
+{
+	unsigned int i;
+	int ret;
+
+	if (check_only)
+		return 0;
+
+	for (i = 0; i < op->ninstrs; i++) {
+		ret = ts72xx_nand_exec_instr(chip, &op->instrs[i]);
+		if (ret)
+			return ret;
+	}
+
+	return 0;
+}
+
+static const struct nand_controller_ops ts72xx_nand_ops = {
+	.attach_chip = ts72xx_nand_attach_chip,
+	.exec_op = ts72xx_nand_exec_op,
+};
+
+static int ts72xx_nand_probe(struct platform_device *pdev)
+{
+	struct ts72xx_nand_data *data;
+	struct fwnode_handle *child;
+	struct mtd_info *mtd;
+	int err;
+
+	data = devm_kzalloc(&pdev->dev, sizeof(*data), GFP_KERNEL);
+	if (!data)
+		return -ENOMEM;
+
+	nand_controller_init(&data->controller);
+	data->controller.ops = &ts72xx_nand_ops;
+	data->chip.controller = &data->controller;
+
+	data->base = devm_platform_ioremap_resource(pdev, 0);
+	if (IS_ERR(data->base))
+		return PTR_ERR(data->base);
+	data->ctrl = data->base + TS72XX_NAND_CONTROL_ADDR_LINE;
+	data->busy = data->base + TS72XX_NAND_BUSY_ADDR_LINE;
+
+	child = fwnode_get_next_child_node(dev_fwnode(&pdev->dev), NULL);
+	if (!child)
+		return dev_err_probe(&pdev->dev, -ENXIO,
+				"ts72xx controller node should have exactly one child\n");
+
+	nand_set_flash_node(&data->chip, to_of_node(child));
+	mtd = nand_to_mtd(&data->chip);
+	mtd->dev.parent = &pdev->dev;
+	platform_set_drvdata(pdev, data);
+
+	/*
+	 * This driver assumes that the default ECC engine should be TYPE_SOFT.
+	 * Set ->engine_type before registering the NAND devices in order to
+	 * provide a driver specific default value.
+	 */
+	data->chip.ecc.engine_type = NAND_ECC_ENGINE_TYPE_SOFT;
+
+	/* Scan to find existence of the device */
+	err = nand_scan(&data->chip, 1);
+	if (err)
+		goto err_handle_put;
+
+	err = mtd_device_parse_register(mtd, NULL, NULL, NULL, 0);
+	if (err)
+		goto err_clean_nand;
+
+	return 0;
+
+err_clean_nand:
+	nand_cleanup(&data->chip);
+err_handle_put:
+	fwnode_handle_put(child);
+	return err;
+}
+
+static void ts72xx_nand_remove(struct platform_device *pdev)
+{
+	struct ts72xx_nand_data *data = platform_get_drvdata(pdev);
+	struct nand_chip *chip = &data->chip;
+	int ret;
+
+	ret = mtd_device_unregister(nand_to_mtd(chip));
+	WARN_ON(ret);
+	nand_cleanup(chip);
+}
+
+static const struct of_device_id ts72xx_id_table[] = {
+	{ .compatible = "technologic,ts7200-nand" },
+	{ /* sentinel */ }
+};
+MODULE_DEVICE_TABLE(of, ts72xx_id_table);
+
+static struct platform_driver ts72xx_nand_driver = {
+	.driver = {
+		.name = "ts72xx-nand",
+		.of_match_table = ts72xx_id_table,
+	},
+	.probe = ts72xx_nand_probe,
+	.remove_new = ts72xx_nand_remove,
+};
+module_platform_driver(ts72xx_nand_driver);
+
+MODULE_AUTHOR("Nikita Shubin <nikita.shubin@maquefel.me>");
+MODULE_DESCRIPTION("Technologic Systems TS72xx NAND controller driver");
+MODULE_LICENSE("GPL");

-- 
2.41.0


  parent reply	other threads:[~2023-12-12  8:22 UTC|newest]

Thread overview: 145+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-12  8:20 [PATCH v6 00/40] ep93xx device tree conversion Nikita Shubin via B4 Relay
2023-12-12  8:20 ` Nikita Shubin
2023-12-12  8:20 ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 01/40] ARM: ep93xx: Add terminator to gpiod_lookup_table Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-13 17:24   ` Andy Shevchenko
2023-12-13 17:24     ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 02/40] gpio: ep93xx: split device in multiple Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 03/40] ARM: ep93xx: add regmap aux_dev Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 17:28   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 04/40] clk: ep93xx: add DT support for Cirrus EP93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 17:42   ` Andy Shevchenko
2023-12-23  8:35     ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 05/40] pinctrl: add a Cirrus ep93xx SoC pin controller Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 17:51   ` Andy Shevchenko
2023-12-23  8:55     ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 06/40] power: reset: Add a driver for the ep93xx reset Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 17:54   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 07/40] dt-bindings: soc: Add Cirrus EP93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13  6:53   ` Krzysztof Kozlowski
2023-12-12  8:20 ` [PATCH v6 08/40] soc: Add SoC driver for Cirrus ep93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:37   ` Andy Shevchenko
2023-12-23 10:06     ` Nikita Shubin
2023-12-23 11:32       ` Arnd Bergmann
2023-12-12  8:20 ` [PATCH v6 09/40] dt-bindings: dma: Add Cirrus EP93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 10/40] dma: cirrus: Convert to DT for " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:28   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 11/40] dt-bindings: watchdog: Add Cirrus EP93x Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 12/40] watchdog: ep93xx: add DT support for Cirrus EP93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 17:56   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 13/40] dt-bindings: pwm: Add " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 14/40] pwm: ep93xx: add DT support for " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 17:56   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 15/40] dt-bindings: spi: Add " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 16/40] spi: ep93xx: add DT support for " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:13   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 17/40] dt-bindings: net: Add " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 18/40] net: cirrus: add DT support for " Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:39   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 19/40] dt-bindings: mtd: Add ts7200 nand-controller Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` Nikita Shubin via B4 Relay [this message]
2023-12-12  8:20   ` [PATCH v6 20/40] mtd: rawnand: add support for ts72xx Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:30   ` Greg Kroah-Hartman
2023-12-12  8:30     ` Greg Kroah-Hartman
2023-12-12  8:35     ` Nikita Shubin
2023-12-12  8:35       ` Nikita Shubin
2023-12-12 14:05       ` Miquel Raynal
2023-12-12 14:05         ` Miquel Raynal
2023-12-15 10:16   ` Miquel Raynal
2023-12-15 10:16     ` Miquel Raynal
2023-12-15 12:11     ` Nikita Shubin
2023-12-15 12:11       ` Nikita Shubin
2023-12-15 12:27       ` Miquel Raynal
2023-12-15 12:27         ` Miquel Raynal
2023-12-12  8:20 ` [PATCH v6 21/40] dt-bindings: ata: Add Cirrus EP93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 22/40] ata: pata_ep93xx: add device tree support Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:19   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 23/40] dt-bindings: input: Add Cirrus EP93xx keypad Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 24/40] input: keypad: ep93xx: add DT support for Cirrus EP93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-13 18:41   ` Andy Shevchenko
2023-12-13 18:41     ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 25/40] dt-bindings: wdt: Add ts72xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12 15:03   ` Guenter Roeck
2023-12-12  8:20 ` [PATCH v6 26/40] wdt: ts72xx: add DT support for ts72xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:10   ` Andy Shevchenko
2023-12-12  8:20 ` [PATCH v6 27/40] gpio: ep93xx: add DT support for gpio-ep93xx Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 28/40] ASoC: dt-bindings: ep93xx: Document DMA support Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 29/40] ASoC: dt-bindings: ep93xx: Document Audio Port support Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 30/40] ASoC: ep93xx: Drop legacy DMA support Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 31/40] ARM: dts: add Cirrus EP93XX SoC .dtsi Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 32/40] ARM: dts: ep93xx: add ts7250 board Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 33/40] ARM: dts: ep93xx: Add EDB9302 DT Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 34/40] ARM: ep93xx: DT for the Cirrus ep93xx SoC platforms Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 35/40] pwm: ep93xx: drop legacy pinctrl Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 36/40] ata: pata_ep93xx: remove legacy pinctrl use Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-13 18:16   ` Andy Shevchenko
2023-12-13 18:16     ` Andy Shevchenko
2023-12-13 18:33     ` Uwe Kleine-König
2023-12-13 18:33       ` Uwe Kleine-König
2023-12-13 18:48       ` Andy Shevchenko
2023-12-13 18:48         ` Andy Shevchenko
2023-12-14 10:26         ` Uwe Kleine-König
2023-12-14 10:26           ` Uwe Kleine-König
2023-12-12  8:20 ` [PATCH v6 37/40] ARM: ep93xx: delete all boardfiles Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 38/40] ARM: ep93xx: soc: drop defines Nikita Shubin
2023-12-12  8:20   ` Nikita Shubin via B4 Relay
2023-12-12  8:20 ` [PATCH v6 39/40] ASoC: cirrus: edb93xx: Delete driver Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-12  8:20 ` [PATCH v6 40/40] dma: cirrus: remove platform code Nikita Shubin via B4 Relay
2023-12-12  8:20   ` Nikita Shubin
2023-12-13 18:30   ` Andy Shevchenko
2023-12-23  9:49     ` Nikita Shubin
2023-12-12 11:53 ` [PATCH v6 00/40] ep93xx device tree conversion Uwe Kleine-König
2023-12-12 11:53   ` Uwe Kleine-König
2023-12-13 17:59 ` Andy Shevchenko
2023-12-13 17:59   ` Andy Shevchenko
2023-12-23  9:12   ` Nikita Shubin
2023-12-23  9:12     ` Nikita Shubin
2023-12-25 19:55     ` Andy Shevchenko
2023-12-25 19:55       ` Andy Shevchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231212-ep93xx-v6-20-c307b8ac9aa8@maquefel.me \
    --to=devnull+nikita.shubin.maquefel.me@kernel.org \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=arnd@arndb.de \
    --cc=chris.packham@alliedtelesis.co.nz \
    --cc=christophe.kerello@foss.st.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jbx6244@gmail.com \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=miquel.raynal@bootlin.com \
    --cc=neil.armstrong@linaro.org \
    --cc=nikita.shubin@maquefel.me \
    --cc=richard@nod.at \
    --cc=vigneshr@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.