Thread (38 messages) read the whole thread 38 messages, 3 authors, 2020-08-17

Re: [PATCH v1 01/12] fbdev: gxfb: use generic power management

From: Vaibhav Gupta <vaibhavgupta40@gmail.com>
Date: 2020-08-10 09:46:07
Also in: dri-devel, linux-arm-kernel, linux-kernel-mentees, lkml

quoted
quoted
-static int gxfb_suspend(struct pci_dev *pdev, pm_message_t state)
+static int __maybe_unused gxfb_suspend(struct device *dev)
 {
-	struct fb_info *info = pci_get_drvdata(pdev);
+	struct fb_info *info = dev_get_drvdata(dev);
I do not see any dev_set_drvdata() so I guess we get a NULL pointer
here which is not intended.
Adding a dev_set_data() to gxfb_probe() would do the trick.
gxfb_probe() invokes pci_set_drvdata(pdev, info) which in turn calls
dev_set_drvdata(&pdev->dev, data). Adding dev_get_drvdata() will be redundant.
s/dev_get_drvdata/dev_set_drvdata

Thanks
Vaibhav Gupta
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help