Messages in this thread | | | Date | Wed, 3 Nov 2004 15:08:27 -0800 | From | Greg KH <> | Subject | Re: patch for sysfs in the cyclades driver |
| |
On Wed, Nov 03, 2004 at 04:35:44PM -0600, Kilau, Scott wrote: > > > Your driver can use whatever name you wanted, as long as it's the > > LANNANA name that you asked for and were assigned. We do have > standards > > for a good reason, and the kernel will follow them. > > >That being said, have your customers use a tool like udev. Then they > > can name their tty devices whatever they want. No limitations there > at > > all. > > The problem is that LANANA assumes a product/driver > may only have a few tty's, say up to maybe 256 or so. > > For example, we have a driver that can support 1000s or 10000s of tty's.
Great, use udev for that.
> When dealing with that large amount of ttys, telling a customer > that they should remember that a tty down in Austin TX is ttyD19234, > and that the tty over in England is ttyD57267 is pretty ridiculous.
I agree, use udev.
> Our customers want to select a custom tty name base, > as well as a custom tty port number... > This way they can use logical names in an "area" specific range.
I agree, use udev.
> For example, maybe they have 10 16 port units in down in Texas, > they may want to group them as /dev/ttytx000 to /dev/ttytx159, > and the guy in england might want to name theirs > /dev/ttyengland_a to /dev/ttyengland_h
Fine, have them use udev.
> I agree using udev is a solution to the final name problem in /dev, > as long as they are using 2.6, (altough I have to support 2.4 as well).
We aren't talking about 2.4 here though. 2.4 is a totally different subject.
> But using udev still doesn't allow me to create that custom name in > /sys/class/tty.
You don't want to do that. The kernel doesn't want you to do that. Userspace doesn't want you to do that. No one wants that.
> I understand this is where you would say we should use the ttyD12143 > value, > but I feel that it simply doesn't show the "linkage" between that value > and the "custom" name in /dev as easily as it would if I could create a > custom name for the tty in /sys/class/tty.
udev will show you that /dev/ttyfoo really is /sys/class/tty/ttyD12143:
$ udevinfo -n /dev/ttyfoo -q path /class/tty/ttyD12143
So you do have that "linkage". Don't mess around with kernel names, it's not allowed. Mess around with userspace names, that's allowed.
thanks,
greg k-h - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |