Skip to contentSkip to conversation

autofs: fix 3.3-rc5 compilation breakage on x86-32

PATCH In review Stanislaw Gruszka 2 participants 2 messages Feb 26, 2012 Kernel automounter

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 autofs: fix 3.3-rc5 compilation breakage on x86-32

Recent commit a32744d4abae24572eff7269bc17895c41bd0085 broke autofs compilation on x86-32:

fs/autofs4/inode.c: In function ‘autofs4_fill_super’:
fs/autofs4/inode.c:228: error: implicit declaration of function ‘is_compat_task’

This patch fix that by adding #if checks.

---
 fs/autofs4/autofs_i.h  |    2 ++
 fs/autofs4/dev-ioctl.c |    2 ++
 fs/autofs4/inode.c     |    2 ++
 3 files changed, 6 insertions(+), 0 deletions(-)
fs/autofs4/autofs_i.h +2 -0
index eb1cc92..60439c2 100644
@@ -110,7 +110,9 @@ struct autofs_sb_info {
 	int sub_version;
 	int min_proto;
 	int max_proto;
+#if defined(CONFIG_X86_64) && defined(CONFIG_COMPAT)
 	int compat_daemon;
+#endif
 	unsigned long exp_timeout;
 	unsigned int type;
 	int reghost_enabled;
fs/autofs4/dev-ioctl.c +2 -0
index 85f1fcd..3ffff72 100644
@@ -385,7 +385,9 @@ static int autofs_dev_ioctl_setpipefd(struct file *fp,
 		sbi->pipefd = pipefd;
 		sbi->pipe = pipe;
 		sbi->catatonic = 0;
+#if defined(CONFIG_X86_64) && defined(CONFIG_COMPAT)
 		sbi->compat_daemon = is_compat_task();
+#endif
 	}
 out:
 	mutex_unlock(&sbi->wq_mutex);
fs/autofs4/inode.c +2 -0
index 06858d9..5f3fb68 100644
@@ -225,7 +225,9 @@ int autofs4_fill_super(struct super_block *s, void *data, int silent)
 	set_autofs_type_indirect(&sbi->type);
 	sbi->min_proto = 0;
 	sbi->max_proto = 0;
+#if defined(CONFIG_X86_64) && defined(CONFIG_COMPAT)
 	sbi->compat_daemon = is_compat_task();
+#endif
 	mutex_init(&sbi->wq_mutex);
 	mutex_init(&sbi->pipe_mutex);
 	spin_lock_init(&sbi->fs_lock);
Signature · 1 line
1.7.1
#1 lore raw
Quoted 9 lines · Stanislaw Gruszka

Recent commit a32744d4abae24572eff7269bc17895c41bd0085 broke autofs compilation on x86-32:

fs/autofs4/inode.c: In function ‘autofs4_fill_super’:
fs/autofs4/inode.c:228: error: implicit declaration of function ‘is_compat_task’

This patch fix that by adding #if checks.

Andreas Schwab submitted an identical patch. Linus came up with something else:

https://lkml.org/lkml/2012/2/25/84

josh