On Sun, 2012-05-06 at 23:51 +0200, Carl-Daniel Hailfinger wrote:
> Am 06.05.2012 21:13 schrieb Carl-Daniel Hailfinger:
> > New version, this time with extremely paranoid checks.
> Even more paranoid checks... and we now handle IT8707F and IT8710F in
> the Winbond detection routine.
As these chips share the config mode init sequence, this makes sense.

> > Please note that this is only SuperI/O detection, we don't call any
> > write enable functions.
> IT8707F and IT8710F write enable needs to be hooked up in it87spi.c, the
> W836xx write enable functions need to be hooked up somewhere.

> +     /* Set HBACS=1. */
> +     sio_mask_alzheimer(hwmport, 0x4e, 0x80, 0x80);
> +     /* Read upper byte of vendor ID. */
> +     OUTB(0x4f, hwmport);
> +     hwm_vendorid = INB(hwmport + 1) << 8;
Why don't you use sio_read to read from the hardware monitor? (three
times)

> +                     tmp = w836xx_deviceid_hwmon(s.port);
> +                     /* FIXME: This might be too paranoid... */
> +                     if (!tmp) {
> +                             msg_pdbg("Probably not a Winbond Super I/O\n");
> +                             break;
> +                     }
I think this *is* to paranoid, but maybe you are right being paranoid.

Acked-by: Michael Karcher <[email protected]>

Thanks for working through the mess of detecting chip generically that
were never meant for that.

Best regards,
  Michael Karcher


_______________________________________________
flashrom mailing list
[email protected]
http://www.flashrom.org/mailman/listinfo/flashrom

Reply via email to