Skip to contentSkip to conversation

mtd: lpddr: use mtd_device_register()

PATCH Applied Rafał Miłecki 2 participants 4 messages Jul 21, 2018 – Jul 24, 2018

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 mtd: lpddr: use mtd_device_register()

From: Rafał Miłecki <[email protected]>

This driver doesn't specify parsers so it can use that little helper.

---
 drivers/mtd/lpddr/lpddr2_nvm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mtd/lpddr/lpddr2_nvm.c +1 -1
index 5d73db2a496d..c950c880ad59 100644
@@ -476,7 +476,7 @@ static int lpddr2_nvm_probe(struct platform_device *pdev)
 		return -EINVAL;
 	}
 	/* Parse partitions and register the MTD device */
-	return mtd_device_parse_register(mtd, NULL, NULL, NULL, 0);
+	return mtd_device_register(mtd, NULL, 0);
 }
 
 /*
Signature · 1 line
2.13.7
#1 lore raw

PATCH 2/2 mtd: spi-nor: intel-spi: use mtd_device_register()

From: Rafał Miłecki <[email protected]>

This driver doesn't specify parsers so it can use that little helper.

---
 drivers/mtd/spi-nor/intel-spi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mtd/spi-nor/intel-spi.c +1 -1
index d2cbfc27826e..af0a22019516 100644
@@ -908,7 +908,7 @@ struct intel_spi *intel_spi_probe(struct device *dev,
 	if (!ispi->writeable || !writeable)
 		ispi->nor.mtd.flags &= ~MTD_WRITEABLE;
 
-	ret = mtd_device_parse_register(&ispi->nor.mtd, NULL, NULL, &part, 1);
+	ret = mtd_device_register(&ispi->nor.mtd, &part, 1);
 	if (ret)
 		return ERR_PTR(ret);
 
Signature · 1 line
2.13.7
#3 lore raw
In reply to Rafał Miłecki
Quoted 5 lines · On Sat, 21 Jul 2018 13:55:09 +0200 Rafał Miłecki <[email protected]> wrote:

From: Rafał Miłecki <[email protected]>

This driver doesn't specify parsers so it can use that little helper.

Applied this one to mtd/next.

Quoted 17 lines
---
 drivers/mtd/lpddr/lpddr2_nvm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mtd/lpddr/lpddr2_nvm.c +1 -1
index 5d73db2a496d..c950c880ad59 100644
@@ -476,7 +476,7 @@ static int lpddr2_nvm_probe(struct platform_device *pdev)
 		return -EINVAL;
 	}
 	/* Parse partitions and register the MTD device */
-	return mtd_device_parse_register(mtd, NULL, NULL, NULL, 0);
+	return mtd_device_register(mtd, NULL, 0);
 }
 
 /*
#2 lore raw

Re: [PATCH 2/2] mtd: spi-nor: intel-spi: use mtd_device_register()

In reply to Rafał Miłecki
Quoted 5 lines · On Sat, 21 Jul 2018 13:55:10 +0200 Rafał Miłecki <[email protected]> wrote:

From: Rafał Miłecki <[email protected]>

This driver doesn't specify parsers so it can use that little helper.

Applied to spi-nor/next.

Quoted 17 lines
---
 drivers/mtd/spi-nor/intel-spi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mtd/spi-nor/intel-spi.c +1 -1
index d2cbfc27826e..af0a22019516 100644
@@ -908,7 +908,7 @@ struct intel_spi *intel_spi_probe(struct device *dev,
 	if (!ispi->writeable || !writeable)
 		ispi->nor.mtd.flags &= ~MTD_WRITEABLE;
 
-	ret = mtd_device_parse_register(&ispi->nor.mtd, NULL, NULL, &part, 1);
+	ret = mtd_device_register(&ispi->nor.mtd, &part, 1);
 	if (ret)
 		return ERR_PTR(ret);