Date: Sat, 24 Feb 2001 19:31:22 +0100 From: Daniel Rock <D.Rock@t-online.de> Cc: freebsd-current@FreeBSD.ORG Subject: Re: HEADS UP Re: cvs commit: src/sys/alpha/alpha trap.c src/sys/dev/acpica/Osd OsdSchedule.c src/sys/i386/i386 genassym.c swtch.strap.c src/sys/ia64/ia64 trap.c src/sys/kern init_main.c kern_condvar.ckern_idle.c kern_intr.c kern_mib.c kern_mutex.c kern_proc.c ... Message-ID: <3A97FDFA.3291CB26@t-online.de> References: <Pine.BSF.4.21.0102241610230.26598-100000@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Bruce Evans schrieb: > > On Thu, 22 Feb 2001, Daniel Rock wrote: > > > You may have forgotten to also change KINFO_PROC_SIZE in src/sys/user.h > > Yes, rev.1.31 of src/sys/sys/user.h leaves it as an exercise to change > KINFO_PROC_SIZE. I hate doing such exercises, since it will be followed by some nasty other exercises: Clean up your conflicting cvs files... > > WARNING: size of kinfo_proc (648) should be 644!!! > > This is normal if you haven't done the exercise. It is just a warning. This seems to be a "non required" exercise, since even if you fail solving it, your machine continues working... > > BTW What is the purpose of KINFO_PROC_SIZE? Why not simply using sizeof()? > > It is to inhibit changes in the size of the struct. Such changes would > break the interface. The struct must have a certain fixed size (and > layout) for binary compatibility. sizeof() would give the current size, > not necessarily the size that is required for compatibility. But: Since the introduction of KINFO_PROC_SIZE (rev. 1.27(?) of src/sys/sys/user.h) there have been two modifications which still required to rebuild libkvm, ... Maybe many people won't use the spare entries at the end of the structure but put their additions somewhere besides some other related variables for aesthetical purposes? Which value does libkvm use? KINFO_PROC_SIZE or sizeof()? It seems it uses sizeof() since ps/top/w still work besides the warning message. -- Daniel 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?3A97FDFA.3291CB26>