leds-clevo-mail: export i8042_command()
Subsystems (2)
PATCH 1/3 leds-clevo-mail: export i8042_command()
From: Márton Németh <[email protected]>
Export the i8042_command() function which manages the mutual exclusion with the help of the i8042_lock spinlock. This lets possible to use the i8042 hardware safely from other part of the kernel, too.
---
drivers/input/serio/i8042.c +2 -1
@@ -208,7 +208,7 @@ static int __i8042_command(unsigned charreturn 0 ; } -static int i8042_command (unsigned char *param,int command) +int i8042_command (unsigned char *param,int command) {unsigned long flags;int retval;
@@ -219,6 +219,7 @@ static int i8042_command(unsigned char *return retval; } +EXPORT_SYMBOL (i8042_command);/* * i8042_kbd_write() sends a byte out through the keyboard interface.
include/linux/i8042.h +10 -0
@@ -0,0 +1,10 @@ + +/* There is already a header file linux/drivers/input/serio/i8042.h, so +* using the _LINUX prefix here as this is the <linux/i8042.h> file. +*/ +#ifndef _LINUX_I8042_H +#define _LINUX_I8402_H + +int i8042_command (unsigned char *param,int command); + +#endif
Dmitry Torokhov
maintainerQuoted 7 lines · Németh Márton
From: Márton Németh <[email protected]>
Export the
i8042_command()function which manages the mutual exclusion with the help of thei8042_lockspinlock. This lets possible to use the i8042 hardware safely from other part of the kernel, too.Signed-off-by Márton Németh <[email protected]>
Please #include <linux/i8042.h> into i8042.c. Doing so saves from nasty surprises later.
Signature · 1 line
Dmitry
From: Márton Németh <[email protected]>
Export the i8042_command() function which manages the mutual exclusion with the help of the i8042_lock spinlock. This lets possible to use the i8042 hardware safely from other part of the kernel, too.
---
drivers/input/serio/i8042.c +3 -1
@@ -20,6 +20,7 @@#include <linux/err.h> #include <linux/rcupdate.h> #include <linux/platform_device.h> +#include <linux/i8042.h> #include <asm/io.h>
@@ -208,7 +209,7 @@ static int __i8042_command(unsigned charreturn 0 ; } -static int i8042_command (unsigned char *param,int command) +int i8042_command (unsigned char *param,int command) {unsigned long flags;int retval;
@@ -219,6 +220,7 @@ static int i8042_command(unsigned char *return retval; } +EXPORT_SYMBOL (i8042_command);/* * i8042_kbd_write() sends a byte out through the keyboard interface.
include/linux/i8042.h +10 -0
@@ -0,0 +1,10 @@ + +/* There is already a header file linux/drivers/input/serio/i8042.h, so +* using the _LINUX prefix here as this is the <linux/i8042.h> file. +*/ +#ifndef _LINUX_I8042_H +#define _LINUX_I8402_H + +int i8042_command (unsigned char *param,int command); + +#endif