diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2011-09-18 06:21:17 -0400 |
---|---|---|
committer | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2012-03-12 17:40:50 -0400 |
commit | e34d0bbb062cc78802d0f0686c939ea1569889a6 (patch) | |
tree | bf38b9444117c01a7675546741c2623efa76be8c /drivers | |
parent | afaad83b9c0d24eac88535cc5a8c6019f0c45bcb (diff) |
sh_mobile_lcdc: Add an lcdc channel pointer to sh_mobile_lcdc_entity
The field will be used by the transmitter drivers to access
sh_mobile_lcdc_chan fields such as fb_info.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/video/sh_mobile_lcdcfb.c | 5 | ||||
-rw-r--r-- | drivers/video/sh_mobile_lcdcfb.h | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/drivers/video/sh_mobile_lcdcfb.c b/drivers/video/sh_mobile_lcdcfb.c index 9e44988155a..1ecc71ec41f 100644 --- a/drivers/video/sh_mobile_lcdcfb.c +++ b/drivers/video/sh_mobile_lcdcfb.c | |||
@@ -1495,8 +1495,10 @@ static int sh_mobile_lcdc_remove(struct platform_device *pdev) | |||
1495 | if (!info || !info->device) | 1495 | if (!info || !info->device) |
1496 | continue; | 1496 | continue; |
1497 | 1497 | ||
1498 | if (ch->tx_dev) | 1498 | if (ch->tx_dev) { |
1499 | ch->tx_dev->lcdc = NULL; | ||
1499 | module_put(ch->cfg.tx_dev->dev.driver->owner); | 1500 | module_put(ch->cfg.tx_dev->dev.driver->owner); |
1501 | } | ||
1500 | 1502 | ||
1501 | if (ch->sglist) | 1503 | if (ch->sglist) |
1502 | vfree(ch->sglist); | 1504 | vfree(ch->sglist); |
@@ -1605,6 +1607,7 @@ sh_mobile_lcdc_channel_init(struct sh_mobile_lcdc_priv *priv, | |||
1605 | return -EINVAL; | 1607 | return -EINVAL; |
1606 | } | 1608 | } |
1607 | ch->tx_dev = platform_get_drvdata(cfg->tx_dev); | 1609 | ch->tx_dev = platform_get_drvdata(cfg->tx_dev); |
1610 | ch->tx_dev->lcdc = ch; | ||
1608 | } | 1611 | } |
1609 | 1612 | ||
1610 | /* Iterate through the modes to validate them and find the highest | 1613 | /* Iterate through the modes to validate them and find the highest |
diff --git a/drivers/video/sh_mobile_lcdcfb.h b/drivers/video/sh_mobile_lcdcfb.h index 9601b929a40..36cd5649598 100644 --- a/drivers/video/sh_mobile_lcdcfb.h +++ b/drivers/video/sh_mobile_lcdcfb.h | |||
@@ -19,6 +19,7 @@ struct fb_info; | |||
19 | struct module; | 19 | struct module; |
20 | struct sh_mobile_lcdc_entity; | 20 | struct sh_mobile_lcdc_entity; |
21 | struct sh_mobile_lcdc_priv; | 21 | struct sh_mobile_lcdc_priv; |
22 | struct sh_mobile_lcdc_chan; | ||
22 | 23 | ||
23 | struct sh_mobile_lcdc_entity_ops { | 24 | struct sh_mobile_lcdc_entity_ops { |
24 | /* Display */ | 25 | /* Display */ |
@@ -30,6 +31,7 @@ struct sh_mobile_lcdc_entity_ops { | |||
30 | struct sh_mobile_lcdc_entity { | 31 | struct sh_mobile_lcdc_entity { |
31 | struct module *owner; | 32 | struct module *owner; |
32 | const struct sh_mobile_lcdc_entity_ops *ops; | 33 | const struct sh_mobile_lcdc_entity_ops *ops; |
34 | struct sh_mobile_lcdc_chan *lcdc; | ||
33 | }; | 35 | }; |
34 | 36 | ||
35 | /* | 37 | /* |