From f691a3e1c51228cb60e64ca40e4fde24a6e1eee3 Mon Sep 17 00:00:00 2001 From: Philippe Langlais Date: Fri, 14 Oct 2011 11:12:33 +0200 Subject: u5500:Docbook:Added the tmpl files for drivers Added the tmpl files for keypad and touchpad drivers with repect to kernel doc compliance. ST-Ericsson Linux next: - ST-Ericsson ID: AP 277198 ST-Ericsson FOSS-OUT ID: Trivial Change-Id: Ie704c10ff44f2b5b7f3806252cbcdd3d0f91f849 Signed-off-by: Naveen Kumar Gaddipati Reviewed-on: http://gerrit.lud.stericsson.com/gerrit/23735 Reviewed-by: QATEST Reviewed-by: Srinidhi KASAGAR Conflicts: Documentation/DocBook/Makefile --- Documentation/DocBook/db5500_keypad.tmpl | 91 +++++++++++++++++++ Documentation/DocBook/synaptics_rmi4_touchp.tmpl | 106 +++++++++++++++++++++++ drivers/input/keyboard/db5500_keypad.c | 85 +++++++++++++++++- drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c | 4 +- 4 files changed, 281 insertions(+), 5 deletions(-) create mode 100644 Documentation/DocBook/db5500_keypad.tmpl create mode 100644 Documentation/DocBook/synaptics_rmi4_touchp.tmpl diff --git a/Documentation/DocBook/db5500_keypad.tmpl b/Documentation/DocBook/db5500_keypad.tmpl new file mode 100644 index 00000000000..a25fc990516 --- /dev/null +++ b/Documentation/DocBook/db5500_keypad.tmpl @@ -0,0 +1,91 @@ + + + + + + DB5500 Keypad + + + + NaveenKumar + Gaddipati + +
+ naveen.gaddipati@stericsson.com +
+
+
+
+ + + 2010 + ST-Ericsson + + + + + Linux standard functions + + + + + + License terms: GNU General Public License (GPL) version 2. + + + +
+ + + + + Introduction + + This documentation describes the API provided by the keypad + driver for internal keypad. + + + + + Known Bugs And Assumptions + + + + None + + + None. + + + + + + + + + Public Functions Provided + + This db5500-keypad driver doesn't export any functions. + + + + + Structures + + This chapter contains the autogenerated documentation of the + structures which are used in the keypad driver. + +!Iarch/arm/mach-ux500/include/mach/db5500-keypad.h + + + + Internal Functions Provided + + This chapter contains the autogenerated documentation of the + internal functions. + +!Idrivers/input/keyboard/db5500_keypad.c + + +
diff --git a/Documentation/DocBook/synaptics_rmi4_touchp.tmpl b/Documentation/DocBook/synaptics_rmi4_touchp.tmpl new file mode 100644 index 00000000000..bc104eb4840 --- /dev/null +++ b/Documentation/DocBook/synaptics_rmi4_touchp.tmpl @@ -0,0 +1,106 @@ + + + + + + Synaptics RMI4 Touch screen + + + + Naveen Kumar + Gaddipati + +
+ naveen.gaddipati@stericsson.com +
+
+
+
+ + + 2010 + ST-Ericsson + + + + + Linux standard functions + + + + + + + + This documentation is free software; you can redistribute + it and/or modify it under the terms of the GNU General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later + version. + + + + This program is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied + warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + See the GNU General Public License for more details. + + + + You should have received a copy of the GNU General Public + License along with this program; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, + MA 02111-1307 USA + + + + For more details see the file COPYING in the source + distribution of Linux. + + +
+ + + + + Introduction + + This documentation describes the functions provided by the + driver of touch panel for Synaptics RMI4 controller + + + + + Known Bugs And Assumptions + + + + None + + + None. + + + + + + + + + Public Functions Provided + + Not Applicable. + + + + + Internal Functions Provided + + This chapter contains the autogenerated documentation of the internal + functions of the Tocuh panel driver. + +!Idrivers/staging/ste_rmi4/synaptics_i2c_rmi4.c + + +
diff --git a/drivers/input/keyboard/db5500_keypad.c b/drivers/input/keyboard/db5500_keypad.c index 8a127eaa94c..a53d72e8ab4 100644 --- a/drivers/input/keyboard/db5500_keypad.c +++ b/drivers/input/keyboard/db5500_keypad.c @@ -61,11 +61,19 @@ struct db5500_keypad { u8 previous_set[KEYPAD_MAX_ROWS]; }; -/* +/** + * db5500_keypad_report() - reports the keypad event + * @keypad: pointer to device structure + * @row: row value of keypad + * @curr: current event + * @previous: previous event + * + * This function uses to reports the event of the keypad + * and returns NONE. + * * By default all column reads are 1111 1111b. Any press will pull the column * down, leading to a 0 in any of these locations. We invert these values so - * that a 1 means means "column pressed". - * + * that a 1 means means "column pressed". * * If curr changes from the previous from 0 to 1, we report it as a key press. * If curr changes from the previous from 1 to 0, we report it as a key * release. @@ -89,6 +97,14 @@ static void db5500_keypad_report(struct db5500_keypad *keypad, int row, } } +/** + * db5500_keypad_irq() - irq handler for keypad + * @irq: irq value for keypad + * @dev_id: pointer for device id + * + * This function uses to handle the interrupt of the keypad + * and returns irqreturn. + */ static irqreturn_t db5500_keypad_irq(int irq, void *dev_id) { struct db5500_keypad *keypad = dev_id; @@ -161,6 +177,15 @@ again: return IRQ_HANDLED; } +/** + * db5500_keypad_writel() - write into keypad registers + * @keypad: pointer to device structure + * @val: value to write into register + * @reg: register offset + * + * This function uses to write into the keypad registers + * and returns NONE. + */ static void db5500_keypad_writel(struct db5500_keypad *keypad, u32 val, u32 reg) { int timeout = 4; @@ -192,6 +217,13 @@ static void db5500_keypad_writel(struct db5500_keypad *keypad, u32 val, u32 reg) writel(val, keypad->base + reg); } +/** + * db5500_keypad_chip_init() - initialize the keypad chip + * @keypad: pointer to device structure + * + * This function uses to initializes the keypad controller + * and returns integer. + */ static int db5500_keypad_chip_init(struct db5500_keypad *keypad) { int debounce = keypad->board->debounce_ms; @@ -222,6 +254,13 @@ static int db5500_keypad_chip_init(struct db5500_keypad *keypad) return 0; } +/** + * db5500_keypad_close() - stops the keypad driver + * @keypad: pointer to device structure + * + * This function uses to stop the keypad + * driver and returns integer. + */ static void db5500_keypad_close(struct db5500_keypad *keypad) { db5500_keypad_writel(keypad, 0, KEYPAD_CTR); @@ -230,6 +269,13 @@ static void db5500_keypad_close(struct db5500_keypad *keypad) clk_disable(keypad->clk); } +/** + * db5500_keypad_probe() - Initialze the the keypad driver + * @pdev: pointer to platform device structure + * + * This function will allocate and initialize the instance + * data and request the irq and register to input subsystem driver. + */ static int __devinit db5500_keypad_probe(struct platform_device *pdev) { const struct db5500_keypad_platform_data *plat; @@ -362,6 +408,13 @@ out_ret: return ret; } +/** + * db5500_keypad_remove() - Removes the keypad driver + * @pdev: pointer to platform device structure + * + * This function uses to remove the keypad + * driver and returns integer. + */ static int __devexit db5500_keypad_remove(struct platform_device *pdev) { struct db5500_keypad *keypad = platform_get_drvdata(pdev); @@ -381,6 +434,13 @@ static int __devexit db5500_keypad_remove(struct platform_device *pdev) } #ifdef CONFIG_PM +/** + * db5500_keypad_suspend() - suspend the keypad controller + * @dev: pointer to device structure + * + * This function is used to suspend the + * keypad controller and returns integer + */ static int db5500_keypad_suspend(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); @@ -397,6 +457,13 @@ static int db5500_keypad_suspend(struct device *dev) return 0; } +/** + * db5500_keypad_resume() - resume the keypad controller + * @dev: pointer to device structure + * + * This function is used to resume the keypad + * controller and returns integer. + */ static int db5500_keypad_resume(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); @@ -431,12 +498,24 @@ static struct platform_driver db5500_keypad_driver = { .remove = __devexit_p(db5500_keypad_remove), }; +/** + * db5500_keypad_init() - Initialize the keypad driver + * + * This function uses to initializes the db5500 + * keypad driver and returns integer. + */ static int __init db5500_keypad_init(void) { return platform_driver_register(&db5500_keypad_driver); } module_init(db5500_keypad_init); +/** + * db5500_keypad_exit() - De-initialize the keypad driver + * + * This function uses to de-initialize the db5500 + * keypad driver and returns none. + */ static void __exit db5500_keypad_exit(void) { platform_driver_unregister(&db5500_keypad_driver); diff --git a/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c b/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c index 2659ea1d70d..e8afb75590a 100644 --- a/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c +++ b/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c @@ -1053,8 +1053,8 @@ static void synaptics_rmi4_resume_handler(struct work_struct *work) /** * synaptics_rmi4_probe() - Initialze the i2c-client touchscreen driver - * @i2c: i2c client structure pointer - * @id:i2c device id pointer + * @client: i2c client structure pointer + * @dev_id:i2c device id pointer * * This function will allocate and initialize the instance * data and request the irq and set the instance data as the clients -- cgit v1.2.3