1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 #include "superiotool.h"
5 #define DEVICE_ID_REG 0x20
6 #define DEVICE_REV_REG 0x21
8 static const struct superio_registers reg_table
[] = {
9 {0x0b, "SLB9635TT12", {
11 {0x20,0x21,0x26,0x27,EOT
},
12 {0x0b,0x00,NANA
,NANA
,EOT
}},
14 {0x30,0x38,0x60,0x61,0x70,0x71,0xf1,0xf2,0xf3,0xf4,0xf5,EOT
},
15 {0x00,0x00,NANA
,NANA
,0x00,0x02,0xd1,0x15,0x0b,0x00,NANA
,EOT
}},
20 /* same as some SMSC */
21 static void enter_conf_mode_infineon(uint16_t port
)
26 static void exit_conf_mode_infineon(uint16_t port
)
31 void probe_idregs_infineon(uint16_t port
)
35 probing_for("Infineon", "", port
);
37 enter_conf_mode_infineon(port
);
39 devid
= regval(port
, DEVICE_ID_REG
);
40 rev
= regval(port
, DEVICE_REV_REG
);
42 if (superio_unknown(reg_table
, devid
)) {
44 printf(NOTFOUND
"id=0x%02x, rev=0x%02x\n", devid
, rev
);
45 exit_conf_mode_infineon(port
);
49 /* Attempt to prevent false matches on SMSC FDC37N972, see smsc.c */
50 if (((regval(port
, 0x27)<<8)|regval(port
, 0x26)) != port
) {
52 printf(NOTFOUND
"id=0x%02x, rev=0x%02x\n", devid
, rev
);
53 exit_conf_mode_infineon(port
);
57 printf("Found Infineon %s (id=0x%02x, rev=0x%02x) at 0x%x\n",
58 get_superio_name(reg_table
, devid
), devid
, rev
, port
);
61 dump_superio("Infineon", reg_table
, port
, devid
, LDN_SEL
);
63 exit_conf_mode_infineon(port
);
66 void print_infineon_chips(void)
68 print_vendor_chips("Infineon", reg_table
);