3 * Humboldt Solutions Ltd, adrian@humboldt.co.uk.
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License as
7 * published by the Free Software Foundation; either version 2 of
8 * the License, or (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
24 static unsigned bsp_size(struct nvram_device *data)
29 static int bsp_read_block(struct nvram_device *dev, unsigned offset,
30 unsigned char *data, unsigned length)
34 for(i = 0; i < length; i++)
36 outb(((offset + i) >> 8) & 0xff, 0x74);
37 outb((offset + i) & 0xff, 0x75);
43 static int bsp_write_byte(struct nvram_device *data, unsigned offset, unsigned char byte)
45 outb((offset >> 8) & 0xff, 0x74);
46 outb(offset & 0xff, 0x75);
51 nvram_device bsp_nvram = {
52 bsp_size, bsp_read_block, bsp_write_byte, 0, 0