On Fri, 7 Oct 2022 at 17:45, Richard Henderson <richard.hender...@linaro.org> wrote: > > On 10/7/22 06:47, Peter Maydell wrote: > > Are there definitely no code paths where we might try to do > > a page table walk with the iothread already locked ? > > I'll double-check, but another possibility is to simply perform the atomic > operation on > the low 32-bits, where both AF and DB are located. Another trick I learned > from x86...
Doesn't that cause a problem where we don't detect that some other CPU wrote to the high 32 bits of the descriptor ? We're supposed to be using those high 32 bits, not the ones we have in hand... If we do need the iothread lock, we could do it the way that io_readx() does, I guess, where we track whether we needed to lock it or not. thanks -- PMM