4 #define W977_EFER 0x370
5 #define W977_EFIR 0x370
6 #define W977_EFDR 0x371
7 #define W977_DEVICE_IR 0x06
11 * Enter extended function mode
13 static inline void w977_efm_enter(void)
15 outb(0x87, W977_EFER
);
16 outb(0x87, W977_EFER
);
20 * Select a device to configure
23 static inline void w977_select_device(__u8 devnum
)
25 outb(0x07, W977_EFIR
);
26 outb(devnum
, W977_EFDR
);
30 * Write a byte to a register
32 static inline void w977_write_reg(__u8 reg
, __u8 value
)
35 outb(value
, W977_EFDR
);
39 * read a byte from a register
41 static inline __u8
w977_read_reg(__u8 reg
)
44 return inb(W977_EFDR
);
48 * Exit extended function mode
50 static inline void w977_efm_exit(void)
52 outb(0xAA, W977_EFER
);