[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <TU4PR8401MB1055C76F16F4D8A2DCF541F8AB7A9@TU4PR8401MB1055.NAMPRD84.PROD.OUTLOOK.COM>
Date: Fri, 2 Apr 2021 14:40:39 +0000
From: "Elliott, Robert (Servers)" <elliott@....com>
To: Arnd Bergmann <arnd@...nel.org>,
Sergei Trofimovich <slyfox@...too.org>
CC: "Martin K. Petersen" <martin.petersen@...cle.com>,
"John Paul Adrian Glaubitz" <glaubitz@...sik.fu-berlin.de>,
Don Brace - C33706 <don.brace@...rochip.com>,
"linux-ia64@...r.kernel.org" <linux-ia64@...r.kernel.org>,
"storagedev@...rochip.com" <storagedev@...rochip.com>,
linux-scsi <linux-scsi@...r.kernel.org>,
"jszczype@...hat.com" <jszczype@...hat.com>,
Scott Benesh <scott.benesh@...rochip.com>,
Scott Teel <scott.teel@...rochip.com>,
"thenzl@...hat.com" <thenzl@...hat.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH v2 3/3] hpsa: add an assert to prevent from __packed
reintroduction
It looks like ia64 implements atomic_t as a 64-bit value and expects atomic_t
to be 64-bit aligned, but does nothing to ensure that.
For x86, atomic_t is a 32-bit value and atomic64_t is a 64-bit value, and
the definition of atomic64_t is overridden in a way that ensures
64-bit (8 byte) alignment:
Generic definitions are in include/linux/types.h:
typedef struct {
int counter;
} atomic_t;
#define ATOMIC_INIT(i) { (i) }
#ifdef CONFIG_64BIT
typedef struct {
s64 counter;
} atomic64_t;
#endif
Override in arch/x86/include/asm/atomic64_32.h:
typedef struct {
s64 __aligned(8) counter;
} atomic64_t;
Perhaps ia64 needs to take over the definition of both atomic_t and atomic64_t
and do the same?
Powered by blists - more mailing lists