• Stefan Tauner's avatar
    ichspi: add support for Intel Hardware Sequencing · 50e7c603
    Stefan Tauner authored
    Based on the new opaque programmer framework this patch adds support
    for Intel Hardware Sequencing on ICH8 and its successors.
    
    By default (or when setting the ich_spi_mode option to auto)
    the module tries to use swseq and only activates hwseq if need be:
    - if important opcodes are inaccessible due to lockdown
    - if more than one flash chip is attached.
    The other options (swseq, hwseq) select the respective mode (if possible).
    
    A general description of Hardware Sequencing can be found in this blog entry:
    http://blogs.coreboot.org/blog/2011/06/11/gsoc-2011-flashrom-part-1/
    
    
    
    Besides adding hwseq this patch also introduces these unrelated changes:
    
    - Fix enable_flash_ich_dc_spi to pass ERROR_FATAL from ich_init_spi.
      The whole error handling looks a bit odd to me, so this patch does
      change very little. Also, it does not touch the tunnelcreek method,
      which should be refactored anyway.
    
    - Add null-pointer guards to find_opcode and find_preop
      to matches the other opcode methods better:
      curopcodes == NULL has some meaning and is actively used/checked in
      other functions.
    
    TODO: adding real documentation when we have a directory for it
    
    Corresponding to flashrom svn r1461.
    Signed-off-by: default avatarStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
    Acked-by: default avatarCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
    50e7c603
chipset_enable.c 42.2 KB