diff --git a/[refs] b/[refs] index cca20dcb3d40..3f94a2aeeefb 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: d046943cbaf332f75284ad99f4b3e60bae7ffff2 +refs/heads/master: 831c70fc13ca8c6074ab0c9d1121a93fd6c5a34a diff --git a/trunk/arch/arm/plat-s3c24xx/dma.c b/trunk/arch/arm/plat-s3c24xx/dma.c index 6d048490c559..08d80f2f51f2 100644 --- a/trunk/arch/arm/plat-s3c24xx/dma.c +++ b/trunk/arch/arm/plat-s3c24xx/dma.c @@ -1333,7 +1333,7 @@ int __init s3c24xx_dma_init(unsigned int channels, unsigned int irq, dma_kmem = kmem_cache_create("dma_desc", sizeof(struct s3c2410_dma_buf), 0, SLAB_HWCACHE_ALIGN, - s3c2410_dma_cache_ctor); + s3c2410_dma_cache_ctor, NULL); if (dma_kmem == NULL) { printk(KERN_ERR "dma failed to make kmem cache\n"); diff --git a/trunk/arch/arm26/mm/memc.c b/trunk/arch/arm26/mm/memc.c index ffecd8578247..42505541a9b1 100644 --- a/trunk/arch/arm26/mm/memc.c +++ b/trunk/arch/arm26/mm/memc.c @@ -176,9 +176,9 @@ void __init pgtable_cache_init(void) { pte_cache = kmem_cache_create("pte-cache", sizeof(pte_t) * PTRS_PER_PTE, - 0, SLAB_PANIC, pte_cache_ctor); + 0, SLAB_PANIC, pte_cache_ctor, NULL); pgd_cache = kmem_cache_create("pgd-cache", MEMC_TABLE_SIZE + sizeof(pgd_t) * PTRS_PER_PGD, - 0, SLAB_PANIC, pgd_cache_ctor); + 0, SLAB_PANIC, pgd_cache_ctor, NULL); } diff --git a/trunk/arch/i386/mm/init.c b/trunk/arch/i386/mm/init.c index 6e72f22e6bbd..6a68b1ae061c 100644 --- a/trunk/arch/i386/mm/init.c +++ b/trunk/arch/i386/mm/init.c @@ -752,7 +752,8 @@ void __init pgtable_cache_init(void) PTRS_PER_PMD*sizeof(pmd_t), PTRS_PER_PMD*sizeof(pmd_t), SLAB_PANIC, - pmd_ctor); + pmd_ctor, + NULL); if (!SHARED_KERNEL_PMD) { /* If we're in PAE mode and have a non-shared kernel pmd, then the pgd size must be a diff --git a/trunk/arch/ia64/ia32/ia32_support.c b/trunk/arch/ia64/ia32/ia32_support.c index e13a1a1db4b5..beea7a0b9dc6 100644 --- a/trunk/arch/ia64/ia32/ia32_support.c +++ b/trunk/arch/ia64/ia32/ia32_support.c @@ -253,7 +253,7 @@ ia32_init (void) partial_page_cachep = kmem_cache_create("partial_page_cache", sizeof(struct partial_page), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); } #endif return 0; diff --git a/trunk/arch/m68k/Kconfig b/trunk/arch/m68k/Kconfig index 20a9c08e59c3..a86e2e9a639f 100644 --- a/trunk/arch/m68k/Kconfig +++ b/trunk/arch/m68k/Kconfig @@ -37,10 +37,6 @@ config TIME_LOW_RES bool default y -config GENERIC_IOMAP - bool - default y - config ARCH_MAY_HAVE_PC_FDC bool depends on Q40 || (BROKEN && SUN3X) @@ -49,9 +45,6 @@ config ARCH_MAY_HAVE_PC_FDC config NO_IOPORT def_bool y -config NO_DMA - def_bool SUN3 - mainmenu "Linux/68k Kernel Configuration" source "init/Kconfig" diff --git a/trunk/arch/m68k/apollo/config.c b/trunk/arch/m68k/apollo/config.c index 78df98f2029a..cb8e7609df4c 100644 --- a/trunk/arch/m68k/apollo/config.c +++ b/trunk/arch/m68k/apollo/config.c @@ -148,8 +148,8 @@ void dn_serial_print (const char *str) } } -void __init config_apollo(void) -{ +void config_apollo(void) { + int i; dn_setup_model(); diff --git a/trunk/arch/m68k/apollo/dn_ints.c b/trunk/arch/m68k/apollo/dn_ints.c index 5d47f3aa3810..13bd41bed28e 100644 --- a/trunk/arch/m68k/apollo/dn_ints.c +++ b/trunk/arch/m68k/apollo/dn_ints.c @@ -37,7 +37,7 @@ static struct irq_controller apollo_irq_controller = { }; -void __init dn_init_IRQ(void) +void dn_init_IRQ(void) { m68k_setup_user_interrupt(VEC_USER + 96, 16, dn_process_int); m68k_setup_irq_controller(&apollo_irq_controller, IRQ_APOLLO, 16); diff --git a/trunk/arch/m68k/atari/atakeyb.c b/trunk/arch/m68k/atari/atakeyb.c index 2b5f64726a2e..1c29603b16b3 100644 --- a/trunk/arch/m68k/atari/atakeyb.c +++ b/trunk/arch/m68k/atari/atakeyb.c @@ -13,7 +13,6 @@ * enhanced by Bjoern Brauel and Roman Hodek */ -#include #include #include #include @@ -43,9 +42,6 @@ void (*atari_mouse_interrupt_hook) (char *); void (*atari_input_keyboard_interrupt_hook) (unsigned char, char); /* Hook for mouse inputdev driver */ void (*atari_input_mouse_interrupt_hook) (char *); -EXPORT_SYMBOL(atari_mouse_interrupt_hook); -EXPORT_SYMBOL(atari_input_keyboard_interrupt_hook); -EXPORT_SYMBOL(atari_input_mouse_interrupt_hook); /* variables for IKBD self test: */ @@ -433,7 +429,6 @@ void ikbd_mouse_rel_pos(void) ikbd_write(cmd, 1); } -EXPORT_SYMBOL(ikbd_mouse_rel_pos); /* Set absolute mouse position reporting */ void ikbd_mouse_abs_pos(int xmax, int ymax) @@ -458,7 +453,6 @@ void ikbd_mouse_thresh(int x, int y) ikbd_write(cmd, 3); } -EXPORT_SYMBOL(ikbd_mouse_thresh); /* Set mouse scale */ void ikbd_mouse_scale(int x, int y) @@ -501,7 +495,6 @@ void ikbd_mouse_y0_top(void) ikbd_write(cmd, 1); } -EXPORT_SYMBOL(ikbd_mouse_y0_top); /* Resume */ void ikbd_resume(void) @@ -518,7 +511,6 @@ void ikbd_mouse_disable(void) ikbd_write(cmd, 1); } -EXPORT_SYMBOL(ikbd_mouse_disable); /* Pause output */ void ikbd_pause(void) @@ -704,6 +696,7 @@ int __init atari_keyb_init(void) return 0; } + int atari_kbdrate(struct kbd_repeat *k) { if (k->delay > 0) { diff --git a/trunk/arch/m68k/bvme6000/config.c b/trunk/arch/m68k/bvme6000/config.c index 9433a88a33c4..896ae3d3d919 100644 --- a/trunk/arch/m68k/bvme6000/config.c +++ b/trunk/arch/m68k/bvme6000/config.c @@ -97,7 +97,7 @@ static int bvme6000_get_hardware_list(char *buffer) * This function is called during kernel startup to initialize * the bvme6000 IRQ handling routines. */ -static void __init bvme6000_init_IRQ(void) +static void bvme6000_init_IRQ(void) { m68k_setup_user_interrupt(VEC_USER, 192, NULL); } diff --git a/trunk/arch/m68k/kernel/head.S b/trunk/arch/m68k/kernel/head.S index faa6764f1d13..05741f233567 100644 --- a/trunk/arch/m68k/kernel/head.S +++ b/trunk/arch/m68k/kernel/head.S @@ -577,7 +577,7 @@ func_define putn,1 #endif .endm -.section ".text.head","ax" +.text ENTRY(_stext) /* * Version numbers of the bootinfo interface diff --git a/trunk/arch/m68k/kernel/setup.c b/trunk/arch/m68k/kernel/setup.c index 7e6d5fb75390..215c7bd43924 100644 --- a/trunk/arch/m68k/kernel/setup.c +++ b/trunk/arch/m68k/kernel/setup.c @@ -58,7 +58,6 @@ extern int end; extern unsigned long availmem; int m68k_num_memory; -EXPORT_SYMBOL(m68k_num_memory); int m68k_realnum_memory; EXPORT_SYMBOL(m68k_realnum_memory); unsigned long m68k_memoffset; diff --git a/trunk/arch/m68k/kernel/sun3-head.S b/trunk/arch/m68k/kernel/sun3-head.S index aad01592dbbc..4b5f050204e8 100644 --- a/trunk/arch/m68k/kernel/sun3-head.S +++ b/trunk/arch/m68k/kernel/sun3-head.S @@ -29,7 +29,7 @@ kernel_pmd_table: .skip 0x2000 .globl kernel_pg_dir .equ kernel_pg_dir,kernel_pmd_table - .section .text.head + .section .head ENTRY(_stext) ENTRY(_start) diff --git a/trunk/arch/m68k/kernel/time.c b/trunk/arch/m68k/kernel/time.c index 7db41594d7b6..4c065f9ceffc 100644 --- a/trunk/arch/m68k/kernel/time.c +++ b/trunk/arch/m68k/kernel/time.c @@ -72,7 +72,7 @@ static irqreturn_t timer_interrupt(int irq, void *dummy) return IRQ_HANDLED; } -void __init time_init(void) +void time_init(void) { struct rtc_time time; diff --git a/trunk/arch/m68k/kernel/vmlinux-std.lds b/trunk/arch/m68k/kernel/vmlinux-std.lds index c42245775a4d..40f02b128f22 100644 --- a/trunk/arch/m68k/kernel/vmlinux-std.lds +++ b/trunk/arch/m68k/kernel/vmlinux-std.lds @@ -11,7 +11,6 @@ SECTIONS . = 0x1000; _text = .; /* Text and read-only data */ .text : { - *(.text.head) TEXT_TEXT SCHED_TEXT LOCK_TEXT diff --git a/trunk/arch/m68k/kernel/vmlinux-sun3.lds b/trunk/arch/m68k/kernel/vmlinux-sun3.lds index 4adffefb5c48..f06425b6d206 100644 --- a/trunk/arch/m68k/kernel/vmlinux-sun3.lds +++ b/trunk/arch/m68k/kernel/vmlinux-sun3.lds @@ -11,7 +11,7 @@ SECTIONS . = 0xE002000; _text = .; /* Text and read-only data */ .text : { - *(.text.head) + *(.head) TEXT_TEXT SCHED_TEXT LOCK_TEXT diff --git a/trunk/arch/m68k/mac/config.c b/trunk/arch/m68k/mac/config.c index 8547dbc5e8d7..5fd413246f89 100644 --- a/trunk/arch/m68k/mac/config.c +++ b/trunk/arch/m68k/mac/config.c @@ -49,7 +49,6 @@ struct mac_booter_data mac_bi_data; int mac_bisize = sizeof mac_bi_data; struct mac_hw_present mac_hw_present; -EXPORT_SYMBOL(mac_hw_present); /* New m68k bootinfo stuff and videobase */ @@ -85,7 +84,7 @@ extern void nubus_sweep_video(void); static void mac_get_model(char *str); -static void __init mac_sched_init(irq_handler_t vector) +static void mac_sched_init(irq_handler_t vector) { via_init_clock(vector); } @@ -770,7 +769,7 @@ static struct mac_model mac_data_table[] = { } }; -void __init mac_identify(void) +void mac_identify(void) { struct mac_model *m; @@ -847,7 +846,7 @@ void __init mac_identify(void) baboon_init(); } -void __init mac_report_hardware(void) +void mac_report_hardware(void) { printk(KERN_INFO "Apple Macintosh %s\n", macintosh_config->name); } diff --git a/trunk/arch/m68k/mac/macints.c b/trunk/arch/m68k/mac/macints.c index ecddac4a02b9..0fc72d8f786e 100644 --- a/trunk/arch/m68k/mac/macints.c +++ b/trunk/arch/m68k/mac/macints.c @@ -114,7 +114,6 @@ * */ -#include #include #include #include @@ -225,7 +224,7 @@ static struct irq_controller mac_irq_controller = { .disable = mac_disable_irq, }; -void __init mac_init_IRQ(void) +void mac_init_IRQ(void) { #ifdef DEBUG_MACINTS printk("mac_init_IRQ(): Setting things up...\n"); @@ -392,7 +391,6 @@ int mac_irq_pending(unsigned int irq) } return 0; } -EXPORT_SYMBOL(mac_irq_pending); static int num_debug[8]; diff --git a/trunk/arch/m68k/mm/init.c b/trunk/arch/m68k/mm/init.c index f42caa79e4e8..f1de19e1dde6 100644 --- a/trunk/arch/m68k/mm/init.c +++ b/trunk/arch/m68k/mm/init.c @@ -44,7 +44,7 @@ pg_data_t *pg_data_table[65]; EXPORT_SYMBOL(pg_data_table); #endif -void __init m68k_setup_node(int node) +void m68k_setup_node(int node) { #ifndef CONFIG_SINGLE_MEMORY_CHUNK struct mem_info *info = m68k_memory + node; diff --git a/trunk/arch/m68k/mm/sun3kmap.c b/trunk/arch/m68k/mm/sun3kmap.c index 3dc41158c05e..1af24cb5bfe1 100644 --- a/trunk/arch/m68k/mm/sun3kmap.c +++ b/trunk/arch/m68k/mm/sun3kmap.c @@ -105,7 +105,6 @@ void __iomem *sun3_ioremap(unsigned long phys, unsigned long size, return (void __iomem *)ret; } -EXPORT_SYMBOL(sun3_ioremap); void __iomem *__ioremap(unsigned long phys, unsigned long size, int cache) @@ -158,4 +157,3 @@ int sun3_map_test(unsigned long addr, char *val) return ret; } -EXPORT_SYMBOL(sun3_map_test); diff --git a/trunk/arch/m68k/mvme147/config.c b/trunk/arch/m68k/mvme147/config.c index 92fe50714112..4a7df9c3f85a 100644 --- a/trunk/arch/m68k/mvme147/config.c +++ b/trunk/arch/m68k/mvme147/config.c @@ -89,7 +89,7 @@ static int mvme147_get_hardware_list(char *buffer) * the mvme147 IRQ handling routines. */ -void __init mvme147_init_IRQ(void) +void mvme147_init_IRQ(void) { m68k_setup_user_interrupt(VEC_USER, 192, NULL); } diff --git a/trunk/arch/m68k/mvme16x/config.c b/trunk/arch/m68k/mvme16x/config.c index daa785161401..c829ebb6b1af 100644 --- a/trunk/arch/m68k/mvme16x/config.c +++ b/trunk/arch/m68k/mvme16x/config.c @@ -119,7 +119,7 @@ static int mvme16x_get_hardware_list(char *buffer) * that the base vectors for the VMEChip2 and PCCChip2 are valid. */ -static void __init mvme16x_init_IRQ (void) +static void mvme16x_init_IRQ (void) { m68k_setup_user_interrupt(VEC_USER, 192, NULL); } diff --git a/trunk/arch/m68k/q40/q40ints.c b/trunk/arch/m68k/q40/q40ints.c index ad3ed1fb8879..2fb25ae46a8a 100644 --- a/trunk/arch/m68k/q40/q40ints.c +++ b/trunk/arch/m68k/q40/q40ints.c @@ -79,7 +79,7 @@ static struct irq_controller q40_irq_controller = { static int disabled; -void __init q40_init_IRQ(void) +void q40_init_IRQ(void) { m68k_setup_irq_controller(&q40_irq_controller, 1, Q40_IRQ_MAX); diff --git a/trunk/arch/m68k/sun3/sun3ints.c b/trunk/arch/m68k/sun3/sun3ints.c index cf93481adb1d..50df34bf80e3 100644 --- a/trunk/arch/m68k/sun3/sun3ints.c +++ b/trunk/arch/m68k/sun3/sun3ints.c @@ -97,7 +97,7 @@ static struct irq_controller sun3_irq_controller = { .disable = sun3_disable_irq, }; -void __init sun3_init_IRQ(void) +void sun3_init_IRQ(void) { *sun3_intreg = 1; diff --git a/trunk/arch/m68k/sun3x/prom.c b/trunk/arch/m68k/sun3x/prom.c index a7b7e818d627..48f8eb7b1565 100644 --- a/trunk/arch/m68k/sun3x/prom.c +++ b/trunk/arch/m68k/sun3x/prom.c @@ -92,7 +92,7 @@ static struct console sun3x_debug = { .index = -1, }; -void __init sun3x_prom_init(void) +void sun3x_prom_init(void) { /* Read the vector table */ diff --git a/trunk/arch/powerpc/kernel/rtas_flash.c b/trunk/arch/powerpc/kernel/rtas_flash.c index 62b7bf2f3eab..f72118c0844f 100644 --- a/trunk/arch/powerpc/kernel/rtas_flash.c +++ b/trunk/arch/powerpc/kernel/rtas_flash.c @@ -804,7 +804,7 @@ int __init rtas_flash_init(void) flash_block_cache = kmem_cache_create("rtas_flash_cache", RTAS_BLK_SIZE, RTAS_BLK_SIZE, 0, - rtas_block_ctor); + rtas_block_ctor, NULL); if (!flash_block_cache) { printk(KERN_ERR "%s: failed to create block cache\n", __FUNCTION__); diff --git a/trunk/arch/powerpc/mm/hugetlbpage.c b/trunk/arch/powerpc/mm/hugetlbpage.c index 4835f73af304..92a1b16fb7e3 100644 --- a/trunk/arch/powerpc/mm/hugetlbpage.c +++ b/trunk/arch/powerpc/mm/hugetlbpage.c @@ -542,7 +542,7 @@ static int __init hugetlbpage_init(void) HUGEPTE_TABLE_SIZE, HUGEPTE_TABLE_SIZE, 0, - zero_ctor); + zero_ctor, NULL); if (! huge_pgtable_cache) panic("hugetlbpage_init(): could not create hugepte cache\n"); diff --git a/trunk/arch/powerpc/mm/init_64.c b/trunk/arch/powerpc/mm/init_64.c index 9f27bb56a61d..1d6edf724c85 100644 --- a/trunk/arch/powerpc/mm/init_64.c +++ b/trunk/arch/powerpc/mm/init_64.c @@ -178,6 +178,7 @@ void pgtable_cache_init(void) pgtable_cache[i] = kmem_cache_create(name, size, size, SLAB_PANIC, - zero_ctor); + zero_ctor, + NULL); } } diff --git a/trunk/arch/powerpc/platforms/cell/spufs/inode.c b/trunk/arch/powerpc/platforms/cell/spufs/inode.c index 7eb4d6cbcb74..f37460e5bfd2 100644 --- a/trunk/arch/powerpc/platforms/cell/spufs/inode.c +++ b/trunk/arch/powerpc/platforms/cell/spufs/inode.c @@ -654,7 +654,7 @@ static int __init spufs_init(void) ret = -ENOMEM; spufs_inode_cache = kmem_cache_create("spufs_inode_cache", sizeof(struct spufs_inode_info), 0, - SLAB_HWCACHE_ALIGN, spufs_init_once); + SLAB_HWCACHE_ALIGN, spufs_init_once, NULL); if (!spufs_inode_cache) goto out; diff --git a/trunk/arch/sh/kernel/cpu/sh4/sq.c b/trunk/arch/sh/kernel/cpu/sh4/sq.c index b98d6c3e6f36..d7fff752e569 100644 --- a/trunk/arch/sh/kernel/cpu/sh4/sq.c +++ b/trunk/arch/sh/kernel/cpu/sh4/sq.c @@ -371,7 +371,8 @@ static int __init sq_api_init(void) printk(KERN_NOTICE "sq: Registering store queue API.\n"); sq_cache = kmem_cache_create("store_queue_cache", - sizeof(struct sq_mapping), 0, 0, NULL); + sizeof(struct sq_mapping), 0, 0, + NULL, NULL); if (unlikely(!sq_cache)) return ret; diff --git a/trunk/arch/sh/mm/pmb.c b/trunk/arch/sh/mm/pmb.c index a08a4a958add..b6a5a338145b 100644 --- a/trunk/arch/sh/mm/pmb.c +++ b/trunk/arch/sh/mm/pmb.c @@ -310,7 +310,7 @@ static int __init pmb_init(void) BUG_ON(unlikely(nr_entries >= NR_PMB_ENTRIES)); pmb_cache = kmem_cache_create("pmb", sizeof(struct pmb_entry), 0, - SLAB_PANIC, pmb_cache_ctor); + SLAB_PANIC, pmb_cache_ctor, NULL); jump_to_P2(); diff --git a/trunk/arch/sparc64/mm/tsb.c b/trunk/arch/sparc64/mm/tsb.c index 7ff0a02f5813..8eb8a7c76ec9 100644 --- a/trunk/arch/sparc64/mm/tsb.c +++ b/trunk/arch/sparc64/mm/tsb.c @@ -262,7 +262,8 @@ void __init pgtable_cache_init(void) tsb_caches[i] = kmem_cache_create(name, size, size, - 0, NULL); + 0, + NULL, NULL); if (!tsb_caches[i]) { prom_printf("Could not create %s cache\n", name); prom_halt(); diff --git a/trunk/arch/um/Makefile b/trunk/arch/um/Makefile index 989224f21346..5d5ed726faa0 100644 --- a/trunk/arch/um/Makefile +++ b/trunk/arch/um/Makefile @@ -146,7 +146,7 @@ define cmd_vmlinux__ -Wl,-T,$(vmlinux-lds) $(vmlinux-init) \ -Wl,--start-group $(vmlinux-main) -Wl,--end-group \ -lutil \ - $(filter-out $(vmlinux-lds) $(vmlinux-init) $(vmlinux-main) vmlinux.o \ + $(filter-out $(vmlinux-lds) $(vmlinux-init) $(vmlinux-main) \ FORCE ,$^) ; rm -f linux endef diff --git a/trunk/block/bsg.c b/trunk/block/bsg.c index f2992e72b841..baa04e7adf19 100644 --- a/trunk/block/bsg.c +++ b/trunk/block/bsg.c @@ -1043,7 +1043,7 @@ static int __init bsg_init(void) dev_t devid; bsg_cmd_cachep = kmem_cache_create("bsg_cmd", - sizeof(struct bsg_command), 0, 0, NULL); + sizeof(struct bsg_command), 0, 0, NULL, NULL); if (!bsg_cmd_cachep) { printk(KERN_ERR "bsg: failed creating slab cache\n"); return -ENOMEM; diff --git a/trunk/block/ll_rw_blk.c b/trunk/block/ll_rw_blk.c index 66056ca5e631..d7cadf304168 100644 --- a/trunk/block/ll_rw_blk.c +++ b/trunk/block/ll_rw_blk.c @@ -3698,13 +3698,13 @@ int __init blk_dev_init(void) panic("Failed to create kblockd\n"); request_cachep = kmem_cache_create("blkdev_requests", - sizeof(struct request), 0, SLAB_PANIC, NULL); + sizeof(struct request), 0, SLAB_PANIC, NULL, NULL); requestq_cachep = kmem_cache_create("blkdev_queue", - sizeof(request_queue_t), 0, SLAB_PANIC, NULL); + sizeof(request_queue_t), 0, SLAB_PANIC, NULL, NULL); iocontext_cachep = kmem_cache_create("blkdev_ioc", - sizeof(struct io_context), 0, SLAB_PANIC, NULL); + sizeof(struct io_context), 0, SLAB_PANIC, NULL, NULL); for_each_possible_cpu(i) INIT_LIST_HEAD(&per_cpu(blk_cpu_done, i)); diff --git a/trunk/drivers/acpi/osl.c b/trunk/drivers/acpi/osl.c index 00d53c2fd1e8..2e7ba615d760 100644 --- a/trunk/drivers/acpi/osl.c +++ b/trunk/drivers/acpi/osl.c @@ -1098,7 +1098,7 @@ void acpi_os_release_lock(acpi_spinlock lockp, acpi_cpu_flags flags) acpi_status acpi_os_create_cache(char *name, u16 size, u16 depth, acpi_cache_t ** cache) { - *cache = kmem_cache_create(name, size, 0, 0, NULL); + *cache = kmem_cache_create(name, size, 0, 0, NULL, NULL); if (*cache == NULL) return AE_ERROR; else diff --git a/trunk/drivers/block/aoe/aoeblk.c b/trunk/drivers/block/aoe/aoeblk.c index 4f598270fa31..478489c568a4 100644 --- a/trunk/drivers/block/aoe/aoeblk.c +++ b/trunk/drivers/block/aoe/aoeblk.c @@ -257,9 +257,9 @@ aoeblk_exit(void) int __init aoeblk_init(void) { - buf_pool_cache = kmem_cache_create("aoe_bufs", + buf_pool_cache = kmem_cache_create("aoe_bufs", sizeof(struct buf), - 0, 0, NULL); + 0, 0, NULL, NULL); if (buf_pool_cache == NULL) return -ENOMEM; diff --git a/trunk/drivers/char/Kconfig b/trunk/drivers/char/Kconfig index 4373d7cdc5d2..9e8f21410d2d 100644 --- a/trunk/drivers/char/Kconfig +++ b/trunk/drivers/char/Kconfig @@ -185,7 +185,7 @@ config ESPSERIAL config MOXA_INTELLIO tristate "Moxa Intellio support" - depends on SERIAL_NONSTANDARD && (ISA || EISA || PCI) + depends on SERIAL_NONSTANDARD help Say Y here if you have a Moxa Intellio multiport serial card. @@ -241,7 +241,7 @@ config SYNCLINK config SYNCLINKMP tristate "SyncLink Multiport support" - depends on SERIAL_NONSTANDARD && PCI + depends on SERIAL_NONSTANDARD help Enable support for the SyncLink Multiport (2 or 4 ports) serial adapter, running asynchronous and HDLC communications up diff --git a/trunk/drivers/char/serial167.c b/trunk/drivers/char/serial167.c index f1497cecffd8..c585b4738f86 100644 --- a/trunk/drivers/char/serial167.c +++ b/trunk/drivers/char/serial167.c @@ -2573,10 +2573,16 @@ static struct tty_driver *serial167_console_device(struct console *c, return cy_serial_driver; } +static int __init serial167_console_setup(struct console *co, char *options) +{ + return 0; +} + static struct console sercons = { .name = "ttyS", .write = serial167_console_write, .device = serial167_console_device, + .setup = serial167_console_setup, .flags = CON_PRINTBUFFER, .index = -1, }; diff --git a/trunk/drivers/char/vme_scc.c b/trunk/drivers/char/vme_scc.c index e122a0e87bb0..bef6d886d4fb 100644 --- a/trunk/drivers/char/vme_scc.c +++ b/trunk/drivers/char/vme_scc.c @@ -1013,10 +1013,18 @@ static struct tty_driver *scc_console_device(struct console *c, int *index) return scc_driver; } + +static int __init scc_console_setup(struct console *co, char *options) +{ + return 0; +} + + static struct console sercons = { .name = "ttyS", .write = scc_console_write, .device = scc_console_device, + .setup = scc_console_setup, .flags = CON_PRINTBUFFER, .index = -1, }; diff --git a/trunk/drivers/ide/legacy/falconide.c b/trunk/drivers/ide/legacy/falconide.c index f0829b83e970..e1e9d9d6893f 100644 --- a/trunk/drivers/ide/legacy/falconide.c +++ b/trunk/drivers/ide/legacy/falconide.c @@ -8,7 +8,6 @@ * more details. */ -#include #include #include #include @@ -55,7 +54,6 @@ static int falconide_offsets[IDE_NR_PORTS] __initdata = { */ int falconide_intr_lock; -EXPORT_SYMBOL(falconide_intr_lock); /* diff --git a/trunk/drivers/ieee1394/eth1394.c b/trunk/drivers/ieee1394/eth1394.c index 3a9d7e2d4de6..93362eed94ed 100644 --- a/trunk/drivers/ieee1394/eth1394.c +++ b/trunk/drivers/ieee1394/eth1394.c @@ -1729,7 +1729,7 @@ static int __init ether1394_init_module(void) packet_task_cache = kmem_cache_create("packet_task", sizeof(struct packet_task), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!packet_task_cache) return -ENOMEM; diff --git a/trunk/drivers/infiniband/core/mad.c b/trunk/drivers/infiniband/core/mad.c index bc547f1d34ba..6b8faca02f8a 100644 --- a/trunk/drivers/infiniband/core/mad.c +++ b/trunk/drivers/infiniband/core/mad.c @@ -2998,6 +2998,7 @@ static int __init ib_mad_init_module(void) sizeof(struct ib_mad_private), 0, SLAB_HWCACHE_ALIGN, + NULL, NULL); if (!ib_mad_cache) { printk(KERN_ERR PFX "Couldn't create ib_mad cache\n"); diff --git a/trunk/drivers/infiniband/hw/amso1100/c2_vq.c b/trunk/drivers/infiniband/hw/amso1100/c2_vq.c index cfdacb1ec279..36620a22413c 100644 --- a/trunk/drivers/infiniband/hw/amso1100/c2_vq.c +++ b/trunk/drivers/infiniband/hw/amso1100/c2_vq.c @@ -85,7 +85,7 @@ int vq_init(struct c2_dev *c2dev) (char) ('0' + c2dev->devnum)); c2dev->host_msg_cache = kmem_cache_create(c2dev->vq_cache_name, c2dev->rep_vq.msg_size, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (c2dev->host_msg_cache == NULL) { return -ENOMEM; } diff --git a/trunk/drivers/infiniband/hw/ehca/ehca_av.c b/trunk/drivers/infiniband/hw/ehca/ehca_av.c index 97d108634c58..e53a97af1260 100644 --- a/trunk/drivers/infiniband/hw/ehca/ehca_av.c +++ b/trunk/drivers/infiniband/hw/ehca/ehca_av.c @@ -259,7 +259,7 @@ int ehca_init_av_cache(void) av_cache = kmem_cache_create("ehca_cache_av", sizeof(struct ehca_av), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!av_cache) return -ENOMEM; return 0; diff --git a/trunk/drivers/infiniband/hw/ehca/ehca_cq.c b/trunk/drivers/infiniband/hw/ehca/ehca_cq.c index 1e8ca3fca4aa..9e87883b561a 100644 --- a/trunk/drivers/infiniband/hw/ehca/ehca_cq.c +++ b/trunk/drivers/infiniband/hw/ehca/ehca_cq.c @@ -387,7 +387,7 @@ int ehca_init_cq_cache(void) cq_cache = kmem_cache_create("ehca_cache_cq", sizeof(struct ehca_cq), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!cq_cache) return -ENOMEM; return 0; diff --git a/trunk/drivers/infiniband/hw/ehca/ehca_main.c b/trunk/drivers/infiniband/hw/ehca/ehca_main.c index 04c324330b7c..36377c6db3d4 100644 --- a/trunk/drivers/infiniband/hw/ehca/ehca_main.c +++ b/trunk/drivers/infiniband/hw/ehca/ehca_main.c @@ -163,7 +163,7 @@ static int ehca_create_slab_caches(void) ctblk_cache = kmem_cache_create("ehca_cache_ctblk", EHCA_PAGESIZE, H_CB_ALIGNMENT, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!ctblk_cache) { ehca_gen_err("Cannot create ctblk SLAB cache."); ehca_cleanup_mrmw_cache(); diff --git a/trunk/drivers/infiniband/hw/ehca/ehca_mrmw.c b/trunk/drivers/infiniband/hw/ehca/ehca_mrmw.c index 9f4c9d46e8ef..6262c5462d50 100644 --- a/trunk/drivers/infiniband/hw/ehca/ehca_mrmw.c +++ b/trunk/drivers/infiniband/hw/ehca/ehca_mrmw.c @@ -1950,13 +1950,13 @@ int ehca_init_mrmw_cache(void) mr_cache = kmem_cache_create("ehca_cache_mr", sizeof(struct ehca_mr), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!mr_cache) return -ENOMEM; mw_cache = kmem_cache_create("ehca_cache_mw", sizeof(struct ehca_mw), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!mw_cache) { kmem_cache_destroy(mr_cache); mr_cache = NULL; diff --git a/trunk/drivers/infiniband/hw/ehca/ehca_pd.c b/trunk/drivers/infiniband/hw/ehca/ehca_pd.c index c85312ad292b..79d0591a8043 100644 --- a/trunk/drivers/infiniband/hw/ehca/ehca_pd.c +++ b/trunk/drivers/infiniband/hw/ehca/ehca_pd.c @@ -100,7 +100,7 @@ int ehca_init_pd_cache(void) pd_cache = kmem_cache_create("ehca_cache_pd", sizeof(struct ehca_pd), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!pd_cache) return -ENOMEM; return 0; diff --git a/trunk/drivers/infiniband/hw/ehca/ehca_qp.c b/trunk/drivers/infiniband/hw/ehca/ehca_qp.c index a3146e696c5d..48e9ceacd6fa 100644 --- a/trunk/drivers/infiniband/hw/ehca/ehca_qp.c +++ b/trunk/drivers/infiniband/hw/ehca/ehca_qp.c @@ -1760,7 +1760,7 @@ int ehca_init_qp_cache(void) qp_cache = kmem_cache_create("ehca_cache_qp", sizeof(struct ehca_qp), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!qp_cache) return -ENOMEM; return 0; diff --git a/trunk/drivers/infiniband/ulp/iser/iscsi_iser.c b/trunk/drivers/infiniband/ulp/iser/iscsi_iser.c index 5db314380271..effdee299b0c 100644 --- a/trunk/drivers/infiniband/ulp/iser/iscsi_iser.c +++ b/trunk/drivers/infiniband/ulp/iser/iscsi_iser.c @@ -637,7 +637,7 @@ static int __init iser_init(void) ig.desc_cache = kmem_cache_create("iser_descriptors", sizeof (struct iser_desc), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (ig.desc_cache == NULL) return -ENOMEM; diff --git a/trunk/drivers/kvm/mmu.c b/trunk/drivers/kvm/mmu.c index 1199d3f32ac3..b297a6b111ac 100644 --- a/trunk/drivers/kvm/mmu.c +++ b/trunk/drivers/kvm/mmu.c @@ -1332,24 +1332,24 @@ int kvm_mmu_module_init(void) { pte_chain_cache = kmem_cache_create("kvm_pte_chain", sizeof(struct kvm_pte_chain), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!pte_chain_cache) goto nomem; rmap_desc_cache = kmem_cache_create("kvm_rmap_desc", sizeof(struct kvm_rmap_desc), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!rmap_desc_cache) goto nomem; mmu_page_cache = kmem_cache_create("kvm_mmu_page", PAGE_SIZE, - PAGE_SIZE, 0, NULL); + PAGE_SIZE, 0, NULL, NULL); if (!mmu_page_cache) goto nomem; mmu_page_header_cache = kmem_cache_create("kvm_mmu_page_header", sizeof(struct kvm_mmu_page), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!mmu_page_header_cache) goto nomem; diff --git a/trunk/drivers/lguest/io.c b/trunk/drivers/lguest/io.c index c8eb79266991..06bdba2337ef 100644 --- a/trunk/drivers/lguest/io.c +++ b/trunk/drivers/lguest/io.c @@ -187,7 +187,7 @@ static u32 copy_data(struct lguest *srclg, /* FIXME: This is not completely portable, since archs do different things for copy_to_user_page. */ if (copy_from_user(maddr + (dst->addr[di] + dstoff)%PAGE_SIZE, - (void __user *)src->addr[si], len) != 0) { + (void *__user)src->addr[si], len) != 0) { kill_guest(srclg, "bad address in sending DMA"); totlen = 0; break; diff --git a/trunk/drivers/md/raid5.c b/trunk/drivers/md/raid5.c index c8dfdb302916..0b66afef2d82 100644 --- a/trunk/drivers/md/raid5.c +++ b/trunk/drivers/md/raid5.c @@ -951,7 +951,7 @@ static int grow_stripes(raid5_conf_t *conf, int num) conf->active_name = 0; sc = kmem_cache_create(conf->cache_name[conf->active_name], sizeof(struct stripe_head)+(devs-1)*sizeof(struct r5dev), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!sc) return 1; conf->slab_cache = sc; @@ -1003,7 +1003,7 @@ static int resize_stripes(raid5_conf_t *conf, int newsize) /* Step 1 */ sc = kmem_cache_create(conf->cache_name[1-conf->active_name], sizeof(struct stripe_head)+(newsize-1)*sizeof(struct r5dev), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!sc) return -ENOMEM; diff --git a/trunk/drivers/message/i2o/i2o_block.c b/trunk/drivers/message/i2o/i2o_block.c index 988c8ce47f58..64a52bd7544a 100644 --- a/trunk/drivers/message/i2o/i2o_block.c +++ b/trunk/drivers/message/i2o/i2o_block.c @@ -1171,7 +1171,8 @@ static int __init i2o_block_init(void) /* Allocate request mempool and slab */ size = sizeof(struct i2o_block_request); i2o_blk_req_pool.slab = kmem_cache_create("i2o_block_req", size, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, + NULL); if (!i2o_blk_req_pool.slab) { osm_err("can't init request slab\n"); rc = -ENOMEM; diff --git a/trunk/drivers/mtd/ubi/eba.c b/trunk/drivers/mtd/ubi/eba.c index 7c5e29eaf118..8aff9385613f 100644 --- a/trunk/drivers/mtd/ubi/eba.c +++ b/trunk/drivers/mtd/ubi/eba.c @@ -1149,7 +1149,7 @@ int ubi_eba_init_scan(struct ubi_device *ubi, struct ubi_scan_info *si) if (ubi_devices_cnt == 0) { ltree_slab = kmem_cache_create("ubi_ltree_slab", sizeof(struct ltree_entry), 0, - 0, <ree_entry_ctor); + 0, <ree_entry_ctor, NULL); if (!ltree_slab) return -ENOMEM; } diff --git a/trunk/drivers/mtd/ubi/wl.c b/trunk/drivers/mtd/ubi/wl.c index a5a9b8d87302..9de953762097 100644 --- a/trunk/drivers/mtd/ubi/wl.c +++ b/trunk/drivers/mtd/ubi/wl.c @@ -1452,7 +1452,7 @@ int ubi_wl_init_scan(struct ubi_device *ubi, struct ubi_scan_info *si) if (ubi_devices_cnt == 0) { wl_entries_slab = kmem_cache_create("ubi_wl_entry_slab", sizeof(struct ubi_wl_entry), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!wl_entries_slab) return -ENOMEM; } diff --git a/trunk/drivers/net/mac89x0.c b/trunk/drivers/net/mac89x0.c index 62c1c6262feb..26a3b45a4a34 100644 --- a/trunk/drivers/net/mac89x0.c +++ b/trunk/drivers/net/mac89x0.c @@ -608,7 +608,7 @@ module_param(debug, int, 0); MODULE_PARM_DESC(debug, "CS89[02]0 debug level (0-5)"); MODULE_LICENSE("GPL"); -int __init +int init_module(void) { net_debug = debug; diff --git a/trunk/drivers/net/sky2.c b/trunk/drivers/net/sky2.c index 13f08a390e1f..a2f32151559e 100644 --- a/trunk/drivers/net/sky2.c +++ b/trunk/drivers/net/sky2.c @@ -692,7 +692,6 @@ static void sky2_mac_init(struct sky2_hw *hw, unsigned port) { struct sky2_port *sky2 = netdev_priv(hw->dev[port]); u16 reg; - u32 rx_reg; int i; const u8 *addr = hw->dev[port]->dev_addr; @@ -769,11 +768,11 @@ static void sky2_mac_init(struct sky2_hw *hw, unsigned port) /* Configure Rx MAC FIFO */ sky2_write8(hw, SK_REG(port, RX_GMF_CTRL_T), GMF_RST_CLR); - rx_reg = GMF_OPER_ON | GMF_RX_F_FL_ON; + reg = GMF_OPER_ON | GMF_RX_F_FL_ON; if (hw->chip_id == CHIP_ID_YUKON_EX) - rx_reg |= GMF_RX_OVER_ON; + reg |= GMF_RX_OVER_ON; - sky2_write32(hw, SK_REG(port, RX_GMF_CTRL_T), rx_reg); + sky2_write32(hw, SK_REG(port, RX_GMF_CTRL_T), reg); /* Flush Rx MAC FIFO on any flow control or error */ sky2_write16(hw, SK_REG(port, RX_GMF_FL_MSK), GMR_FS_ANY_ERR); diff --git a/trunk/drivers/parport/Kconfig b/trunk/drivers/parport/Kconfig index d449b150930e..09c93ff932b1 100644 --- a/trunk/drivers/parport/Kconfig +++ b/trunk/drivers/parport/Kconfig @@ -35,7 +35,7 @@ if PARPORT config PARPORT_PC tristate "PC-style hardware" - depends on (!SPARC64 || PCI) && !SPARC32 && !M32R && !FRV && (!M68K || ISA) + depends on (!SPARC64 || PCI) && !SPARC32 && !M32R && !FRV ---help--- You should say Y here if you have a PC-style parallel port. All IBM PC compatible computers and some Alphas have PC-style diff --git a/trunk/drivers/s390/block/dasd_devmap.c b/trunk/drivers/s390/block/dasd_devmap.c index 0c67258fb9ec..6a89cefe99bb 100644 --- a/trunk/drivers/s390/block/dasd_devmap.c +++ b/trunk/drivers/s390/block/dasd_devmap.c @@ -291,7 +291,7 @@ dasd_parse_keyword( char *parsestring ) { dasd_page_cache = kmem_cache_create("dasd_page_cache", PAGE_SIZE, PAGE_SIZE, SLAB_CACHE_DMA, - NULL); + NULL, NULL ); if (!dasd_page_cache) MESSAGE(KERN_WARNING, "%s", "Failed to create slab, " "fixed buffer mode disabled."); diff --git a/trunk/drivers/s390/scsi/zfcp_aux.c b/trunk/drivers/s390/scsi/zfcp_aux.c index 9726261c367d..a1db95925138 100644 --- a/trunk/drivers/s390/scsi/zfcp_aux.c +++ b/trunk/drivers/s390/scsi/zfcp_aux.c @@ -259,21 +259,21 @@ zfcp_module_init(void) size = sizeof(struct zfcp_fsf_req_qtcb); align = calc_alignment(size); zfcp_data.fsf_req_qtcb_cache = - kmem_cache_create("zfcp_fsf", size, align, 0, NULL); + kmem_cache_create("zfcp_fsf", size, align, 0, NULL, NULL); if (!zfcp_data.fsf_req_qtcb_cache) goto out; size = sizeof(struct fsf_status_read_buffer); align = calc_alignment(size); zfcp_data.sr_buffer_cache = - kmem_cache_create("zfcp_sr", size, align, 0, NULL); + kmem_cache_create("zfcp_sr", size, align, 0, NULL, NULL); if (!zfcp_data.sr_buffer_cache) goto out_sr_cache; size = sizeof(struct zfcp_gid_pn_data); align = calc_alignment(size); zfcp_data.gid_pn_cache = - kmem_cache_create("zfcp_gid", size, align, 0, NULL); + kmem_cache_create("zfcp_gid", size, align, 0, NULL, NULL); if (!zfcp_data.gid_pn_cache) goto out_gid_cache; diff --git a/trunk/drivers/scsi/NCR53C9x.c b/trunk/drivers/scsi/NCR53C9x.c index 79b4df158140..773d11dd9953 100644 --- a/trunk/drivers/scsi/NCR53C9x.c +++ b/trunk/drivers/scsi/NCR53C9x.c @@ -95,8 +95,6 @@ enum { /* The master ring of all esp hosts we are managing in this driver. */ static struct NCR_ESP *espchain; int nesps = 0, esps_in_use = 0, esps_running = 0; -EXPORT_SYMBOL(nesps); -EXPORT_SYMBOL(esps_running); irqreturn_t esp_intr(int irq, void *dev_id); @@ -526,7 +524,6 @@ void esp_bootup_reset(struct NCR_ESP *esp, struct ESP_regs *eregs) /* Eat any bitrot in the chip and we are done... */ trash = esp_read(eregs->esp_intrpt); } -EXPORT_SYMBOL(esp_bootup_reset); /* Allocate structure and insert basic data such as SCSI chip frequency * data and a pointer to the device @@ -775,7 +772,6 @@ const char *esp_info(struct Scsi_Host *host) panic("Bogon ESP revision"); }; } -EXPORT_SYMBOL(esp_info); /* From Wolfgang Stanglmeier's NCR scsi driver. */ struct info_str @@ -906,7 +902,6 @@ int esp_proc_info(struct Scsi_Host *shost, char *buffer, char **start, off_t off *start = buffer; return esp_host_info(esp, buffer, offset, length); } -EXPORT_SYMBOL(esp_proc_info); static void esp_get_dmabufs(struct NCR_ESP *esp, Scsi_Cmnd *sp) { @@ -3540,7 +3535,6 @@ void esp_handle(struct NCR_ESP *esp) if(esp->dma_irq_exit) esp->dma_irq_exit(esp); } -EXPORT_SYMBOL(esp_handle); #ifndef CONFIG_SMP irqreturn_t esp_intr(int irq, void *dev_id) @@ -3637,7 +3631,6 @@ void esp_release(void) esps_in_use--; esps_running = esps_in_use; } -EXPORT_SYMBOL(esp_release); #endif EXPORT_SYMBOL(esp_abort); diff --git a/trunk/drivers/scsi/aic94xx/aic94xx_init.c b/trunk/drivers/scsi/aic94xx/aic94xx_init.c index b8c6810090d5..1c0d7578e791 100644 --- a/trunk/drivers/scsi/aic94xx/aic94xx_init.c +++ b/trunk/drivers/scsi/aic94xx/aic94xx_init.c @@ -462,7 +462,7 @@ static int asd_create_global_caches(void) sizeof(struct asd_dma_tok), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!asd_dma_token_cache) { asd_printk("couldn't create dma token cache\n"); return -ENOMEM; @@ -474,7 +474,7 @@ static int asd_create_global_caches(void) sizeof(struct asd_ascb), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!asd_ascb_cache) { asd_printk("couldn't create ascb cache\n"); goto Err; diff --git a/trunk/drivers/scsi/iscsi_tcp.c b/trunk/drivers/scsi/iscsi_tcp.c index 7829ab1e2fb4..aebcd5fcdc55 100644 --- a/trunk/drivers/scsi/iscsi_tcp.c +++ b/trunk/drivers/scsi/iscsi_tcp.c @@ -1885,7 +1885,7 @@ static int iscsi_tcp_get_addr(struct iscsi_conn *conn, struct socket *sock, struct sockaddr_in *sin; int rc = 0, len; - addr = kmalloc(sizeof(*addr), GFP_KERNEL); + addr = kmalloc(GFP_KERNEL, sizeof(*addr)); if (!addr) return -ENOMEM; diff --git a/trunk/drivers/scsi/libsas/sas_init.c b/trunk/drivers/scsi/libsas/sas_init.c index 1396c83b0c9c..965698c8b7bf 100644 --- a/trunk/drivers/scsi/libsas/sas_init.c +++ b/trunk/drivers/scsi/libsas/sas_init.c @@ -292,7 +292,7 @@ EXPORT_SYMBOL_GPL(sas_domain_release_transport); static int __init sas_class_init(void) { sas_task_cache = kmem_cache_create("sas_task", sizeof(struct sas_task), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); if (!sas_task_cache) return -ENOMEM; diff --git a/trunk/drivers/scsi/qla2xxx/qla_os.c b/trunk/drivers/scsi/qla2xxx/qla_os.c index 92376f9dfdd5..b5a77b0c0deb 100644 --- a/trunk/drivers/scsi/qla2xxx/qla_os.c +++ b/trunk/drivers/scsi/qla2xxx/qla_os.c @@ -2723,7 +2723,7 @@ qla2x00_module_init(void) /* Allocate cache for SRBs. */ srb_cachep = kmem_cache_create("qla2xxx_srbs", sizeof(srb_t), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (srb_cachep == NULL) { printk(KERN_ERR "qla2xxx: Unable to allocate SRB cache...Failing load!\n"); diff --git a/trunk/drivers/scsi/qla4xxx/ql4_os.c b/trunk/drivers/scsi/qla4xxx/ql4_os.c index b1d565c12c5b..e69160a7bc60 100644 --- a/trunk/drivers/scsi/qla4xxx/ql4_os.c +++ b/trunk/drivers/scsi/qla4xxx/ql4_os.c @@ -1677,7 +1677,7 @@ static int __init qla4xxx_module_init(void) /* Allocate cache for SRBs. */ srb_cachep = kmem_cache_create("qla4xxx_srbs", sizeof(struct srb), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (srb_cachep == NULL) { printk(KERN_ERR "%s: Unable to allocate SRB cache..." diff --git a/trunk/drivers/scsi/scsi.c b/trunk/drivers/scsi/scsi.c index a5de1a829a76..a691dda40d2c 100644 --- a/trunk/drivers/scsi/scsi.c +++ b/trunk/drivers/scsi/scsi.c @@ -288,7 +288,7 @@ int scsi_setup_command_freelist(struct Scsi_Host *shost) if (!pool->users) { pool->slab = kmem_cache_create(pool->name, sizeof(struct scsi_cmnd), 0, - pool->slab_flags, NULL); + pool->slab_flags, NULL, NULL); if (!pool->slab) goto fail; } diff --git a/trunk/drivers/scsi/scsi_lib.c b/trunk/drivers/scsi/scsi_lib.c index da63c544919b..1f5a07bf2a75 100644 --- a/trunk/drivers/scsi/scsi_lib.c +++ b/trunk/drivers/scsi/scsi_lib.c @@ -1661,7 +1661,7 @@ int __init scsi_init_queue(void) scsi_io_context_cache = kmem_cache_create("scsi_io_context", sizeof(struct scsi_io_context), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!scsi_io_context_cache) { printk(KERN_ERR "SCSI: can't init scsi io context cache\n"); return -ENOMEM; @@ -1672,7 +1672,7 @@ int __init scsi_init_queue(void) int size = sgp->size * sizeof(struct scatterlist); sgp->slab = kmem_cache_create(sgp->name, size, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (!sgp->slab) { printk(KERN_ERR "SCSI: can't init sg slab %s\n", sgp->name); diff --git a/trunk/drivers/scsi/scsi_tgt_lib.c b/trunk/drivers/scsi/scsi_tgt_lib.c index 371b69c110bc..2570f48a69c7 100644 --- a/trunk/drivers/scsi/scsi_tgt_lib.c +++ b/trunk/drivers/scsi/scsi_tgt_lib.c @@ -585,7 +585,7 @@ static int __init scsi_tgt_init(void) scsi_tgt_cmd_cache = kmem_cache_create("scsi_tgt_cmd", sizeof(struct scsi_tgt_cmd), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!scsi_tgt_cmd_cache) return -ENOMEM; diff --git a/trunk/drivers/usb/gadget/serial.c b/trunk/drivers/usb/gadget/serial.c index 38138bb9ddb0..9cd98e73dc1d 100644 --- a/trunk/drivers/usb/gadget/serial.c +++ b/trunk/drivers/usb/gadget/serial.c @@ -33,6 +33,7 @@ #include #include #include +#include #include #include @@ -258,7 +259,7 @@ static const char *EP_IN_NAME; static const char *EP_OUT_NAME; static const char *EP_NOTIFY_NAME; -static struct semaphore gs_open_close_sem[GS_NUM_PORTS]; +static struct mutex gs_open_close_lock[GS_NUM_PORTS]; static unsigned int read_q_size = GS_DEFAULT_READ_Q_SIZE; static unsigned int write_q_size = GS_DEFAULT_WRITE_Q_SIZE; @@ -595,7 +596,7 @@ static int __init gs_module_init(void) tty_set_operations(gs_tty_driver, &gs_tty_ops); for (i=0; i < GS_NUM_PORTS; i++) - sema_init(&gs_open_close_sem[i], 1); + mutex_init(&gs_open_close_lock[i]); retval = tty_register_driver(gs_tty_driver); if (retval) { @@ -635,7 +636,7 @@ static int gs_open(struct tty_struct *tty, struct file *file) struct gs_port *port; struct gs_dev *dev; struct gs_buf *buf; - struct semaphore *sem; + struct mutex *mtx; int ret; port_num = tty->index; @@ -656,10 +657,10 @@ static int gs_open(struct tty_struct *tty, struct file *file) return -ENODEV; } - sem = &gs_open_close_sem[port_num]; - if (down_interruptible(sem)) { + mtx = &gs_open_close_lock[port_num]; + if (mutex_lock_interruptible(mtx)) { printk(KERN_ERR - "gs_open: (%d,%p,%p) interrupted waiting for semaphore\n", + "gs_open: (%d,%p,%p) interrupted waiting for mutex\n", port_num, tty, file); return -ERESTARTSYS; } @@ -754,12 +755,12 @@ static int gs_open(struct tty_struct *tty, struct file *file) exit_unlock_port: spin_unlock_irqrestore(&port->port_lock, flags); - up(sem); + mutex_unlock(mtx); return ret; exit_unlock_dev: spin_unlock_irqrestore(&dev->dev_lock, flags); - up(sem); + mutex_unlock(mtx); return ret; } @@ -781,7 +782,7 @@ static int gs_open(struct tty_struct *tty, struct file *file) static void gs_close(struct tty_struct *tty, struct file *file) { struct gs_port *port = tty->driver_data; - struct semaphore *sem; + struct mutex *mtx; if (port == NULL) { printk(KERN_ERR "gs_close: NULL port pointer\n"); @@ -790,8 +791,8 @@ static void gs_close(struct tty_struct *tty, struct file *file) gs_debug("gs_close: (%d,%p,%p)\n", port->port_num, tty, file); - sem = &gs_open_close_sem[port->port_num]; - down(sem); + mtx = &gs_open_close_lock[port->port_num]; + mutex_lock(mtx); spin_lock_irq(&port->port_lock); @@ -846,7 +847,7 @@ static void gs_close(struct tty_struct *tty, struct file *file) exit: spin_unlock_irq(&port->port_lock); - up(sem); + mutex_unlock(mtx); } /* diff --git a/trunk/drivers/usb/host/uhci-hcd.c b/trunk/drivers/usb/host/uhci-hcd.c index 805e5fc5f5db..76c555a67dac 100644 --- a/trunk/drivers/usb/host/uhci-hcd.c +++ b/trunk/drivers/usb/host/uhci-hcd.c @@ -933,7 +933,7 @@ static int __init uhci_hcd_init(void) } uhci_up_cachep = kmem_cache_create("uhci_urb_priv", - sizeof(struct urb_priv), 0, 0, NULL); + sizeof(struct urb_priv), 0, 0, NULL, NULL); if (!uhci_up_cachep) goto up_failed; diff --git a/trunk/drivers/usb/mon/mon_text.c b/trunk/drivers/usb/mon/mon_text.c index 8f27a9e1c36b..982b773d71e6 100644 --- a/trunk/drivers/usb/mon/mon_text.c +++ b/trunk/drivers/usb/mon/mon_text.c @@ -340,7 +340,7 @@ static int mon_text_open(struct inode *inode, struct file *file) snprintf(rp->slab_name, SLAB_NAME_SZ, "mon_text_%p", rp); rp->e_slab = kmem_cache_create(rp->slab_name, sizeof(struct mon_event_text), sizeof(long), 0, - mon_text_ctor); + mon_text_ctor, NULL); if (rp->e_slab == NULL) { rc = -ENOMEM; goto err_slab; diff --git a/trunk/fs/adfs/super.c b/trunk/fs/adfs/super.c index 1c9fd3029496..de2ed5ca3351 100644 --- a/trunk/fs/adfs/super.c +++ b/trunk/fs/adfs/super.c @@ -234,14 +234,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { adfs_inode_cachep = kmem_cache_create("adfs_inode_cache", sizeof(struct adfs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (adfs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/affs/super.c b/trunk/fs/affs/super.c index c80191ae2059..6d0ebc321530 100644 --- a/trunk/fs/affs/super.c +++ b/trunk/fs/affs/super.c @@ -99,7 +99,7 @@ static int init_inodecache(void) sizeof(struct affs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (affs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/afs/super.c b/trunk/fs/afs/super.c index b8808b40f82b..993cdf1cce3a 100644 --- a/trunk/fs/afs/super.c +++ b/trunk/fs/afs/super.c @@ -89,7 +89,8 @@ int __init afs_fs_init(void) sizeof(struct afs_vnode), 0, SLAB_HWCACHE_ALIGN, - afs_i_init_once); + afs_i_init_once, + NULL); if (!afs_inode_cachep) { printk(KERN_NOTICE "kAFS: Failed to allocate inode cache\n"); return ret; diff --git a/trunk/fs/befs/linuxvfs.c b/trunk/fs/befs/linuxvfs.c index a45141827681..a5c5171c2828 100644 --- a/trunk/fs/befs/linuxvfs.c +++ b/trunk/fs/befs/linuxvfs.c @@ -414,7 +414,7 @@ befs_read_inode(struct inode *inode) } /* Initialize the inode cache. Called at fs setup. - * + * * Taken from NFS implementation by Al Viro. */ static int @@ -424,7 +424,7 @@ befs_init_inodecache(void) sizeof (struct befs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (befs_inode_cachep == NULL) { printk(KERN_ERR "befs_init_inodecache: " "Couldn't initalize inode slabcache\n"); diff --git a/trunk/fs/bfs/inode.c b/trunk/fs/bfs/inode.c index f346eb14e86f..58c7bd9f5301 100644 --- a/trunk/fs/bfs/inode.c +++ b/trunk/fs/bfs/inode.c @@ -250,14 +250,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&bi->vfs_inode); } - + static int init_inodecache(void) { bfs_inode_cachep = kmem_cache_create("bfs_inode_cache", sizeof(struct bfs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (bfs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/bio.c b/trunk/fs/bio.c index 0d2c2d38b7ba..33e46340a766 100644 --- a/trunk/fs/bio.c +++ b/trunk/fs/bio.c @@ -1187,7 +1187,7 @@ static void __init biovec_init_slabs(void) size = bvs->nr_vecs * sizeof(struct bio_vec); bvs->slab = kmem_cache_create(bvs->name, size, 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); } } diff --git a/trunk/fs/block_dev.c b/trunk/fs/block_dev.c index 2980eabe5779..3635315e3b99 100644 --- a/trunk/fs/block_dev.c +++ b/trunk/fs/block_dev.c @@ -517,7 +517,7 @@ void __init bdev_cache_init(void) bdev_cachep = kmem_cache_create("bdev_cache", sizeof(struct bdev_inode), 0, (SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD|SLAB_PANIC), - init_once); + init_once, NULL); err = register_filesystem(&bd_type); if (err) panic("Cannot register bdev pseudo-fs"); diff --git a/trunk/fs/cifs/cifsfs.c b/trunk/fs/cifs/cifsfs.c index cabb6a55d7dd..1fd0dc85f53c 100644 --- a/trunk/fs/cifs/cifsfs.c +++ b/trunk/fs/cifs/cifsfs.c @@ -719,7 +719,7 @@ cifs_init_inodecache(void) sizeof (struct cifsInodeInfo), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - cifs_init_once); + cifs_init_once, NULL); if (cifs_inode_cachep == NULL) return -ENOMEM; @@ -748,7 +748,7 @@ cifs_init_request_bufs(void) cifs_req_cachep = kmem_cache_create("cifs_request", CIFSMaxBufSize + MAX_CIFS_HDR_SIZE, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (cifs_req_cachep == NULL) return -ENOMEM; @@ -776,7 +776,7 @@ cifs_init_request_bufs(void) alloc of large cifs buffers even when page debugging is on */ cifs_sm_req_cachep = kmem_cache_create("cifs_small_rq", MAX_CIFS_SMALL_BUFFER_SIZE, 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (cifs_sm_req_cachep == NULL) { mempool_destroy(cifs_req_poolp); kmem_cache_destroy(cifs_req_cachep); @@ -817,7 +817,7 @@ cifs_init_mids(void) { cifs_mid_cachep = kmem_cache_create("cifs_mpx_ids", sizeof (struct mid_q_entry), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (cifs_mid_cachep == NULL) return -ENOMEM; @@ -830,7 +830,7 @@ cifs_init_mids(void) cifs_oplock_cachep = kmem_cache_create("cifs_oplock_structs", sizeof (struct oplock_q_entry), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (cifs_oplock_cachep == NULL) { mempool_destroy(cifs_mid_poolp); kmem_cache_destroy(cifs_mid_cachep); diff --git a/trunk/fs/coda/inode.c b/trunk/fs/coda/inode.c index 342f4e0d582e..6771a4271e33 100644 --- a/trunk/fs/coda/inode.c +++ b/trunk/fs/coda/inode.c @@ -64,13 +64,13 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + int coda_init_inodecache(void) { coda_inode_cachep = kmem_cache_create("coda_inode_cache", sizeof(struct coda_inode_info), 0, SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, - init_once); + init_once, NULL); if (coda_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/configfs/mount.c b/trunk/fs/configfs/mount.c index 871b0cb61839..b00d962de833 100644 --- a/trunk/fs/configfs/mount.c +++ b/trunk/fs/configfs/mount.c @@ -136,7 +136,7 @@ static int __init configfs_init(void) configfs_dir_cachep = kmem_cache_create("configfs_dir_cache", sizeof(struct configfs_dirent), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!configfs_dir_cachep) goto out; diff --git a/trunk/fs/dcache.c b/trunk/fs/dcache.c index 678d39deb607..cb9d05056b54 100644 --- a/trunk/fs/dcache.c +++ b/trunk/fs/dcache.c @@ -2165,10 +2165,10 @@ void __init vfs_caches_init(unsigned long mempages) mempages -= reserve; names_cachep = kmem_cache_create("names_cache", PATH_MAX, 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); filp_cachep = kmem_cache_create("filp", sizeof(struct file), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); dcache_init(mempages); inode_init(mempages); diff --git a/trunk/fs/dcookies.c b/trunk/fs/dcookies.c index c1208f53bd74..21af1629f9bc 100644 --- a/trunk/fs/dcookies.c +++ b/trunk/fs/dcookies.c @@ -205,7 +205,7 @@ static int dcookie_init(void) dcookie_cache = kmem_cache_create("dcookie_cache", sizeof(struct dcookie_struct), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!dcookie_cache) goto out; diff --git a/trunk/fs/dlm/lowcomms.c b/trunk/fs/dlm/lowcomms.c index dd362739d291..0553a6158dcb 100644 --- a/trunk/fs/dlm/lowcomms.c +++ b/trunk/fs/dlm/lowcomms.c @@ -1449,7 +1449,7 @@ int dlm_lowcomms_start(void) error = -ENOMEM; con_cache = kmem_cache_create("dlm_conn", sizeof(struct connection), __alignof__(struct connection), 0, - NULL); + NULL, NULL); if (!con_cache) goto out; diff --git a/trunk/fs/dlm/memory.c b/trunk/fs/dlm/memory.c index ecf0e5cb2035..fb9e2ee998ae 100644 --- a/trunk/fs/dlm/memory.c +++ b/trunk/fs/dlm/memory.c @@ -23,7 +23,7 @@ int dlm_memory_init(void) int ret = 0; lkb_cache = kmem_cache_create("dlm_lkb", sizeof(struct dlm_lkb), - __alignof__(struct dlm_lkb), 0, NULL); + __alignof__(struct dlm_lkb), 0, NULL, NULL); if (!lkb_cache) ret = -ENOMEM; return ret; diff --git a/trunk/fs/dnotify.c b/trunk/fs/dnotify.c index 28d01ed66de0..936409fcd939 100644 --- a/trunk/fs/dnotify.c +++ b/trunk/fs/dnotify.c @@ -176,7 +176,7 @@ EXPORT_SYMBOL_GPL(dnotify_parent); static int __init dnotify_init(void) { dn_cache = kmem_cache_create("dnotify_cache", - sizeof(struct dnotify_struct), 0, SLAB_PANIC, NULL); + sizeof(struct dnotify_struct), 0, SLAB_PANIC, NULL, NULL); return 0; } diff --git a/trunk/fs/dquot.c b/trunk/fs/dquot.c index de9a29f64ff3..7e273151f589 100644 --- a/trunk/fs/dquot.c +++ b/trunk/fs/dquot.c @@ -1848,11 +1848,11 @@ static int __init dquot_init(void) register_sysctl_table(sys_table); - dquot_cachep = kmem_cache_create("dquot", + dquot_cachep = kmem_cache_create("dquot", sizeof(struct dquot), sizeof(unsigned long) * 4, (SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD|SLAB_PANIC), - NULL); + NULL, NULL); order = 0; dquot_hash = (struct hlist_head *)__get_free_pages(GFP_ATOMIC, order); diff --git a/trunk/fs/ecryptfs/main.c b/trunk/fs/ecryptfs/main.c index e557a6766927..02ca6f1e55d7 100644 --- a/trunk/fs/ecryptfs/main.c +++ b/trunk/fs/ecryptfs/main.c @@ -677,7 +677,7 @@ static int ecryptfs_init_kmem_caches(void) info = &ecryptfs_cache_infos[i]; *(info->cache) = kmem_cache_create(info->name, info->size, - 0, SLAB_HWCACHE_ALIGN, info->ctor); + 0, SLAB_HWCACHE_ALIGN, info->ctor, NULL); if (!*(info->cache)) { ecryptfs_free_kmem_caches(); ecryptfs_printk(KERN_WARNING, "%s: " diff --git a/trunk/fs/efs/super.c b/trunk/fs/efs/super.c index ce4acb8ff819..d360c81f3a72 100644 --- a/trunk/fs/efs/super.c +++ b/trunk/fs/efs/super.c @@ -75,13 +75,13 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { efs_inode_cachep = kmem_cache_create("efs_inode_cache", sizeof(struct efs_inode_info), 0, SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, - init_once); + init_once, NULL); if (efs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/eventpoll.c b/trunk/fs/eventpoll.c index 77b9953624f4..0b73cd45a06d 100644 --- a/trunk/fs/eventpoll.c +++ b/trunk/fs/eventpoll.c @@ -1324,12 +1324,12 @@ static int __init eventpoll_init(void) /* Allocates slab cache used to allocate "struct epitem" items */ epi_cache = kmem_cache_create("eventpoll_epi", sizeof(struct epitem), 0, SLAB_HWCACHE_ALIGN|EPI_SLAB_DEBUG|SLAB_PANIC, - NULL); + NULL, NULL); /* Allocates slab cache used to allocate "struct eppoll_entry" */ pwq_cache = kmem_cache_create("eventpoll_pwq", sizeof(struct eppoll_entry), 0, - EPI_SLAB_DEBUG|SLAB_PANIC, NULL); + EPI_SLAB_DEBUG|SLAB_PANIC, NULL, NULL); return 0; } diff --git a/trunk/fs/ext2/super.c b/trunk/fs/ext2/super.c index 68579a0ed3f0..a6b1072daea7 100644 --- a/trunk/fs/ext2/super.c +++ b/trunk/fs/ext2/super.c @@ -167,14 +167,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag #endif inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { ext2_inode_cachep = kmem_cache_create("ext2_inode_cache", sizeof(struct ext2_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (ext2_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/ext3/super.c b/trunk/fs/ext3/super.c index f0614e3f1fe8..4f84dc86628a 100644 --- a/trunk/fs/ext3/super.c +++ b/trunk/fs/ext3/super.c @@ -490,7 +490,7 @@ static int init_inodecache(void) sizeof(struct ext3_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (ext3_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/ext4/super.c b/trunk/fs/ext4/super.c index 75adbb64e028..6dcbb28dc06d 100644 --- a/trunk/fs/ext4/super.c +++ b/trunk/fs/ext4/super.c @@ -541,7 +541,7 @@ static int init_inodecache(void) sizeof(struct ext4_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (ext4_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/fat/cache.c b/trunk/fs/fat/cache.c index be6f89b152ca..3c9c8a15ec73 100644 --- a/trunk/fs/fat/cache.c +++ b/trunk/fs/fat/cache.c @@ -48,7 +48,7 @@ int __init fat_cache_init(void) fat_cache_cachep = kmem_cache_create("fat_cache", sizeof(struct fat_cache), 0, SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, - init_once); + init_once, NULL); if (fat_cache_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/fat/inode.c b/trunk/fs/fat/inode.c index 4baa5f205368..0a7ddb39a593 100644 --- a/trunk/fs/fat/inode.c +++ b/trunk/fs/fat/inode.c @@ -514,7 +514,7 @@ static int __init fat_init_inodecache(void) sizeof(struct msdos_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (fat_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/fcntl.c b/trunk/fs/fcntl.c index 78b2ff044054..3f22e9f4f691 100644 --- a/trunk/fs/fcntl.c +++ b/trunk/fs/fcntl.c @@ -638,7 +638,7 @@ EXPORT_SYMBOL(kill_fasync); static int __init fasync_init(void) { fasync_cache = kmem_cache_create("fasync_cache", - sizeof(struct fasync_struct), 0, SLAB_PANIC, NULL); + sizeof(struct fasync_struct), 0, SLAB_PANIC, NULL, NULL); return 0; } diff --git a/trunk/fs/freevxfs/vxfs_super.c b/trunk/fs/freevxfs/vxfs_super.c index 4f95572d2722..647d600f0bc8 100644 --- a/trunk/fs/freevxfs/vxfs_super.c +++ b/trunk/fs/freevxfs/vxfs_super.c @@ -263,8 +263,8 @@ vxfs_init(void) int rv; vxfs_inode_cachep = kmem_cache_create("vxfs_inode", - sizeof(struct vxfs_inode_info), 0, - SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, NULL); + sizeof(struct vxfs_inode_info), 0, + SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, NULL, NULL); if (!vxfs_inode_cachep) return -ENOMEM; rv = register_filesystem(&vxfs_fs_type); diff --git a/trunk/fs/fuse/dev.c b/trunk/fs/fuse/dev.c index 3ad22beb24c2..357764d85ff1 100644 --- a/trunk/fs/fuse/dev.c +++ b/trunk/fs/fuse/dev.c @@ -1044,7 +1044,7 @@ int __init fuse_dev_init(void) int err = -ENOMEM; fuse_req_cachep = kmem_cache_create("fuse_request", sizeof(struct fuse_req), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!fuse_req_cachep) goto out; diff --git a/trunk/fs/fuse/inode.c b/trunk/fs/fuse/inode.c index 5448f625ab56..cc5efc13496a 100644 --- a/trunk/fs/fuse/inode.c +++ b/trunk/fs/fuse/inode.c @@ -706,7 +706,7 @@ static int __init fuse_fs_init(void) fuse_inode_cachep = kmem_cache_create("fuse_inode", sizeof(struct fuse_inode), 0, SLAB_HWCACHE_ALIGN, - fuse_inode_init_once); + fuse_inode_init_once, NULL); err = -ENOMEM; if (!fuse_inode_cachep) goto out_unreg2; diff --git a/trunk/fs/gfs2/main.c b/trunk/fs/gfs2/main.c index d5d4e68b8807..787a0edef100 100644 --- a/trunk/fs/gfs2/main.c +++ b/trunk/fs/gfs2/main.c @@ -72,7 +72,7 @@ static int __init init_gfs2_fs(void) gfs2_glock_cachep = kmem_cache_create("gfs2_glock", sizeof(struct gfs2_glock), 0, 0, - gfs2_init_glock_once); + gfs2_init_glock_once, NULL); if (!gfs2_glock_cachep) goto fail; @@ -80,13 +80,13 @@ static int __init init_gfs2_fs(void) sizeof(struct gfs2_inode), 0, SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD, - gfs2_init_inode_once); + gfs2_init_inode_once, NULL); if (!gfs2_inode_cachep) goto fail; gfs2_bufdata_cachep = kmem_cache_create("gfs2_bufdata", sizeof(struct gfs2_bufdata), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!gfs2_bufdata_cachep) goto fail; diff --git a/trunk/fs/hfs/super.c b/trunk/fs/hfs/super.c index 6c5f92dfb500..92cf8751e428 100644 --- a/trunk/fs/hfs/super.c +++ b/trunk/fs/hfs/super.c @@ -443,7 +443,7 @@ static int __init init_hfs_fs(void) hfs_inode_cachep = kmem_cache_create("hfs_inode_cache", sizeof(struct hfs_inode_info), 0, SLAB_HWCACHE_ALIGN, - hfs_init_once); + hfs_init_once, NULL); if (!hfs_inode_cachep) return -ENOMEM; err = register_filesystem(&hfs_fs_type); diff --git a/trunk/fs/hfsplus/super.c b/trunk/fs/hfsplus/super.c index 7b0f2e5a44e2..6d87a2a9534d 100644 --- a/trunk/fs/hfsplus/super.c +++ b/trunk/fs/hfsplus/super.c @@ -479,7 +479,7 @@ static int __init init_hfsplus_fs(void) hfsplus_inode_cachep = kmem_cache_create("hfsplus_icache", HFSPLUS_INODE_SIZE, 0, SLAB_HWCACHE_ALIGN, - hfsplus_init_once); + hfsplus_init_once, NULL); if (!hfsplus_inode_cachep) return -ENOMEM; err = register_filesystem(&hfsplus_fs_type); diff --git a/trunk/fs/hpfs/super.c b/trunk/fs/hpfs/super.c index 89612ee7c80d..29cc34abb2ea 100644 --- a/trunk/fs/hpfs/super.c +++ b/trunk/fs/hpfs/super.c @@ -181,14 +181,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag mutex_init(&ei->i_parent_mutex); inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { hpfs_inode_cachep = kmem_cache_create("hpfs_inode_cache", sizeof(struct hpfs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (hpfs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/hugetlbfs/inode.c b/trunk/fs/hugetlbfs/inode.c index c848a191525d..d145cb79c30a 100644 --- a/trunk/fs/hugetlbfs/inode.c +++ b/trunk/fs/hugetlbfs/inode.c @@ -848,7 +848,7 @@ static int __init init_hugetlbfs_fs(void) hugetlbfs_inode_cachep = kmem_cache_create("hugetlbfs_inode_cache", sizeof(struct hugetlbfs_inode_info), - 0, 0, init_once); + 0, 0, init_once, NULL); if (hugetlbfs_inode_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/inode.c b/trunk/fs/inode.c index 29f5068f819b..320e088d0b28 100644 --- a/trunk/fs/inode.c +++ b/trunk/fs/inode.c @@ -1388,7 +1388,8 @@ void __init inode_init(unsigned long mempages) 0, (SLAB_RECLAIM_ACCOUNT|SLAB_PANIC| SLAB_MEM_SPREAD), - init_once); + init_once, + NULL); register_shrinker(&icache_shrinker); /* Hash may have been set up in inode_init_early */ diff --git a/trunk/fs/inotify_user.c b/trunk/fs/inotify_user.c index 9bf2f6c09df6..9f2224f65a18 100644 --- a/trunk/fs/inotify_user.c +++ b/trunk/fs/inotify_user.c @@ -716,10 +716,10 @@ static int __init inotify_user_setup(void) watch_cachep = kmem_cache_create("inotify_watch_cache", sizeof(struct inotify_user_watch), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); event_cachep = kmem_cache_create("inotify_event_cache", sizeof(struct inotify_kernel_event), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); return 0; } diff --git a/trunk/fs/isofs/inode.c b/trunk/fs/isofs/inode.c index 95c72aa81867..4f5418be0590 100644 --- a/trunk/fs/isofs/inode.c +++ b/trunk/fs/isofs/inode.c @@ -86,7 +86,7 @@ static int init_inodecache(void) sizeof(struct iso_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (isofs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/jbd/journal.c b/trunk/fs/jbd/journal.c index 06ab3c10b1b8..46fe7439fb91 100644 --- a/trunk/fs/jbd/journal.c +++ b/trunk/fs/jbd/journal.c @@ -1668,7 +1668,7 @@ static int journal_create_jbd_slab(size_t slab_size) * boundary. */ jbd_slab[i] = kmem_cache_create(jbd_slab_names[i], - slab_size, slab_size, 0, NULL); + slab_size, slab_size, 0, NULL, NULL); if (!jbd_slab[i]) { printk(KERN_EMERG "JBD: no memory for jbd_slab cache\n"); return -ENOMEM; @@ -1711,7 +1711,8 @@ static int journal_init_journal_head_cache(void) sizeof(struct journal_head), 0, /* offset */ 0, /* flags */ - NULL); /* ctor */ + NULL, /* ctor */ + NULL); /* dtor */ retval = 0; if (journal_head_cache == 0) { retval = -ENOMEM; @@ -2007,7 +2008,8 @@ static int __init journal_init_handle_cache(void) sizeof(handle_t), 0, /* offset */ 0, /* flags */ - NULL); /* ctor */ + NULL, /* ctor */ + NULL); /* dtor */ if (jbd_handle_cache == NULL) { printk(KERN_EMERG "JBD: failed to create handle cache\n"); return -ENOMEM; diff --git a/trunk/fs/jbd/revoke.c b/trunk/fs/jbd/revoke.c index 62e13c8db132..8db2fa25170b 100644 --- a/trunk/fs/jbd/revoke.c +++ b/trunk/fs/jbd/revoke.c @@ -170,13 +170,13 @@ int __init journal_init_revoke_caches(void) { revoke_record_cache = kmem_cache_create("revoke_record", sizeof(struct jbd_revoke_record_s), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); if (revoke_record_cache == 0) return -ENOMEM; revoke_table_cache = kmem_cache_create("revoke_table", sizeof(struct jbd_revoke_table_s), - 0, 0, NULL); + 0, 0, NULL, NULL); if (revoke_table_cache == 0) { kmem_cache_destroy(revoke_record_cache); revoke_record_cache = NULL; diff --git a/trunk/fs/jbd2/journal.c b/trunk/fs/jbd2/journal.c index f37324aee817..f290cb7cb834 100644 --- a/trunk/fs/jbd2/journal.c +++ b/trunk/fs/jbd2/journal.c @@ -1680,7 +1680,7 @@ static int jbd2_journal_create_jbd_slab(size_t slab_size) * boundary. */ jbd_slab[i] = kmem_cache_create(jbd_slab_names[i], - slab_size, slab_size, 0, NULL); + slab_size, slab_size, 0, NULL, NULL); if (!jbd_slab[i]) { printk(KERN_EMERG "JBD: no memory for jbd_slab cache\n"); return -ENOMEM; @@ -1723,7 +1723,8 @@ static int journal_init_jbd2_journal_head_cache(void) sizeof(struct journal_head), 0, /* offset */ 0, /* flags */ - NULL); /* ctor */ + NULL, /* ctor */ + NULL); /* dtor */ retval = 0; if (jbd2_journal_head_cache == 0) { retval = -ENOMEM; @@ -2005,7 +2006,8 @@ static int __init journal_init_handle_cache(void) sizeof(handle_t), 0, /* offset */ 0, /* flags */ - NULL); /* ctor */ + NULL, /* ctor */ + NULL); /* dtor */ if (jbd2_handle_cache == NULL) { printk(KERN_EMERG "JBD: failed to create handle cache\n"); return -ENOMEM; diff --git a/trunk/fs/jbd2/revoke.c b/trunk/fs/jbd2/revoke.c index 01d88975e0c5..28cac049a56b 100644 --- a/trunk/fs/jbd2/revoke.c +++ b/trunk/fs/jbd2/revoke.c @@ -171,13 +171,13 @@ int __init jbd2_journal_init_revoke_caches(void) { jbd2_revoke_record_cache = kmem_cache_create("jbd2_revoke_record", sizeof(struct jbd2_revoke_record_s), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); if (jbd2_revoke_record_cache == 0) return -ENOMEM; jbd2_revoke_table_cache = kmem_cache_create("jbd2_revoke_table", sizeof(struct jbd2_revoke_table_s), - 0, 0, NULL); + 0, 0, NULL, NULL); if (jbd2_revoke_table_cache == 0) { kmem_cache_destroy(jbd2_revoke_record_cache); jbd2_revoke_record_cache = NULL; diff --git a/trunk/fs/jffs2/malloc.c b/trunk/fs/jffs2/malloc.c index f9211252b5f1..35c1a5e30ba1 100644 --- a/trunk/fs/jffs2/malloc.c +++ b/trunk/fs/jffs2/malloc.c @@ -33,56 +33,56 @@ int __init jffs2_create_slab_caches(void) { full_dnode_slab = kmem_cache_create("jffs2_full_dnode", sizeof(struct jffs2_full_dnode), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!full_dnode_slab) goto err; raw_dirent_slab = kmem_cache_create("jffs2_raw_dirent", sizeof(struct jffs2_raw_dirent), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!raw_dirent_slab) goto err; raw_inode_slab = kmem_cache_create("jffs2_raw_inode", sizeof(struct jffs2_raw_inode), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!raw_inode_slab) goto err; tmp_dnode_info_slab = kmem_cache_create("jffs2_tmp_dnode", sizeof(struct jffs2_tmp_dnode_info), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!tmp_dnode_info_slab) goto err; raw_node_ref_slab = kmem_cache_create("jffs2_refblock", sizeof(struct jffs2_raw_node_ref) * (REFS_PER_BLOCK + 1), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!raw_node_ref_slab) goto err; node_frag_slab = kmem_cache_create("jffs2_node_frag", sizeof(struct jffs2_node_frag), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!node_frag_slab) goto err; inode_cache_slab = kmem_cache_create("jffs2_inode_cache", sizeof(struct jffs2_inode_cache), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!inode_cache_slab) goto err; #ifdef CONFIG_JFFS2_FS_XATTR xattr_datum_cache = kmem_cache_create("jffs2_xattr_datum", sizeof(struct jffs2_xattr_datum), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!xattr_datum_cache) goto err; xattr_ref_cache = kmem_cache_create("jffs2_xattr_ref", sizeof(struct jffs2_xattr_ref), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!xattr_ref_cache) goto err; #endif diff --git a/trunk/fs/jffs2/super.c b/trunk/fs/jffs2/super.c index be2b70c2ec16..e220d3bd610d 100644 --- a/trunk/fs/jffs2/super.c +++ b/trunk/fs/jffs2/super.c @@ -192,7 +192,7 @@ static int __init init_jffs2_fs(void) sizeof(struct jffs2_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - jffs2_i_init_once); + jffs2_i_init_once, NULL); if (!jffs2_inode_cachep) { printk(KERN_ERR "JFFS2 error: Failed to initialise inode cache\n"); return -ENOMEM; diff --git a/trunk/fs/jfs/jfs_metapage.c b/trunk/fs/jfs/jfs_metapage.c index 62e96be02acf..77c7f1129dde 100644 --- a/trunk/fs/jfs/jfs_metapage.c +++ b/trunk/fs/jfs/jfs_metapage.c @@ -213,7 +213,7 @@ int __init metapage_init(void) * Allocate the metapage structures */ metapage_cache = kmem_cache_create("jfs_mp", sizeof(struct metapage), - 0, 0, init_once); + 0, 0, init_once, NULL); if (metapage_cache == NULL) return -ENOMEM; diff --git a/trunk/fs/jfs/super.c b/trunk/fs/jfs/super.c index 4b372f550652..929fceca7999 100644 --- a/trunk/fs/jfs/super.c +++ b/trunk/fs/jfs/super.c @@ -776,7 +776,7 @@ static int __init init_jfs_fs(void) jfs_inode_cachep = kmem_cache_create("jfs_ip", sizeof(struct jfs_inode_info), 0, SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, - init_once); + init_once, NULL); if (jfs_inode_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/locks.c b/trunk/fs/locks.c index 310510637247..4f2d749ac624 100644 --- a/trunk/fs/locks.c +++ b/trunk/fs/locks.c @@ -2276,7 +2276,7 @@ static int __init filelock_init(void) { filelock_cache = kmem_cache_create("file_lock_cache", sizeof(struct file_lock), 0, SLAB_PANIC, - init_once); + init_once, NULL); return 0; } diff --git a/trunk/fs/mbcache.c b/trunk/fs/mbcache.c index 1046cbefbfbf..fbb1d02f8791 100644 --- a/trunk/fs/mbcache.c +++ b/trunk/fs/mbcache.c @@ -292,7 +292,7 @@ mb_cache_create(const char *name, struct mb_cache_op *cache_op, INIT_LIST_HEAD(&cache->c_indexes_hash[m][n]); } cache->c_entry_cache = kmem_cache_create(name, entry_size, 0, - SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, NULL); + SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, NULL, NULL); if (!cache->c_entry_cache) goto fail; diff --git a/trunk/fs/minix/inode.c b/trunk/fs/minix/inode.c index 43668d7d668f..be4044614ac8 100644 --- a/trunk/fs/minix/inode.c +++ b/trunk/fs/minix/inode.c @@ -75,14 +75,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { minix_inode_cachep = kmem_cache_create("minix_inode_cache", sizeof(struct minix_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (minix_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/namespace.c b/trunk/fs/namespace.c index ddbda13c2d31..4198003d7e18 100644 --- a/trunk/fs/namespace.c +++ b/trunk/fs/namespace.c @@ -1801,7 +1801,7 @@ void __init mnt_init(unsigned long mempages) init_rwsem(&namespace_sem); mnt_cache = kmem_cache_create("mnt_cache", sizeof(struct vfsmount), - 0, SLAB_HWCACHE_ALIGN | SLAB_PANIC, NULL); + 0, SLAB_HWCACHE_ALIGN | SLAB_PANIC, NULL, NULL); mount_hashtable = (struct list_head *)__get_free_page(GFP_ATOMIC); diff --git a/trunk/fs/ncpfs/inode.c b/trunk/fs/ncpfs/inode.c index 7f8536dbdedc..cf06eb9f050e 100644 --- a/trunk/fs/ncpfs/inode.c +++ b/trunk/fs/ncpfs/inode.c @@ -63,14 +63,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag mutex_init(&ei->open_mutex); inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { ncp_inode_cachep = kmem_cache_create("ncp_inode_cache", sizeof(struct ncp_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (ncp_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/nfs/direct.c b/trunk/fs/nfs/direct.c index fcf4d384610e..a5c82b6f3b45 100644 --- a/trunk/fs/nfs/direct.c +++ b/trunk/fs/nfs/direct.c @@ -875,7 +875,7 @@ int __init nfs_init_directcache(void) sizeof(struct nfs_direct_req), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - NULL); + NULL, NULL); if (nfs_direct_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/nfs/inode.c b/trunk/fs/nfs/inode.c index bca6cdcb9f0d..3d9fccf4ef93 100644 --- a/trunk/fs/nfs/inode.c +++ b/trunk/fs/nfs/inode.c @@ -1165,14 +1165,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag nfsi->npages = 0; nfs4_init_once(nfsi); } - + static int __init nfs_init_inodecache(void) { nfs_inode_cachep = kmem_cache_create("nfs_inode_cache", sizeof(struct nfs_inode), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (nfs_inode_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/nfs/pagelist.c b/trunk/fs/nfs/pagelist.c index 345bb9b4765b..f56dae5216f4 100644 --- a/trunk/fs/nfs/pagelist.c +++ b/trunk/fs/nfs/pagelist.c @@ -442,7 +442,7 @@ int __init nfs_init_nfspagecache(void) nfs_page_cachep = kmem_cache_create("nfs_page", sizeof(struct nfs_page), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (nfs_page_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/nfs/read.c b/trunk/fs/nfs/read.c index 19e05633f4e3..6ae2e58ed05a 100644 --- a/trunk/fs/nfs/read.c +++ b/trunk/fs/nfs/read.c @@ -598,7 +598,7 @@ int __init nfs_init_readpagecache(void) nfs_rdata_cachep = kmem_cache_create("nfs_read_data", sizeof(struct nfs_read_data), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (nfs_rdata_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/nfs/write.c b/trunk/fs/nfs/write.c index ef97e0c0f5b1..73ac992ece85 100644 --- a/trunk/fs/nfs/write.c +++ b/trunk/fs/nfs/write.c @@ -1467,7 +1467,7 @@ int __init nfs_init_writepagecache(void) nfs_wdata_cachep = kmem_cache_create("nfs_write_data", sizeof(struct nfs_write_data), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (nfs_wdata_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/nfsd/nfs4state.c b/trunk/fs/nfsd/nfs4state.c index 3f559700788f..6284807bd37e 100644 --- a/trunk/fs/nfsd/nfs4state.c +++ b/trunk/fs/nfsd/nfs4state.c @@ -1032,19 +1032,19 @@ static int nfsd4_init_slabs(void) { stateowner_slab = kmem_cache_create("nfsd4_stateowners", - sizeof(struct nfs4_stateowner), 0, 0, NULL); + sizeof(struct nfs4_stateowner), 0, 0, NULL, NULL); if (stateowner_slab == NULL) goto out_nomem; file_slab = kmem_cache_create("nfsd4_files", - sizeof(struct nfs4_file), 0, 0, NULL); + sizeof(struct nfs4_file), 0, 0, NULL, NULL); if (file_slab == NULL) goto out_nomem; stateid_slab = kmem_cache_create("nfsd4_stateids", - sizeof(struct nfs4_stateid), 0, 0, NULL); + sizeof(struct nfs4_stateid), 0, 0, NULL, NULL); if (stateid_slab == NULL) goto out_nomem; deleg_slab = kmem_cache_create("nfsd4_delegations", - sizeof(struct nfs4_delegation), 0, 0, NULL); + sizeof(struct nfs4_delegation), 0, 0, NULL, NULL); if (deleg_slab == NULL) goto out_nomem; return 0; diff --git a/trunk/fs/ntfs/super.c b/trunk/fs/ntfs/super.c index 90c4e3a29706..4566b9182551 100644 --- a/trunk/fs/ntfs/super.c +++ b/trunk/fs/ntfs/super.c @@ -3143,7 +3143,7 @@ static int __init init_ntfs_fs(void) ntfs_index_ctx_cache = kmem_cache_create(ntfs_index_ctx_cache_name, sizeof(ntfs_index_context), 0 /* offset */, - SLAB_HWCACHE_ALIGN, NULL /* ctor */); + SLAB_HWCACHE_ALIGN, NULL /* ctor */, NULL /* dtor */); if (!ntfs_index_ctx_cache) { printk(KERN_CRIT "NTFS: Failed to create %s!\n", ntfs_index_ctx_cache_name); @@ -3151,7 +3151,7 @@ static int __init init_ntfs_fs(void) } ntfs_attr_ctx_cache = kmem_cache_create(ntfs_attr_ctx_cache_name, sizeof(ntfs_attr_search_ctx), 0 /* offset */, - SLAB_HWCACHE_ALIGN, NULL /* ctor */); + SLAB_HWCACHE_ALIGN, NULL /* ctor */, NULL /* dtor */); if (!ntfs_attr_ctx_cache) { printk(KERN_CRIT "NTFS: Failed to create %s!\n", ntfs_attr_ctx_cache_name); @@ -3160,7 +3160,7 @@ static int __init init_ntfs_fs(void) ntfs_name_cache = kmem_cache_create(ntfs_name_cache_name, (NTFS_MAX_NAME_LEN+1) * sizeof(ntfschar), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (!ntfs_name_cache) { printk(KERN_CRIT "NTFS: Failed to create %s!\n", ntfs_name_cache_name); @@ -3169,7 +3169,7 @@ static int __init init_ntfs_fs(void) ntfs_inode_cache = kmem_cache_create(ntfs_inode_cache_name, sizeof(ntfs_inode), 0, - SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, NULL); + SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, NULL, NULL); if (!ntfs_inode_cache) { printk(KERN_CRIT "NTFS: Failed to create %s!\n", ntfs_inode_cache_name); @@ -3179,7 +3179,7 @@ static int __init init_ntfs_fs(void) ntfs_big_inode_cache = kmem_cache_create(ntfs_big_inode_cache_name, sizeof(big_ntfs_inode), 0, SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, - ntfs_big_inode_init_once); + ntfs_big_inode_init_once, NULL); if (!ntfs_big_inode_cache) { printk(KERN_CRIT "NTFS: Failed to create %s!\n", ntfs_big_inode_cache_name); diff --git a/trunk/fs/ocfs2/dlm/dlmfs.c b/trunk/fs/ocfs2/dlm/dlmfs.c index 7418dc83de1c..fd8cb1badc9b 100644 --- a/trunk/fs/ocfs2/dlm/dlmfs.c +++ b/trunk/fs/ocfs2/dlm/dlmfs.c @@ -592,7 +592,7 @@ static int __init init_dlmfs_fs(void) sizeof(struct dlmfs_inode_private), 0, (SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - dlmfs_init_once); + dlmfs_init_once, NULL); if (!dlmfs_inode_cache) return -ENOMEM; cleanup_inode = 1; diff --git a/trunk/fs/ocfs2/dlm/dlmmaster.c b/trunk/fs/ocfs2/dlm/dlmmaster.c index 62e4a7daa286..65b2b9b92688 100644 --- a/trunk/fs/ocfs2/dlm/dlmmaster.c +++ b/trunk/fs/ocfs2/dlm/dlmmaster.c @@ -510,7 +510,7 @@ int dlm_init_mle_cache(void) dlm_mle_cache = kmem_cache_create("dlm_mle_cache", sizeof(struct dlm_master_list_entry), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (dlm_mle_cache == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/ocfs2/super.c b/trunk/fs/ocfs2/super.c index 200c7d4790dc..3a5a1ed09ac9 100644 --- a/trunk/fs/ocfs2/super.c +++ b/trunk/fs/ocfs2/super.c @@ -984,7 +984,7 @@ static int ocfs2_initialize_mem_caches(void) 0, (SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - ocfs2_inode_init_once); + ocfs2_inode_init_once, NULL); if (!ocfs2_inode_cachep) return -ENOMEM; diff --git a/trunk/fs/ocfs2/uptodate.c b/trunk/fs/ocfs2/uptodate.c index 4da8851f2b23..39814b900fc0 100644 --- a/trunk/fs/ocfs2/uptodate.c +++ b/trunk/fs/ocfs2/uptodate.c @@ -548,7 +548,7 @@ int __init init_ocfs2_uptodate_cache(void) { ocfs2_uptodate_cachep = kmem_cache_create("ocfs2_uptodate", sizeof(struct ocfs2_meta_cache_item), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); if (!ocfs2_uptodate_cachep) return -ENOMEM; diff --git a/trunk/fs/openpromfs/inode.c b/trunk/fs/openpromfs/inode.c index dd86be2aa6c9..e62397341c36 100644 --- a/trunk/fs/openpromfs/inode.c +++ b/trunk/fs/openpromfs/inode.c @@ -431,7 +431,7 @@ static int __init init_openprom_fs(void) 0, (SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD), - op_inode_init_once); + op_inode_init_once, NULL); if (!op_inode_cachep) return -ENOMEM; diff --git a/trunk/fs/proc/inode.c b/trunk/fs/proc/inode.c index 94e2c1adf184..dd28e86ab422 100644 --- a/trunk/fs/proc/inode.c +++ b/trunk/fs/proc/inode.c @@ -112,14 +112,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + int __init proc_init_inodecache(void) { proc_inode_cachep = kmem_cache_create("proc_inode_cache", sizeof(struct proc_inode), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (proc_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/qnx4/inode.c b/trunk/fs/qnx4/inode.c index 1bc8d873a9e1..8d256eb11813 100644 --- a/trunk/fs/qnx4/inode.c +++ b/trunk/fs/qnx4/inode.c @@ -545,7 +545,7 @@ static int init_inodecache(void) sizeof(struct qnx4_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (qnx4_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/reiserfs/super.c b/trunk/fs/reiserfs/super.c index 5b68dd3f191a..5a93cfe1a032 100644 --- a/trunk/fs/reiserfs/super.c +++ b/trunk/fs/reiserfs/super.c @@ -527,7 +527,7 @@ static int init_inodecache(void) reiserfs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (reiserfs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/romfs/inode.c b/trunk/fs/romfs/inode.c index dae7945f90e4..2284e03342c6 100644 --- a/trunk/fs/romfs/inode.c +++ b/trunk/fs/romfs/inode.c @@ -572,14 +572,14 @@ static void init_once(void *foo, struct kmem_cache *cachep, unsigned long flags) inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { romfs_inode_cachep = kmem_cache_create("romfs_inode_cache", sizeof(struct romfs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (romfs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/smbfs/inode.c b/trunk/fs/smbfs/inode.c index 73d1450a95d4..6724a6cf01ff 100644 --- a/trunk/fs/smbfs/inode.c +++ b/trunk/fs/smbfs/inode.c @@ -73,14 +73,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { smb_inode_cachep = kmem_cache_create("smb_inode_cache", sizeof(struct smb_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (smb_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/smbfs/request.c b/trunk/fs/smbfs/request.c index ca4b2d59c0ca..3f54a0f80fae 100644 --- a/trunk/fs/smbfs/request.c +++ b/trunk/fs/smbfs/request.c @@ -40,7 +40,7 @@ int smb_init_request_cache(void) req_cachep = kmem_cache_create("smb_request", sizeof(struct smb_request), 0, SMB_SLAB_DEBUG | SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (req_cachep == NULL) return -ENOMEM; diff --git a/trunk/fs/sysfs/mount.c b/trunk/fs/sysfs/mount.c index fbc7b65fe262..60714d075c2f 100644 --- a/trunk/fs/sysfs/mount.c +++ b/trunk/fs/sysfs/mount.c @@ -86,7 +86,7 @@ int __init sysfs_init(void) sysfs_dir_cachep = kmem_cache_create("sysfs_dir_cache", sizeof(struct sysfs_dirent), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!sysfs_dir_cachep) goto out; diff --git a/trunk/fs/sysv/inode.c b/trunk/fs/sysv/inode.c index 7c4e5d302abb..564411693394 100644 --- a/trunk/fs/sysv/inode.c +++ b/trunk/fs/sysv/inode.c @@ -342,7 +342,7 @@ int __init sysv_init_icache(void) sysv_inode_cachep = kmem_cache_create("sysv_inode_cache", sizeof(struct sysv_inode_info), 0, SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, - init_once); + init_once, NULL); if (!sysv_inode_cachep) return -ENOMEM; return 0; diff --git a/trunk/fs/udf/super.c b/trunk/fs/udf/super.c index 72097ee6b752..911387aa1810 100644 --- a/trunk/fs/udf/super.c +++ b/trunk/fs/udf/super.c @@ -149,7 +149,7 @@ static int init_inodecache(void) sizeof(struct udf_inode_info), 0, (SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (udf_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/ufs/super.c b/trunk/fs/ufs/super.c index 73402c5eeb8a..2b3011689e89 100644 --- a/trunk/fs/ufs/super.c +++ b/trunk/fs/ufs/super.c @@ -1240,14 +1240,14 @@ static void init_once(void * foo, struct kmem_cache * cachep, unsigned long flag inode_init_once(&ei->vfs_inode); } - + static int init_inodecache(void) { ufs_inode_cachep = kmem_cache_create("ufs_inode_cache", sizeof(struct ufs_inode_info), 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (ufs_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/fs/xfs/linux-2.6/kmem.h b/trunk/fs/xfs/linux-2.6/kmem.h index b4acc7f3c374..4b6470cf87f0 100644 --- a/trunk/fs/xfs/linux-2.6/kmem.h +++ b/trunk/fs/xfs/linux-2.6/kmem.h @@ -74,14 +74,14 @@ extern void kmem_free(void *, size_t); static inline kmem_zone_t * kmem_zone_init(int size, char *zone_name) { - return kmem_cache_create(zone_name, size, 0, 0, NULL); + return kmem_cache_create(zone_name, size, 0, 0, NULL, NULL); } static inline kmem_zone_t * kmem_zone_init_flags(int size, char *zone_name, unsigned long flags, void (*construct)(void *, kmem_zone_t *, unsigned long)) { - return kmem_cache_create(zone_name, size, 0, flags, construct); + return kmem_cache_create(zone_name, size, 0, flags, construct, NULL); } static inline void diff --git a/trunk/include/asm-m68k/io.h b/trunk/include/asm-m68k/io.h index 47bb9cf107b7..5e0fcf41804d 100644 --- a/trunk/include/asm-m68k/io.h +++ b/trunk/include/asm-m68k/io.h @@ -27,7 +27,6 @@ #include #include -#include #ifdef CONFIG_ATARI #include @@ -153,16 +152,6 @@ static inline u16 __iomem *isa_itw(unsigned long addr) default: return NULL; /* avoid warnings, just in case */ } } -static inline u32 __iomem *isa_itl(unsigned long addr) -{ - switch(ISA_TYPE) - { -#ifdef CONFIG_AMIGA_PCMCIA - case AG_ISA: return (u32 __iomem *)AG_ISA_IO_W(addr); -#endif - default: return 0; /* avoid warnings, just in case */ - } -} static inline u8 __iomem *isa_mtb(unsigned long addr) { switch(ISA_TYPE) @@ -199,10 +188,8 @@ static inline u16 __iomem *isa_mtw(unsigned long addr) #define isa_inb(port) in_8(isa_itb(port)) #define isa_inw(port) (ISA_SEX ? in_be16(isa_itw(port)) : in_le16(isa_itw(port))) -#define isa_inl(port) (ISA_SEX ? in_be32(isa_itl(port)) : in_le32(isa_itl(port))) #define isa_outb(val,port) out_8(isa_itb(port),(val)) #define isa_outw(val,port) (ISA_SEX ? out_be16(isa_itw(port),(val)) : out_le16(isa_itw(port),(val))) -#define isa_outl(val,port) (ISA_SEX ? out_be32(isa_itl(port),(val)) : out_le32(isa_itl(port),(val))) #define isa_readb(p) in_8(isa_mtb((unsigned long)(p))) #define isa_readw(p) \ @@ -247,15 +234,6 @@ static inline void isa_delay(void) #define isa_outsw(port, buf, nr) \ (ISA_SEX ? raw_outsw(isa_itw(port), (u16 *)(buf), (nr)) : \ raw_outsw_swapw(isa_itw(port), (u16 *)(buf), (nr))) - -#define isa_insl(port, buf, nr) \ - (ISA_SEX ? raw_insl(isa_itl(port), (u32 *)(buf), (nr)) : \ - raw_insw_swapw(isa_itw(port), (u16 *)(buf), (nr)<<1)) - -#define isa_outsl(port, buf, nr) \ - (ISA_SEX ? raw_outsl(isa_itl(port), (u32 *)(buf), (nr)) : \ - raw_outsw_swapw(isa_itw(port), (u16 *)(buf), (nr)<<1)) - #endif /* CONFIG_ISA */ @@ -268,16 +246,14 @@ static inline void isa_delay(void) #define inw_p isa_inw_p #define outw isa_outw #define outw_p isa_outw_p -#define inl isa_inl -#define inl_p isa_inl_p -#define outl isa_outl -#define outl_p isa_outl_p +#define inl isa_inw +#define inl_p isa_inw_p +#define outl isa_outw +#define outl_p isa_outw_p #define insb isa_insb #define insw isa_insw -#define insl isa_insl #define outsb isa_outsb #define outsw isa_outsw -#define outsl isa_outsl #define readb isa_readb #define readw isa_readw #define writeb isa_writeb @@ -286,6 +262,8 @@ static inline void isa_delay(void) #if defined(CONFIG_PCI) +#define inl(port) in_le32(port) +#define outl(val,port) out_le32((port),(val)) #define readl(addr) in_le32(addr) #define writel(val,addr) out_le32((addr),(val)) @@ -304,8 +282,6 @@ static inline void isa_delay(void) #define outb(val,port) out_8((port),(val)) #define inw(port) in_le16(port) #define outw(val,port) out_le16((port),(val)) -#define inl(port) in_le32(port) -#define outl(val,port) out_le32((port),(val)) #else /* @@ -330,35 +306,20 @@ static inline void isa_delay(void) #endif #endif /* CONFIG_PCI */ -#if !defined(CONFIG_ISA) && !defined(CONFIG_PCI) +#if !defined(CONFIG_ISA) && !defined(CONFIG_PCI) && defined(CONFIG_HP300) /* - * We need to define dummy functions for GENERIC_IOMAP support. + * We need to define dummy functions otherwise drivers/serial/8250.c doesn't link */ -#define inb(port) 0xff -#define inb_p(port) 0xff -#define outb(val,port) ((void)0) -#define outb_p(val,port) ((void)0) -#define inw(port) 0xffff -#define outw(val,port) ((void)0) -#define inl(port) 0xffffffffUL -#define outl(val,port) ((void)0) - -#define insb(port,buf,nr) ((void)0) -#define outsb(port,buf,nr) ((void)0) -#define insw(port,buf,nr) ((void)0) -#define outsw(port,buf,nr) ((void)0) -#define insl(port,buf,nr) ((void)0) -#define outsl(port,buf,nr) ((void)0) +#define inb(port) 0xff +#define inb_p(port) 0xff +#define outb(val,port) do { } while (0) +#define outb_p(val,port) do { } while (0) /* * These should be valid on any ioremap()ed region */ #define readb(addr) in_8(addr) #define writeb(val,addr) out_8((addr),(val)) -#define readw(addr) in_le16(addr) -#define writew(val,addr) out_le16((addr),(val)) -#endif -#if !defined(CONFIG_PCI) #define readl(addr) in_le32(addr) #define writel(val,addr) out_le32((addr),(val)) #endif @@ -390,18 +351,6 @@ extern void dma_cache_wback_inv(unsigned long start, unsigned long size); extern void dma_cache_wback(unsigned long start, unsigned long size); extern void dma_cache_inv(unsigned long start, unsigned long size); -static inline void memset_io(volatile void __iomem *addr, unsigned char val, int count) -{ - __builtin_memset((void __force *) addr, val, count); -} -static inline void memcpy_fromio(void *dst, const volatile void __iomem *src, int count) -{ - __builtin_memcpy(dst, (void __force *) src, count); -} -static inline void memcpy_toio(volatile void __iomem *dst, const void *src, int count) -{ - __builtin_memcpy((void __force *) dst, src, count); -} #ifndef CONFIG_SUN3 #define IO_SPACE_LIMIT 0xffff diff --git a/trunk/include/asm-m68k/raw_io.h b/trunk/include/asm-m68k/raw_io.h index 91c623f0994c..811ccd25d4a6 100644 --- a/trunk/include/asm-m68k/raw_io.h +++ b/trunk/include/asm-m68k/raw_io.h @@ -49,16 +49,10 @@ extern void __iounmap(void *addr, unsigned long size); #define raw_inb in_8 #define raw_inw in_be16 #define raw_inl in_be32 -#define __raw_readb in_8 -#define __raw_readw in_be16 -#define __raw_readl in_be32 #define raw_outb(val,port) out_8((port),(val)) #define raw_outw(val,port) out_be16((port),(val)) #define raw_outl(val,port) out_be32((port),(val)) -#define __raw_writeb(val,addr) out_8((addr),(val)) -#define __raw_writew(val,addr) out_be16((addr),(val)) -#define __raw_writel(val,addr) out_be32((addr),(val)) static inline void raw_insb(volatile u8 __iomem *port, u8 *buf, unsigned int len) { @@ -342,6 +336,8 @@ static inline void raw_outsw_swapw(volatile u16 __iomem *port, const u16 *buf, : "d0", "a0", "a1", "d6"); } +#define __raw_writel raw_outl + #endif /* __KERNEL__ */ #endif /* _RAW_IO_H */ diff --git a/trunk/include/linux/i2o.h b/trunk/include/linux/i2o.h index 9752307d16ba..333a370a3bdc 100644 --- a/trunk/include/linux/i2o.h +++ b/trunk/include/linux/i2o.h @@ -946,7 +946,8 @@ static inline int i2o_pool_alloc(struct i2o_pool *pool, const char *name, strcpy(pool->name, name); pool->slab = - kmem_cache_create(pool->name, size, 0, SLAB_HWCACHE_ALIGN, NULL); + kmem_cache_create(pool->name, size, 0, SLAB_HWCACHE_ALIGN, NULL, + NULL); if (!pool->slab) goto free_name; diff --git a/trunk/include/linux/slab.h b/trunk/include/linux/slab.h index 7d0ecc1659f0..0e1d0daef6a2 100644 --- a/trunk/include/linux/slab.h +++ b/trunk/include/linux/slab.h @@ -51,6 +51,7 @@ int slab_is_available(void); struct kmem_cache *kmem_cache_create(const char *, size_t, size_t, unsigned long, + void (*)(void *, struct kmem_cache *, unsigned long), void (*)(void *, struct kmem_cache *, unsigned long)); void kmem_cache_destroy(struct kmem_cache *); int kmem_cache_shrink(struct kmem_cache *); @@ -69,7 +70,7 @@ int kmem_ptr_validate(struct kmem_cache *cachep, const void *ptr); */ #define KMEM_CACHE(__struct, __flags) kmem_cache_create(#__struct,\ sizeof(struct __struct), __alignof__(struct __struct),\ - (__flags), NULL) + (__flags), NULL, NULL) /* * The largest kmalloc size supported by the slab allocators is diff --git a/trunk/include/linux/slub_def.h b/trunk/include/linux/slub_def.h index 124270df8734..07f7e4cbcee3 100644 --- a/trunk/include/linux/slub_def.h +++ b/trunk/include/linux/slub_def.h @@ -160,7 +160,7 @@ static inline struct kmem_cache *kmalloc_slab(size_t size) #define SLUB_DMA __GFP_DMA #else /* Disable DMA functionality */ -#define SLUB_DMA (__force gfp_t)0 +#define SLUB_DMA 0 #endif void *kmem_cache_alloc(struct kmem_cache *, gfp_t); diff --git a/trunk/ipc/mqueue.c b/trunk/ipc/mqueue.c index 145d5a0d299f..a242c83d89d6 100644 --- a/trunk/ipc/mqueue.c +++ b/trunk/ipc/mqueue.c @@ -1253,7 +1253,7 @@ static int __init init_mqueue_fs(void) mqueue_inode_cachep = kmem_cache_create("mqueue_inode_cache", sizeof(struct mqueue_inode_info), 0, - SLAB_HWCACHE_ALIGN, init_once); + SLAB_HWCACHE_ALIGN, init_once, NULL); if (mqueue_inode_cachep == NULL) return -ENOMEM; diff --git a/trunk/kernel/fork.c b/trunk/kernel/fork.c index 7332e236d367..469838998220 100644 --- a/trunk/kernel/fork.c +++ b/trunk/kernel/fork.c @@ -137,7 +137,7 @@ void __init fork_init(unsigned long mempages) /* create a slab on which task_structs can be allocated */ task_struct_cachep = kmem_cache_create("task_struct", sizeof(struct task_struct), - ARCH_MIN_TASKALIGN, SLAB_PANIC, NULL); + ARCH_MIN_TASKALIGN, SLAB_PANIC, NULL, NULL); #endif /* @@ -1446,22 +1446,22 @@ void __init proc_caches_init(void) sighand_cachep = kmem_cache_create("sighand_cache", sizeof(struct sighand_struct), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC|SLAB_DESTROY_BY_RCU, - sighand_ctor); + sighand_ctor, NULL); signal_cachep = kmem_cache_create("signal_cache", sizeof(struct signal_struct), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); - files_cachep = kmem_cache_create("files_cache", + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); + files_cachep = kmem_cache_create("files_cache", sizeof(struct files_struct), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); - fs_cachep = kmem_cache_create("fs_cache", + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); + fs_cachep = kmem_cache_create("fs_cache", sizeof(struct fs_struct), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); vm_area_cachep = kmem_cache_create("vm_area_struct", sizeof(struct vm_area_struct), 0, - SLAB_PANIC, NULL); + SLAB_PANIC, NULL, NULL); mm_cachep = kmem_cache_create("mm_struct", sizeof(struct mm_struct), ARCH_MIN_MMSTRUCT_ALIGN, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); } /* diff --git a/trunk/kernel/nsproxy.c b/trunk/kernel/nsproxy.c index a4fb7d46971f..10f0bbba382b 100644 --- a/trunk/kernel/nsproxy.c +++ b/trunk/kernel/nsproxy.c @@ -193,7 +193,7 @@ int unshare_nsproxy_namespaces(unsigned long unshare_flags, static int __init nsproxy_cache_init(void) { nsproxy_cachep = kmem_cache_create("nsproxy", sizeof(struct nsproxy), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); return 0; } diff --git a/trunk/kernel/posix-timers.c b/trunk/kernel/posix-timers.c index 55b3761edaa9..329ce0172074 100644 --- a/trunk/kernel/posix-timers.c +++ b/trunk/kernel/posix-timers.c @@ -241,7 +241,7 @@ static __init int init_posix_timers(void) register_posix_clock(CLOCK_MONOTONIC, &clock_monotonic); posix_timers_cache = kmem_cache_create("posix_timers_cache", - sizeof (struct k_itimer), 0, 0, NULL); + sizeof (struct k_itimer), 0, 0, NULL, NULL); idr_init(&posix_timers_id); return 0; } diff --git a/trunk/kernel/user.c b/trunk/kernel/user.c index e7d11cef6998..98b82507797a 100644 --- a/trunk/kernel/user.c +++ b/trunk/kernel/user.c @@ -208,7 +208,7 @@ static int __init uid_cache_init(void) int n; uid_cachep = kmem_cache_create("uid_cache", sizeof(struct user_struct), - 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); for(n = 0; n < UIDHASH_SZ; ++n) INIT_LIST_HEAD(init_user_ns.uidhash_table + n); diff --git a/trunk/lib/idr.c b/trunk/lib/idr.c index ffd61941e75d..5ca67b3cfd35 100644 --- a/trunk/lib/idr.c +++ b/trunk/lib/idr.c @@ -590,7 +590,7 @@ static int init_id_cache(void) { if (!idr_layer_cache) idr_layer_cache = kmem_cache_create("idr_layer_cache", - sizeof(struct idr_layer), 0, 0, idr_cache_ctor); + sizeof(struct idr_layer), 0, 0, idr_cache_ctor, NULL); return 0; } diff --git a/trunk/lib/radix-tree.c b/trunk/lib/radix-tree.c index 514efb200be6..9927cca14cb7 100644 --- a/trunk/lib/radix-tree.c +++ b/trunk/lib/radix-tree.c @@ -1021,7 +1021,7 @@ void __init radix_tree_init(void) { radix_tree_node_cachep = kmem_cache_create("radix_tree_node", sizeof(struct radix_tree_node), 0, - SLAB_PANIC, radix_tree_node_ctor); + SLAB_PANIC, radix_tree_node_ctor, NULL); radix_tree_init_maxindex(); hotcpu_notifier(radix_tree_callback, 0); } diff --git a/trunk/mm/mempolicy.c b/trunk/mm/mempolicy.c index 71b84b45154a..9f4e9b95e8f2 100644 --- a/trunk/mm/mempolicy.c +++ b/trunk/mm/mempolicy.c @@ -1605,11 +1605,11 @@ void __init numa_policy_init(void) policy_cache = kmem_cache_create("numa_policy", sizeof(struct mempolicy), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); sn_cache = kmem_cache_create("shared_policy_node", sizeof(struct sp_node), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); /* * Set interleaving policy for system init. Interleaving is only diff --git a/trunk/mm/rmap.c b/trunk/mm/rmap.c index 41ac39749ef4..fede5c7910be 100644 --- a/trunk/mm/rmap.c +++ b/trunk/mm/rmap.c @@ -149,7 +149,7 @@ static void anon_vma_ctor(void *data, struct kmem_cache *cachep, void __init anon_vma_init(void) { anon_vma_cachep = kmem_cache_create("anon_vma", sizeof(struct anon_vma), - 0, SLAB_DESTROY_BY_RCU|SLAB_PANIC, anon_vma_ctor); + 0, SLAB_DESTROY_BY_RCU|SLAB_PANIC, anon_vma_ctor, NULL); } /* diff --git a/trunk/mm/shmem.c b/trunk/mm/shmem.c index fcd19d323f9f..ad155c7745dc 100644 --- a/trunk/mm/shmem.c +++ b/trunk/mm/shmem.c @@ -2322,7 +2322,7 @@ static int init_inodecache(void) { shmem_inode_cachep = kmem_cache_create("shmem_inode_cache", sizeof(struct shmem_inode_info), - 0, 0, init_once); + 0, 0, init_once, NULL); if (shmem_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/mm/slab.c b/trunk/mm/slab.c index bde271c001ba..c3feeaab3875 100644 --- a/trunk/mm/slab.c +++ b/trunk/mm/slab.c @@ -1484,7 +1484,7 @@ void __init kmem_cache_init(void) sizes[INDEX_AC].cs_size, ARCH_KMALLOC_MINALIGN, ARCH_KMALLOC_FLAGS|SLAB_PANIC, - NULL); + NULL, NULL); if (INDEX_AC != INDEX_L3) { sizes[INDEX_L3].cs_cachep = @@ -1492,7 +1492,7 @@ void __init kmem_cache_init(void) sizes[INDEX_L3].cs_size, ARCH_KMALLOC_MINALIGN, ARCH_KMALLOC_FLAGS|SLAB_PANIC, - NULL); + NULL, NULL); } slab_early_init = 0; @@ -1510,7 +1510,7 @@ void __init kmem_cache_init(void) sizes->cs_size, ARCH_KMALLOC_MINALIGN, ARCH_KMALLOC_FLAGS|SLAB_PANIC, - NULL); + NULL, NULL); } #ifdef CONFIG_ZONE_DMA sizes->cs_dmacachep = kmem_cache_create( @@ -1519,7 +1519,7 @@ void __init kmem_cache_init(void) ARCH_KMALLOC_MINALIGN, ARCH_KMALLOC_FLAGS|SLAB_CACHE_DMA| SLAB_PANIC, - NULL); + NULL, NULL); #endif sizes++; names++; @@ -2101,10 +2101,12 @@ static int __init_refok setup_cpu_cache(struct kmem_cache *cachep) * @align: The required alignment for the objects. * @flags: SLAB flags * @ctor: A constructor for the objects. + * @dtor: A destructor for the objects (not implemented anymore). * * Returns a ptr to the cache on success, NULL on failure. * Cannot be called within a int, but can be interrupted. - * The @ctor is run when new pages are allocated by the cache. + * The @ctor is run when new pages are allocated by the cache + * and the @dtor is run before the pages are handed back. * * @name must be valid until the cache is destroyed. This implies that * the module calling this has to destroy the cache before getting unloaded. @@ -2124,7 +2126,8 @@ static int __init_refok setup_cpu_cache(struct kmem_cache *cachep) struct kmem_cache * kmem_cache_create (const char *name, size_t size, size_t align, unsigned long flags, - void (*ctor)(void*, struct kmem_cache *, unsigned long)) + void (*ctor)(void*, struct kmem_cache *, unsigned long), + void (*dtor)(void*, struct kmem_cache *, unsigned long)) { size_t left_over, slab_size, ralign; struct kmem_cache *cachep = NULL, *pc; @@ -2133,7 +2136,7 @@ kmem_cache_create (const char *name, size_t size, size_t align, * Sanity checks... these are all serious usage bugs. */ if (!name || in_interrupt() || (size < BYTES_PER_WORD) || - size > KMALLOC_MAX_SIZE) { + size > KMALLOC_MAX_SIZE || dtor) { printk(KERN_ERR "%s: Early error in slab %s\n", __FUNCTION__, name); BUG(); diff --git a/trunk/mm/slob.c b/trunk/mm/slob.c index d50920ecc02b..c89ef116d7aa 100644 --- a/trunk/mm/slob.c +++ b/trunk/mm/slob.c @@ -492,7 +492,8 @@ struct kmem_cache { struct kmem_cache *kmem_cache_create(const char *name, size_t size, size_t align, unsigned long flags, - void (*ctor)(void*, struct kmem_cache *, unsigned long)) + void (*ctor)(void*, struct kmem_cache *, unsigned long), + void (*dtor)(void*, struct kmem_cache *, unsigned long)) { struct kmem_cache *c; diff --git a/trunk/mm/slub.c b/trunk/mm/slub.c index 9b2d6178d06c..322f3a5d72c7 100644 --- a/trunk/mm/slub.c +++ b/trunk/mm/slub.c @@ -2668,10 +2668,12 @@ static struct kmem_cache *find_mergeable(size_t size, struct kmem_cache *kmem_cache_create(const char *name, size_t size, size_t align, unsigned long flags, - void (*ctor)(void *, struct kmem_cache *, unsigned long)) + void (*ctor)(void *, struct kmem_cache *, unsigned long), + void (*dtor)(void *, struct kmem_cache *, unsigned long)) { struct kmem_cache *s; + BUG_ON(dtor); down_write(&slub_lock); s = find_mergeable(size, align, flags, ctor); if (s) { diff --git a/trunk/net/bridge/br_fdb.c b/trunk/net/bridge/br_fdb.c index 69b70977f000..3fc697293819 100644 --- a/trunk/net/bridge/br_fdb.c +++ b/trunk/net/bridge/br_fdb.c @@ -36,7 +36,7 @@ int __init br_fdb_init(void) br_fdb_cache = kmem_cache_create("bridge_fdb_cache", sizeof(struct net_bridge_fdb_entry), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (!br_fdb_cache) return -ENOMEM; diff --git a/trunk/net/core/flow.c b/trunk/net/core/flow.c index 0ab5234b17d8..051430545a05 100644 --- a/trunk/net/core/flow.c +++ b/trunk/net/core/flow.c @@ -350,7 +350,7 @@ static int __init flow_cache_init(void) flow_cachep = kmem_cache_create("flow_cache", sizeof(struct flow_cache_entry), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); flow_hash_shift = 10; flow_lwm = 2 * flow_hash_size; flow_hwm = 4 * flow_hash_size; diff --git a/trunk/net/core/neighbour.c b/trunk/net/core/neighbour.c index ca2a1533138a..9df26a07f067 100644 --- a/trunk/net/core/neighbour.c +++ b/trunk/net/core/neighbour.c @@ -1347,7 +1347,7 @@ void neigh_table_init_no_netlink(struct neigh_table *tbl) tbl->kmem_cachep = kmem_cache_create(tbl->id, tbl->entry_size, 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); tbl->stats = alloc_percpu(struct neigh_statistics); if (!tbl->stats) panic("cannot create neighbour cache statistics"); diff --git a/trunk/net/core/skbuff.c b/trunk/net/core/skbuff.c index 35021eb3ed07..0583e8498f13 100644 --- a/trunk/net/core/skbuff.c +++ b/trunk/net/core/skbuff.c @@ -2021,13 +2021,13 @@ void __init skb_init(void) sizeof(struct sk_buff), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); skbuff_fclone_cache = kmem_cache_create("skbuff_fclone_cache", (2*sizeof(struct sk_buff)) + sizeof(atomic_t), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); } /** diff --git a/trunk/net/core/sock.c b/trunk/net/core/sock.c index bd209c4477a9..239a08a6ff24 100644 --- a/trunk/net/core/sock.c +++ b/trunk/net/core/sock.c @@ -1767,7 +1767,7 @@ int proto_register(struct proto *prot, int alloc_slab) if (alloc_slab) { prot->slab = kmem_cache_create(prot->name, prot->obj_size, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (prot->slab == NULL) { printk(KERN_CRIT "%s: Can't create sock SLAB cache!\n", @@ -1785,7 +1785,7 @@ int proto_register(struct proto *prot, int alloc_slab) sprintf(request_sock_slab_name, mask, prot->name); prot->rsk_prot->slab = kmem_cache_create(request_sock_slab_name, prot->rsk_prot->obj_size, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (prot->rsk_prot->slab == NULL) { printk(KERN_CRIT "%s: Can't create request sock SLAB cache!\n", @@ -1807,7 +1807,7 @@ int proto_register(struct proto *prot, int alloc_slab) kmem_cache_create(timewait_sock_slab_name, prot->twsk_prot->twsk_obj_size, 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (prot->twsk_prot->twsk_slab == NULL) goto out_free_timewait_sock_slab_name; } diff --git a/trunk/net/dccp/ackvec.c b/trunk/net/dccp/ackvec.c index 7ac775f9a64b..01030f346177 100644 --- a/trunk/net/dccp/ackvec.c +++ b/trunk/net/dccp/ackvec.c @@ -481,14 +481,14 @@ int __init dccp_ackvec_init(void) { dccp_ackvec_slab = kmem_cache_create("dccp_ackvec", sizeof(struct dccp_ackvec), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (dccp_ackvec_slab == NULL) goto out_err; dccp_ackvec_record_slab = kmem_cache_create("dccp_ackvec_record", sizeof(struct dccp_ackvec_record), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); if (dccp_ackvec_record_slab == NULL) goto out_destroy_slab; diff --git a/trunk/net/dccp/ccid.c b/trunk/net/dccp/ccid.c index ccbf72c793b6..d8cf92f09e68 100644 --- a/trunk/net/dccp/ccid.c +++ b/trunk/net/dccp/ccid.c @@ -69,7 +69,7 @@ static struct kmem_cache *ccid_kmem_cache_create(int obj_size, const char *fmt,. if (slab_name == NULL) return NULL; slab = kmem_cache_create(slab_name, sizeof(struct ccid) + obj_size, 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (slab == NULL) kfree(slab_name); return slab; diff --git a/trunk/net/dccp/ccids/lib/loss_interval.c b/trunk/net/dccp/ccids/lib/loss_interval.c index 174d3f13d93f..dd0fc992b042 100644 --- a/trunk/net/dccp/ccids/lib/loss_interval.c +++ b/trunk/net/dccp/ccids/lib/loss_interval.c @@ -282,7 +282,7 @@ static __init int dccp_li_init(void) { dccp_li_cachep = kmem_cache_create("dccp_li_hist", sizeof(struct dccp_li_hist_entry), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); return dccp_li_cachep == NULL ? -ENOBUFS : 0; } diff --git a/trunk/net/dccp/ccids/lib/packet_history.c b/trunk/net/dccp/ccids/lib/packet_history.c index 34c4f6047724..2e8ef42721e2 100644 --- a/trunk/net/dccp/ccids/lib/packet_history.c +++ b/trunk/net/dccp/ccids/lib/packet_history.c @@ -59,7 +59,7 @@ struct dccp_tx_hist *dccp_tx_hist_new(const char *name) hist->dccptxh_slab = kmem_cache_create(slab_name, sizeof(struct dccp_tx_hist_entry), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (hist->dccptxh_slab == NULL) goto out_free_slab_name; out: @@ -148,7 +148,7 @@ struct dccp_rx_hist *dccp_rx_hist_new(const char *name) hist->dccprxh_slab = kmem_cache_create(slab_name, sizeof(struct dccp_rx_hist_entry), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (hist->dccprxh_slab == NULL) goto out_free_slab_name; out: diff --git a/trunk/net/dccp/proto.c b/trunk/net/dccp/proto.c index 04b59ec4f512..6607b7b14f34 100644 --- a/trunk/net/dccp/proto.c +++ b/trunk/net/dccp/proto.c @@ -1003,7 +1003,7 @@ static int __init dccp_init(void) dccp_hashinfo.bind_bucket_cachep = kmem_cache_create("dccp_bind_bucket", sizeof(struct inet_bind_bucket), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (!dccp_hashinfo.bind_bucket_cachep) goto out; diff --git a/trunk/net/decnet/dn_route.c b/trunk/net/decnet/dn_route.c index f2a61ef2af9c..82622fb6f68f 100644 --- a/trunk/net/decnet/dn_route.c +++ b/trunk/net/decnet/dn_route.c @@ -1770,7 +1770,7 @@ void __init dn_route_init(void) dn_dst_ops.kmem_cachep = kmem_cache_create("dn_dst_cache", sizeof(struct dn_route), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); init_timer(&dn_route_timer); dn_route_timer.function = dn_dst_check_expire; dn_route_timer.expires = jiffies + decnet_dst_gc_interval * HZ; diff --git a/trunk/net/decnet/dn_table.c b/trunk/net/decnet/dn_table.c index fda0772fa215..d6615c9361e9 100644 --- a/trunk/net/decnet/dn_table.c +++ b/trunk/net/decnet/dn_table.c @@ -881,7 +881,7 @@ void __init dn_fib_table_init(void) dn_hash_kmem = kmem_cache_create("dn_fib_info_cache", sizeof(struct dn_fib_info), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); } void __exit dn_fib_table_cleanup(void) diff --git a/trunk/net/ipv4/fib_hash.c b/trunk/net/ipv4/fib_hash.c index 9ad1d9ff9ce7..07e843a47dde 100644 --- a/trunk/net/ipv4/fib_hash.c +++ b/trunk/net/ipv4/fib_hash.c @@ -771,13 +771,13 @@ struct fib_table * __init fib_hash_init(u32 id) fn_hash_kmem = kmem_cache_create("ip_fib_hash", sizeof(struct fib_node), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (fn_alias_kmem == NULL) fn_alias_kmem = kmem_cache_create("ip_fib_alias", sizeof(struct fib_alias), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); tb = kmalloc(sizeof(struct fib_table) + sizeof(struct fn_hash), GFP_KERNEL); diff --git a/trunk/net/ipv4/fib_trie.c b/trunk/net/ipv4/fib_trie.c index 9ca786a6fd3c..30e332ade61b 100644 --- a/trunk/net/ipv4/fib_trie.c +++ b/trunk/net/ipv4/fib_trie.c @@ -1970,7 +1970,7 @@ struct fib_table * __init fib_hash_init(u32 id) fn_alias_kmem = kmem_cache_create("ip_fib_alias", sizeof(struct fib_alias), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); tb = kmalloc(sizeof(struct fib_table) + sizeof(struct trie), GFP_KERNEL); diff --git a/trunk/net/ipv4/inetpeer.c b/trunk/net/ipv4/inetpeer.c index 6cbce96a54ce..2f44e6128068 100644 --- a/trunk/net/ipv4/inetpeer.c +++ b/trunk/net/ipv4/inetpeer.c @@ -123,7 +123,7 @@ void __init inet_initpeers(void) peer_cachep = kmem_cache_create("inet_peer_cache", sizeof(struct inet_peer), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); /* All the timers, started at system startup tend to synchronize. Perturb it a bit. diff --git a/trunk/net/ipv4/ipmr.c b/trunk/net/ipv4/ipmr.c index 7003cc1b7fe2..d96582acdf69 100644 --- a/trunk/net/ipv4/ipmr.c +++ b/trunk/net/ipv4/ipmr.c @@ -1917,7 +1917,7 @@ void __init ip_mr_init(void) mrt_cachep = kmem_cache_create("ip_mrt_cache", sizeof(struct mfc_cache), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); init_timer(&ipmr_expire_timer); ipmr_expire_timer.function=ipmr_expire_process; register_netdevice_notifier(&ip_mr_notifier); diff --git a/trunk/net/ipv4/ipvs/ip_vs_conn.c b/trunk/net/ipv4/ipvs/ip_vs_conn.c index d612a6a5d957..3b446b1a6b9c 100644 --- a/trunk/net/ipv4/ipvs/ip_vs_conn.c +++ b/trunk/net/ipv4/ipvs/ip_vs_conn.c @@ -901,7 +901,7 @@ int ip_vs_conn_init(void) /* Allocate ip_vs_conn slab cache */ ip_vs_conn_cachep = kmem_cache_create("ip_vs_conn", sizeof(struct ip_vs_conn), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (!ip_vs_conn_cachep) { vfree(ip_vs_conn_tab); return -ENOMEM; diff --git a/trunk/net/ipv4/route.c b/trunk/net/ipv4/route.c index df42b7fb3268..88fa648d7ba3 100644 --- a/trunk/net/ipv4/route.c +++ b/trunk/net/ipv4/route.c @@ -2967,7 +2967,7 @@ int __init ip_rt_init(void) ipv4_dst_ops.kmem_cachep = kmem_cache_create("ip_dst_cache", sizeof(struct rtable), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); ipv4_dst_blackhole_ops.kmem_cachep = ipv4_dst_ops.kmem_cachep; diff --git a/trunk/net/ipv4/tcp.c b/trunk/net/ipv4/tcp.c index da4c0b6ab79a..987b94403be5 100644 --- a/trunk/net/ipv4/tcp.c +++ b/trunk/net/ipv4/tcp.c @@ -2430,7 +2430,7 @@ void __init tcp_init(void) tcp_hashinfo.bind_bucket_cachep = kmem_cache_create("tcp_bind_bucket", sizeof(struct inet_bind_bucket), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); /* Size and allocate the main established and bind bucket * hash tables. diff --git a/trunk/net/ipv6/ip6_fib.c b/trunk/net/ipv6/ip6_fib.c index 6a612a701eaa..662a7d9681fd 100644 --- a/trunk/net/ipv6/ip6_fib.c +++ b/trunk/net/ipv6/ip6_fib.c @@ -1474,7 +1474,7 @@ void __init fib6_init(void) fib6_node_kmem = kmem_cache_create("fib6_nodes", sizeof(struct fib6_node), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); fib6_tables_init(); diff --git a/trunk/net/ipv6/route.c b/trunk/net/ipv6/route.c index 919de682b331..fe8d9837f9f8 100644 --- a/trunk/net/ipv6/route.c +++ b/trunk/net/ipv6/route.c @@ -2555,7 +2555,7 @@ void __init ip6_route_init(void) #endif ip6_dst_ops.kmem_cachep = kmem_cache_create("ip6_dst_cache", sizeof(struct rt6_info), 0, - SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); ip6_dst_blackhole_ops.kmem_cachep = ip6_dst_ops.kmem_cachep; fib6_init(); diff --git a/trunk/net/ipv6/xfrm6_tunnel.c b/trunk/net/ipv6/xfrm6_tunnel.c index 30f3236c402a..6f87dd568ded 100644 --- a/trunk/net/ipv6/xfrm6_tunnel.c +++ b/trunk/net/ipv6/xfrm6_tunnel.c @@ -84,7 +84,7 @@ static int xfrm6_tunnel_spi_init(void) xfrm6_tunnel_spi_kmem = kmem_cache_create("xfrm6_tunnel_spi", sizeof(struct xfrm6_tunnel_spi), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!xfrm6_tunnel_spi_kmem) return -ENOMEM; diff --git a/trunk/net/netfilter/nf_conntrack_core.c b/trunk/net/netfilter/nf_conntrack_core.c index aa086c83af80..8cce814f6bee 100644 --- a/trunk/net/netfilter/nf_conntrack_core.c +++ b/trunk/net/netfilter/nf_conntrack_core.c @@ -1108,7 +1108,7 @@ int __init nf_conntrack_init(void) nf_conntrack_cachep = kmem_cache_create("nf_conntrack", sizeof(struct nf_conn), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!nf_conntrack_cachep) { printk(KERN_ERR "Unable to create nf_conn slab cache\n"); goto err_free_hash; diff --git a/trunk/net/netfilter/nf_conntrack_expect.c b/trunk/net/netfilter/nf_conntrack_expect.c index 1aa6229ca99f..2191fe008f60 100644 --- a/trunk/net/netfilter/nf_conntrack_expect.c +++ b/trunk/net/netfilter/nf_conntrack_expect.c @@ -540,7 +540,7 @@ int __init nf_conntrack_expect_init(void) nf_ct_expect_cachep = kmem_cache_create("nf_conntrack_expect", sizeof(struct nf_conntrack_expect), - 0, 0, NULL); + 0, 0, NULL, NULL); if (!nf_ct_expect_cachep) goto err2; diff --git a/trunk/net/netfilter/nf_conntrack_helper.c b/trunk/net/netfilter/nf_conntrack_helper.c index ca10df40784f..b1179dd3d8c3 100644 --- a/trunk/net/netfilter/nf_conntrack_helper.c +++ b/trunk/net/netfilter/nf_conntrack_helper.c @@ -194,7 +194,7 @@ static struct nf_ct_ext_type helper_extend __read_mostly = { .id = NF_CT_EXT_HELPER, }; -int nf_conntrack_helper_init(void) +int nf_conntrack_helper_init() { int err; @@ -216,7 +216,7 @@ int nf_conntrack_helper_init(void) return err; } -void nf_conntrack_helper_fini(void) +void nf_conntrack_helper_fini() { nf_ct_extend_unregister(&helper_extend); nf_ct_free_hashtable(nf_ct_helper_hash, nf_ct_helper_vmalloc, diff --git a/trunk/net/netfilter/xt_hashlimit.c b/trunk/net/netfilter/xt_hashlimit.c index bd45f9d3f7d0..d6b3d01975b6 100644 --- a/trunk/net/netfilter/xt_hashlimit.c +++ b/trunk/net/netfilter/xt_hashlimit.c @@ -738,7 +738,7 @@ static int __init xt_hashlimit_init(void) err = -ENOMEM; hashlimit_cachep = kmem_cache_create("xt_hashlimit", sizeof(struct dsthash_ent), 0, 0, - NULL); + NULL, NULL); if (!hashlimit_cachep) { printk(KERN_ERR "xt_hashlimit: unable to create slab cache\n"); goto err2; diff --git a/trunk/net/rxrpc/af_rxrpc.c b/trunk/net/rxrpc/af_rxrpc.c index 16a68df4e36b..46f6d572ad2d 100644 --- a/trunk/net/rxrpc/af_rxrpc.c +++ b/trunk/net/rxrpc/af_rxrpc.c @@ -792,7 +792,7 @@ static int __init af_rxrpc_init(void) ret = -ENOMEM; rxrpc_call_jar = kmem_cache_create( "rxrpc_call_jar", sizeof(struct rxrpc_call), 0, - SLAB_HWCACHE_ALIGN, NULL); + SLAB_HWCACHE_ALIGN, NULL, NULL); if (!rxrpc_call_jar) { printk(KERN_NOTICE "RxRPC: Failed to allocate call jar\n"); goto error_call_jar; diff --git a/trunk/net/sctp/protocol.c b/trunk/net/sctp/protocol.c index e98579b788b8..34bab36637ac 100644 --- a/trunk/net/sctp/protocol.c +++ b/trunk/net/sctp/protocol.c @@ -980,14 +980,14 @@ SCTP_STATIC __init int sctp_init(void) sctp_bucket_cachep = kmem_cache_create("sctp_bind_bucket", sizeof(struct sctp_bind_bucket), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!sctp_bucket_cachep) goto out; sctp_chunk_cachep = kmem_cache_create("sctp_chunk", sizeof(struct sctp_chunk), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!sctp_chunk_cachep) goto err_chunk_cachep; diff --git a/trunk/net/socket.c b/trunk/net/socket.c index ec077037f534..b71114250046 100644 --- a/trunk/net/socket.c +++ b/trunk/net/socket.c @@ -272,7 +272,8 @@ static int init_inodecache(void) (SLAB_HWCACHE_ALIGN | SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD), - init_once); + init_once, + NULL); if (sock_inode_cachep == NULL) return -ENOMEM; return 0; diff --git a/trunk/net/sunrpc/rpc_pipe.c b/trunk/net/sunrpc/rpc_pipe.c index 650af064ff8d..5b2b6fb244f2 100644 --- a/trunk/net/sunrpc/rpc_pipe.c +++ b/trunk/net/sunrpc/rpc_pipe.c @@ -867,7 +867,7 @@ int register_rpc_pipefs(void) sizeof(struct rpc_inode), 0, (SLAB_HWCACHE_ALIGN|SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD), - init_once); + init_once, NULL); if (!rpc_inode_cachep) return -ENOMEM; err = register_filesystem(&rpc_pipe_fs_type); diff --git a/trunk/net/sunrpc/sched.c b/trunk/net/sunrpc/sched.c index b5723c262a3e..2ac43c41c3a9 100644 --- a/trunk/net/sunrpc/sched.c +++ b/trunk/net/sunrpc/sched.c @@ -1031,13 +1031,13 @@ rpc_init_mempool(void) rpc_task_slabp = kmem_cache_create("rpc_tasks", sizeof(struct rpc_task), 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!rpc_task_slabp) goto err_nomem; rpc_buffer_slabp = kmem_cache_create("rpc_buffers", RPC_BUFFER_MAXSIZE, 0, SLAB_HWCACHE_ALIGN, - NULL); + NULL, NULL); if (!rpc_buffer_slabp) goto err_nomem; rpc_task_mempool = mempool_create_slab_pool(RPC_TASK_POOLSIZE, diff --git a/trunk/net/tipc/handler.c b/trunk/net/tipc/handler.c index 0c70010a7dfe..e1dcf663f8a6 100644 --- a/trunk/net/tipc/handler.c +++ b/trunk/net/tipc/handler.c @@ -97,7 +97,7 @@ int tipc_handler_start(void) { tipc_queue_item_cache = kmem_cache_create("tipc_queue_items", sizeof(struct queue_item), - 0, SLAB_HWCACHE_ALIGN, NULL); + 0, SLAB_HWCACHE_ALIGN, NULL, NULL); if (!tipc_queue_item_cache) return -ENOMEM; diff --git a/trunk/net/xfrm/xfrm_input.c b/trunk/net/xfrm/xfrm_input.c index 113f44429982..5c4695840c58 100644 --- a/trunk/net/xfrm/xfrm_input.c +++ b/trunk/net/xfrm/xfrm_input.c @@ -83,5 +83,5 @@ void __init xfrm_input_init(void) secpath_cachep = kmem_cache_create("secpath_cache", sizeof(struct sec_path), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); } diff --git a/trunk/net/xfrm/xfrm_policy.c b/trunk/net/xfrm/xfrm_policy.c index c3a4b0a18687..cfaf17c8851e 100644 --- a/trunk/net/xfrm/xfrm_policy.c +++ b/trunk/net/xfrm/xfrm_policy.c @@ -2378,7 +2378,7 @@ static void __init xfrm_policy_init(void) xfrm_dst_cache = kmem_cache_create("xfrm_dst_cache", sizeof(struct xfrm_dst), 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, - NULL); + NULL, NULL); hmask = 8 - 1; sz = (hmask+1) * sizeof(struct hlist_head); diff --git a/trunk/scripts/mod/modpost.c b/trunk/scripts/mod/modpost.c index 5ab7914d30ef..04579a517900 100644 --- a/trunk/scripts/mod/modpost.c +++ b/trunk/scripts/mod/modpost.c @@ -1076,7 +1076,6 @@ static int initexit_section_ref_ok(const char *name) ".plt", /* seen on ARCH=um build on x86_64. Harmless */ ".smp_locks", ".stab", - ".m68k_fixup", NULL }; /* Start of section names */ diff --git a/trunk/security/keys/key.c b/trunk/security/keys/key.c index 01bbc6d9d19b..700400d801dc 100644 --- a/trunk/security/keys/key.c +++ b/trunk/security/keys/key.c @@ -1001,7 +1001,7 @@ void __init key_init(void) { /* allocate a slab in which we can store keys */ key_jar = kmem_cache_create("key_jar", sizeof(struct key), - 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL); + 0, SLAB_HWCACHE_ALIGN|SLAB_PANIC, NULL, NULL); /* add the special key types */ list_add_tail(&key_type_keyring.link, &key_types_list); diff --git a/trunk/security/selinux/avc.c b/trunk/security/selinux/avc.c index ecd067384531..78c408fd2b02 100644 --- a/trunk/security/selinux/avc.c +++ b/trunk/security/selinux/avc.c @@ -239,7 +239,7 @@ void __init avc_init(void) atomic_set(&avc_cache.lru_hint, 0); avc_node_cachep = kmem_cache_create("avc_node", sizeof(struct avc_node), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); audit_log(current->audit_context, GFP_KERNEL, AUDIT_KERNEL, "AVC INITIALIZED\n"); } diff --git a/trunk/security/selinux/hooks.c b/trunk/security/selinux/hooks.c index 0fac6829c63a..26356e67108e 100644 --- a/trunk/security/selinux/hooks.c +++ b/trunk/security/selinux/hooks.c @@ -4913,7 +4913,7 @@ static __init int selinux_init(void) sel_inode_cache = kmem_cache_create("selinux_inode_security", sizeof(struct inode_security_struct), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); avc_init(); original_ops = secondary_ops = security_ops; diff --git a/trunk/security/selinux/ss/avtab.c b/trunk/security/selinux/ss/avtab.c index 85705eb289e0..3122908afdc1 100644 --- a/trunk/security/selinux/ss/avtab.c +++ b/trunk/security/selinux/ss/avtab.c @@ -445,7 +445,7 @@ void avtab_cache_init(void) { avtab_node_cachep = kmem_cache_create("avtab_node", sizeof(struct avtab_node), - 0, SLAB_PANIC, NULL); + 0, SLAB_PANIC, NULL, NULL); } void avtab_cache_destroy(void)