Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-22 Thread Rasmus Villemoes
On Fri, Feb 19 2016, Theodore Ts'o wrote: > On Thu, Feb 18, 2016 at 09:10:21PM +0100, Rasmus Villemoes wrote: >> >> Sure, that would work as well. I don't really care how ->iname is pushed >> out to offset 32, but I'd like to know if it's worth it. > > Do you have access to one

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-22 Thread Rasmus Villemoes
On Fri, Feb 19 2016, Theodore Ts'o wrote: > On Thu, Feb 18, 2016 at 09:10:21PM +0100, Rasmus Villemoes wrote: >> >> Sure, that would work as well. I don't really care how ->iname is pushed >> out to offset 32, but I'd like to know if it's worth it. > > Do you have access to one of these

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-19 Thread Theodore Ts'o
On Thu, Feb 18, 2016 at 09:10:21PM +0100, Rasmus Villemoes wrote: > > Sure, that would work as well. I don't really care how ->iname is pushed > out to offset 32, but I'd like to know if it's worth it. Do you have access to one of these platforms where unaligned access is really painful? The

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-19 Thread Theodore Ts'o
On Thu, Feb 18, 2016 at 09:10:21PM +0100, Rasmus Villemoes wrote: > > Sure, that would work as well. I don't really care how ->iname is pushed > out to offset 32, but I'd like to know if it's worth it. Do you have access to one of these platforms where unaligned access is really painful? The

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-18 Thread Rasmus Villemoes
On Tue, Feb 16 2016, Al Viro wrote: > On Tue, Feb 16, 2016 at 11:49:24PM +0100, Rasmus Villemoes wrote: >> I noticed that offsetof(struct filename, iname) is actually 28 on 64 >> bit platforms, so we always pass an unaligned pointer to >> strncpy_from_user. This is

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-18 Thread Rasmus Villemoes
On Tue, Feb 16 2016, Al Viro wrote: > On Tue, Feb 16, 2016 at 11:49:24PM +0100, Rasmus Villemoes wrote: >> I noticed that offsetof(struct filename, iname) is actually 28 on 64 >> bit platforms, so we always pass an unaligned pointer to >> strncpy_from_user. This is mostly a problem for those 64

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-16 Thread Al Viro
On Tue, Feb 16, 2016 at 11:49:24PM +0100, Rasmus Villemoes wrote: > I noticed that offsetof(struct filename, iname) is actually 28 on 64 > bit platforms, so we always pass an unaligned pointer to > strncpy_from_user. This is mostly a problem for those 64 bit platforms > without

Re: [PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-16 Thread Al Viro
On Tue, Feb 16, 2016 at 11:49:24PM +0100, Rasmus Villemoes wrote: > I noticed that offsetof(struct filename, iname) is actually 28 on 64 > bit platforms, so we always pass an unaligned pointer to > strncpy_from_user. This is mostly a problem for those 64 bit platforms > without

[PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-16 Thread Rasmus Villemoes
I noticed that offsetof(struct filename, iname) is actually 28 on 64 bit platforms, so we always pass an unaligned pointer to strncpy_from_user. This is mostly a problem for those 64 bit platforms without HAVE_EFFICIENT_UNALIGNED_ACCESS, but even on x86_64, unaligned accesses carry a penalty,

[PATCH 1/2] vfs: make sure struct filename->iname is word-aligned

2016-02-16 Thread Rasmus Villemoes
I noticed that offsetof(struct filename, iname) is actually 28 on 64 bit platforms, so we always pass an unaligned pointer to strncpy_from_user. This is mostly a problem for those 64 bit platforms without HAVE_EFFICIENT_UNALIGNED_ACCESS, but even on x86_64, unaligned accesses carry a penalty,