1
0
mirror of https://review.coreboot.org/flashrom.git synced 2025-04-28 15:33:42 +02:00

1491 Commits

Author SHA1 Message Date
Sean Nelson
ed3eae6873 Clang complains loudly when there are duplicate printlock_sst_fwhub, gcc ignores them
Ack via IRC.

Corresponding to flashrom svn r969.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-22 21:48:51 +00:00
Carl-Daniel Hailfinger
9979eacd9c Refine compile-time checks for libpci
Idwer Vollering reported problems with the current libpci check on
FreeBSD 8.0-RELEASE i386. This is caused by a strict linker.

Parsing linker error messages is an exercise in futility, and library
detection with $CC --print-file-name is totally useless for libraries
outside the standard hardcoded builtin gcc search path (probably the
same for other compilers as well).

Look for libpciutils instead of libpci on NetBSD during the check.

Corresponding to flashrom svn r968.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Idwer Vollering <vidwer@gmail.com>
2010-03-22 12:29:45 +00:00
Sean Nelson
4e54de944d In unlock_28f004s5, variable 'i' needs to be int...
Corresponding to flashrom svn r967.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-22 07:03:26 +00:00
Sean Nelson
8864710cd5 Fix a few typos from the last commit
Corresponding to flashrom svn r966.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-22 06:57:02 +00:00
Sean Nelson
dee4a83e1c To access/read the lock bits, we use the same mode to read the chip id
This patch looks into the write situation for the Intel 28F001BX-{B,T}.
Looks like they're just a 82802ab page write.

Unlock_28f004s5 has been changed to read all the lock bits and if at
least one of the block lock bits are set, clear them all. If the master
lock bit is set, we can't do anything about it, so we return.

Corresponding to flashrom svn r965.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-22 04:39:31 +00:00
Carl-Daniel Hailfinger
408e47af32 Multibyte SPI write for the Bus Pirate
Corresponding to flashrom svn r964.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-22 03:30:58 +00:00
Carl-Daniel Hailfinger
50415d2e48 Add DOS cross-compilation support to the Makefile
Add a README with build instructions.

Corresponding to flashrom svn r963.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Rudolf Marek <r.marek@assembler.cz>
2010-03-21 14:54:57 +00:00
Daniel Brandt
4ad4c745af Adds board enable to Termtek TK-3370 thin client motherboard
Corresponding to flashrom svn r962.

Signed-off-by: Daniel Brandt <dbr@mindglow.se>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-21 13:36:20 +00:00
Sean Nelson
46313198d8 Unlock fixup
Corresponding to flashrom svn r961.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-20 15:15:36 +00:00
Sean Nelson
fcc4f749f3 Fix some problems introduced in commit r948 brought up by carldani
The Intel 28F001BX-T/B chips don't have block locks or mention of
registers; chip is old. The Intel 28F004S5 mentions block locks which
require a remapping registers.

Corresponding to flashrom svn r960.

The Intel 28F004S5 mentions block locks which require a remapping registers.
Fixes problems brought up by carldani because of commit r948.
Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-20 03:01:19 +00:00
Luc Verhaegen
f63c4364b7 Rebased Board Enable Patch: iBase MB899
Corresponding to flashrom svn r959.

Signed-off-by: Luc Verhaegen <libv@skynet.be>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 23:01:34 +00:00
Sean Nelson
c94746d892 Rebased Board Enable Patch: Abit AN-M2
Original patch by: Luc Verhaegen.

Corresponding to flashrom svn r958.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 23:00:07 +00:00
Sean Nelson
392e05ad4a Reversed-engineered board enable for the ASUS A8N-LA
Rebased.
IDs are ISA and SMBus.
Added DMI string to match 3 HP boards: Nagami, Nagami2, Nagami2L.

This could match any HP Nagami board. Needs testing.

Corresponding to flashrom svn r957.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:58:15 +00:00
Peter Lemenkov
064f166011 Rebased Board Enable Patch: 2nd attempt to fix board detection on GA-MA74GM-S2H
This board (GA-MA74GM-S2H) has the same list of pciids as the GA-MA78M-S2H,
so I narroved search conditions by populating corresponding board_pciid_enable
entry for GA-MA78M-S2H with DMI pattern.

Untested!

