aboutsummaryrefslogtreecommitdiffstats
path: root/package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch
diff options
context:
space:
mode:
Diffstat (limited to 'package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch')
-rw-r--r--package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch25
1 files changed, 8 insertions, 17 deletions
diff --git a/package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch b/package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch
index f17aa32698..8000ff004e 100644
--- a/package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch
+++ b/package/boot/uboot-lantiq/patches/0005-sf-make-calculatiom-of-address-bytes-completely-conf.patch
@@ -5,8 +5,6 @@ Subject: sf: make calculatiom of address bytes completely configurable
Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
-diff --git a/drivers/mtd/spi/sf_ops.c b/drivers/mtd/spi/sf_ops.c
-index d34747b..207adf5 100644
--- a/drivers/mtd/spi/sf_ops.c
+++ b/drivers/mtd/spi/sf_ops.c
@@ -15,12 +15,17 @@
@@ -31,7 +29,7 @@ index d34747b..207adf5 100644
}
int spi_flash_cmd_write_status(struct spi_flash *flash, u8 sr)
-@@ -158,7 +163,7 @@ int spi_flash_write_common(struct spi_flash *flash, const u8 *cmd,
+@@ -158,7 +163,7 @@ int spi_flash_write_common(struct spi_fl
int spi_flash_cmd_erase_ops(struct spi_flash *flash, u32 offset, size_t len)
{
u32 erase_size;
@@ -40,7 +38,7 @@ index d34747b..207adf5 100644
int ret = -1;
erase_size = flash->erase_size;
-@@ -180,12 +185,13 @@ int spi_flash_cmd_erase_ops(struct spi_flash *flash, u32 offset, size_t len)
+@@ -180,12 +185,13 @@ int spi_flash_cmd_erase_ops(struct spi_f
if (ret < 0)
goto done;
#endif
@@ -56,7 +54,7 @@ index d34747b..207adf5 100644
if (ret < 0) {
debug("SF: erase failed\n");
goto done;
-@@ -206,7 +212,7 @@ int spi_flash_cmd_write_ops(struct spi_flash *flash, u32 offset,
+@@ -206,7 +212,7 @@ int spi_flash_cmd_write_ops(struct spi_f
{
unsigned long byte_addr, page_size;
size_t chunk_len, actual;
@@ -65,7 +63,7 @@ index d34747b..207adf5 100644
int ret = -1;
ret = spi_claim_bus(flash->spi);
-@@ -230,12 +236,13 @@ int spi_flash_cmd_write_ops(struct spi_flash *flash, u32 offset,
+@@ -230,12 +236,13 @@ int spi_flash_cmd_write_ops(struct spi_f
if (flash->spi->max_write_size)
chunk_len = min(chunk_len, flash->spi->max_write_size);
@@ -81,7 +79,7 @@ index d34747b..207adf5 100644
buf + actual, chunk_len);
if (ret < 0) {
debug("SF: write failed\n");
-@@ -269,7 +276,7 @@ int spi_flash_read_common(struct spi_flash *flash, const u8 *cmd,
+@@ -269,7 +276,7 @@ int spi_flash_read_common(struct spi_fla
int spi_flash_cmd_read_ops(struct spi_flash *flash, u32 offset,
size_t len, void *data)
{
@@ -90,7 +88,7 @@ index d34747b..207adf5 100644
u32 remain_len, read_len;
int ret = -1;
-@@ -288,7 +295,6 @@ int spi_flash_cmd_read_ops(struct spi_flash *flash, u32 offset,
+@@ -288,7 +295,6 @@ int spi_flash_cmd_read_ops(struct spi_fl
}
cmd[0] = CMD_READ_ARRAY_FAST;
@@ -98,7 +96,7 @@ index d34747b..207adf5 100644
while (len) {
#ifdef CONFIG_SPI_FLASH_BAR
-@@ -306,9 +312,11 @@ int spi_flash_cmd_read_ops(struct spi_flash *flash, u32 offset,
+@@ -306,9 +312,11 @@ int spi_flash_cmd_read_ops(struct spi_fl
else
read_len = remain_len;
@@ -112,11 +110,9 @@ index d34747b..207adf5 100644
data, read_len);
if (ret < 0) {
debug("SF: read failed\n");
-diff --git a/drivers/mtd/spi/sf_probe.c b/drivers/mtd/spi/sf_probe.c
-index 380aa09..84289db 100644
--- a/drivers/mtd/spi/sf_probe.c
+++ b/drivers/mtd/spi/sf_probe.c
-@@ -218,6 +218,9 @@ static int spi_flash_validate_params(struct spi_flash *flash,
+@@ -218,6 +218,9 @@ static int spi_flash_validate_params(str
flash->poll_cmd = CMD_FLAG_STATUS;
#endif
@@ -126,8 +122,6 @@ index 380aa09..84289db 100644
/* Configure the BAR - discover bank cmds and read current bank */
#ifdef CONFIG_SPI_FLASH_BAR
u8 curr_bank = 0;
-diff --git a/include/spi_flash.h b/include/spi_flash.h
-index 411dd1b..cc9398b 100644
--- a/include/spi_flash.h
+++ b/include/spi_flash.h
@@ -57,6 +57,7 @@ struct spi_flash {
@@ -138,6 +132,3 @@ index 411dd1b..cc9398b 100644
void *memory_map;
int (*read)(struct spi_flash *flash, u32 offset, size_t len, void *buf);
---
-1.8.3.2
-