Commit 6d55d31e authored by Miquel Raynal's avatar Miquel Raynal
Browse files

Merge tag 'nand/for-6.7' into mtd/next



The raw NAND subsystem has, as usual, seen a bit of cleanup being done
this cycle, typically return values of platform_get_irq() and
devm_kasprintf(), plus structure annotations for sanitizers. There is
also a better ECC check in the Arasan driver. This comes with smaller
misc changes.

In the SPI-NAND world there is now support for Foresee F35SQA002G,
Winbond W25N and XTX XT26 chips.

Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
parents 3a8ab4a1 5a985960
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -481,7 +481,7 @@ static int anfc_read_page_hw_ecc(struct nand_chip *chip, u8 *buf,
		}

		bf = nand_check_erased_ecc_chunk(raw_buf, chip->ecc.size,
						 NULL, 0, NULL, 0,
						 anand->hw_ecc, chip->ecc.bytes, NULL, 0,
						 chip->ecc.strength);
		if (bf > 0) {
			mtd->ecc_stats.corrected += bf;
+1 −1
Original line number Diff line number Diff line
@@ -528,7 +528,7 @@ struct cdns_nand_chip {
	/* ECC strength index. */
	u8 corr_str_idx;

	u8 cs[];
	u8 cs[] __counted_by(nsels);
};

struct ecc_info {
+10 −0
Original line number Diff line number Diff line
@@ -619,6 +619,11 @@ static int ebu_nand_probe(struct platform_device *pdev)
	ebu_host->cs_num = cs;

	resname = devm_kasprintf(dev, GFP_KERNEL, "nand_cs%d", cs);
	if (!resname) {
		ret = -ENOMEM;
		goto err_of_node_put;
	}

	ebu_host->cs[cs].chipaddr = devm_platform_ioremap_resource_byname(pdev,
									  resname);
	if (IS_ERR(ebu_host->cs[cs].chipaddr)) {
@@ -649,6 +654,11 @@ static int ebu_nand_probe(struct platform_device *pdev)
	}

	resname = devm_kasprintf(dev, GFP_KERNEL, "addr_sel%d", cs);
	if (!resname) {
		ret = -ENOMEM;
		goto err_cleanup_dma;
	}

	res = platform_get_resource_byname(pdev, IORESOURCE_MEM, resname);
	if (!res) {
		ret = -EINVAL;
+0 −1
Original line number Diff line number Diff line
@@ -106,7 +106,6 @@ int nand_read_page_raw_notsupp(struct nand_chip *chip, u8 *buf,
			       int oob_required, int page);
int nand_write_page_raw_notsupp(struct nand_chip *chip, const u8 *buf,
				int oob_required, int page);
int nand_exit_status_op(struct nand_chip *chip);
int nand_read_param_page_op(struct nand_chip *chip, u8 page, void *buf,
			    unsigned int len);
void nand_decode_ext_id(struct nand_chip *chip);
+3 −0
Original line number Diff line number Diff line
@@ -1134,6 +1134,9 @@ static int meson_nfc_clk_init(struct meson_nfc *nfc)
	init.name = devm_kasprintf(nfc->dev,
				   GFP_KERNEL, "%s#div",
				   dev_name(nfc->dev));
	if (!init.name)
		return -ENOMEM;

	init.ops = &clk_divider_ops;
	nfc_divider_parent_data[0].fw_name = "device";
	init.parent_data = nfc_divider_parent_data;
Loading