mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-26 16:41:25 +00:00
auxdisplay: constify charlcd_ops.
charlcd_ops are not supposed to change at runtime. All functions working with charlcd_ops provided by <misc/charlcd.h> work with const charlcd_ops. So mark the non-const structs as const. File size before: text data bss dec hex filename 12750 560 362 13672 3568 drivers/auxdisplay/panel.o File size After adding 'const': text data bss dec hex filename 12942 368 362 13672 3568 drivers/auxdisplay/panel.o Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
caa97be1a2
commit
7b948f1377
1 changed files with 3 additions and 3 deletions
|
@ -877,21 +877,21 @@ static void lcd_clear_fast_tilcd(struct charlcd *charlcd)
|
||||||
spin_unlock_irq(&pprt_lock);
|
spin_unlock_irq(&pprt_lock);
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct charlcd_ops charlcd_serial_ops = {
|
static const struct charlcd_ops charlcd_serial_ops = {
|
||||||
.write_cmd = lcd_write_cmd_s,
|
.write_cmd = lcd_write_cmd_s,
|
||||||
.write_data = lcd_write_data_s,
|
.write_data = lcd_write_data_s,
|
||||||
.clear_fast = lcd_clear_fast_s,
|
.clear_fast = lcd_clear_fast_s,
|
||||||
.backlight = lcd_backlight,
|
.backlight = lcd_backlight,
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct charlcd_ops charlcd_parallel_ops = {
|
static const struct charlcd_ops charlcd_parallel_ops = {
|
||||||
.write_cmd = lcd_write_cmd_p8,
|
.write_cmd = lcd_write_cmd_p8,
|
||||||
.write_data = lcd_write_data_p8,
|
.write_data = lcd_write_data_p8,
|
||||||
.clear_fast = lcd_clear_fast_p8,
|
.clear_fast = lcd_clear_fast_p8,
|
||||||
.backlight = lcd_backlight,
|
.backlight = lcd_backlight,
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct charlcd_ops charlcd_tilcd_ops = {
|
static const struct charlcd_ops charlcd_tilcd_ops = {
|
||||||
.write_cmd = lcd_write_cmd_tilcd,
|
.write_cmd = lcd_write_cmd_tilcd,
|
||||||
.write_data = lcd_write_data_tilcd,
|
.write_data = lcd_write_data_tilcd,
|
||||||
.clear_fast = lcd_clear_fast_tilcd,
|
.clear_fast = lcd_clear_fast_tilcd,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue