From: Bin Meng <bmeng.cn@gmail.com>
To: Alistair Francis <alistair.francis@wdc.com>
Cc: Bin Meng <bin.meng@windriver.com>,
qemu-devel@nongnu.org, qemu-block@nongnu.org
Subject: [PATCH v2] hw/block: m25p80: Support fast read for SST flashes
Date: Sat, 6 Mar 2021 14:01:52 +0800 [thread overview]
Message-ID: <20210306060152.7250-1-bmeng.cn@gmail.com> (raw)
From: Bin Meng <bin.meng@windriver.com>
Per SST25VF016B datasheet [1], SST flash requires a dummy byte after
the address bytes. Note only SPI mode is supported by SST flashes.
[1] http://ww1.microchip.com/downloads/en/devicedoc/s71271_04.pdf
Signed-off-by: Bin Meng <bin.meng@windriver.com>
Acked-by: Alistair Francis <alistair.francis@wdc.com>
---
Changes in v2:
- rebase on qemu/master
hw/block/m25p80.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c
index 5f9471d83c..183d3f44c2 100644
--- a/hw/block/m25p80.c
+++ b/hw/block/m25p80.c
@@ -895,6 +895,9 @@ static void decode_fast_read_cmd(Flash *s)
s->needed_bytes = get_addr_length(s);
switch (get_man(s)) {
/* Dummy cycles - modeled with bytes writes instead of bits */
+ case MAN_SST:
+ s->needed_bytes += 1;
+ break;
case MAN_WINBOND:
s->needed_bytes += 8;
break;
--
2.25.1
next reply other threads:[~2021-03-06 6:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-06 6:01 Bin Meng [this message]
2021-03-11 8:18 ` [PATCH v2] hw/block: m25p80: Support fast read for SST flashes Bin Meng
2021-03-16 1:39 ` Bin Meng
2021-03-22 1:29 ` Bin Meng
2021-03-22 15:17 ` Alistair Francis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210306060152.7250-1-bmeng.cn@gmail.com \
--to=bmeng.cn@gmail.com \
--cc=alistair.francis@wdc.com \
--cc=bin.meng@windriver.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).