mirror of
https://github.com/qemu/qemu.git
synced 2024-11-26 21:33:40 +08:00
m25p80: Fix WINBOND fast read command handling
This commit fix obvious bug in WINBOND command handling. Datasheet states that default dummy cycles is 8 so fix it. Signed-off-by: Marcin Krzeminski <marcin.krzeminski@nokia.com> Message-id: 1466755631-25201-11-git-send-email-marcin.krzeminski@nokia.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
dadb2f9078
commit
3830c7a460
@ -738,6 +738,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_WINBOND:
|
||||
s->needed_bytes += 8;
|
||||
break;
|
||||
case MAN_NUMONYX:
|
||||
s->needed_bytes += extract32(s->volatile_cfg, 4, 4);
|
||||
break;
|
||||
@ -768,7 +771,7 @@ static void decode_dio_read_cmd(Flash *s)
|
||||
/* Dummy cycles modeled with bytes writes instead of bits */
|
||||
switch (get_man(s)) {
|
||||
case MAN_WINBOND:
|
||||
s->needed_bytes = 4;
|
||||
s->needed_bytes += 8;
|
||||
break;
|
||||
case MAN_SPANSION:
|
||||
s->needed_bytes += SPANSION_CONTINUOUS_READ_MODE_CMD_LEN;
|
||||
@ -807,7 +810,7 @@ static void decode_qio_read_cmd(Flash *s)
|
||||
/* Dummy cycles modeled with bytes writes instead of bits */
|
||||
switch (get_man(s)) {
|
||||
case MAN_WINBOND:
|
||||
s->needed_bytes = 6;
|
||||
s->needed_bytes += 8;
|
||||
break;
|
||||
case MAN_SPANSION:
|
||||
s->needed_bytes += SPANSION_CONTINUOUS_READ_MODE_CMD_LEN;
|
||||
|
Loading…
Reference in New Issue
Block a user