linux-hardened/fs/autofs4
Linus Torvalds fcbf94b9de Revert "autofs: work around unhappy compat problem on x86-64"
This reverts commit a32744d4ab.

While that commit was technically the right thing to do, and made the
x86-64 compat mode work identically to native 32-bit mode (and thus
fixing the problem with a 32-bit systemd install on a 64-bit kernel), it
turns out that the automount binaries had workarounds for this compat
problem.

Now, the workarounds are disgusting: doing an "uname()" to find out the
architecture of the kernel, and then comparing it for the 64-bit cases
and fixing up the size of the read() in automount for those.  And they
were confused: it's not actually a generic 64-bit issue at all, it's
very much tied to just x86-64, which has different alignment for an
'u64' in 64-bit mode than in 32-bit mode.

But the end result is that fixing the compat layer actually breaks the
case of a 32-bit automount on a x86-64 kernel.

There are various approaches to fix this (including just doing a
"strcmp()" on current->comm and comparing it to "automount"), but I
think that I will do the one that teaches pipes about a special "packet
mode", which will allow user space to not have to care too deeply about
the padding at the end of the autofs packet.

That change will make the compat workaround unnecessary, so let's revert
it first, and get automount working again in compat mode.  The
packetized pipes will then fix autofs for systemd.

Reported-and-requested-by: Michael Tokarev <mjt@tls.msk.ru>
Cc: Ian Kent <raven@themaw.net>
Cc: stable@kernel.org # for 3.3
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-04-28 08:29:56 -07:00
..
autofs_i.h Revert "autofs: work around unhappy compat problem on x86-64" 2012-04-28 08:29:56 -07:00
dev-ioctl.c Revert "autofs: work around unhappy compat problem on x86-64" 2012-04-28 08:29:56 -07:00
expire.c autofs4 - fix lockdep splat in autofs 2012-02-13 20:45:37 -05:00
init.c autofs: set things up *before* registering fs type 2012-03-20 21:29:46 -04:00
inode.c Revert "autofs: work around unhappy compat problem on x86-64" 2012-04-28 08:29:56 -07:00
Kconfig fs/Kconfig: move autofs, autofs4 out 2009-01-22 13:15:54 +03:00
Makefile autofs4: add miscellaneous device for ioctls 2008-10-16 11:21:39 -07:00
root.c switch vfs_mkdir() and ->mkdir() to umode_t 2012-01-03 22:54:53 -05:00
symlink.c autofs4: keep symlink body in inode->i_private 2011-01-18 01:21:27 -05:00
waitq.c Revert "autofs: work around unhappy compat problem on x86-64" 2012-04-28 08:29:56 -07:00