X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=drivers%2Fparisc%2Flasi.c;fp=drivers%2Fparisc%2Flasi.c;h=cb3d281761293f82eb5e7fbeec1e26d28d7bc473;hb=43bc926fffd92024b46cafaf7350d669ba9ca884;hp=731855053392995fa6ad4530314ed588b9249056;hpb=cee37fe97739d85991964371c1f3a745c00dd236;p=linux-2.6.git diff --git a/drivers/parisc/lasi.c b/drivers/parisc/lasi.c index 731855053..cb3d28176 100644 --- a/drivers/parisc/lasi.c +++ b/drivers/parisc/lasi.c @@ -20,7 +20,6 @@ #include #include #include -#include #include #include @@ -151,7 +150,7 @@ void __init lasi_led_init(unsigned long lasi_hpa) * */ -static unsigned long lasi_power_off_hpa; +static unsigned long lasi_power_off_hpa __read_mostly; static void lasi_power_off(void) { @@ -167,16 +166,17 @@ static void lasi_power_off(void) int __init lasi_init_chip(struct parisc_device *dev) { + extern void (*chassis_power_off)(void); struct gsc_asic *lasi; struct gsc_irq gsc_irq; int ret; - lasi = kmalloc(sizeof(*lasi), GFP_KERNEL); + lasi = kzalloc(sizeof(*lasi), GFP_KERNEL); if (!lasi) return -ENOMEM; lasi->name = "Lasi"; - lasi->hpa = dev->hpa; + lasi->hpa = dev->hpa.start; /* Check the 4-bit (yes, only 4) version register */ lasi->version = gsc_readl(lasi->hpa + LASI_VER) & 0xf; @@ -223,7 +223,7 @@ lasi_init_chip(struct parisc_device *dev) * ensure that only the first LASI (the one controlling the power off) * should set the HPA here */ lasi_power_off_hpa = lasi->hpa; - pm_power_off = lasi_power_off; + chassis_power_off = lasi_power_off; return ret; } @@ -234,7 +234,7 @@ static struct parisc_device_id lasi_tbl[] = { }; struct parisc_driver lasi_driver = { - .name = "Lasi", + .name = "lasi", .id_table = lasi_tbl, .probe = lasi_init_chip, };