mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* USB: set default y for CONFIG_USB_DEVICE_CLASS
@ 2007-05-27 15:04 Kay Sievers
  2007-05-27 16:10 ` Jesper Juhl
  0 siblings, 1 reply; 4+ messages in thread
From: Kay Sievers @ 2007-05-27 15:04 UTC (permalink / raw)
  To: Greg KH; +Cc: bert hubert, linux-kernel

From: Kay Sievers <kay.sievers@vrfy.org>
Subject: USB: set default y for CONFIG_USB_DEVICE_CLASS

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
---

diff --git a/drivers/usb/core/Kconfig b/drivers/usb/core/Kconfig
index f493fb1..346fc03 100644
--- a/drivers/usb/core/Kconfig
+++ b/drivers/usb/core/Kconfig
@@ -40,21 +40,25 @@ config USB_DEVICEFS
 config USB_DEVICE_CLASS
 	bool "USB device class-devices (DEPRECATED)"
 	depends on USB
-	default n
+	default y
 	---help---
 	  Userspace access to USB devices is granted by device-nodes exported
 	  directly from the usbdev in sysfs. Old versions of the driver
 	  core and udev needed additional class devices to export device nodes.
 
 	  These additional devices are difficult to handle in userspace, if
-	  information about USB interfaces must be available. One device contains
-	  the device node, the other device contains the interface data. Both
-	  devices are at the same level in sysfs (siblings) and one can't access
-	  the other. The device node created directly by the usbdev is the parent
-	  device of the interface and therefore easily accessible from the interface
-	  event.
-
-	  This option provides backward compatibility if needed.
+	  information about USB interfaces must be available. One device
+	  contains the device node, the other device contains the interface
+	  data. Both devices are at the same level in sysfs (siblings) and one
+	  can't access the other. The device node created directly by the
+	  usb device is the parent device of the interface and therefore
+	  easily accessible from the interface event.
+
+	  This option provides backward compatibility for libusb device
+	  nodes (lsusb) when usbfs is not used, and the following udev rule
+	  doesn't exist:
+	    SUBSYSTEM=="usb", ACTION=="add", ENV{DEVTYPE}=="usb_device", \
+	    NAME="bus/usb/$env{BUSNUM}/$env{DEVNUM}", MODE="0644"
 
 config USB_DYNAMIC_MINORS
 	bool "Dynamic USB minor allocation (EXPERIMENTAL)"


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: USB: set default y for CONFIG_USB_DEVICE_CLASS
  2007-05-27 15:04 USB: set default y for CONFIG_USB_DEVICE_CLASS Kay Sievers
@ 2007-05-27 16:10 ` Jesper Juhl
  2007-05-27 16:14   ` bert hubert
  2007-05-27 16:19   ` Kay Sievers
  0 siblings, 2 replies; 4+ messages in thread
From: Jesper Juhl @ 2007-05-27 16:10 UTC (permalink / raw)
  To: Kay Sievers; +Cc: Greg KH, bert hubert, linux-kernel

On 27/05/07, Kay Sievers <kay.sievers@vrfy.org> wrote:
> From: Kay Sievers <kay.sievers@vrfy.org>
> Subject: USB: set default y for CONFIG_USB_DEVICE_CLASS
>
> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
> ---
>
> diff --git a/drivers/usb/core/Kconfig b/drivers/usb/core/Kconfig
> index f493fb1..346fc03 100644
> --- a/drivers/usb/core/Kconfig
> +++ b/drivers/usb/core/Kconfig
> @@ -40,21 +40,25 @@ config USB_DEVICEFS
>  config USB_DEVICE_CLASS
>         bool "USB device class-devices (DEPRECATED)"
>         depends on USB
> -       default n
> +       default y

It puzzles me why a deprecated option should be default 'Y'...

-- 
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post  http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please      http://www.expita.com/nomime.html

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: USB: set default y for CONFIG_USB_DEVICE_CLASS
  2007-05-27 16:10 ` Jesper Juhl
@ 2007-05-27 16:14   ` bert hubert
  2007-05-27 16:19   ` Kay Sievers
  1 sibling, 0 replies; 4+ messages in thread
From: bert hubert @ 2007-05-27 16:14 UTC (permalink / raw)
  To: Jesper Juhl; +Cc: Kay Sievers, Greg KH, linux-kernel

On Sun, May 27, 2007 at 06:10:41PM +0200, Jesper Juhl wrote:
> >        bool "USB device class-devices (DEPRECATED)"
> >        depends on USB
> >-       default n
> >+       default y
> 
> It puzzles me why a deprecated option should be default 'Y'...

Because if it defaults to 'n', a 'make oldconfig' will break unmodified
userspace on reboot, which is something we don't want to do in a 'stable'
series, without announcing it first for a serious length of time.

	Bert

-- 
http://www.PowerDNS.com      Open source, database driven DNS Software 
http://netherlabs.nl              Open and Closed source services

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: USB: set default y for CONFIG_USB_DEVICE_CLASS
  2007-05-27 16:10 ` Jesper Juhl
  2007-05-27 16:14   ` bert hubert
@ 2007-05-27 16:19   ` Kay Sievers
  1 sibling, 0 replies; 4+ messages in thread
From: Kay Sievers @ 2007-05-27 16:19 UTC (permalink / raw)
  To: Jesper Juhl; +Cc: Greg KH, bert hubert, linux-kernel

On Sun, 2007-05-27 at 18:10 +0200, Jesper Juhl wrote:
> On 27/05/07, Kay Sievers <kay.sievers@vrfy.org> wrote:
> > From: Kay Sievers <kay.sievers@vrfy.org>
> > Subject: USB: set default y for CONFIG_USB_DEVICE_CLASS
> >
> > Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
> > ---
> >
> > diff --git a/drivers/usb/core/Kconfig b/drivers/usb/core/Kconfig
> > index f493fb1..346fc03 100644
> > --- a/drivers/usb/core/Kconfig
> > +++ b/drivers/usb/core/Kconfig
> > @@ -40,21 +40,25 @@ config USB_DEVICEFS
> >  config USB_DEVICE_CLASS
> >         bool "USB device class-devices (DEPRECATED)"
> >         depends on USB
> > -       default n
> > +       default y
> 
> It puzzles me why a deprecated option should be default 'Y'...

Because usb_device class devices are kind of broken regarding the event
timing, and should not be used anymore. They are replaced by
device-nodes created by the real usb-device, but some systems still
depend on the class devices:
   http://lkml.org/lkml/2007/5/27/56

We better default to y for a while until the users have switched over.

Kay


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-05-27 16:20 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-05-27 15:04 USB: set default y for CONFIG_USB_DEVICE_CLASS Kay Sievers
2007-05-27 16:10 ` Jesper Juhl
2007-05-27 16:14   ` bert hubert
2007-05-27 16:19   ` Kay Sievers

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®