[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v5 11/13] xen/spinlock: support higher number of cpus
On 18.03.24 16:08, Jan Beulich wrote: On 14.03.2024 08:20, Juergen Gross wrote:--- a/xen/include/xen/spinlock.h +++ b/xen/include/xen/spinlock.h @@ -8,16 +8,16 @@ #include <asm/system.h> #include <asm/spinlock.h>-#define SPINLOCK_CPU_BITS 12+#define SPINLOCK_CPU_BITS 16#ifdef CONFIG_DEBUG_LOCKSunion lock_debug { - uint16_t val; -#define LOCK_DEBUG_INITVAL 0xffff + uint32_t val; +#define LOCK_DEBUG_INITVAL 0xffffffffWith this #define I can see the desire for using a fixed width type for "val". However, ...struct { - uint16_t cpu:SPINLOCK_CPU_BITS; -#define LOCK_DEBUG_PAD_BITS (14 - SPINLOCK_CPU_BITS) - uint16_t :LOCK_DEBUG_PAD_BITS; + uint32_t cpu:SPINLOCK_CPU_BITS; +#define LOCK_DEBUG_PAD_BITS (30 - SPINLOCK_CPU_BITS) + uint32_t :LOCK_DEBUG_PAD_BITS;.. "unsigned int" ought to be fine for both of these. Fine with me. Juergen
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |