Skip to content

Commit 8b208b0

Browse files
MaureenHelmjhedberg
authored andcommitted
drivers: hwspinlock: Fix context initializer build warning
Fixes a build warning in the hwspinlock context initializer macro that occurs when struct k_spinlock has no members ("warning: excess elements in struct initializer"). This change is consistent with other struct k_spinlock initializers in kernel.h. Signed-off-by: Maureen Helm <maureen.helm@analog.com>
1 parent a7f4150 commit 8b208b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/zephyr/drivers/hwspinlock.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ struct hwspinlock_dt_spec {
7373
*/
7474
#define HWSPINLOCK_CTX_INITIALIZER \
7575
{ \
76-
.lock = {0}, \
76+
.lock = {}, \
7777
}
7878

7979
/**

0 commit comments

Comments
 (0)