summaryrefslogtreecommitdiffstats
path: root/flashrom.c
diff options
context:
space:
mode:
authorCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>2010-02-11 11:28:37 +0000
committerCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>2010-02-11 11:28:37 +0000
commitf15e1abbaade215dd0318de881361a21f39ed9a6 (patch)
tree3872b4c7bd25c03b3b365930a61cb88185e7e5c9 /flashrom.c
parent7a788f567df9cf4abb28b82261c2aa7af800f630 (diff)
downloadast2050-flashrom-f15e1abbaade215dd0318de881361a21f39ed9a6.zip
ast2050-flashrom-f15e1abbaade215dd0318de881361a21f39ed9a6.tar.gz
Rewrite substantial parts of the ICH SPI support
This megapatch rewrites substantial parts of ICH SPI to actually do what the SPI layer wants instead of its own weird idea about commands (running unrequested commands, running modified commands). Besides that, there is a fair share of cleanups as well. - Add JEDEC_EWSR (Enable Write Status Register) to default commands. - Mark a no longer used opcode/preopcode table as unused. - Declare all commands as non-atomic/standalone by default. The ICH SPI driver has no business executing commands (preopcodes) automatically if they were not requested. - Automatically adjust preopcode/opcode pairings (like WREN+ERASE) based on what the SPI layer requested. The ICH SPI driver has no business executing altered opcode pairs as it sees fit. - Fix incomplete initialization in the case of a locked down chipset. Leaving the first 4 opcodes with uninitialized pairings had unpredictable results. - switch() exists for a reason. Nested if() checking on the same variable is an interesting style. - Actually check if the requested readcnt/writecnt for a command is supported by the hardware instead of delivering corrupt/incomplete commands and data. - If a command has unsupported readlen/writelen, complain loudly to the user. - Use find_opcode instead of open-coding the same stuff in a dozen variations. - Introduce infrastructure for updating the command set of unlocked chipsets on the fly. Corresponding to flashrom svn r894. Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: David Hendricks <dhendrix@google.com>
Diffstat (limited to 'flashrom.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud