X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=drivers%2Facpi%2Fevent.c;h=0c24bd4d65629bb4647fee1958ceeac2dda424ad;hb=54364b752ef0c91fe92684df000cc4593d1e8963;hp=5479dc0eeeecdfe6401d0d81fd435af69ac67e42;hpb=81e242d0efafb319938d511b115088a5c4523c91;p=linux-2.6 diff --git a/drivers/acpi/event.c b/drivers/acpi/event.c index 5479dc0eee..0c24bd4d65 100644 --- a/drivers/acpi/event.c +++ b/drivers/acpi/event.c @@ -102,6 +102,7 @@ static unsigned int acpi_system_poll_event(struct file *file, poll_table * wait) } static const struct file_operations acpi_system_event_ops = { + .owner = THIS_MODULE, .open = acpi_system_open_event, .read = acpi_system_read_event, .release = acpi_system_close_event, @@ -110,7 +111,7 @@ static const struct file_operations acpi_system_event_ops = { #endif /* CONFIG_ACPI_PROC_EVENT */ /* ACPI notifier chain */ -BLOCKING_NOTIFIER_HEAD(acpi_chain_head); +static BLOCKING_NOTIFIER_HEAD(acpi_chain_head); int acpi_notifier_call_chain(struct acpi_device *dev, u32 type, u32 data) { @@ -294,10 +295,9 @@ static int __init acpi_event_init(void) #ifdef CONFIG_ACPI_PROC_EVENT /* 'event' [R] */ - entry = create_proc_entry("event", S_IRUSR, acpi_root_dir); - if (entry) - entry->proc_fops = &acpi_system_event_ops; - else + entry = proc_create("event", S_IRUSR, acpi_root_dir, + &acpi_system_event_ops); + if (!entry) return -ENODEV; #endif