Commit 7b6a9b28 authored by Boris Brezillon's avatar Boris Brezillon Committed by Miquel Raynal
Browse files

mtd: rawnand: Deprecate the dummy_controller field



We try to force NAND controller drivers to properly separate the NAND
controller object from the NAND chip one, so let's deprecate the dummy
controller object embedded in nand_chip to encourage them to create
their own instance.

Signed-off-by: default avatarBoris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
parent 419e5b84
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -780,7 +780,7 @@ static int cafe_nand_probe(struct pci_dev *pdev,
	cafe->usedma = 0;

	/* Scan to find existence of the device */
	cafe->nand.dummy_controller.ops = &cafe_nand_controller_ops;
	cafe->nand.legacy.dummy_controller.ops = &cafe_nand_controller_ops;
	err = nand_scan(&cafe->nand, 2);
	if (err)
		goto out_irq;
+1 −1
Original line number Diff line number Diff line
@@ -801,7 +801,7 @@ static int nand_davinci_probe(struct platform_device *pdev)
	spin_unlock_irq(&davinci_nand_lock);

	/* Scan to find existence of the device(s) */
	info->chip.dummy_controller.ops = &davinci_nand_controller_ops;
	info->chip.legacy.dummy_controller.ops = &davinci_nand_controller_ops;
	ret = nand_scan(&info->chip, pdata->mask_chipsel ? 2 : 1);
	if (ret < 0) {
		dev_dbg(&pdev->dev, "no NAND chip(s) found\n");
+1 −1
Original line number Diff line number Diff line
@@ -1325,7 +1325,7 @@ int denali_init(struct denali_nand_info *denali)
	if (denali->clk_rate && denali->clk_x_rate)
		chip->options |= NAND_KEEP_TIMINGS;

	chip->dummy_controller.ops = &denali_controller_ops;
	chip->legacy.dummy_controller.ops = &denali_controller_ops;
	ret = nand_scan(chip, denali->max_banks);
	if (ret)
		goto disable_irq;
+1 −1
Original line number Diff line number Diff line
@@ -1931,7 +1931,7 @@ static int gpmi_nand_init(struct gpmi_nand_data *this)
	if (ret)
		goto err_out;

	chip->dummy_controller.ops = &gpmi_nand_controller_ops;
	chip->legacy.dummy_controller.ops = &gpmi_nand_controller_ops;
	ret = nand_scan(chip, GPMI_IS_MX6(this) ? 2 : 1);
	if (ret)
		goto err_out;
+1 −1
Original line number Diff line number Diff line
@@ -799,7 +799,7 @@ static int hisi_nfc_probe(struct platform_device *pdev)
		return ret;
	}

	chip->dummy_controller.ops = &hisi_nfc_controller_ops;
	chip->legacy.dummy_controller.ops = &hisi_nfc_controller_ops;
	ret = nand_scan(chip, max_chips);
	if (ret)
		return ret;
Loading