summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/via/via_map.c
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2021-05-02 12:49:52 +0200
committerThomas Zimmermann <tzimmermann@suse.de>2021-05-03 19:48:37 +0200
commit9a31b3813f91408bbd5e4059f6c6cc6713eef790 (patch)
tree7bc42fe8c54d80eaca249c9b8de452199b5905d6 /drivers/gpu/drm/via/via_map.c
parente2c5ab5cb8e57249bde217c72a9097d9e84c196e (diff)
downloadlinux-9a31b3813f91408bbd5e4059f6c6cc6713eef790.tar.bz2
drm/via: Remove references to drm_device.pdev
Replace all references to struct drm_device's pdev field with an upcast from dev. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de> Reviewed-by: Maxime Ripard <maxime@cerno.tech> Link: https://patchwork.freedesktop.org/patch/msgid/20210502104953.21768-7-tzimmermann@suse.de
Diffstat (limited to 'drivers/gpu/drm/via/via_map.c')
-rw-r--r--drivers/gpu/drm/via/via_map.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/via/via_map.c b/drivers/gpu/drm/via/via_map.c
index 255c5066a939..a9f6b0c11966 100644
--- a/drivers/gpu/drm/via/via_map.c
+++ b/drivers/gpu/drm/via/via_map.c
@@ -98,6 +98,7 @@ int via_map_init(struct drm_device *dev, void *data, struct drm_file *file_priv)
int via_driver_load(struct drm_device *dev, unsigned long chipset)
{
+ struct pci_dev *pdev = to_pci_dev(dev->dev);
drm_via_private_t *dev_priv;
int ret = 0;
@@ -110,7 +111,7 @@ int via_driver_load(struct drm_device *dev, unsigned long chipset)
dev_priv->chipset = chipset;
- pci_set_master(dev->pdev);
+ pci_set_master(pdev);
ret = drm_vblank_init(dev, 1);
if (ret) {