1 /* SPDX-License-Identifier: GPL-2.0-only */
3 /* RAM driver for the SMSC KBC1100 Super I/O chip */
5 #include <device/device.h>
6 #include <device/pnp.h>
7 #include <superio/conf_mode.h>
8 #include <pc80/keyboard.h>
12 /* Forward declarations */
13 static void enable_dev(struct device
*dev
);
14 static void kbc1100_init(struct device
*dev
);
16 struct chip_operations superio_smsc_kbc1100_ops
= {
17 CHIP_NAME("SMSC KBC1100 Super I/O")
18 .enable_dev
= enable_dev
21 static struct device_operations ops
= {
22 .read_resources
= pnp_read_resources
,
23 .set_resources
= pnp_set_resources
,
24 .enable_resources
= pnp_enable_resources
,
25 .enable
= pnp_alt_enable
,
27 .ops_pnp_mode
= &pnp_conf_mode_55_aa
,
30 static struct pnp_info pnp_dev_info
[] = {
31 { NULL
, KBC1100_KBC
, PNP_IO0
| PNP_IO1
| PNP_IRQ0
| PNP_IRQ1
,
35 static void enable_dev(struct device
*dev
)
37 pnp_enable_devices(dev
, &ops
, ARRAY_SIZE(pnp_dev_info
), pnp_dev_info
);
40 static void kbc1100_init(struct device
*dev
)
45 switch (dev
->path
.pnp
.device
) {
47 pc_keyboard_init(NO_AUX_DEVICE
);