Date: Mon, 17 May 1999 12:07:51 +0100 (BST) From: Doug Rabson <dfr@nlsystems.com> To: Poul-Henning Kamp <phk@critter.freebsd.dk> Cc: John Polstra <jdp@polstra.com>, current@freebsd.org Subject: Re: sys/types.h rev. 1.33 breaks ps etc. on alpha Message-ID: <Pine.BSF.4.05.9905171207160.509-100000@herring.nlsystems.com> In-Reply-To: <22167.926938043@critter.freebsd.dk>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 17 May 1999, Poul-Henning Kamp wrote: > In message <Pine.BSF.4.05.9905171142070.509-100000@herring.nlsystems.com>, Doug > Rabson writes: > >On Mon, 17 May 1999, Poul-Henning Kamp wrote: > > > >> In message <Pine.BSF.4.05.9905171113530.509-100000@herring.nlsystems.com>, Doug > >> Rabson writes: > >> >On Mon, 17 May 1999, Poul-Henning Kamp wrote: > >> > > >> >> > >> >> Try it and tell me if it works... > >> > > >> >Not good so far. In my test kernel which defines udev_t as uintptr_t, sh > >> >faults when init tries to go multiuser. > >> > >> I'm worried about the sign extension from 32 to 64 bits... > > > >I haven't been able to diagnose the problem yet but I don't think its sign > >extension since uintptr_t is an unsigned type. > > Lots of places fiddle minor/major in ints... This alternative patch seems to fix things (and its probably more correct). Index: sys/user.h =================================================================== RCS file: /home/ncvs/src/sys/sys/user.h,v retrieving revision 1.20 diff -u -r1.20 user.h --- user.h 1999/01/26 02:38:11 1.20 +++ user.h 1999/05/17 10:55:26 @@ -74,7 +74,7 @@ pid_t e_ppid; /* parent process id */ pid_t e_pgid; /* process group id */ short e_jobc; /* job control counter */ - dev_t e_tdev; /* controlling tty dev */ + udev_t e_tdev; /* controlling tty dev */ pid_t e_tpgid; /* tty process group id */ struct session *e_tsess; /* tty session pointer */ #define WMESGLEN 7 Index: kern/kern_proc.c =================================================================== RCS file: /home/ncvs/src/sys/kern/kern_proc.c,v retrieving revision 1.50 diff -u -r1.50 kern_proc.c --- kern_proc.c 1999/05/11 19:54:29 1.50 +++ kern_proc.c 1999/05/17 10:55:17 @@ -443,7 +443,7 @@ if ((p->p_flag & P_CONTROLT) && (ep->e_sess != NULL) && ((tp = ep->e_sess->s_ttyp) != NULL)) { - ep->e_tdev = tp->t_dev; + ep->e_tdev = dev2udev(tp->t_dev); ep->e_tpgid = tp->t_pgrp ? tp->t_pgrp->pg_id : NO_PID; ep->e_tsess = tp->t_session; } else -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 181 442 9037 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.05.9905171207160.509-100000>