Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 018882aa authored by Laurent Pinchart's avatar Laurent Pinchart
Browse files

fbdev: sh_mobile_lcdc: Remove board configuration board_data field



The field is unused, remove it. Update board code accordingly.

Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
parent aa7b5b0b
Loading
Loading
Loading
Loading
+2 −12
Original line number Diff line number Diff line
@@ -229,16 +229,6 @@ static void lcd_backlight_reset(void)
	gpio_set_value(GPIO_PORT235, 1);
}

static void lcd_on(void *board_data, struct fb_info *info)
{
	lcd_backlight_on();
}

static void lcd_off(void *board_data)
{
	lcd_backlight_reset();
}

/* LCDC0 */
static const struct fb_videomode lcdc0_modes[] = {
	{
@@ -268,8 +258,8 @@ static struct sh_mobile_lcdc_info lcdc0_info = {
		.lcd_cfg = lcdc0_modes,
		.num_cfg = ARRAY_SIZE(lcdc0_modes),
		.board_cfg = {
			.display_on = lcd_on,
			.display_off = lcd_off,
			.display_on = lcd_backlight_on,
			.display_off = lcd_backlight_reset,
		},
	}
};
+2 −2
Original line number Diff line number Diff line
@@ -351,14 +351,14 @@ static struct fb_videomode mackerel_lcdc_modes[] = {
	},
};

static int mackerel_set_brightness(void *board_data, int brightness)
static int mackerel_set_brightness(int brightness)
{
	gpio_set_value(GPIO_PORT31, brightness);

	return 0;
}

static int mackerel_get_brightness(void *board_data)
static int mackerel_get_brightness(void)
{
	return gpio_get_value(GPIO_PORT31);
}
+4 −4
Original line number Diff line number Diff line
@@ -157,7 +157,7 @@ static struct platform_device nand_flash_device = {
#define PORT_DRVCRA	0xA405018A
#define PORT_DRVCRB	0xA405018C

static int ap320_wvga_set_brightness(void *board_data, int brightness)
static int ap320_wvga_set_brightness(int brightness)
{
	if (brightness) {
		gpio_set_value(GPIO_PTS3, 0);
@@ -170,12 +170,12 @@ static int ap320_wvga_set_brightness(void *board_data, int brightness)
	return 0;
}

static int ap320_wvga_get_brightness(void *board_data)
static int ap320_wvga_get_brightness(void)
{
	return gpio_get_value(GPIO_PTS3);
}

static void ap320_wvga_power_on(void *board_data, struct fb_info *info)
static void ap320_wvga_power_on(void)
{
	msleep(100);

@@ -183,7 +183,7 @@ static void ap320_wvga_power_on(void *board_data, struct fb_info *info)
	__raw_writew(FPGA_LCDREG_VAL, FPGA_LCDREG);
}

static void ap320_wvga_power_off(void *board_data)
static void ap320_wvga_power_off(void)
{
	/* ASD AP-320/325 LCD OFF */
	__raw_writew(0, FPGA_LCDREG);
+2 −2
Original line number Diff line number Diff line
@@ -310,14 +310,14 @@ static const struct fb_videomode ecovec_dvi_modes[] = {
	},
};

static int ecovec24_set_brightness(void *board_data, int brightness)
static int ecovec24_set_brightness(int brightness)
{
	gpio_set_value(GPIO_PTR1, brightness);

	return 0;
}

static int ecovec24_get_brightness(void *board_data)
static int ecovec24_get_brightness(void)
{
	return gpio_get_value(GPIO_PTR1);
}
+4 −6
Original line number Diff line number Diff line
@@ -251,8 +251,7 @@ static void display_on(void *sohandle,
	write_memory_start(sohandle, so);
}

int kfr2r09_lcd_setup(void *board_data, void *sohandle,
		      struct sh_mobile_lcdc_sys_bus_ops *so)
int kfr2r09_lcd_setup(void *sohandle, struct sh_mobile_lcdc_sys_bus_ops *so)
{
	/* power on */
	gpio_set_value(GPIO_PTF4, 0);  /* PROTECT/ -> L */
@@ -273,8 +272,7 @@ int kfr2r09_lcd_setup(void *board_data, void *sohandle,
	return 0;
}

void kfr2r09_lcd_start(void *board_data, void *sohandle,
		       struct sh_mobile_lcdc_sys_bus_ops *so)
void kfr2r09_lcd_start(void *sohandle, struct sh_mobile_lcdc_sys_bus_ops *so)
{
	write_memory_start(sohandle, so);
}
@@ -327,12 +325,12 @@ static int kfr2r09_lcd_backlight(int on)
	return 0;
}

void kfr2r09_lcd_on(void *board_data, struct fb_info *info)
void kfr2r09_lcd_on(void)
{
	kfr2r09_lcd_backlight(1);
}

void kfr2r09_lcd_off(void *board_data)
void kfr2r09_lcd_off(void)
{
	kfr2r09_lcd_backlight(0);
}
Loading