X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=arch%2Fppc%2Fplatforms%2Fkatana.c;h=720f8b3e2fbc508b9aa42cc321c32a9b9397d504;hb=refs%2Fheads%2Fvserver;hp=6e58e30ceed101b1aeace5055a19d4a00583b308;hpb=76828883507a47dae78837ab5dec5a5b4513c667;p=linux-2.6.git diff --git a/arch/ppc/platforms/katana.c b/arch/ppc/platforms/katana.c index 6e58e30ce..720f8b3e2 100644 --- a/arch/ppc/platforms/katana.c +++ b/arch/ppc/platforms/katana.c @@ -1,6 +1,4 @@ /* - * arch/ppc/platforms/katana.c - * * Board setup routines for the Artesyn Katana cPCI boards. * * Author: Tim Montgomery @@ -18,7 +16,6 @@ * Supports the Artesyn 750i, 752i, and 3750. The 752i is virtually identical * to the 750i except that it has an mv64460 bridge. */ -#include #include #include #include @@ -598,7 +595,7 @@ katana_fixup_mv64xxx_pdata(struct platform_device *pdev) } #endif -static int __init +static int katana_platform_notify(struct device *dev) { static struct { @@ -664,12 +661,11 @@ katana_setup_mtd(void) ptbl_entries = (size >= (64*MB)) ? 6 : 4; - if ((ptbl = kmalloc(ptbl_entries * sizeof(struct mtd_partition), + if ((ptbl = kcalloc(ptbl_entries, sizeof(struct mtd_partition), GFP_KERNEL)) == NULL) { printk(KERN_WARNING "Can't alloc MTD partition table\n"); return -ENOMEM; } - memset(ptbl, 0, ptbl_entries * sizeof(struct mtd_partition)); ptbl[0].name = "Monitor"; ptbl[0].size = KATANA_MTD_MONITOR_SIZE;