9 Dec
2014
9 Dec
'14
11:08 a.m.
On Tue, Dec 09, 2014 at 11:41:16AM +0200, Imre Deak wrote:
+static inline struct drm_i915_private *dev_to_i915(struct device *dev) +{
- return to_i915(pci_get_drvdata(to_pci_dev(dev)));
+}
dev_get_drvdata. No need to upcast to pci_dev for pci_get_drvdata to downcast to device again. Let's really simplify this ;-) -Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch