Date: Tue, 3 Sep 2002 14:46:15 -0700 (PDT) From: John Baldwin <jhb@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 17009 for review Message-ID: <200209032146.g83LkFgt099659@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://people.freebsd.org/~peter/p4db/chv.cgi?CH=17009 Change 17009 by jhb@jhb_laptop on 2002/09/03 14:46:04 IFC @17008. Affected files ... .. //depot/projects/smpng/sys/conf/NOTES#22 integrate .. //depot/projects/smpng/sys/kern/imgact_elf.c#18 integrate .. //depot/projects/smpng/sys/kern/kern_descrip.c#35 integrate Differences ... ==== //depot/projects/smpng/sys/conf/NOTES#22 (text+ko) ==== @@ -1,8 +1,9 @@ +# $FreeBSD: src/sys/conf/NOTES,v 1.1071 2002/09/03 19:21:39 jhb Exp $ # # NOTES -- Lines that can be cut/pasted into kernel and hints configs. # # Lines that begin with 'device', 'options', 'machine', 'ident', 'maxusers', -# 'makeoptions', 'hints' etc go into the kernel configuration that you +# 'makeoptions', 'hints', etc. go into the kernel configuration that you # run config(8) with. # # Lines that begin with 'hint.' are NOT for config(8), they go into your @@ -14,7 +15,25 @@ # This file contains machine independent kernel configuration notes. For # machine dependent notes, look in /sys/<arch>/conf/NOTES. # -# $FreeBSD: src/sys/conf/NOTES,v 1.1070 2002/09/02 20:10:18 brooks Exp $ + +# +# NOTES conventions and style guide: +# +# Large block comments should begin and end with a line containing only a +# comment character. +# +# To describe a particular object, a block comment (if it exists) should +# come first. Next should come device, options, and hints lines in that +# order. All device and option lines must be described by a comment that +# doesn't just expand the device or option name. Use only a concise +# comment on the same line if possible. Very detailed descriptions of +# devices and subsystems belong in manpages. +# +# A space followed by a tab separates 'option' from an option name. Two +# spaces followed by a tab separate 'device' from a device name. Comments +# after an option or device should use one space after the comment character. +# To comment out a negative option that disables code and thus should not be +# enabled for LINT builds, precede 'option' with "#!". # # ==== //depot/projects/smpng/sys/kern/imgact_elf.c#18 (text+ko) ==== @@ -27,7 +27,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sys/kern/imgact_elf.c,v 1.124 2002/09/02 17:27:30 dillon Exp $ + * $FreeBSD: src/sys/kern/imgact_elf.c,v 1.125 2002/09/03 21:18:17 peter Exp $ */ #include <sys/param.h> @@ -734,18 +734,20 @@ phdr[i].p_vaddr - seg_addr); /* - * Is this .text or .data? Use VM_PROT_WRITE - * to distinguish between the two for the purpose - * of limit checking and vmspace fields. + * Check whether the entry point is in this segment + * to determine whether to count is as text or data. + * XXX: this needs to be done better! */ - if (prot & VM_PROT_WRITE) { + if (hdr->e_entry >= phdr[i].p_vaddr && + hdr->e_entry < (phdr[i].p_vaddr + + phdr[i].p_memsz)) { + text_size = seg_size; + text_addr = seg_addr; + entry = (u_long)hdr->e_entry; + } else { data_size += seg_size; if (data_addr == 0) data_addr = seg_addr; - } else { - text_size += seg_size; - if (text_addr == 0) - text_addr = seg_addr; } /* @@ -761,13 +763,6 @@ error = ENOMEM; goto fail; } - - /* Does the entry point belong to this segment? */ - if (hdr->e_entry >= phdr[i].p_vaddr && - hdr->e_entry < (phdr[i].p_vaddr + - phdr[i].p_memsz)) { - entry = (u_long)hdr->e_entry; - } break; case PT_PHDR: /* Program header table info */ proghdr = phdr[i].p_vaddr; ==== //depot/projects/smpng/sys/kern/kern_descrip.c#35 (text+ko) ==== @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * @(#)kern_descrip.c 8.6 (Berkeley) 4/19/94 - * $FreeBSD: src/sys/kern/kern_descrip.c,v 1.157 2002/09/02 22:24:14 iedowse Exp $ + * $FreeBSD: src/sys/kern/kern_descrip.c,v 1.158 2002/09/03 20:16:31 jhb Exp $ */ #include "opt_compat.h" To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200209032146.g83LkFgt099659>