The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: linux-kernel@vger.kernel.org, trivial@rustcorp.com.au
Subject: [TRIVIAL] Fix compile with !CONFIG_VT
Date: Fri, 27 Jun 2003 15:54:08 +1000	[thread overview]
Message-ID: <20030627055408.GL1521@zax> (raw)

Linus, please apply:

Architectures using the generic 32/64-bit ioctl() compatibility shims
will get a link error if CONFIG_VT is not defined, since the
compatbility ioctl() code calls functions in drivers/char/vt.c which
is only included in the build if CONFIG_VT is set.

This fixes the compile with a couple of #ifdefs:

diff -urN /scratch/anton/export/fs/compat_ioctl.c linux-gogogo/fs/compat_ioctl.c
--- /scratch/anton/export/fs/compat_ioctl.c	2003-06-20 00:42:50.000000000 +1000
+++ linux-gogogo/fs/compat_ioctl.c	2003-06-27 15:36:38.000000000 +1000
@@ -1562,6 +1562,8 @@
 
 extern int tty_ioctl(struct inode * inode, struct file * file, unsigned int cmd, unsigned long arg);
 
+#ifdef CONFIG_VT
+
 static int vt_check(struct file *file)
 {
 	struct tty_struct *tty;
@@ -1693,6 +1695,8 @@
 	return 0;
 }
 
+#endif /* CONFIG_VT */
+
 static int do_smb_getmountuid(unsigned int fd, unsigned int cmd, unsigned long arg)
 {
 	mm_segment_t old_fs = get_fs();
@@ -2398,11 +2402,13 @@
 HANDLE_IOCTL(LOOP_GET_STATUS, loop_status)
 #define AUTOFS_IOC_SETTIMEOUT32 _IOWR(0x93,0x64,unsigned int)
 HANDLE_IOCTL(AUTOFS_IOC_SETTIMEOUT32, ioc_settimeout)
+#ifdef CONFIG_VT
 HANDLE_IOCTL(PIO_FONTX, do_fontx_ioctl)
 HANDLE_IOCTL(GIO_FONTX, do_fontx_ioctl)
 HANDLE_IOCTL(PIO_UNIMAP, do_unimap_ioctl)
 HANDLE_IOCTL(GIO_UNIMAP, do_unimap_ioctl)
 HANDLE_IOCTL(KDFONTOP, do_kdfontop_ioctl)
+#endif
 HANDLE_IOCTL(EXT2_IOC32_GETFLAGS, do_ext2_ioctl)
 HANDLE_IOCTL(EXT2_IOC32_SETFLAGS, do_ext2_ioctl)
 HANDLE_IOCTL(EXT2_IOC32_GETVERSION, do_ext2_ioctl)


-- 
David Gibson			| For every complex problem there is a
david@gibson.dropbear.id.au	| solution which is simple, neat and
				| wrong.
http://www.ozlabs.org/people/dgibson

                 reply	other threads:[~2003-06-27  5:38 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030627055408.GL1521@zax \
    --to=david@gibson.dropbear.id.au \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.com \
    --cc=trivial@rustcorp.com.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox