Re: [PATCH] qemu/bitops.h: Locate changed bits

2024-05-29 Thread Ho, Tong
, 2024 6:44 AM To: Ho, Tong Cc: qemu-devel@nongnu.org Subject: Re: [PATCH] qemu/bitops.h: Locate changed bits On Wed, 29 May 2024 at 06:05, Tong Ho wrote: > > Add inlined functions to obtain a mask of changed bits. 3 flavors > are added: toggled, changed to 1, changed to 0. > > Th

Re: [PATCH] qemu/bitops.h: Locate changed bits

2024-05-29 Thread Peter Maydell
On Wed, 29 May 2024 at 06:05, Tong Ho wrote: > > Add inlined functions to obtain a mask of changed bits. 3 flavors > are added: toggled, changed to 1, changed to 0. > > These newly added utilities aid common device behaviors where > actions are taken only when a register's bit(s) are changed. Ge

Re: [PATCH] qemu/bitops.h: Locate changed bits

2024-05-28 Thread Wang, Lei
On 5/29/2024 12:59, Tong Ho wrote:> Add inlined functions to obtain a mask of changed bits. 3 flavors > are added: toggled, changed to 1, changed to 0. > > These newly added utilities aid common device behaviors where > actions are taken only when a register's bit(s) are changed. > > Signed-off-

[PATCH] qemu/bitops.h: Locate changed bits

2024-05-28 Thread Tong Ho
Add inlined functions to obtain a mask of changed bits. 3 flavors are added: toggled, changed to 1, changed to 0. These newly added utilities aid common device behaviors where actions are taken only when a register's bit(s) are changed. Signed-off-by: Tong Ho --- include/qemu/bitops.h | 33 +++