Date: Wed, 10 Dec 2008 16:28:17 -0700 (MST) From: "M. Warner Losh" <imp@bsdimp.com> To: jhb@FreeBSD.org Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r185874 - head/sys/sys Message-ID: <20081210.162817.474623206.imp@bsdimp.com> In-Reply-To: <200812101945.mBAJjwn2040853@svn.freebsd.org> References: <200812101945.mBAJjwn2040853@svn.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
In message: <200812101945.mBAJjwn2040853@svn.freebsd.org> John Baldwin <jhb@FreeBSD.org> writes: : Author: jhb : Date: Wed Dec 10 19:45:58 2008 : New Revision: 185874 : URL: http://svn.freebsd.org/changeset/base/185874 : : Log: : Rather than using a char array with explicit assumptions about the layout : of 'struct osigevent' in 'struct aiocb', use int and void pointer spare : members that are identical to 'struct osigevent'. This is better from an alignment perspective for !intel architectures. warner : MFC after: 1 month : : Modified: : head/sys/sys/aio.h : : Modified: head/sys/sys/aio.h : ============================================================================== : --- head/sys/sys/aio.h Wed Dec 10 19:33:10 2008 (r185873) : +++ head/sys/sys/aio.h Wed Dec 10 19:45:58 2008 (r185874) : @@ -69,7 +69,8 @@ typedef struct aiocb { : off_t aio_offset; /* File offset for I/O */ : volatile void *aio_buf; /* I/O buffer in process space */ : size_t aio_nbytes; /* Number of bytes for I/O */ : - char __spare__[sizeof(int) * 2 + sizeof(void *)]; /* osigevent. */ : + int __spare__[2]; : + void *__spare2__; : int aio_lio_opcode; /* LIO opcode */ : int aio_reqprio; /* Request priority -- ignored */ : struct __aiocb_private _aiocb_private; :
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20081210.162817.474623206.imp>