X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-1.7 required=5.0	tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,UNPARSEABLE_RELAY
X-Spam-Check-By: sourceware.org
X-Yahoo-SMTP: jenXL62swBAWhMTL3wnej93oaS0ClBQOAKs8jbEbx_o-
Date: Thu, 4 Aug 2011 00:22:06 -0400
From: Christopher Faylor <cgf-use-the-mailinglist-please@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: Device numbers, Cygwin vs. Linux
Message-ID: <20110804042206.GA2483@ednor.casa.cgf.cx>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <CAGvSfexx5=oMuY0QwDAOKdkwSsSAZ8BniVgBY75DV==i44_m_w@mail.gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <CAGvSfexx5=oMuY0QwDAOKdkwSsSAZ8BniVgBY75DV==i44_m_w@mail.gmail.com>
User-Agent: Mutt/1.5.20 (2009-06-14)
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

On Wed, Aug 03, 2011 at 09:33:32PM -0500, Yaakov (Cygwin/X) wrote:
>I'm working on /proc/devices, but upon comparing to Linux[1], I
>noticed some differences in character device numbering:
>
>* /dev/tty
>Linux is 5,0, Cygwin is 3,0

You're using a snapshot.  After my pty reorg, Cygwin, probably
erroneously, effectively symlinks /dev/tty to whatever your current
"tty" is.  It will either be a pty or a console.

>* /dev/tty[N]
>Linux is 4,[N], Cygwin 136,N (major 136 is /dev/pts/N on Linux)
>
>* /dev/console
>Linux is 5,1, Cygwin is 3,0 (same as /dev/tty !)

See above.

>* /dev/ttyS[N]
>Linux is 4,[N+64], Cygwin is 117,[N]
>
>Why these differences?

I had a reason when I set up the device numbers but I don't remember any
more.  I tried to adhere to linux but there wasn't a 1-1 correspondence.
And, possibly the numbering changed over time for linux.

cgf

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

