summaryrefslogtreecommitdiff
path: root/drivers/auxdisplay/charlcd.h
diff options
context:
space:
mode:
authorLars Poeschel <poeschel@lemonage.de>2020-11-03 10:58:13 +0100
committerMiguel Ojeda <ojeda@kernel.org>2020-11-04 11:04:03 +0100
commit88645a86e3420cddfe5bb9cd8d7c15aff8f54b46 (patch)
tree685137731ca062ddbfa71413bd8db9d6c750e3a0 /drivers/auxdisplay/charlcd.h
parentd3a2fb810f273b7a2c393d4de28ae91a3f76985d (diff)
auxdisplay: add home to charlcd_ops
This adds a home function to the charlcd_ops struct and offer an implementation for hd44780_common. This implementation is used by our two hd44780 drivers. This is to make charlcd device independent. Reviewed-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Lars Poeschel <poeschel@lemonage.de> Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
Diffstat (limited to 'drivers/auxdisplay/charlcd.h')
-rw-r--r--drivers/auxdisplay/charlcd.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/auxdisplay/charlcd.h b/drivers/auxdisplay/charlcd.h
index f36cc80ce385..236fd0e9e8ab 100644
--- a/drivers/auxdisplay/charlcd.h
+++ b/drivers/auxdisplay/charlcd.h
@@ -41,12 +41,15 @@ struct charlcd {
* wrap to the next line at the end of a line.
* @gotoxy: Set cursor to x, y. The x and y values to set the cursor to are
* previously set in addr.x and addr.y by charlcd.
+ * @home: Set cursor to 0, 0. The values in addr.x and addr.y are set to 0, 0 by
+ * charlcd prior to calling this function.
*/
struct charlcd_ops {
void (*clear_fast)(struct charlcd *lcd);
void (*backlight)(struct charlcd *lcd, enum charlcd_onoff on);
int (*print)(struct charlcd *lcd, int c);
int (*gotoxy)(struct charlcd *lcd);
+ int (*home)(struct charlcd *lcd);
};
struct charlcd *charlcd_alloc(void);