aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/omap
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2009-06-23 11:31:46 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-07-12 16:02:10 -0400
commit5e9a8bd65761bf0c1ee26d8514ef3e9ff22ee465 (patch)
tree217a567624f3ee0a7b8352a837b4d8f813efcc9b /drivers/video/omap
parent864e1e8db436dfd784340d0aef18ea303d157bcb (diff)
omap: video: remove direct access of driver_data
dev_set/get_drvdata() should be used instead, as driver_data is going away. Cc: Imre Deak <imre.deak@nokia.com> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Andrew Morton <akpm@linux-foundation.org> Acked-by: Trilok Soni <soni.trilok@gmail.com> Cc: Tony Lindgren <tony@atomide.com> Cc: Felipe Contreras <felipe.contreras@nokia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/video/omap')
-rw-r--r--drivers/video/omap/omapfb_main.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/video/omap/omapfb_main.c b/drivers/video/omap/omapfb_main.c
index 4ea99bfc37b4..8862233d57b6 100644
--- a/drivers/video/omap/omapfb_main.c
+++ b/drivers/video/omap/omapfb_main.c
@@ -1254,7 +1254,7 @@ static struct fb_ops omapfb_ops = {
1254static ssize_t omapfb_show_caps_num(struct device *dev, 1254static ssize_t omapfb_show_caps_num(struct device *dev,
1255 struct device_attribute *attr, char *buf) 1255 struct device_attribute *attr, char *buf)
1256{ 1256{
1257 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1257 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1258 int plane; 1258 int plane;
1259 size_t size; 1259 size_t size;
1260 struct omapfb_caps caps; 1260 struct omapfb_caps caps;
@@ -1274,7 +1274,7 @@ static ssize_t omapfb_show_caps_num(struct device *dev,
1274static ssize_t omapfb_show_caps_text(struct device *dev, 1274static ssize_t omapfb_show_caps_text(struct device *dev,
1275 struct device_attribute *attr, char *buf) 1275 struct device_attribute *attr, char *buf)
1276{ 1276{
1277 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1277 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1278 int i; 1278 int i;
1279 struct omapfb_caps caps; 1279 struct omapfb_caps caps;
1280 int plane; 1280 int plane;
@@ -1321,7 +1321,7 @@ static DEVICE_ATTR(caps_text, 0444, omapfb_show_caps_text, NULL);
1321static ssize_t omapfb_show_panel_name(struct device *dev, 1321static ssize_t omapfb_show_panel_name(struct device *dev,
1322 struct device_attribute *attr, char *buf) 1322 struct device_attribute *attr, char *buf)
1323{ 1323{
1324 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1324 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1325 1325
1326 return snprintf(buf, PAGE_SIZE, "%s\n", fbdev->panel->name); 1326 return snprintf(buf, PAGE_SIZE, "%s\n", fbdev->panel->name);
1327} 1327}
@@ -1330,7 +1330,7 @@ static ssize_t omapfb_show_bklight_level(struct device *dev,
1330 struct device_attribute *attr, 1330 struct device_attribute *attr,
1331 char *buf) 1331 char *buf)
1332{ 1332{
1333 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1333 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1334 int r; 1334 int r;
1335 1335
1336 if (fbdev->panel->get_bklight_level) { 1336 if (fbdev->panel->get_bklight_level) {
@@ -1345,7 +1345,7 @@ static ssize_t omapfb_store_bklight_level(struct device *dev,
1345 struct device_attribute *attr, 1345 struct device_attribute *attr,
1346 const char *buf, size_t size) 1346 const char *buf, size_t size)
1347{ 1347{
1348 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1348 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1349 int r; 1349 int r;
1350 1350
1351 if (fbdev->panel->set_bklight_level) { 1351 if (fbdev->panel->set_bklight_level) {
@@ -1364,7 +1364,7 @@ static ssize_t omapfb_store_bklight_level(struct device *dev,
1364static ssize_t omapfb_show_bklight_max(struct device *dev, 1364static ssize_t omapfb_show_bklight_max(struct device *dev,
1365 struct device_attribute *attr, char *buf) 1365 struct device_attribute *attr, char *buf)
1366{ 1366{
1367 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1367 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1368 int r; 1368 int r;
1369 1369
1370 if (fbdev->panel->get_bklight_level) { 1370 if (fbdev->panel->get_bklight_level) {
@@ -1397,7 +1397,7 @@ static struct attribute_group panel_attr_grp = {
1397static ssize_t omapfb_show_ctrl_name(struct device *dev, 1397static ssize_t omapfb_show_ctrl_name(struct device *dev,
1398 struct device_attribute *attr, char *buf) 1398 struct device_attribute *attr, char *buf)
1399{ 1399{
1400 struct omapfb_device *fbdev = (struct omapfb_device *)dev->driver_data; 1400 struct omapfb_device *fbdev = dev_get_drvdata(dev);
1401 1401
1402 return snprintf(buf, PAGE_SIZE, "%s\n", fbdev->ctrl->name); 1402 return snprintf(buf, PAGE_SIZE, "%s\n", fbdev->ctrl->name);
1403} 1403}