Re: How to add uart driver for /dev/ttyS1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



El Wed, Jul 15, 2009 at 02:56:41PM +0800 vichy ha dit:

> >
> >  tr@fuckup:~/work$ ls -al /dev/ttyS*
> >  crw-rw---- 1 root dialout 4, 64 2009-07-12 14:46 /dev/ttyS0
> >  crw-rw---- 1 root dialout 4, 65 2009-07-12 14:46 /dev/ttyS1
> >  crw-rw---- 1 root dialout 4, 66 2009-07-12 14:46 /dev/ttyS2
> >  crw-rw---- 1 root dialout 4, 67 2009-07-12 14:46 /dev/ttyS3
> >
> as you can see the minor number of /dev/ttyS1 is 65.
> if I remember correctly, each driver has to register its device node
> with major, minor number.
> In 8250.c, the 8250_init will assign each 8250 device  with 8250
> driver which minor number is 64.
> if I have 2 8250 serial devices, it seems impossible I can driver my
> second 8250 serial device through /dev/ttyS1, since driver is
> registered for minor 64 but ttyS1 is minor 65.

the driver is identified by the major number and reserves a range of
minor numbers (one for each device), the minor number identifies the
device

-- 
Matthias Kaehlcke
Embedded Linux Engineer
Barcelona

  Si deseas mantener tu libertad, debes estar preparado para defenderla
                          (Richard Stallman)
                                                                 .''`.
    using free software / Debian GNU/Linux | http://debian.org  : :'  :
                                                                `. `'`
gpg --keyserver pgp.mit.edu --recv-keys 47D8E5D4                  `-

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux