]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
iommu/vt-d: Fix rwxp flags in SVM device fault callback
authorDavid Woodhouse <David.Woodhouse@intel.com>
Wed, 28 Oct 2015 06:14:09 +0000 (15:14 +0900)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Wed, 28 Oct 2015 06:14:09 +0000 (15:14 +0900)
This is the downside of using bitfields in the struct definition, rather
than doing all the explicit masking and shifting.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/iommu/intel-svm.c

index 48a3d4a3d6c03d3003032b5b79d7260bd25b6e3a..c69e3f9ec9586bca0cd2ef712a3cf9fc25f4689f 100644 (file)
@@ -564,7 +564,7 @@ static irqreturn_t prq_event_thread(int irq, void *d)
 
                if (sdev && sdev->ops && sdev->ops->fault_cb) {
                        int rwxp = (req->rd_req << 3) | (req->wr_req << 2) |
-                               (req->wr_req << 1) | (req->exe_req);
+                               (req->exe_req << 1) | (req->priv_req);
                        sdev->ops->fault_cb(sdev->dev, req->pasid, req->addr, req->private, rwxp, result);
                }
                /* We get here in the error case where the PASID lookup failed,