Skip to content

Commit bd97615

Browse files
t-8chhdeller
authored andcommitted
fbdev: efifb: Use driver-private screen_info for sysfs
Since commit b9cfd1d ("fbdev/efifb: Use screen_info pointer from device") efifb uses a local copy of screen_info and applies its modifications there. Adapt the sysfs attributes to also work with the custom copy instead of the unmodified platform data. Signed-off-by: Thomas Weißschuh <[email protected]> Signed-off-by: Helge Deller <[email protected]>
1 parent 0770917 commit bd97615

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

drivers/video/fbdev/efifb.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ static ssize_t name##_show(struct device *dev, \
322322
struct device_attribute *attr, \
323323
char *buf) \
324324
{ \
325-
struct screen_info *si = dev_get_platdata(dev); \
325+
struct screen_info *si = dev_get_drvdata(dev); \
326326
if (!si) \
327327
return -ENODEV; \
328328
return sprintf(buf, fmt "\n", (si->lfb_##name)); \
@@ -369,6 +369,8 @@ static int efifb_probe(struct platform_device *dev)
369369
if (!si)
370370
return -ENOMEM;
371371

372+
dev_set_drvdata(&dev->dev, si);
373+
372374
if (si->orig_video_isVGA != VIDEO_TYPE_EFI)
373375
return -ENODEV;
374376

0 commit comments

Comments
 (0)