auxdisplay: provide hd44780_common_gotoxy

Provide a hd44780_common_gotoxy function and a pointer in the ops for
charlcd to use to move the cursor.

Reviewed-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Lars Poeschel <poeschel@lemonage.de>
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
This commit is contained in:
Lars Poeschel
2020-11-03 10:58:12 +01:00
committed by Miguel Ojeda
parent b26deabb1d
commit d3a2fb810f
6 changed files with 43 additions and 28 deletions

View File

@@ -875,16 +875,19 @@ static void lcd_clear_fast_tilcd(struct charlcd *charlcd)
static const struct charlcd_ops charlcd_serial_ops = {
.clear_fast = lcd_clear_fast_s,
.backlight = lcd_backlight,
.gotoxy = hd44780_common_gotoxy,
};
static const struct charlcd_ops charlcd_parallel_ops = {
.clear_fast = lcd_clear_fast_p8,
.backlight = lcd_backlight,
.gotoxy = hd44780_common_gotoxy,
};
static const struct charlcd_ops charlcd_tilcd_ops = {
.clear_fast = lcd_clear_fast_tilcd,
.backlight = lcd_backlight,
.gotoxy = hd44780_common_gotoxy,
};
/* initialize the LCD driver */