18 #include <linux/module.h>
19 #include <linux/kernel.h>
23 #include <linux/sched.h>
24 #include <linux/slab.h>
28 #define LCD_CONTROL_BLOCK_BASE 0x110000
29 #define CMN (LCD_CONTROL_BLOCK_BASE|0x10)
30 #define INTFLG (LCD_CONTROL_BLOCK_BASE|0x18)
31 #define HCYCLE (LCD_CONTROL_BLOCK_BASE|0x34)
32 #define HDE_START (LCD_CONTROL_BLOCK_BASE|0x3C)
33 #define VPOS (LCD_CONTROL_BLOCK_BASE|0xC0)
34 #define MPLFBUF (LCD_CONTROL_BLOCK_BASE|0x20)
35 #define WAKEUP (LCD_CONTROL_BLOCK_BASE|0x54)
36 #define WSYN_DLY (LCD_CONTROL_BLOCK_BASE|0x58)
37 #define REGENB (LCD_CONTROL_BLOCK_BASE|0x5C)
39 #define BASE5 0x150000
40 #define BASE6 0x160000
41 #define BASE7 0x170000
43 #define GPIOIEV (BASE5 + 0x10)
44 #define GPIOIE (BASE5 + 0x14)
45 #define GPIORIS (BASE5 + 0x18)
46 #define GPIOMIS (BASE5 + 0x1C)
47 #define GPIOIC (BASE5 + 0x20)
49 #define INTMASK (BASE6 + 0x0C)
50 #define INTMASK_VWAKEOUT (1U << 0)
51 #define INTMASK_VWAKEOUT_ACTIVE_LOW (1U << 8)
52 #define GPIOSEL (BASE7 + 0x00)
53 #define GPIOSEL_VWAKEINT (1U << 0)
66 static void toshiba_request_vsync(
struct msm_panel_data *panel_data,
116 ret = bridge_data->
uninit(bridge_data, client_data);
122 client_data->
suspend(client_data);
136 client_data->
resume(client_data);
137 ret = bridge_data->
init(bridge_data, client_data);
151 return bridge_data->
blank(bridge_data, client_data);
162 return bridge_data->
unblank(bridge_data, client_data);
178 static int setup_vsync(
struct panel_info *panel,
191 goto err_request_gpio_failed;
195 goto err_get_irq_num_failed;
200 goto err_request_irq_failed;
207 err_request_irq_failed:
208 err_get_irq_num_failed:
210 err_request_gpio_failed:
224 platform_set_drvdata(pdev, panel);
230 ret = setup_vsync(panel, 1);
232 dev_err(&pdev->
dev,
"mddi_bridge_setup_vsync failed\n");
239 panel->
panel_data.wait_vsync = toshiba_wait_vsync;
240 panel->
panel_data.request_vsync = toshiba_request_vsync;
241 panel->
panel_data.clear_vsync = toshiba_clear_vsync;
247 panel->
pdev.name =
"msm_panel";
248 panel->
pdev.id = pdev->
id;
250 panel->
pdev.num_resources = 1;
252 bridge_data->
init(bridge_data, client_data);
260 struct panel_info *panel = platform_get_drvdata(pdev);
262 setup_vsync(panel, 0);
268 .probe = mddi_toshiba_probe,
269 .remove = mddi_toshiba_remove,
270 .driver = { .name =
"mddi_c_d263_0000" },
273 static int __init mddi_client_toshiba_init(
void)