From 1138c13e2858ebf247edf6e855eeb1bbedbe85a6 Mon Sep 17 00:00:00 2001 From: imp Date: Thu, 8 Feb 2001 22:14:27 +0000 Subject: Fix memory leaks with dev_get_children(). Submitted by: Jeroen Ruigrok/Asmodai --- sys/dev/pccbb/pccbb.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'sys/dev/pccbb') diff --git a/sys/dev/pccbb/pccbb.c b/sys/dev/pccbb/pccbb.c index c319e2f..b45b7ce 100644 --- a/sys/dev/pccbb/pccbb.c +++ b/sys/dev/pccbb/pccbb.c @@ -89,6 +89,10 @@ pci_write_config(DEV, REG, ( \ pci_read_config(DEV, REG, SIZE) MASK1) MASK2, SIZE) +/* + * XXX all the pcic code really doesn't belong here and needs to be + * XXX migrated to its own file, shared with the 16-bit code + */ #define PCIC_READ(SC,REG) \ (((u_int8_t*)((SC)->sc_socketreg))[0x800+(REG)]) #define PCIC_WRITE(SC,REG,val) \ @@ -522,6 +526,7 @@ pccbb_detach(device_t dev) else error++; } + free(devlist, M_TEMP); if (error > 0) return ENXIO; @@ -585,6 +590,7 @@ pccbb_driver_added(device_t dev, driver_t *driver) driver->name); } } + free(devlist, M_TEMP); } static void -- cgit v1.1