IPMUX1IPMUX2IPMUX3: function_description(opl_minte.c)

RTL96xx (RTL9607,...)

function_description(opl_minte.c)
[minte module]


local function declaration

ssize_t opl_minte_read (struct file *filp, char *buffer, size_t length, loff_t *offset)
 description: copy the opl_chip_irq_pending(indicate which interrupt occured) to user App, which will handle its interrupt.if the no irq pending occured,the process will sleep until the isr wake up it.
ssize_t opl_minte_write (struct file *filp, const char *buffer, size_t length, loff_t *offset)
 description: because the enable irq or disable irq will be in atomic mode,so it should be operated in kernel mode is correct.

函数

int __init opl_minte_init (void)
 description: The driver module entry.to register the chrdev and request irq.
void __exit opl_minte_exit (void)
 description: it is called when the module removed.
 module_init (opl_minte_init)
 module_exit (opl_minte_exit)
 MODULE_LICENSE ("GPL2")
 MODULE_AUTHOR ("stephanxu <[email protected]>")
 MODULE_DESCRIPTION ("control interface for opulan ipmux-e switch chip")

函数文档

MODULE_AUTHOR "stephanxu <[email protected]>"   ) 
 

MODULE_DESCRIPTION "control interface for opulan ipmux-e switch chip"   ) 
 

module_exit opl_minte_exit   ) 
 

module_init opl_minte_init   ) 
 

MODULE_LICENSE "GPL2"   ) 
 

void __exit opl_minte_exit void   )  [static]
 

description: it is called when the module removed.

do the reverse of opl_minte_init().

参数:
void 
返回:
NULL
参见:
Deprecated:

在文件opl_minte.c219行定义。

参考 OPL_MINTE_DEVICEopl_minte_hw0_irqexitOPL_MINTE_MAJOR.

参考自 main().

int __init opl_minte_init void   )  [static]
 

description: The driver module entry.to register the chrdev and request irq.

and some essential initialization.

参数:
void 
返回值:
0 success
!0 failure.the module cant be inserted into os.
参见:
insmod rmmod
Deprecated:

在文件opl_minte.c189行定义。

参考 g_opl_chip_waitqOPL_MINTE_DEVICEopl_minte_fopsopl_minte_hw0_irqinitOPL_MINTE_MAJOR.

参考自 main().

ssize_t opl_minte_read struct file *  filp,
char *  buffer,
size_t  length,
loff_t *  offset
[static]
 

description: copy the opl_chip_irq_pending(indicate which interrupt occured) to user App, which will handle its interrupt.if the no irq pending occured,the process will sleep until the isr wake up it.

参数:
struct file *filp
char *buffer
size_t length
loff_t offset
返回:
the length of bytes process read.
参见:
opl_minte_interrupt_handler
Deprecated:

在文件opl_minte.c109行定义。

参考 clear_irq_pending()g_opl_chip_irq_eventg_opl_chip_waitqget_irq_pending()opl_minte_is_openu32.

ssize_t opl_minte_write struct file *  filp,
const char *  buffer,
size_t  length,
loff_t *  offset
[static]
 

description: because the enable irq or disable irq will be in atomic mode,so it should be operated in kernel mode is correct.

the value in user *buffer it is the enable or disable. 1. enable 0. disable if the value is enable, to enble the ipmux interrupt, call the function in malta_int.c

参数:
@param const char *buffer: contain the value(0-disable or 1-enable).
 
返回值:
0 is success
!0 failure. the device is not open or copy *buf from user to kernel fails.
参见:
Deprecated:

在文件opl_minte.c146行定义。

参考 ipmux_irq_disable()ipmux_irq_enable()OPL_IPMUX_IRQopl_minte_is_open.


Generated at Mon Jul 30 16:43:48 2007 for IPMUX1IPMUX2IPMUX3 by  doxygen 1.3.9.1