linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* /sys/class/tty bugglet in 2.6.0-test1 +
@ 2003-07-15 20:09 James H. Cloos Jr.
  2003-07-15 21:09 ` Greg KH
  0 siblings, 1 reply; 2+ messages in thread
From: James H. Cloos Jr. @ 2003-07-15 20:09 UTC (permalink / raw)
  To: linux-kernel

It looks like sysfs is creating a dir in class/tty by the name of
usb/acm/0 for my acm modem:

:; ls -AF /sys/class/tty
total 0
   0 console/
   0 ptmx/
   0 tty/
   0 tty0/
[ tty1 to tty63 elided ]
   0 ttyS0/
   0 ttyS1/
   0 ttyS2/
   0 ttyS3/
   0 usb/acm/0/

A [TAB] in bash will autocomplete /sys/class/tty/usb/acm/0.

W/ devfs the modem is at /dev/usb/acm/0, so it may be a sysfs
vs. devfs conflict.  (Box is gentoo; devfs is required for the 
init scripts to work.)

I think I'm at bk current, but may be off by a couple of csets.

-JimC


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

* Re: /sys/class/tty bugglet in 2.6.0-test1 +
  2003-07-15 20:09 /sys/class/tty bugglet in 2.6.0-test1 + James H. Cloos Jr.
@ 2003-07-15 21:09 ` Greg KH
  0 siblings, 0 replies; 2+ messages in thread
From: Greg KH @ 2003-07-15 21:09 UTC (permalink / raw)
  To: James H. Cloos Jr.; +Cc: linux-kernel

On Tue, Jul 15, 2003 at 04:09:45PM -0400, James H. Cloos Jr. wrote:
> It looks like sysfs is creating a dir in class/tty by the name of
> usb/acm/0 for my acm modem:
> 
> :; ls -AF /sys/class/tty
> total 0
>    0 console/
>    0 ptmx/
>    0 tty/
>    0 tty0/
> [ tty1 to tty63 elided ]
>    0 ttyS0/
>    0 ttyS1/
>    0 ttyS2/
>    0 ttyS3/
>    0 usb/acm/0/

Ouch, someone forgot to fix up this driver's devfs_name logic.  The
patch below should fix it.  Let me know if it doesn't work for you.

greg k-h


# USB: fix up cdc-acm driver's tty and devfs names.

diff -Nru a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c
--- a/drivers/usb/class/cdc-acm.c	Tue Jul 15 14:08:30 2003
+++ b/drivers/usb/class/cdc-acm.c	Tue Jul 15 14:08:30 2003
@@ -765,7 +765,8 @@
 		return -ENOMEM;
 	acm_tty_driver->owner = THIS_MODULE,
 	acm_tty_driver->driver_name = "acm",
-	acm_tty_driver->name = "usb/acm/",
+	acm_tty_driver->name = "ttyACM",
+	acm_tty_driver->devfs_name = "usb/acm/",
 	acm_tty_driver->major = ACM_TTY_MAJOR,
 	acm_tty_driver->minor_start = 0,
 	acm_tty_driver->type = TTY_DRIVER_TYPE_SERIAL,

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

end of thread, other threads:[~2003-07-15 20:55 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-07-15 20:09 /sys/class/tty bugglet in 2.6.0-test1 + James H. Cloos Jr.
2003-07-15 21:09 ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).