mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: "Björn Steinbrink" <B.Steinbrink@gmx.de>,
	"Dmitry Torokhov" <dmitry.torokhov@gmail.com>,
	"Arjan van de Ven" <arjan@linux.intel.com>,
	"Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>,
	"Jiri Kosina" <jkosina@suse.cz>, "Greg KH" <greg@kroah.com>
Subject: Re: [PATCH] evdev: Release eventual input device grabs when getting disconnected
Date: Mon, 31 Mar 2008 22:21:10 +0200	[thread overview]
Message-ID: <1206994870.5143.7.camel@johannes.berg> (raw)
In-Reply-To: <alpine.LFD.1.00.0803301448190.14670@woody.linux-foundation.org>

[-- Attachment #1: Type: text/plain, Size: 1621 bytes --]

On Sun, 2008-03-30 at 14:51 -0700, Linus Torvalds wrote:

> On Sun, 30 Mar 2008, Björn Steinbrink wrote:
> >
> > I can't reproduce the bug on my UP box and currently can't afford
> > crashing my SMP box (all the oopses seem to come from SMP kernels, so I
> > guess it needs SMP to crash), so while this doesn't show any new
> > problems, I can't tell whether it actually fixes anything. Testers
> > welcome!

Odd, I can reproduce trivially on UP. The patch definitely helps.

> Ok, I applied this because I will do an -rc8 today or tomorrow, but I 
> really really hope somebody can figure out what made this all start to 
> trigger.

Unfortunately, I can't even bisect, I just tried compiling 2.6.25-rc1
and it failed to link because of __udivi3, __umodi3 and another one (or
similar). A quick look failed to tell me why I get that with -rc1 and
-rc2 but not -rc7.

Below is a simple test program. Run it on any event device, then rmmod
the module the device belongs to and abort the program with ctrl-c.

johannes

#include <stdlib.h>
#include <unistd.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <linux/input.h>

int main (int argc, char **argv)
{
	int fd;

	if (argc < 2) {
		printf("Usage: grab /dev/input/eventX\n");
		printf("Where X = input device number\n");
		exit(1);
	}

	if ((fd = open(argv[argc - 1], O_RDONLY)) < 0) {
		perror("grab[open]");
		exit(1);
	}

	if (ioctl(fd, EVIOCGRAB, 1)) {
		perror("grab[EVIOCGRAB]");
		exit(1);
	}

	printf("interrupt to exit\n");

	while (1)
		sleep(1000);
}


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

  parent reply	other threads:[~2008-04-01 11:48 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-30 18:42 Björn Steinbrink
2008-03-30 21:51 ` Linus Torvalds
2008-03-30 22:22   ` Greg KH
2008-03-30 22:35     ` Linus Torvalds
2008-03-30 22:42     ` Björn Steinbrink
2008-03-30 23:19       ` Arjan van de Ven
2008-03-31 20:46       ` Dmitry Torokhov
2008-03-31  6:15   ` Dmitry Torokhov
2008-03-31 17:28     ` Greg KH
2008-03-31 18:01       ` Dmitry Torokhov
2008-03-31 18:24         ` Linus Torvalds
2008-03-31 23:12           ` Benjamin Herrenschmidt
2008-03-31 23:51             ` Greg KH
2008-04-01  1:01               ` Benjamin Herrenschmidt
2008-03-31 20:42         ` Greg KH
2008-03-31 20:57           ` Dmitry Torokhov
2008-03-31 22:09             ` Greg KH
2008-04-01  3:30               ` Dmitry Torokhov
2008-03-31 21:27           ` Jiri Kosina
2008-03-31 22:46             ` Kay Sievers
2008-03-31 20:21   ` Johannes Berg [this message]
2008-03-31 19:05 ` Björn Steinbrink
2008-04-01 11:51   ` Johannes Berg
2008-04-01 15:20     ` Björn Steinbrink
2008-04-02  9:17       ` Johannes Berg
2008-03-31 21:02 ` Johannes Berg

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=1206994870.5143.7.camel@johannes.berg \
    --to=johannes@sipsolutions.net \
    --cc=B.Steinbrink@gmx.de \
    --cc=arjan@linux.intel.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=greg@kroah.com \
    --cc=jkosina@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /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

all inboxes | Powered by JetHome®