From 624fc6d1d9957065529c1b19a2e4c81b2e5e361e Mon Sep 17 00:00:00 2001 From: Marius Strobl Date: Mon, 5 Jun 2006 17:48:54 +0000 Subject: [PATCH] - Declare the PnP map const. - Add devices found in V210 to the PnP map. - Don't leak memory if we didn't find a match for a node in the PnP map. MFC after: 2 weeks --- sys/sparc64/isa/isa.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sys/sparc64/isa/isa.c b/sys/sparc64/isa/isa.c index 4147e376a593..75c736b2352b 100644 --- a/sys/sparc64/isa/isa.c +++ b/sys/sparc64/isa/isa.c @@ -153,7 +153,7 @@ isa_init(device_t dev) } } -static struct { +static const struct { const char *name; uint32_t id; } ofw_isa_pnp_map[] = { @@ -164,6 +164,8 @@ static struct { { "flashprom", 0x0100ae4e }, /* SUN0001 */ { "parallel", 0x0104d041 }, /* PNP0401 */ { "serial", 0x0105d041 }, /* PNP0501 */ + { "i2c", 0x0200ae4e }, /* SUN0002 */ + { "rmc-comm", 0x0300ae4e }, /* SUN0003 */ { "kb_ps2", 0x0303d041 }, /* PNP0303 */ { "kdmouse", 0x030fd041 }, /* PNP0F03 */ { "power", 0x0c0cd041 }, /* PNP0C0C */ @@ -213,6 +215,7 @@ isa_setup_children(device_t dev, phandle_t parent) if (ofw_isa_pnp_map[i].name == NULL) { printf("isa_setup_children: no PnP map entry for node " "0x%lx: %s\n", (unsigned long)node, name); + free(name, M_OFWPROP); continue; }