summaryrefslogtreecommitdiffstats
path: root/chipset_enable.c
diff options
context:
space:
mode:
authorLuc Verhaegen <libv@skynet.be>2010-01-10 15:01:08 +0000
committerLuc Verhaegen <libv@skynet.be>2010-01-10 15:01:08 +0000
commit9cce2f536581da4f278005a621ad95de1e21b284 (patch)
treed7a765fd8a3c1d5cca804890699b770a2616184e /chipset_enable.c
parent1a1415cc671f7f4f88c658d81536f60171859fe1 (diff)
downloadast2050-flashrom-9cce2f536581da4f278005a621ad95de1e21b284.zip
ast2050-flashrom-9cce2f536581da4f278005a621ad95de1e21b284.tar.gz
Chipset: Fix sis5x0 register write verification
Also remove separate sis 5596 routine: superio code will be handled separately, which then turns this routine into the sis 5511 chipset enable. Corresponding to flashrom svn r859. Signed-off-by: Luc Verhaegen <libv@skynet.be> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Diffstat (limited to 'chipset_enable.c')
-rw-r--r--chipset_enable.c16
1 files changed, 3 insertions, 13 deletions
diff --git a/chipset_enable.c b/chipset_enable.c
index 6a0fc4f..f106f96 100644
--- a/chipset_enable.c
+++ b/chipset_enable.c
@@ -144,16 +144,6 @@ static int enable_flash_sis5511(struct pci_dev *dev, const char *name)
return ret;
}
-static int enable_flash_sis5596(struct pci_dev *dev, const char *name)
-{
- int ret;
-
- ret = enable_flash_sis5511(dev, name);
-
- /* FIXME: Needs same superio handling as enable_flash_sis630 */
- return ret;
-}
-
static int enable_flash_sis530(struct pci_dev *dev, const char *name)
{
uint8_t new, newer;
@@ -170,7 +160,7 @@ static int enable_flash_sis530(struct pci_dev *dev, const char *name)
new &= (~0x20);
new |= 0x4;
pci_write_byte(sbdev, 0x45, new);
- newer = pci_read_byte(dev, 0x45);
+ newer = pci_read_byte(sbdev, 0x45);
if (newer != new) {
printf_debug("tried to set register 0x%x to 0x%x on %s failed (WARNING ONLY)\n", 0x45, new, name);
printf_debug("Stuck at 0x%x\n", newer);
@@ -196,7 +186,7 @@ static int enable_flash_sis540(struct pci_dev *dev, const char *name)
new &= (~0x80);
new |= 0x40;
pci_write_byte(sbdev, 0x45, new);
- newer = pci_read_byte(dev, 0x45);
+ newer = pci_read_byte(sbdev, 0x45);
if (newer != new) {
printf_debug("tried to set register 0x%x to 0x%x on %s failed (WARNING ONLY)\n", 0x45, new, name);
printf_debug("Stuck at 0x%x\n", newer);
@@ -1206,7 +1196,7 @@ const struct penable chipset_enables[] = {
{0x1039, 0x0496, NT, "SiS", "85C496+497", enable_flash_sis85c496},
{0x1039, 0x0406, NT, "SiS", "501/5101/5501", enable_flash_sis501},
{0x1039, 0x5511, NT, "SiS", "5511", enable_flash_sis5511},
- {0x1039, 0x5596, NT, "SiS", "5596", enable_flash_sis5596},
+ {0x1039, 0x5596, NT, "SiS", "5596", enable_flash_sis5511},
{0x1039, 0x5571, NT, "SiS", "5571", enable_flash_sis530},
{0x1039, 0x5591, NT, "SiS", "5591/5592", enable_flash_sis530},
{0x1039, 0x5597, NT, "SiS", "5597/5598/5581/5120", enable_flash_sis530},
OpenPOWER on IntegriCloud