Re: kernel unaligned accesses on IA64 in IDE | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
[adding Jens to CC: ]
On Fri, Aug 22, 2008 at 01:36:06PM -0700, Luck, Tony wrote:
> > How about long instead of int. int leaves us with the possibility that
> > something else will expect 8 byte alignment.
>
:> How about this?
>
> Align __cmd to ward off kernel unaligned access consoles messages on
> ia64 (and perhaps make an almost imperceptible performance improvement
> on other architectures that can handle unaligned access, but do so
> more slowly than aligned accesses).
>
> Signed-off-by: Tony Luck <tony.luck@xxxxxxxxx>
Tested-by: Borislav Petkov <petkovbb@xxxxxxxxx>
>
> ---
>
> diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
> index e61f22b..a493a4b 100644
> --- a/include/linux/blkdev.h
> +++ b/include/linux/blkdev.h
> @@ -211,7 +211,7 @@ struct request {
> * when request is used as a packet command carrier
> */
> unsigned short cmd_len;
> - unsigned char __cmd[BLK_MAX_CDB];
> + unsigned char __cmd[BLK_MAX_CDB] __attribute__((aligned(8)));
> unsigned char *cmd;
>
> unsigned int data_len;
--
Regards/Gruss,
Boris.
--
To unsubscribe from this list: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Linux MIPS Home] [Kernel List] [Sparc Linux] [DCCP] [Linux ARM List] [Linux] [Photo] [Yosemite News] [MIPS Architecture] [Linux SCSI] [Linux x86_64] [Linux Hams] [Site Home]
![]() |