Corresponding to flashrom svn r956.

Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:55:48 +00:00
Michael Karcher
255a9e0394 Rebased Board Enable Patch: Asus P4B533-E
Corresponding to flashrom svn r955.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:52:00 +00:00
Michael Karcher
0647733638 Rebased Board Enable Patch: Factor out Via Apollo GPO setting
The board enable for the VT6X4 committed in r950 actually depended on this commit.

Corresponding to flashrom svn r954.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:49:09 +00:00
James Lancaster
998c9dc6ee Rebased Board Enable Patch: A8JM board_enable patch
Corresponding to flashrom svn r953.

Signed-off-by: James Lancaster <deathstalker@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:39:24 +00:00
Sean Nelson
92bc6bddc5 Rebased Board Enable Patch: Abit KN8 Ultra
Patch by Chris <zinx+flashrom@zenthought.org>

Corresponding to flashrom svn r952.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:37:29 +00:00
Michael Karcher
51cd0c9838 Rebased Board Enable Patch: Intel SE440BX-2
This board has no subsystem IDs, but thankfully the DMI patch is in
now, which is a real life safer. There are *WAY* to many 440BX/PIIX4
boards out there to match this without DMI.

Corresponding to flashrom svn r951.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:35:21 +00:00
Michael Karcher
187a46acd1 Rebased Board Enable Patch: Abit VT6X4
This board has *no* usable IDs at all, neither DMI nor PCI
subsystem IDs. You have to force it using "-m abit:vt6x4"

Try 3: really correct polarity of the GPIO

Corresponding to flashrom svn r950.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:30:49 +00:00
Luc Verhaegen
49146c15a9 Rebased Board Enable Patch: Add Asus A8N
Corresponding to flashrom svn r949.

Signed-off-by: Luc Verhaegen <libv@skynet.be>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-19 22:26:44 +00:00
Sean Nelson
28accc2700 Various JEDEC refactorings touching 82802ab.c, sharplhf00l04.c and stm50flw0x0x.c
Rename print_82802ab_status to print_status_82802ab add unlock_82802ab strip unlock code from erase_block_82802ab rename erase_82802ab_block  to erase_block_80280ab delete sharplhf00l04.o from Makefile delete *_lhf00l04* from chipdrivers.h.

add unlock_stm50flw0x0x
delete wait_stm50flw0x0x
delete write_page_stm50flw0x0x
convert erase_stm50flw0x0x to erase_chip_stm50flw0x0x
delete write_stm50flw0x0x
add unlock_82802ab to two Intel chips with TEST_BAD_WRITE
change the status of 82802AB, 82802AC, M50FW040, M50FW080 to TEST_OK_PR

Corresponding to flashrom svn r948.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-19 18:47:06 +00:00
Michael Karcher
6499d5a681 Add board enable for P4C800-E
Lspci/flashrom/superiotool at
http://www.coreboot.org/pipermail/flashrom/2010-March/002579.html

Corresponding to flashrom svn r947.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-17 06:19:23 +00:00
Carl-Daniel Hailfinger
295b3af767 PCI device BARs of all types had only bits 1:0 cleared while reading the address
That was correct for IO BARs, but failed to mask bit 3:2 for MEM BARs,
resulting in odd offsets for prefetchable MEM BARs and for 64-bit
capable MEM BARs. Mask the correct number of bits for all types of BARs
and add some debug printing about BAR type.

Corresponding to flashrom svn r946.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Uwe Hermann <uwe@hermann-uwe.de>
2010-03-17 00:47:56 +00:00
Uwe Hermann
6093969529 Mark a bunch of parallel chips I tested as TEST_OK_PRW
All operations for these chips were tested on hardware. ERASE is not marked
as working yet, as there are multiple erase functions per chip and only one
was (successfully) tested. I'll redo the ERASE test when the respective
infrastructure in flashrom is there.

Corresponding to flashrom svn r945.

Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-17 00:05:59 +00:00
Rudolf Marek
03ae5c117a Add MS-DOS crosscompilation support
Tested, works fine. Part 1: Code changes.

Corresponding to flashrom svn r944.

Signed-off-by: Rudolf Marek <r.marek@assembler.cz>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 23:59:19 +00:00
Sean Nelson
ccf7a2a231 Further cleanup after JEDEC refactorings
Convert _sst_fwhub functions to jedec.

