[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [patch-4.16] arm/smmuv1,v2: Protect smmu master list with a lock





On 28/10/2021 13:15, Michal Orzel wrote:
Hi Julien,

Hi Michal,

On 28.10.2021 12:05, Julien Grall wrote:
The purpose of this patch is to fix the issue that is present in 4.16.

I think this is a latent bug (see more below).

The patch adding support for removal you are reffering to:
-is in RFC state
-is not meant for 4.16
-will need to be modified anyway because of the future PCI passthrough patches 
that are going to modify lots of stuff

That being said, the bug we want to fix touches only point 1). And in fact my 
patch is solving this issue.
So I think we should focus on 4.16 and fixing bugs for it without thinking of 
future patches/modifications.

I would have agreed with your reasoning if this bug could be triggered with Xen 4.16 out-of-box. AFAIK, this is not the case because PCI devices cannot be registered with the SMMU driver.

I agree that the locking behaviour will change as soon as the patch you are 
reffering to will be merged.
However, the PCI passthrough patches are going to modify this code anyway, so 
all in all the future modifications will be needed.

Right. PCI passthrough is not going to work in 4.16 whether this patch is merged or not. We are past the code freeze and as you said the code (and potentially the locking) is going to be reworked for PCI passthrough.

So, I think this is a bad idea to rush this patch in 4.16. Instead, we should focus on getting a consistent locking for 4.17 that would cover the removal part and all PCI and DT concurrent call.

To be clear, I am not expecting you to implement the both part. I am fine if you focus only on the latter. But first, we need to agree on the approach (see my 2 proposals sent earlier).

Regarding the patch itself, I will be happy to queue the patch when it is fully ready and merge it after the tree is re-opened for 4.17.

Cheers,

--
Julien Grall



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.