staging: vchiq_core: use BITSET_WORD macro
authorStefan Wahren <stefan.wahren@i2se.com>
Sun, 11 Apr 2021 18:11:37 +0000 (20:11 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Apr 2021 09:41:22 +0000 (11:41 +0200)
Use this macro to make the index retrieval less opaque.

Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com>
Link: https://lore.kernel.org/r/1618164700-21150-8-git-send-email-stefan.wahren@i2se.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c

index 22989866ff70c6949e7dca124512ab566b3b612b..2db2332f80decc220d5ae50acd6cd6ca478b7584 100644 (file)
@@ -547,7 +547,7 @@ request_poll(struct vchiq_state *state, struct vchiq_service *service,
        } while (atomic_cmpxchg(&service->poll_flags, value,
                 value | BIT(poll_type)) != value);
 
-       index = service->localport >> 5;
+       index = BITSET_WORD(service->localport);
        do {
                value = atomic_read(&state->poll_services[index]);
        } while (atomic_cmpxchg(&state->poll_services[index],