Corresponding to flashrom svn r943.

kill unused sst_fwhub.c functions
make unlock_* check if unlock was successful and only return 0 when fully successful
Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 03:09:10 +00:00
Sean Nelson
b3289c904c Clean up sst28sf040.c after JEDEC refactorings
Remove function probe_28sf040.

Corresponding to flashrom svn r942.

delete references to dead sharplhf00l04.c and sst29sf040.c functions from chipdrivers.h
Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 01:00:50 +00:00
Sean Nelson
e4446e4ddb Clean up sharplhf00l04.c after JEDEC refactorings
- remove some copied functions (from 82802ab.c) and use the 82802ab equivalents
 - fix missing prototypes to *_82802ab functions

Corresponding to flashrom svn r941.

fix missing prototypes to _82802ab functions
Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 00:51:31 +00:00
Sean Nelson
ffae6ca468 Kill dead w39v080fa.c functions
Corresponding to flashrom svn r940.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 00:45:00 +00:00
Sean Nelson
ba966f6f93 Kill dead w39v040c.c functions
Corresponding to flashrom svn r939.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 00:35:53 +00:00
Sean Nelson
2f9374bd9d Kill dead pm49fl00x.c functions
Corresponding to flashrom svn r938.

Signed-off-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-16 00:32:30 +00:00
Carl-Daniel Hailfinger
81449a2482 Add FEATURE_REGISTERMAP to some more chips and change the use of various probing functions
Add FEATURE_REGISTERMAP to * Intel 82802AB, 82802AC * Sharp LHF00L04 * SST SST49LF004C, SST49LF008C, SST49LF016C, SST49LF160C * ST M50FLW040A, M50FLW040B, M50FLW080A, M50FLW080B, M50FW002, M50FW016      M50FW040, M50FW080, M50LPW116.

Make register mapping conditional on FEATURE_REGISTERMAP in 82802ab.c.
Replace probe_49lfxxxc with probe_82802ab.
Replace probe_28sf040 with probe_82802ab.
Replace probe_sst_fwhub with probe_jedec.
Add printlock_sst_fwhub to chips which used probe_sst_fwhub.

Corresponding to flashrom svn r937.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-15 03:48:42 +00:00
Michael Karcher
fd41670dd6 Skip DMI laptop check if DMI doesn't work
Also further removes dead code from dmi.c and adds a missing newline.

Corresponding to flashrom svn r936.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-14 17:57:52 +00:00
Raúl Soriano
8111e7ffa4 Enabling Gigabyte GA-MA69VM-S2
This board has a supported chipset and a supported bios, but it's
connected indirectly through IT8716 and not recognized.

Corresponding to flashrom svn r935.

Signed-off-by: Raúl Soriano <GatoLoko@gmail.com>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-14 00:00:14 +00:00
Michael Karcher
e3cb0a13bf Fix EN29F002 Top/Bottom Boot Block
See http://www.coreboot.org/pipermail/flashrom/2010-March/002480.html
for effects of mixup: blockwise erase will fail, fallback to chip
erase works.

Corresponding to flashrom svn r934.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-13 23:47:09 +00:00
Uwe Hermann
439597032e Various coding style and cosmetic changes
- Fix coding-style, whitespace, and indentation in a few places.

 - Consistently use the same spelling ("Super I/O") everywhere.

Corresponding to flashrom svn r933.

 - Make some flashrom stdout output look a bit nicer.
 
Signed-off-by: Uwe Hermann <uwe@hermann-uwe.de>
Acked-by: Uwe Hermann <uwe@hermann-uwe.de>
2010-03-13 17:28:29 +00:00
Joerg Mayer
645c6df21a Patch: Manpage: Move description of layout file into the right place
Move the description of the layout file out of the --chip option
into the --layout option.

Corresponding to flashrom svn r932.

Signed-off-by: Joerg Mayer <jmayer@loplof.de>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-13 14:47:48 +00:00
Michael Karcher
31fd8254cf Tell users to probe/backup first
Corresponding to flashrom svn r931.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-12 06:41:39 +00:00
Michael Karcher
0b9e2a746e Fix NULL pointer reference in board_flash_enable
Was introduced in r926. Found by Henrik Kretzschmar <henne@nachtwindheim.de>.

