diff options
Diffstat (limited to 'drivers/pci/hotplug')
| -rw-r--r-- | drivers/pci/hotplug/cpqphp_nvram.c | 3 | ||||
| -rw-r--r-- | drivers/pci/hotplug/cpqphp_pci.c | 21 | ||||
| -rw-r--r-- | drivers/pci/hotplug/ibmphp_ebda.c | 9 | ||||
| -rw-r--r-- | drivers/pci/hotplug/ibmphp_pci.c | 36 | ||||
| -rw-r--r-- | drivers/pci/hotplug/ibmphp_res.c | 21 |
5 files changed, 30 insertions, 60 deletions
diff --git a/drivers/pci/hotplug/cpqphp_nvram.c b/drivers/pci/hotplug/cpqphp_nvram.c index 692d3cafa16d..a197fb98be3e 100644 --- a/drivers/pci/hotplug/cpqphp_nvram.c +++ b/drivers/pci/hotplug/cpqphp_nvram.c @@ -532,8 +532,7 @@ int compaq_nvram_load(void __iomem *rom_start, struct controller *ctrl) } while (numpmem--) { - p_mem_node = kmalloc_obj(struct pci_resource, - GFP_KERNEL); + p_mem_node = kmalloc_obj(struct pci_resource); if (!p_mem_node) break; diff --git a/drivers/pci/hotplug/cpqphp_pci.c b/drivers/pci/hotplug/cpqphp_pci.c index 4ccd5294c545..81c58b1ec200 100644 --- a/drivers/pci/hotplug/cpqphp_pci.c +++ b/drivers/pci/hotplug/cpqphp_pci.c @@ -768,8 +768,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) pci_bus_read_config_word(pci_bus, devfn, PCI_PREF_MEMORY_LIMIT, &w_length); if ((w_base <= w_length) && (save_command & 0x02)) { - p_mem_node = kmalloc_obj(*p_mem_node, - GFP_KERNEL); + p_mem_node = kmalloc_obj(*p_mem_node); if (!p_mem_node) return -ENOMEM; @@ -800,8 +799,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) temp_register = base & 0xFFFFFFFE; temp_register = (~temp_register) + 1; - io_node = kmalloc_obj(*io_node, - GFP_KERNEL); + io_node = kmalloc_obj(*io_node); if (!io_node) return -ENOMEM; @@ -818,8 +816,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) temp_register = base & 0xFFFFFFF0; temp_register = (~temp_register) + 1; - p_mem_node = kmalloc_obj(*p_mem_node, - GFP_KERNEL); + p_mem_node = kmalloc_obj(*p_mem_node); if (!p_mem_node) return -ENOMEM; @@ -835,8 +832,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) temp_register = base & 0xFFFFFFF0; temp_register = (~temp_register) + 1; - mem_node = kmalloc_obj(*mem_node, - GFP_KERNEL); + mem_node = kmalloc_obj(*mem_node); if (!mem_node) return -ENOMEM; @@ -872,8 +868,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) temp_register = base & 0xFFFFFFFE; temp_register = (~temp_register) + 1; - io_node = kmalloc_obj(*io_node, - GFP_KERNEL); + io_node = kmalloc_obj(*io_node); if (!io_node) return -ENOMEM; @@ -889,8 +884,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) temp_register = base & 0xFFFFFFF0; temp_register = (~temp_register) + 1; - p_mem_node = kmalloc_obj(*p_mem_node, - GFP_KERNEL); + p_mem_node = kmalloc_obj(*p_mem_node); if (!p_mem_node) return -ENOMEM; @@ -906,8 +900,7 @@ int cpqhp_save_used_resources(struct controller *ctrl, struct pci_func *func) temp_register = base & 0xFFFFFFF0; temp_register = (~temp_register) + 1; - mem_node = kmalloc_obj(*mem_node, - GFP_KERNEL); + mem_node = kmalloc_obj(*mem_node); if (!mem_node) return -ENOMEM; diff --git a/drivers/pci/hotplug/ibmphp_ebda.c b/drivers/pci/hotplug/ibmphp_ebda.c index 49575cb2a2dc..c1939b88e75b 100644 --- a/drivers/pci/hotplug/ibmphp_ebda.c +++ b/drivers/pci/hotplug/ibmphp_ebda.c @@ -352,8 +352,7 @@ int __init ibmphp_access_ebda(void) debug("now enter io table ---\n"); debug("rio blk id: %x\n", blk_id); - rio_table_ptr = kzalloc_obj(struct rio_table_hdr, - GFP_KERNEL); + rio_table_ptr = kzalloc_obj(struct rio_table_hdr); if (!rio_table_ptr) { rc = -ENOMEM; goto out; @@ -500,8 +499,7 @@ static int combine_wpg_for_expansion(void) list_for_each_entry(rio_detail_ptr, &rio_lo_head, rio_detail_list) { opt_rio_lo_ptr = search_opt_lo(rio_detail_ptr->chassis_num); if (!opt_rio_lo_ptr) { - opt_rio_lo_ptr = kzalloc_obj(struct opt_rio_lo, - GFP_KERNEL); + opt_rio_lo_ptr = kzalloc_obj(struct opt_rio_lo); if (!opt_rio_lo_ptr) return -ENOMEM; opt_rio_lo_ptr->rio_type = rio_detail_ptr->rio_type; @@ -740,8 +738,7 @@ static int __init ebda_rsrc_controller(void) bus_info_ptr2 = ibmphp_find_same_bus_num(slot_ptr->slot_bus_num); if (!bus_info_ptr2) { - bus_info_ptr1 = kzalloc_obj(struct bus_info, - GFP_KERNEL); + bus_info_ptr1 = kzalloc_obj(struct bus_info); if (!bus_info_ptr1) { rc = -ENOMEM; goto error_no_slot; diff --git a/drivers/pci/hotplug/ibmphp_pci.c b/drivers/pci/hotplug/ibmphp_pci.c index c4d28987af3f..cffce14879a6 100644 --- a/drivers/pci/hotplug/ibmphp_pci.c +++ b/drivers/pci/hotplug/ibmphp_pci.c @@ -152,8 +152,7 @@ int ibmphp_configure_card(struct pci_func *func, u8 slotno) cleanup_count = 6; goto error; } - newfunc = kzalloc_obj(*newfunc, - GFP_KERNEL); + newfunc = kzalloc_obj(*newfunc); if (!newfunc) return -ENOMEM; @@ -190,8 +189,7 @@ int ibmphp_configure_card(struct pci_func *func, u8 slotno) flag = 0; for (i = 0; i < 32; i++) { if (func->devices[i]) { - newfunc = kzalloc_obj(*newfunc, - GFP_KERNEL); + newfunc = kzalloc_obj(*newfunc); if (!newfunc) return -ENOMEM; @@ -218,8 +216,7 @@ int ibmphp_configure_card(struct pci_func *func, u8 slotno) } } - newfunc = kzalloc_obj(*newfunc, - GFP_KERNEL); + newfunc = kzalloc_obj(*newfunc); if (!newfunc) return -ENOMEM; @@ -264,8 +261,7 @@ int ibmphp_configure_card(struct pci_func *func, u8 slotno) for (i = 0; i < 32; i++) { if (func->devices[i]) { debug("inside for loop, device is %x\n", i); - newfunc = kzalloc_obj(*newfunc, - GFP_KERNEL); + newfunc = kzalloc_obj(*newfunc); if (!newfunc) return -ENOMEM; @@ -388,8 +384,7 @@ static int configure_device(struct pci_func *func) debug("len[count] in IO %x, count %d\n", len[count], count); - io[count] = kzalloc_obj(struct resource_node, - GFP_KERNEL); + io[count] = kzalloc_obj(struct resource_node); if (!io[count]) return -ENOMEM; @@ -426,8 +421,7 @@ static int configure_device(struct pci_func *func) debug("len[count] in PFMEM %x, count %d\n", len[count], count); - pfmem[count] = kzalloc_obj(struct resource_node, - GFP_KERNEL); + pfmem[count] = kzalloc_obj(struct resource_node); if (!pfmem[count]) return -ENOMEM; @@ -441,8 +435,7 @@ static int configure_device(struct pci_func *func) ibmphp_add_resource(pfmem[count]); func->pfmem[count] = pfmem[count]; } else { - mem_tmp = kzalloc_obj(*mem_tmp, - GFP_KERNEL); + mem_tmp = kzalloc_obj(*mem_tmp); if (!mem_tmp) { kfree(pfmem[count]); return -ENOMEM; @@ -492,8 +485,7 @@ static int configure_device(struct pci_func *func) debug("len[count] in Mem %x, count %d\n", len[count], count); - mem[count] = kzalloc_obj(struct resource_node, - GFP_KERNEL); + mem[count] = kzalloc_obj(struct resource_node); if (!mem[count]) return -ENOMEM; @@ -656,8 +648,7 @@ static int configure_bridge(struct pci_func **func_passed, u8 slotno) debug("len[count] in IO = %x\n", len[count]); - bus_io[count] = kzalloc_obj(struct resource_node, - GFP_KERNEL); + bus_io[count] = kzalloc_obj(struct resource_node); if (!bus_io[count]) { retval = -ENOMEM; @@ -689,8 +680,7 @@ static int configure_bridge(struct pci_func **func_passed, u8 slotno) debug("len[count] in PFMEM = %x\n", len[count]); - bus_pfmem[count] = kzalloc_obj(struct resource_node, - GFP_KERNEL); + bus_pfmem[count] = kzalloc_obj(struct resource_node); if (!bus_pfmem[count]) { retval = -ENOMEM; goto error; @@ -705,8 +695,7 @@ static int configure_bridge(struct pci_func **func_passed, u8 slotno) ibmphp_add_resource(bus_pfmem[count]); func->pfmem[count] = bus_pfmem[count]; } else { - mem_tmp = kzalloc_obj(*mem_tmp, - GFP_KERNEL); + mem_tmp = kzalloc_obj(*mem_tmp); if (!mem_tmp) { retval = -ENOMEM; goto error; @@ -746,8 +735,7 @@ static int configure_bridge(struct pci_func **func_passed, u8 slotno) debug("len[count] in Memory is %x\n", len[count]); - bus_mem[count] = kzalloc_obj(struct resource_node, - GFP_KERNEL); + bus_mem[count] = kzalloc_obj(struct resource_node); if (!bus_mem[count]) { retval = -ENOMEM; goto error; diff --git a/drivers/pci/hotplug/ibmphp_res.c b/drivers/pci/hotplug/ibmphp_res.c index e52d4acd1310..0294fd97e6db 100644 --- a/drivers/pci/hotplug/ibmphp_res.c +++ b/drivers/pci/hotplug/ibmphp_res.c @@ -1687,8 +1687,7 @@ static int __init once_over(void) bus_cur->firstPFMemFromMem = pfmem_cur; - mem = kzalloc_obj(struct resource_node, - GFP_KERNEL); + mem = kzalloc_obj(struct resource_node); if (!mem) return -ENOMEM; @@ -1970,8 +1969,7 @@ static int __init update_bridge_ranges(struct bus_node **bus) end_address |= (upper_io_end << 16); if ((start_address) && (start_address <= end_address)) { - range = kzalloc_obj(struct range_node, - GFP_KERNEL); + range = kzalloc_obj(struct range_node); if (!range) return -ENOMEM; @@ -1995,8 +1993,7 @@ static int __init update_bridge_ranges(struct bus_node **bus) fix_resources(bus_sec); if (ibmphp_find_resource(bus_cur, start_address, &io, IO)) { - io = kzalloc_obj(struct resource_node, - GFP_KERNEL); + io = kzalloc_obj(struct resource_node); if (!io) { kfree(range); return -ENOMEM; @@ -2019,8 +2016,7 @@ static int __init update_bridge_ranges(struct bus_node **bus) if ((start_address) && (start_address <= end_address)) { - range = kzalloc_obj(struct range_node, - GFP_KERNEL); + range = kzalloc_obj(struct range_node); if (!range) return -ENOMEM; @@ -2045,8 +2041,7 @@ static int __init update_bridge_ranges(struct bus_node **bus) fix_resources(bus_sec); if (ibmphp_find_resource(bus_cur, start_address, &mem, MEM)) { - mem = kzalloc_obj(struct resource_node, - GFP_KERNEL); + mem = kzalloc_obj(struct resource_node); if (!mem) { kfree(range); return -ENOMEM; @@ -2073,8 +2068,7 @@ static int __init update_bridge_ranges(struct bus_node **bus) if ((start_address) && (start_address <= end_address)) { - range = kzalloc_obj(struct range_node, - GFP_KERNEL); + range = kzalloc_obj(struct range_node); if (!range) return -ENOMEM; @@ -2098,8 +2092,7 @@ static int __init update_bridge_ranges(struct bus_node **bus) fix_resources(bus_sec); if (ibmphp_find_resource(bus_cur, start_address, &pfmem, PFMEM)) { - pfmem = kzalloc_obj(struct resource_node, - GFP_KERNEL); + pfmem = kzalloc_obj(struct resource_node); if (!pfmem) { kfree(range); return -ENOMEM; |
