Nico Huber has uploaded this change for review. ( https://review.coreboot.org/25150
Change subject: linux_spi: Reduce maximum read chunksize
......................................................................
linux_spi: Reduce maximum read chunksize
It turned out that older kernels use a single buffer for combined
input and output data. So we have to account for the read command +
max 3 address bytes.
Change-Id: Ide50db38af1004fde09a70b15938e77f5e1285ac
Signed-off-by: Nico Huber <nico.huber(a)secunet.com>
---
M linux_spi.c
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/50/25150/1
diff --git a/linux_spi.c b/linux_spi.c
index e51fbc4..d276402 100644
--- a/linux_spi.c
+++ b/linux_spi.c
@@ -183,7 +183,7 @@
unsigned int start, unsigned int len)
{
return spi_read_chunked(flash, buf, start, len,
- (unsigned int)getpagesize());
+ (unsigned int)getpagesize() - 4);
}
static int linux_spi_write_256(struct flashctx *flash, const uint8_t *buf, unsigned int start, unsigned int len)
--
To view, visit https://review.coreboot.org/25150
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: 1.0.x
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ide50db38af1004fde09a70b15938e77f5e1285ac
Gerrit-Change-Number: 25150
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Nico Huber has uploaded this change for review. ( https://review.coreboot.org/25149
Change subject: linux_spi: Reduce maximum read chunksize
......................................................................
linux_spi: Reduce maximum read chunksize
It turned out that older kernels use a single buffer of `bufsiz` bytes
for combined input and output data. So we have to account for the read
command + max 4 address bytes.
Change-Id: Ide50db38af1004fde09a70b15938e77f5e1285ac
Signed-off-by: Nico Huber <nico.huber(a)secunet.com>
---
M linux_spi.c
1 file changed, 3 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/49/25149/1
diff --git a/linux_spi.c b/linux_spi.c
index 1d3605a..714e612 100644
--- a/linux_spi.c
+++ b/linux_spi.c
@@ -221,8 +221,9 @@
static int linux_spi_read(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len)
{
- /* Read buffer is fully utilized for data. */
- return spi_read_chunked(flash, buf, start, len, max_kernel_buf_size);
+ /* Older kernels use a single buffer for combined input and output
+ data. So account for longest possible command + address, too. */
+ return spi_read_chunked(flash, buf, start, len, max_kernel_buf_size - 5);
}
static int linux_spi_write_256(struct flashctx *flash, const uint8_t *buf, unsigned int start, unsigned int len)
--
To view, visit https://review.coreboot.org/25149
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ide50db38af1004fde09a70b15938e77f5e1285ac
Gerrit-Change-Number: 25149
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Hello Paul Menzel, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/25134
to look at the new patch set (#5).
Change subject: Enable native 4BA instructions for Spansion 25FL256S
......................................................................
Enable native 4BA instructions for Spansion 25FL256S
Change-Id: I0ffc816ca714ecce5b89b1eaadb5e73ccb38d9ab
Signed-off-by: Nico Huber <nico.h(a)gmx.de>
Tested-by: Michael Fuckner <michael(a)fuckner.net>
---
M flashchips.c
1 file changed, 4 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/34/25134/5
--
To view, visit https://review.coreboot.org/25134
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I0ffc816ca714ecce5b89b1eaadb5e73ccb38d9ab
Gerrit-Change-Number: 25134
Gerrit-PatchSet: 5
Gerrit-Owner: Nico Huber <nico.h(a)gmx.de>
Gerrit-Reviewer: Paul Menzel <paulepanter(a)users.sourceforge.net>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>