[LinuxPPS] LinuxPPS new functionalities

Rodolfo Giometti giometti at enneenne.com
Fri Feb 19 17:33:11 CET 2010


On Fri, Feb 19, 2010 at 05:21:42PM +0100, Udo van den Heuvel wrote:
> On 2010-02-18 19:37, William S. Brasher wrote:
> > I am using ldattach which comes from util-linux-ng, and it is working well 
> > for me.  I do patch ldattach so that ntpd will start reliably when I boot 
> > the machine; otherwise I have to first start ntpd, kill it, start ldattach 
> > and finally start ntpd.  The patch to ldattach I use is:
> > 
> > --- util-linux-ng-2.17.org/sys-utils/ldattach.c 2009-12-01 03:31:53.000000000 -0600
> > +++ util-linux-ng-2.17/sys-utils/ldattach.c     2010-01-09 16:09:51.000000000 -0600
> > @@ -239,6 +239,10 @@
> >         ts.c_cflag |= (PARENB|PARODD);
> >         break;
> >      }
> > +
> > +    if (ldisc == 18)

Let me suggest here using N_PPS define instead of it's magic
number. :)

> > +        ts.c_iflag |= (IGNBRK|ICRNL);
> > +
> >      ts.c_cflag |= CREAD;       /* just to be on the safe side */
> >      if (tcsetattr(tty_fd, TCSAFLUSH, &ts) < 0)
> >         err(EXIT_FAILURE, _("cannot set terminal attributes for %s"), dev);
> > 
> 
> Thanks!
> If we can confirm this patch makes ldattach work I'll send it to the
> maintainer so it well be added to the ldattach code.
> So please test!

Thanks,

Rodolfo

-- 

GNU/Linux Solutions                  e-mail: giometti at enneenne.com
Linux Device Driver                          giometti at linux.it
Embedded Systems                     phone:  +39 349 2432127
UNIX programming                     skype:  rodolfo.giometti
Freelance ICT Italia - Consulente ICT Italia - www.consulenti-ict.it



More information about the LinuxPPS mailing list