lkml.org 
[lkml]   [2023]   [Dec]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [RFC PATCH v6 2/4] iommu/vt-d: don's issue devTLB flush request when device is disconnected
From

On 12/24/2023 6:32 PM, Lukas Wunner wrote:
> On Sun, Dec 24, 2023 at 12:06:55AM -0500, Ethan Zhao wrote:
>> --- a/drivers/iommu/intel/pasid.c
>> +++ b/drivers/iommu/intel/pasid.c
>> @@ -481,6 +481,9 @@ devtlb_invalidation_with_pasid(struct intel_iommu *iommu,
>> if (!info || !info->ats_enabled)
>> return;
>>
>> + if (pci_dev_is_disconnected(to_pci_dev(dev)))
>> + return;
>> +
>> sid = info->bus << 8 | info->devfn;
>> qdep = info->ats_qdep;
>> pfsid = info->pfsid;
> Do you even need this or is patch [4/4] sufficient?
> Is there a benefit to the hunk above on top of patch [4/4]?

this is enough for purely surprise_removal or safe_removal,

it is better to not send "ATS invalidation request" than sent,

then check device state later.


Thanks,

Ethan

> Thanks,
>
> Lukas
>

\
 
 \ /
  Last update: 2023-12-25 02:56    [W:0.325 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site