Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F150089536
D6382.id16363.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1017 B
Referenced Files
None
Subscribers
None
D6382.id16363.diff
View Options
Index: sys/dev/hyperv/vmbus/hv_connection.c
===================================================================
--- sys/dev/hyperv/vmbus/hv_connection.c
+++ sys/dev/hyperv/vmbus/hv_connection.c
@@ -33,6 +33,7 @@
#include <sys/lock.h>
#include <sys/mutex.h>
#include <machine/bus.h>
+#include <machine/atomic.h>
#include <vm/vm.h>
#include <vm/vm_param.h>
#include <vm/pmap.h>
@@ -313,7 +314,7 @@
/*
* receive size is 1/2 page and divide that by 4 bytes
*/
- if (synch_test_and_clear_bit(0, &event->flags32[0])) {
+ if (atomic_testandclear_int(&event->flags32[0], 0)) {
recv_interrupt_page =
hv_vmbus_g_connection.recv_interrupt_page;
} else {
@@ -337,8 +338,8 @@
continue;
for (bit = 0; bit < HV_CHANNEL_DWORD_LEN; bit++) {
- if (synch_test_and_clear_bit(bit,
- (uint32_t *)&recv_interrupt_page[dword])) {
+ if (atomic_testandclear_int(
+ &recv_interrupt_page[dword], bit)) {
struct hv_vmbus_channel *channel;
rel_id = (dword << 5) + bit;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Mar 30, 7:27 AM (36 m, 31 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30569429
Default Alt Text
D6382.id16363.diff (1017 B)
Attached To
Mode
D6382: hyperv/vmbus: Use atomic_testandclear
Attached
Detach File
Event Timeline
Log In to Comment