mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 23:24:38 +00:00
flash: Fix CFI buffer size bug
Fix bug introduced by 9c048b5234
.
The cfi_flash.c driver cast the flash buffer size to a uchar in
flash_write_cfibuffer(). On some flash parts, (tested on Numonyx
part PC32F512M29EWH), the buffer size is 1KB. Remove the cast to
uchar to enable buffer sizes to be larger.
Signed-off-by: John Schmoller <jschmoller@xes-inc.com>
Signed-off-by: Stefan Roese <sr@denx.de>
This commit is contained in:
parent
f6e3a1fa92
commit
7dedefdf74
1 changed files with 1 additions and 1 deletions
|
@ -1001,7 +1001,7 @@ static int flash_write_cfibuffer (flash_info_t * info, ulong dest, uchar * cp,
|
|||
#endif
|
||||
flash_write_cmd(info, sector, offset, AMD_CMD_WRITE_TO_BUFFER);
|
||||
cnt = len >> shift;
|
||||
flash_write_cmd(info, sector, offset, (uchar)cnt - 1);
|
||||
flash_write_cmd(info, sector, offset, cnt - 1);
|
||||
|
||||
switch (info->portwidth) {
|
||||
case FLASH_CFI_8BIT:
|
||||
|
|
Loading…
Reference in a new issue