diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2016-11-08 09:43:50 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2016-11-17 09:50:35 +1000 |
commit | 9e38b13ea5f9b0a513e4a31f8cc964d267e3d4bd (patch) | |
tree | 7238d7617411e16ec00b0becfaa4bcfa5db3ba96 /drivers/gpu | |
parent | 3ca03cac399340563941828e58316105e26cffc1 (diff) | |
download | op-kernel-dev-9e38b13ea5f9b0a513e4a31f8cc964d267e3d4bd.zip op-kernel-dev-9e38b13ea5f9b0a513e4a31f8cc964d267e3d4bd.tar.gz |
drm/nouveau/device/pci: fix oops if no mmu subdev present
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c b/drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c index 0030cd9..74a1ffa 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/device/pci.c @@ -1687,7 +1687,7 @@ nvkm_device_pci_new(struct pci_dev *pci_dev, const char *cfg, const char *dbg, * This is necessary for platforms where the default DMA mask of 32 * does not cover any system memory, i.e., when all RAM is > 4 GB. */ - if (subdev_mask & BIT(NVKM_SUBDEV_MMU)) + if (pdev->device.mmu) dma_set_mask_and_coherent(&pci_dev->dev, DMA_BIT_MASK(pdev->device.mmu->dma_bits)); |