Re: [PATCH v2] KVM: arm64: Don't acquire RCU read lock for exclusive table walks

2022-11-16 Thread Oliver Upton
On Wed, Nov 16, 2022 at 07:27:27AM +, Oliver Upton wrote: > On Wed, Nov 16, 2022 at 03:08:49AM +, Marc Zyngier wrote: > > I'm not crazy about this sort of parameters. I think it would make a > > lot more sense to pass a pointer to the walker structure and do the > > flag check inside the he

Re: [PATCH v2] KVM: arm64: Don't acquire RCU read lock for exclusive table walks

2022-11-15 Thread Oliver Upton
On Wed, Nov 16, 2022 at 03:08:49AM +, Marc Zyngier wrote: > I'm not crazy about this sort of parameters. I think it would make a > lot more sense to pass a pointer to the walker structure and do the > flag check inside the helper. > > That way, we avoid extra churn if/when we need extra state

Re: [PATCH v2] KVM: arm64: Don't acquire RCU read lock for exclusive table walks

2022-11-15 Thread Marc Zyngier
On Tue, 15 Nov 2022 22:55:02 +, Oliver Upton wrote: > > Marek reported a BUG resulting from the recent parallel faults changes, > as the hyp stage-1 map walker attempted to allocate table memory while > holding the RCU read lock: > > BUG: sleeping function called from invalid context at >

[PATCH v2] KVM: arm64: Don't acquire RCU read lock for exclusive table walks

2022-11-15 Thread Oliver Upton
Marek reported a BUG resulting from the recent parallel faults changes, as the hyp stage-1 map walker attempted to allocate table memory while holding the RCU read lock: BUG: sleeping function called from invalid context at include/linux/sched/mm.h:274 in_atomic(): 0, irqs_disabled(): 0, non