patch-2.1.29 linux/drivers/char/apm_bios.c
Next file: linux/drivers/char/istallion.c
Previous file: linux/drivers/char/README.stallion
Back to the patch index
Back to the overall index
- Lines: 31
- Date:
Fri Mar 7 12:51:45 1997
- Orig file:
v2.1.28/linux/drivers/char/apm_bios.c
- Orig date:
Wed Jan 29 03:32:58 1997
diff -u --recursive --new-file v2.1.28/linux/drivers/char/apm_bios.c linux/drivers/char/apm_bios.c
@@ -375,12 +375,6 @@
&apm_bios_fops
};
-#ifdef CONFIG_PROC_FS
-static struct proc_dir_entry apm_proc_entry = {
- 0, 3, "apm", S_IFREG | S_IRUGO, 1, 0, 0, 0, 0, apm_get_info
-};
-#endif
-
typedef struct callback_list_t {
int (* callback)(apm_event_t);
struct callback_list_t * next;
@@ -1072,6 +1066,7 @@
unsigned short error;
char * power_stat;
char * bat_stat;
+ static struct proc_dir_entry *ent;
if (apm_bios_info.version == 0) {
printk("APM BIOS not found.\n");
@@ -1196,7 +1191,8 @@
add_timer(&apm_timer);
#ifdef CONFIG_PROC_FS
- proc_register_dynamic(&proc_root, &apm_proc_entry);
+ ent = create_proc_entry("apm", 0, 0);
+ ent->get_info = apm_get_info;
#endif
misc_register(&apm_device);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov