]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
iommu/vt-d: Set the right field for Page Walk Snoop
authorLu Baolu <baolu.lu@linux.intel.com>
Tue, 21 May 2019 07:30:16 +0000 (15:30 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 10 Jul 2019 07:52:22 +0000 (09:52 +0200)
[ Upstream commit 66d78ad316b0e1ca5ae19663468554e2c0e31c26 ]

Set the page walk snoop to the right bit, otherwise the domain
id field will be overlapped.

Reported-by: Dave Jiang <dave.jiang@intel.com>
Fixes: 6f7db75e1c469 ("iommu/vt-d: Add second level page table interface")
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/iommu/intel-pasid.c

index 03b12d2ee2132fe624eeed719dc486d89279f2e4..fdf05c45d516c4a57b1aaee8b166fa26ac6b718f 100644 (file)
@@ -387,7 +387,7 @@ static inline void pasid_set_present(struct pasid_entry *pe)
  */
 static inline void pasid_set_page_snoop(struct pasid_entry *pe, bool value)
 {
-       pasid_set_bits(&pe->val[1], 1 << 23, value);
+       pasid_set_bits(&pe->val[1], 1 << 23, value << 23);
 }
 
 /*