From 5770ced918468d627595003a9a3bb0421cb0cfbc Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Fri, 14 May 2004 05:45:07 -0700 Subject: [PATCH] Module ref counting for vt console drivers From: Herbert Xu The following patch adds basic module reference counting to vt console drivers. Currently modules like fbcon are not counted at all. --- include/linux/console.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'include/linux') diff --git a/include/linux/console.h b/include/linux/console.h index 2092454b2d8f..c8a8fe4f27b3 100644 --- a/include/linux/console.h +++ b/include/linux/console.h @@ -19,6 +19,7 @@ struct vc_data; struct console_font_op; +struct module; /* * this is what the terminal answers to a ESC-Z or csi0c query. @@ -27,6 +28,7 @@ struct console_font_op; #define VT102ID "\033[?6c" struct consw { + struct module *owner; const char *(*con_startup)(void); void (*con_init)(struct vc_data *, int); void (*con_deinit)(struct vc_data *); @@ -58,7 +60,7 @@ extern const struct consw vga_con; /* VGA text console */ extern const struct consw newport_con; /* SGI Newport console */ extern const struct consw prom_con; /* SPARC PROM console */ -void take_over_console(const struct consw *sw, int first, int last, int deflt); +int take_over_console(const struct consw *sw, int first, int last, int deflt); void give_up_console(const struct consw *sw); /* scroll */ -- cgit v1.2.3