Re: Enabling A Serial Port On 6.2

2007-07-08 Thread Tim Daneliuk

Tim Daneliuk wrote:

System is FreeBSD 6.2-STABLE.

I've added this to /etc/ttys:

  ttyd0   /usr/libexec/getty dial.115200unknown on insecure

And this to gettytabs:

  dial.115200:\
:np:to#30:hw:sp#115200:pp=/etc/ppp/pppserv

But when I 'kill -HUP 1' no getty process on ttyd0 shows up in the ps 
listing.


I found (and fixed) what was causing this, but it is very strange and I
am documenting here so others may avoid the pain.

At the *end* of  /etc/ttys the file, I put:

  ttyd0   /usr/libexec/getty dial.115200unknown on insecure


But ... the entry did not end with a newline and init apparently thus didn't
recognize it.  Ending the line made everything happy.  I am submitting
this as a (very minor) bug, since I do not believe this to be correct
behavior (but what do I know ;) ...


Tim Daneliuk [EMAIL PROTECTED]
PGP Key: http://www.tundraware.com/PGP/

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Enabling A Serial Port On 6.2

2007-07-08 Thread Lowell Gilbert
Tim Daneliuk [EMAIL PROTECTED] writes:

 But ... the entry did not end with a newline and init apparently thus didn't
 recognize it.  Ending the line made everything happy.  I am submitting
 this as a (very minor) bug, since I do not believe this to be correct
 behavior (but what do I know ;) ...

That's perfectly normal and age-old behaviour.  Part of the definition
of a line of text is that it ends in a newline...
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Enabling A Serial Port On 6.2

2007-07-08 Thread Tim Daneliuk

Lowell Gilbert wrote:

Tim Daneliuk [EMAIL PROTECTED] writes:


But ... the entry did not end with a newline and init apparently thus didn't
recognize it.  Ending the line made everything happy.  I am submitting
this as a (very minor) bug, since I do not believe this to be correct
behavior (but what do I know ;) ...


That's perfectly normal and age-old behaviour.  Part of the definition
of a line of text is that it ends in a newline...


Hmm  - while I acknowledge that I've seen this problem before (I've used
some variant of Unix since the late 1970s and FreeBSD since 2.x), whether
it is perfectly normal is arguable.  I suspect that there are a great
many places - shell scripts and C source code leap to mind - where the
lack of a terminating newline at the end of a file does not cause the
line to be ignored altogether.  I rather think this is an age-old bug
that never got fixed because of its minor importance.  In any case,
i've authored a PR to make note of it.  If I ever get the time, I'll
dig into the source myself and see if I can figure out where the wheels are
coming off...

--

Tim Daneliuk [EMAIL PROTECTED]
PGP Key: http://www.tundraware.com/PGP/

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Enabling A Serial Port On 6.2

2007-07-08 Thread Lowell Gilbert
Tim Daneliuk [EMAIL PROTECTED] writes:

I suspect that there are a great
 many places - shell scripts and C source code leap to mind - where the
 lack of a terminating newline at the end of a file does not cause the
 line to be ignored altogether.

In both of those cases, the relevant standards say that such input is
invalid.  
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Enabling A Serial Port On 6.2

2007-07-07 Thread Tim Daneliuk

System is FreeBSD 6.2-STABLE.

I've added this to /etc/ttys:

  ttyd0   /usr/libexec/getty dial.115200unknown on insecure

And this to gettytabs:

  dial.115200:\
:np:to#30:hw:sp#115200:pp=/etc/ppp/pppserv

But when I 'kill -HUP 1' no getty process on ttyd0 shows up in the ps listing.

dmesg | grep sio yields:

  ioapic0 Version 2.0 irqs 0-23 on motherboard
  acpi_hpet0: High Precision Event Timer iomem 0xfed0-0xfed003ff on acpi0
  usb0: USB revision 1.0
  usb1: USB revision 1.0
  usb2: USB revision 1.0
  usb3: USB revision 1.0
  usb4: EHCI version 1.0
  usb4: USB revision 2.0
  sio0: 16550A-compatible COM port port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0
  sio0: type 16550A
  sio1: configured irq 3 not in bitmap of probed irqs 0
  sio1: port may not be enabled

Looking into /dev, I see:

  crw---  1 root  wheel  -   0,  50 Jul  7 14:46 /dev/ttyd0
  crw---  1 root  wheel  -   0,  51 Jul  7 14:46 /dev/ttyd0.init
  crw---  1 root  wheel  -   0,  52 Jul  7 14:46 /dev/ttyd0.lock


This all used to work swell under 4.x, so what am I missing.  I've got a modem
connected to the port in question and I've tried resetting it and re-initing.
No luck.

Ideas? (And TIA)
--

Tim Daneliuk [EMAIL PROTECTED]
PGP Key: http://www.tundraware.com/PGP/

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]