]> git.baikalelectronics.ru Git - kernel.git/commit
iommu/amd: Fix incorrect PASID decoding from event log
authorSuthikulpanit, Suravee <Suravee.Suthikulpanit@amd.com>
Mon, 14 Oct 2019 20:06:05 +0000 (20:06 +0000)
committerJoerg Roedel <jroedel@suse.de>
Tue, 15 Oct 2019 12:13:31 +0000 (14:13 +0200)
commitbb64c2e176485edeebfa216008852c3be3eeda2b
tree0bac239bbda2af1e217e0b1e99b6c134787a0e0d
parent9913670fc1d1d535e5614608cae79434675b69f8
iommu/amd: Fix incorrect PASID decoding from event log

IOMMU Event Log encodes 20-bit PASID for events:
    ILLEGAL_DEV_TABLE_ENTRY
    IO_PAGE_FAULT
    PAGE_TAB_HARDWARE_ERROR
    INVALID_DEVICE_REQUEST
as:
    PASID[15:0]  = bit 47:32
    PASID[19:16] = bit 19:16

Note that INVALID_PPR_REQUEST event has different encoding
from the rest of the events as the following:
    PASID[15:0]  = bit 31:16
    PASID[19:16] = bit 45:42

So, fixes the decoding logic.

Fixes: 76997c1cd876 ("iommu/amd: Update the PASID information printed to the system log")
Cc: Joerg Roedel <jroedel@suse.de>
Cc: Gary R Hook <gary.hook@amd.com>
Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/amd_iommu.c
drivers/iommu/amd_iommu_types.h