search for: futex_atomic_cmpxchg

Displaying 3 results from an estimated 3 matches for "futex_atomic_cmpxchg".

2019 May 08
0
[PATCH RFC] vhost: don't use kmap() to log dirty pages
...GUP and > kmap_atomic() since kernel doesn't have a set_bit_to_user() > helper. This will cause issues for the arch that has virtually tagged > caches. The way to fix is to keep using userspace virtual address. > > Fortunately, futex has a cmpxchg to userspace memory helper > futex_atomic_cmpxchg_inatomic(). So switch to use it to exchange the > userspace bitmap with zero, set the bit and then write it back through > put_user(). > > Note: there're archs (few non popular ones) that don't implement > futex helper, we can't log dirty pages. We can fix them on top or...
2019 May 07
4
[PATCH RFC] vhost: don't use kmap() to log dirty pages
...to a userspace bitmap through GUP and kmap_atomic() since kernel doesn't have a set_bit_to_user() helper. This will cause issues for the arch that has virtually tagged caches. The way to fix is to keep using userspace virtual address. Fortunately, futex has a cmpxchg to userspace memory helper futex_atomic_cmpxchg_inatomic(). So switch to use it to exchange the userspace bitmap with zero, set the bit and then write it back through put_user(). Note: there're archs (few non popular ones) that don't implement futex helper, we can't log dirty pages. We can fix them on top or simply disable LOG_ALL f...
2019 May 07
4
[PATCH RFC] vhost: don't use kmap() to log dirty pages
...to a userspace bitmap through GUP and kmap_atomic() since kernel doesn't have a set_bit_to_user() helper. This will cause issues for the arch that has virtually tagged caches. The way to fix is to keep using userspace virtual address. Fortunately, futex has a cmpxchg to userspace memory helper futex_atomic_cmpxchg_inatomic(). So switch to use it to exchange the userspace bitmap with zero, set the bit and then write it back through put_user(). Note: there're archs (few non popular ones) that don't implement futex helper, we can't log dirty pages. We can fix them on top or simply disable LOG_ALL f...