Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
serio.h File Reference
#include <linux/types.h>
#include <linux/interrupt.h>
#include <linux/list.h>
#include <linux/spinlock.h>
#include <linux/mutex.h>
#include <linux/device.h>
#include <linux/mod_devicetable.h>
#include <uapi/linux/serio.h>

Go to the source code of this file.

Data Structures

struct  serio
struct  serio_driver


#define to_serio_port(d)   container_of(d, struct serio, dev)
#define to_serio_driver(d)   container_of(d, struct serio_driver, driver)
#define serio_register_port(serio)   __serio_register_port(serio, THIS_MODULE)
#define serio_register_driver(drv)   __serio_register_driver(drv, THIS_MODULE, KBUILD_MODNAME)
#define module_serio_driver(__serio_driver)


int serio_open (struct serio *serio, struct serio_driver *drv)
void serio_close (struct serio *serio)
void serio_rescan (struct serio *serio)
void serio_reconnect (struct serio *serio)
irqreturn_t serio_interrupt (struct serio *serio, unsigned char data, unsigned int flags)
void __serio_register_port (struct serio *serio, struct module *owner)
void serio_unregister_port (struct serio *serio)
void serio_unregister_child_port (struct serio *serio)
int __must_check __serio_register_driver (struct serio_driver *drv, struct module *owner, const char *mod_name)
void serio_unregister_driver (struct serio_driver *drv)

Macro Definition Documentation

#define module_serio_driver (   __serio_driver)

module_serio_driver() - Helper macro for registering a serio driver : serio_driver struct

Helper macro for serio drivers which do not do anything special in module init/exit. This eliminates a lot of boilerplate. Each module may only use this macro once, and calling it replaces module_init() and module_exit().

Definition at line 103 of file serio.h.

#define serio_register_driver (   drv)    __serio_register_driver(drv, THIS_MODULE, KBUILD_MODNAME)

Definition at line 89 of file serio.h.

#define serio_register_port (   serio)    __serio_register_port(serio, THIS_MODULE)

Definition at line 79 of file serio.h.

#define to_serio_driver (   d)    container_of(d, struct serio_driver, driver)

Definition at line 68 of file serio.h.

#define to_serio_port (   d)    container_of(d, struct serio, dev)

Definition at line 51 of file serio.h.

Function Documentation

int __must_check __serio_register_driver ( struct serio_driver drv,
struct module owner,
const char mod_name 

Definition at line 813 of file serio.c.

void __serio_register_port ( struct serio serio,
struct module owner 

Definition at line 695 of file serio.c.

void serio_close ( struct serio serio)

Definition at line 977 of file serio.c.

irqreturn_t serio_interrupt ( struct serio serio,
unsigned char  data,
unsigned int  flags 

Definition at line 986 of file serio.c.

int serio_open ( struct serio serio,
struct serio_driver drv 

Definition at line 964 of file serio.c.

void serio_reconnect ( struct serio serio)

Definition at line 685 of file serio.c.

void serio_rescan ( struct serio serio)

Definition at line 679 of file serio.c.

void serio_unregister_child_port ( struct serio serio)

Definition at line 717 of file serio.c.

void serio_unregister_driver ( struct serio_driver drv)

Definition at line 852 of file serio.c.

void serio_unregister_port ( struct serio serio)

Definition at line 705 of file serio.c.