Corresponding to flashrom svn r930.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Maciej Pijanka <maciej.pijanka@gmail.com>
2010-03-11 23:04:16 +00:00
Russ Dill
bd622d1a47 Add ASUS A7V8X-X write-enable
I have an ASUS A7V8X-X, the BIOS programming requires a write-enable. It
has an IT8712F, just like the A7V600-X.

Corresponding to flashrom svn r929.

Signed-off-by: Russ Dill <Russ.Dill@gmail.com>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-09 16:57:06 +00:00
Russ Dill
8c7c468645 Mark PMC Pm49FL002 as tested
This chip is on my ASUS A7V8X-X mainboard.

Corresponding to flashrom svn r928.

Signed-off-by: Russ Dill <Russ.Dill@gmail.com>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
2010-03-09 16:53:06 +00:00
Carl-Daniel Hailfinger
e8e369fcc3 Write granularity is chip specific
The following write granularities exist according to my datasheet
survey: - 1 bit. Each bit can be cleared individually. - 1 byte. A byte
can be written once. Further writes to an already written byte cause
the contents to be either undefined or to stay unchanged. - 128 bytes.
If less than 128 bytes are written, the rest will be erased. Each write
to a 128-byte region will trigger an automatic erase before anything is
written. Very uncommon behaviour. - 256 bytes. If less than 256 bytes
are written, the contents of the unwritten bytes are undefined.

Note that chips with default 256-byte writes, which keep the original
contents for unwritten bytes, have a granularity of 1 byte.

Handle 1-bit, 1-byte and 256-byte write granularity.

Corresponding to flashrom svn r927.

Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Sean Nelson <audiohacked@gmail.com>
Acked-by: David Hendricks <dhendrix@google.com>
2010-03-08 00:42:32 +00:00
Michael Karcher
7f0c3ec56b Move untested board enable documentation to manpage
This also checks the testedness of boards in all cases, not just for
PCI/DMI detection.

Corresponding to flashrom svn r926.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-07 22:29:28 +00:00
Michael Karcher
5fdf270450 Board enable for MS-7202 (K8N GM2-L)
Board enable code is untested, marked as such.

Corresponding to flashrom svn r925.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-07 16:52:59 +00:00
Michael Karcher
b2184c153f Board enable for Asus M2NBP-VM CSM
Board info: http://www.coreboot.org/pipermail/flashrom/2009-December/001373.html

Corresponding to flashrom svn r924.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-07 16:42:55 +00:00
Michael Karcher
03b80e922c Board enable for HP Vectra VL420SFF
This code has been tested by Mattias Mattsson on 23. December 2009,
but without the DMI match. Now that DMI support is in and working,
the board can be added to mainline flashrom.

board info: http://www.coreboot.org/pipermail/flashrom/2009-December/001440.html

Corresponding to flashrom svn r923.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-07 16:32:32 +00:00
Michael Karcher
e5eafb2191 Refactor man page
This patch puts the description of the different programmers into a
separate section of the manpage instead of having them one after the
other without visual structuring in the description of "-p". It is
made as a preparation of a man-page patch that adds the background
of board enables into flashrom.8 that would really blow up the OPTIONS
section.

The only differences in content are:
 - The parameter for serprog is mandatory, not optional
 - Default behaviour of it87spi (using BIOS-set I/O address) is mentioned.
 - Default speed of buspiratespi is mentioned.

Corresponding to flashrom svn r922.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
2010-03-07 12:11:08 +00:00
Russ Dill
3cd5a12e04 Add support for Eon EN29F010
Tested by Russ Dill.
Checked against datasheet by Sean Nelson.
Datasheet: http://www.essi.com.tw/upfile/p2008929171446.pdf

Corresponding to flashrom svn r921.

Signed-off-by: Russ Dill <Russ.Dill@gmail.com>
Acked-by: Sean Nelson <audiohacked@gmail.com>
2010-03-05 08:44:11 +00:00
Michael Karcher
b4a3d1c422 Board enable for Abit IP35 Pro
This board is like the IP35. Just changed the IDs to match.

Corresponding to flashrom svn r920.

Signed-off-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
Acked-by: Timothy Lepre <Klavious@gmail.com>
2010-03-03 16:15:12 +00:00