Hi,
The Adaptec 1430SA is a Marvell 88SX7042 based controller. It has a different vendor/device ID pair when using the Adaptec firmware, so I added this in:
--- satamv.c (revision 1364) +++ satamv.c (working copy) @@ -30,6 +30,7 @@ const struct pcidev_status satas_mv[] = { /* 88SX6041 and 88SX6042 are the same according to the datasheet. */ {0x11ab, 0x7042, OK, "Marvell", "88SX7042 PCI-e 4-port SATA-II"}, + {0x9005, 0x0243, OK, "Marvell", "88SX7042 PCI-e 4-port SATA-II (Adaptec 1430SA)"},
{}, };
... but it doesn't seem to work on the Adaptec card:
flashrom -p satamv:pci=06:00.0 flashrom v0.9.3-r1364 on Linux 2.6.39-2-amd64 (x86_64), built with libpci 3.1.7, GCC 4.4.5, little endian flashrom is free software, get the source code at http://www.flashrom.org
Calibrating delay loop... OK. Found "Marvell 88SX7042 PCI-e 4-port SATA-II (Adaptec 1430SA)" (9005:0243, BDF 06:00.0). Warning! Either the straps are incorrect or you have no flash or someone overwrote the strap values! No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
The eeprom on the card is an AMD Am29LV004BT (which is supported for probing).
Cheers,
Tim.
On Wed, 06 Jul 2011 22:21:04 +0100 Tim Small tim@seoss.co.uk wrote:
Hi,
The Adaptec 1430SA is a Marvell 88SX7042 based controller. It has a different vendor/device ID pair when using the Adaptec firmware, so I added this in:
--- satamv.c (revision 1364) +++ satamv.c (working copy) @@ -30,6 +30,7 @@ const struct pcidev_status satas_mv[] = { /* 88SX6041 and 88SX6042 are the same according to the datasheet. */ {0x11ab, 0x7042, OK, "Marvell", "88SX7042 PCI-e 4-port SATA-II"},
{0x9005, 0x0243, OK, "Marvell", "88SX7042 PCI-e 4-port SATA-II
(Adaptec 1430SA)"},
{},
};
looks ok afaict.
... but it doesn't seem to work on the Adaptec card:
flashrom -p satamv:pci=06:00.0 flashrom v0.9.3-r1364 on Linux 2.6.39-2-amd64 (x86_64), built with libpci 3.1.7, GCC 4.4.5, little endian flashrom is free software, get the source code at http://www.flashrom.org
Calibrating delay loop... OK. Found "Marvell 88SX7042 PCI-e 4-port SATA-II (Adaptec 1430SA)" (9005:0243, BDF 06:00.0). Warning! Either the straps are incorrect or you have no flash or someone overwrote the strap values! No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically.
the init code uses lots of spew printing which might be useful here. please post the output of "flashrom -p satamv:pci=06:00.0 -VV"
i am looking at that code for the first time and have no datasheet (yet). the warning stems from GPIO Port Mode (lowest two bits of GPIO_PORT_CONTROL) not being 0x2 i.e. 10b.
The eeprom on the card is an AMD Am29LV004BT (which is supported for probing).
should not be the problem imho.
the init code uses lots of spew printing which might be useful here.
please post the output of "flashrom -p satamv:pci=06:00.0 -VV"
root@debian:~# flashrom -VV -p satamv:pci=06:00.0 -c Am29LV004BT flashrom v0.9.3-r1364 on Linux 2.6.39-2-amd64 (x86_64), built with libpci 3.1.7, GCC 4.4.5, little endian flashrom is free software, get the source code at http://www.flashrom.org
Calibrating delay loop... OS timer resolution is 1 usecs, 2496M loops per second, 10 myus = 10 us, 100 myus = 108 us, 1000 myus = 1010 us, 10000 myus = 10015 us, 4 myus = 5 us, OK. Initializing satamv programmer Found "Marvell 88SX7042 PCI-e 4-port SATA-II (Adaptec 1430SA)" (9005:0243, BDF 06:00.0). PCI header type 0x00 Requested BAR is MEM, 64bit, not prefetchable Flash Parameters: TurnOff=0x7 Acc2First=0xf Acc2Next=0xf ALE2Wr=0x7 WrLow=0x7 WrHigh=0x7 Reserved[21:20]=0x0 TurnOffExt=0x1 Acc2FirstExt=0x1 Acc2NextExt=0x1 ALE2WrExt=0x1 WrLowExt=0x1 WrHighExt=0x1 Reserved[31:28]=0x0 Expansion ROM BAR Control: ExpROMSz=0x0 PCI BAR2 (Flash/NVRAM) Control: Bar2En=0x1 BAR2TransAttr=0xf BAR2Sz=0x1 GPIOPortMode=0x0 Warning! Either the straps are incorrect or you have no flash or someone overwrote the strap values! Activating I/O BAR at 0x9c00 Probing for AMD Am29LV004BT, 512 kB: probe_jedec_common: id1 0x55, id2 0xaa, id1 parity violation, id1 is normal flash content, id2 is normal flash content No EEPROM/flash device found. Note: flashrom can never write if the flash chip isn't found automatically. Restoring MMIO space at 0x7fa9effa14f0 Restoring MMIO space at 0x7fa9eff91c08
i am looking at that code for the first time and have no datasheet (yet).
I was unable to track it down either.
Cheers,
Tim.
OK, so I've banged my head against this for a while more, but don't expect to get much further. Perhaps these notes will be useful for someone else.
Reserved[31:28]=0x0
This should be 0x8 apparently, but fixing it up didn't do any good.
GPIOPortMode=0x0 Warning! Either the straps are incorrect or you have no flash or someone overwrote the strap values!
This indicates that the 88SX7042 is in a mode (presumably set by Adaptec's custom BIOS after it no longer needed to read flash) whereby some of the GPIO pins are used to run SATA port activity/status LEDs, instead of talking to the flash chip. The code puts the port into flash mode, and I verified that this "stuck", but still no dice.
Maybe there's some GPIO pokery needed first to put Adaptec's hardware back into flash mode, but I couldn't see anything obvious when looking at the card.
Maybe a logic analyser is needed, or maybe running the Adaptec DOS updater under kvm+vtd to see how it sets up the chip prior to write. I don't have either available at the moment unfortunately...
Anyway, my reason for doing this was that I actually want to wipe/disable the Adaptec flash (since I don't want to use their proprietary "HostRAID" blurgh anyway, and their BIOS takes ages to timeout port scans when SATA port multipliers attached and/or their proprietary RAID metadata isn't present on the drives etc. etc. etc.).
It's probably possible to do this instead by disabling the expansion ROM PCI mapping at reset time, so I'll attack it that way if I have time....
Tim.