Actually you do not need to set the index reg twice. I just used the code pattern from the Agami Aruma board, which does the same thing...
Mondrian Luc Verhaegen wrote: > On Fri, Apr 27, 2007 at 01:01:19PM +0200, Mondrian Nuessle wrote: >> The attached patch enables flashing on the Iwill DK8-HTX board. >> Basically, it configures the SuperIO to set the right GPIO pins, so >> write protection is disabled. >> >> Signed-off-by: Mondrian Nuessle <[EMAIL PROTECTED]> >> --- >> >> Ok, this is the third try :-) >> >> Regards, >> Mondrian > >> + /* set GPIO regs... */ >> + outb(0x2b, EFIR); /* GPIO multiplexed pin reg. */ >> + b = inb(EFDR) | 0xd0; >> + outb(0x2b, EFIR); >> + outb(b, EFDR); > > Is it really necessary to write the index register twice here? Not that > it matters much in codesize. > >> - /* Disable the flash write protect. The flash write protect is >> - * connected to the WinBond w83627hf GPIO 24. >> - */ >> - outb(0x87, EFIR); /* sequence to unlock extended functions */ >> + /* Disable the flash write protect. The flash write protect is >> + * connected to the WinBond w83627hf GPIO 24. >> + */ >> + outb(0x87, EFIR); /* sequence to unlock extended functions */ >> outb(0x87, EFIR); > > Ah, my old spaces for tabs setting, removed now. I had assumed that this > was handled earlier, when stepan committed my code when i was too busy > to fix things then. Sorry for that. > > It will probably still exist in other places of flashrom too, nothing > you should worry about though. > > Luc Verhaegen. > > -- Mondrian Nuessle University of Mannheim Phone: +49 621 181 2717 Computer Architecture Group Fax: +49 621 181 2713 http://ra.ti.uni-mannheim.de mailto:[EMAIL PROTECTED] -- linuxbios mailing list [email protected] http://www.linuxbios.org/mailman/listinfo/linuxbios
