All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: Rudmer van Dijk <rudmer@legolas.dynup.net>
Cc: marado@student.dei.uc.pt, linux-kernel@vger.kernel.org
Subject: Re: 2.6.10-rc3-mm1
Date: Mon, 13 Dec 2004 11:33:36 -0800	[thread overview]
Message-ID: <20041213113336.02a0abfd.akpm@osdl.org> (raw)
In-Reply-To: <200412131910.24255.rudmer@legolas.dynup.net>

Rudmer van Dijk <rudmer@legolas.dynup.net> wrote:
>
> > OTOH, while I had no problems with the previous mm's or with 2.6.10-rc3,
>  > with -rc3-mm1 kdm has an weird function: with kdm/unstable uptodate
>  > 4:3.3.1-3 from Debian it just restarts X when it's going to show the
>  > login/password form, restarting over and over.
> 
>  saw it too with gdm on Gentoo,

It's probably the ioctl screwup.


From: Mikael Pettersson <mikpe@csd.uu.se>

The ioctl-cleanup.patch in 2.6.10-rc3-mm1 broke the file ioctls: FIONREAD
etc.  These ioctls have inline code for S_ISREG() cases, but should be
redirected to ->ioctl() for other cases.  ioctl-cleanup.patch removed that
redirection.

For me, both emacs and X refused to start from a console with ENOTTY
errors; at least emacs got the ENOTTY from FIONREAD.

Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/fs/ioctl.c |   18 ++++++------------
 1 files changed, 6 insertions(+), 12 deletions(-)

diff -puN fs/ioctl.c~ioctl-cleanups-broke-fionread-et-al fs/ioctl.c
--- 25/fs/ioctl.c~ioctl-cleanups-broke-fionread-et-al	2004-12-13 11:12:37.687951760 -0800
+++ 25-akpm/fs/ioctl.c	2004-12-13 11:12:37.690951304 -0800
@@ -91,10 +91,8 @@ asmlinkage long sys_ioctl(unsigned int f
 			int block;
 			int res;
 
-			if (!S_ISREG(inode->i_mode)) {
-				error = -ENOTTY;
-				goto done;
-			}
+			if (!S_ISREG(inode->i_mode))
+				break;
 			/* do we support this mess? */
 			if (!mapping->a_ops->bmap) {
 				error = -EINVAL;
@@ -112,19 +110,15 @@ asmlinkage long sys_ioctl(unsigned int f
 			goto done;
 		}
 	case FIGETBSZ:
-		if (!S_ISREG(inode->i_mode)) {
-			error = -ENOTTY;
-			goto done;
-		}
+		if (!S_ISREG(inode->i_mode))
+			break;
 		error = -EBADF;
 		if (inode->i_sb)
 			error = put_user(inode->i_sb->s_blocksize, p);
 		goto done;
 	case FIONREAD:
-		if (!S_ISREG(inode->i_mode)) {
-			error = -ENOTTY;
-			goto done;
-		}
+		if (!S_ISREG(inode->i_mode))
+			break;
 		error = put_user(i_size_read(inode) - filp->f_pos, p);
 		goto done;
 	}
_


  reply	other threads:[~2004-12-13 19:54 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-13 10:03 2.6.10-rc3-mm1 Andrew Morton
2004-12-13 10:31 ` 2.6.10-rc3-mm1 Kasper Sandberg
2004-12-13 10:36   ` 2.6.10-rc3-mm1 Andrew Morton
2004-12-13 20:27     ` 2.6.10-rc3-mm1 Nigel Cunningham
2004-12-13 12:02 ` 2.6.10-rc3-mm1 Christoph Hellwig
2004-12-13 15:01 ` 2.6.10-rc3-mm1 J.A. Magallon
2004-12-13 16:06   ` 2.6.10-rc3-mm1 Greg KH
2004-12-13 16:15 ` 2.6.10-rc3-mm1 Marcos D. Marado Torres
2004-12-13 17:02   ` 2.6.10-rc3-mm1 Fabio Coatti
2004-12-13 18:10   ` 2.6.10-rc3-mm1 Rudmer van Dijk
2004-12-13 19:33     ` Andrew Morton [this message]
2004-12-13 19:49       ` 2.6.10-rc3-mm1 Rudmer van Dijk
2004-12-13 21:06     ` 2.6.10-rc3-mm1 Felipe Alfaro Solana
2004-12-13 20:08 ` 2.6.10-rc3-mm1 Stephen Smalley
2004-12-14  4:10 ` [patch] 2.6.10-rc3-mm1: fix net/tulip/xircom_tulip_cb.c warning Adrian Bunk
2004-12-14 16:04 ` 2.6.10-rc3-mm1 (compile stats) John Cherry
2004-12-15 10:41   ` Paul Rolland
2004-12-15 16:16     ` John Cherry
2004-12-15 11:35 ` 2.6.10-rc3-mm1 William Lee Irwin III
2004-12-15 11:42   ` 2.6.10-rc3-mm1 Andrew Morton
2004-12-17  2:51     ` 2.6.10-rc3-mm1 William Lee Irwin III
2004-12-17  7:55       ` 2.6.10-rc3-mm1 Andrew Morton
2004-12-17 12:00         ` 2.6.10-rc3-mm1 William Lee Irwin III
2004-12-17 12:18           ` 2.6.10-rc3-mm1 Hugh Dickins
2004-12-16 17:49 ` 2.6.10-rc3-mm1 Nathan Lynch

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=20041213113336.02a0abfd.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marado@student.dei.uc.pt \
    --cc=rudmer@legolas.dynup.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.