aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/spi-nor/spi-nor.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/spi-nor/spi-nor.c')
-rw-r--r--drivers/mtd/spi-nor/spi-nor.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/mtd/spi-nor/spi-nor.c b/drivers/mtd/spi-nor/spi-nor.c
index c51ee52386a7..a98c134e51b6 100644
--- a/drivers/mtd/spi-nor/spi-nor.c
+++ b/drivers/mtd/spi-nor/spi-nor.c
@@ -904,8 +904,6 @@ static int spi_nor_check(struct spi_nor *nor)
904 return -EINVAL; 904 return -EINVAL;
905 } 905 }
906 906
907 if (!nor->read_id)
908 nor->read_id = spi_nor_read_id;
909 if (!nor->wait_till_ready) 907 if (!nor->wait_till_ready)
910 nor->wait_till_ready = spi_nor_wait_till_ready; 908 nor->wait_till_ready = spi_nor_wait_till_ready;
911 909
@@ -935,7 +933,7 @@ int spi_nor_scan(struct spi_nor *nor, const char *name, enum read_mode mode)
935 if (info->jedec_id) { 933 if (info->jedec_id) {
936 const struct spi_device_id *jid; 934 const struct spi_device_id *jid;
937 935
938 jid = nor->read_id(nor); 936 jid = spi_nor_read_id(nor);
939 if (IS_ERR(jid)) { 937 if (IS_ERR(jid)) {
940 return PTR_ERR(jid); 938 return PTR_ERR(jid);
941 } else if (jid != id) { 939 } else if (jid != id) {