summaryrefslogtreecommitdiff
path: root/util/superiotool/smsc.c
diff options
context:
space:
mode:
Diffstat (limited to 'util/superiotool/smsc.c')
-rw-r--r--util/superiotool/smsc.c98
1 files changed, 93 insertions, 5 deletions
diff --git a/util/superiotool/smsc.c b/util/superiotool/smsc.c
index cd612e87f1..c2fed31193 100644
--- a/util/superiotool/smsc.c
+++ b/util/superiotool/smsc.c
@@ -20,8 +20,11 @@
#include "superiotool.h"
-#define DEVICE_ID_REG 0x0d
-#define DEVICE_REV_REG 0x0e
+#define DEVICE_ID_REG_OLD 0x0d
+#define DEVICE_REV_REG_OLD 0x0e
+
+#define DEVICE_ID_REG 0x20
+#define DEVICE_REV_REG 0x21
const static struct superio_registers reg_table[] = {
{0x28, "FDC37N769", {
@@ -37,6 +40,82 @@ const static struct superio_registers reg_table[] = {
0x80,0x00,0x3c,RSVD,RSVD,0x00,0x00,0x00,0x00,0x00,
0x00,0x00,RSVD,0x00,0x00,0x03,0x00,0x00,EOT}},
{EOT}}},
+ {0x42, "FDC37B80x", {
+ {EOT}}},
+ {0x44, "FDC37B78x", {
+ {EOT}}},
+ {0x4c, "FDC37B72x", {
+ {EOT}}},
+ {0x4d, "FDC37M81x", {
+ {EOT}}},
+ {0x47, "FDC37M60x", {
+ {EOT}}},
+ {0x51, "LPC47B27x", {
+ {EOT}}},
+ {0x59, "LPC47M10x", {
+ {EOT}}},
+ {0x60, "LPC47M15x", {
+ {EOT}}},
+ {0x62, "LPC47S45x", {
+ {EOT}}},
+ {0x6f, "LPC47B397", {
+ {EOT}}},
+ {0x77, "A8000", { /* ASUS A8000, a rebranded DME1737(?) */
+ {NOLDN, NULL,
+ {0x03,0x07,0x20,0x21,0x22,0x23,0x24,0x26,0x27,0x28,
+ 0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,EOT},
+ {RSVD,0x00,0x77,NANA,0x00,RSVD,0x44,MISC,MISC,RSVD,
+ NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
+ {0x0, "Floppy",
+ {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,0xf2,0xf4,
+ 0xf5,EOT},
+ {0x00,0x03,0xf0,0x06,0x02,0x0e,0x00,0xff,0x00,
+ 0x00,EOT}},
+ {0x3, "Parallel port",
+ {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
+ {0x00,0x00,0x00,0x00,0x04,0x3c,0x00,EOT}},
+ {0x4, "COM1",
+ {0x30,0x60,0x61,0x70,0xf0,EOT},
+ {0x00,0x00,0x00,0x00,0x00,EOT}},
+ {0x5, "COM2",
+ {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
+ {0x00,0x00,0x00,0x00,0x00,0x02,0x03,EOT}},
+ {0x7, "Keyboard",
+ {0x30,0x70,0x72,0xf0,EOT},
+ {0x00,0x00,0x00,0x00,EOT}},
+ {0xa, "Runtime registers",
+ {0x30,0x60,0x61,0x62,0x63,0xf0,0xf1,0xf2,EOT},
+ {0x00,0x00,0x00,0x00,0x00,NANA,RSVD,0x04,EOT}},
+ {EOT}}},
+ {0x78, "DME1737", {
+ {NOLDN, NULL,
+ {0x03,0x07,0x20,0x21,0x22,0x23,0x24,0x26,0x27,0x28,
+ 0x2a,0x2b,0x2c,0x2d,0x2e,0x2f,EOT},
+ {RSVD,0x00,0x77,NANA,0x00,RSVD,0x44,MISC,MISC,RSVD,
+ NANA,NANA,NANA,NANA,NANA,NANA,EOT}},
+ {0x0, "Floppy",
+ {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,0xf2,0xf4,
+ 0xf5,EOT},
+ {0x00,0x03,0xf0,0x06,0x02,0x0e,0x00,0xff,0x00,
+ 0x00,EOT}},
+ {0x3, "Parallel port",
+ {0x30,0x60,0x61,0x70,0x74,0xf0,0xf1,EOT},
+ {0x00,0x00,0x00,0x00,0x04,0x3c,0x00,EOT}},
+ {0x4, "COM1",
+ {0x30,0x60,0x61,0x70,0xf0,EOT},
+ {0x00,0x00,0x00,0x00,0x00,EOT}},
+ {0x5, "COM2",
+ {0x30,0x60,0x61,0x70,0xf0,0xf1,0xf2,EOT},
+ {0x00,0x00,0x00,0x00,0x00,0x02,0x03,EOT}},
+ {0x7, "Keyboard",
+ {0x30,0x70,0x72,0xf0,EOT},
+ {0x00,0x00,0x00,0x00,EOT}},
+ {0xa, "Runtime registers",
+ {0x30,0x60,0x61,0x62,0x63,0xf0,0xf1,0xf2,EOT},
+ {0x00,0x00,0x00,0x00,0x00,NANA,RSVD,0x04,EOT}},
+ {EOT}}},
+ {0x81, "SCH5307", {
+ {EOT}}},
{EOT}
};
@@ -56,6 +135,14 @@ void probe_idregs_smsc(uint16_t port)
enter_conf_mode_smsc(port);
+ /* Check for older SMSC Super I/Os. */
+ id = regval(port, DEVICE_ID_REG_OLD);
+ rev = regval(port, DEVICE_REV_REG_OLD);
+
+ if (superio_unknown(reg_table, id))
+ no_superio_found(port);
+
+ /* Check for newer SMSC Super I/Os. */
id = regval(port, DEVICE_ID_REG);
rev = regval(port, DEVICE_REV_REG);
@@ -65,10 +152,11 @@ void probe_idregs_smsc(uint16_t port)
return;
}
- printf("Found SMSC %s (id=0x%02x, rev=0x%02x) at port=0x%x\n",
- get_superio_name(reg_table, id), id, rev, port);
+ printf("Found %s %s (id=0x%02x, rev=0x%02x) at port=0x%x\n",
+ (id == 0x77 ? "ASUS" : "SMSC"), get_superio_name(reg_table, id),
+ id, rev, port);
- dump_superio("SMSC", reg_table, port, id);
+ dump_superio((id == 0x77 ? "ASUS" : "SMSC"), reg_table, port, id);
dump_superio_readable(port); /* TODO */
exit_conf_mode_smsc(port);