Re: How do I choose an arbitrary minor number for my tty device?

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Greg KH
Date: Wednesday, November 17, 2010 - 3:19 pm

On Wed, Nov 17, 2010 at 04:10:21PM -0600, Timur Tabi wrote:

No, you want to have a tty device attached to your "byte channel
device".  That will give you the correct mapping here.  Your tty device
number is sequencial and has nothing in its name to do with your "byte
channel device number" just like ttyS1 has nothing in its pci device id
that it lives on with my multi-port serial card.


You just create your tty device and assign the parent of it to be your
"byte channel device".  Just like we do for PCI, USB, and all other bus
device types.

I think you are forgetting that your byte channel devices must be
"devices" in the system here, right?  There is a 'struct bus_id" for
your bus that these devices live on.  Then you create a tty device in
your tty driver that attaches to the byte channel that shows up as a tty
device on your bus.

Does that help explain things a bit better?

thanks,

greg k-h
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: How do I choose an arbitrary minor number for my tty d ..., Greg KH, (Wed Nov 17, 3:19 pm)
Re: How do I choose an arbitrary minor number for my tty d ..., Tabi Timur-B04825, (Mon Nov 29, 9:15 pm)