From owner-freebsd-arch Sun Mar 16 5:32:40 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 826DD37B401; Sun, 16 Mar 2003 05:32:39 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 51E0F43F3F; Sun, 16 Mar 2003 05:32:38 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 0DD945308; Sun, 16 Mar 2003 14:32:37 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: arch@freebsd.org Cc: Maxime Henrion Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Sun, 16 Mar 2003 14:32:36 +0100 In-Reply-To: <20030316062315.GA75492@dragon.nuxi.com> ("David O'Brien"'s message of "Sat, 15 Mar 2003 22:23:15 -0800") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "David O'Brien" writes: > I am all for this change of making our C standard level C99. > Do you think we should do this for lower WARNS than 6? As far as > warnings go, -ansi (aka, -std=c89) is responsable for all the 'long long' > warnings and that is why it was done at WARNS==6. Since that will go > away, maybe we should turn on -std= at a lower WARNS. Hmm, I think it should be a separate knob. We can merge it into WARNS later, but for now, we should just remove -ansi / -pedantic from WARNS, and add a CSTD knob which can be either c89 or c99. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 5:52: 9 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 50A6037B401; Sun, 16 Mar 2003 05:52:07 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 98A5943F93; Sun, 16 Mar 2003 05:52:06 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 399EA5308; Sun, 16 Mar 2003 14:52:03 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: arch@freebsd.org Cc: Maxime Henrion Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Sun, 16 Mar 2003 14:52:02 +0100 In-Reply-To: (des@ofug.org's message of "Sun, 16 Mar 2003 14:32:36 +0100") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --=-=-= Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable des@ofug.org (Dag-Erling Sm=F8rgrav) writes: > Hmm, I think it should be a separate knob. We can merge it into WARNS > later, but for now, we should just remove -ansi / -pedantic from > WARNS, and add a CSTD knob which can be either c89 or c99. See the attached patch. DES --=20 Dag-Erling Smorgrav - des@ofug.org --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=cstd.diff Index: bsd.sys.mk =================================================================== RCS file: /home/ncvs/src/share/mk/bsd.sys.mk,v retrieving revision 1.11 diff -u -r1.11 bsd.sys.mk --- bsd.sys.mk 13 Nov 2002 13:49:29 -0000 1.11 +++ bsd.sys.mk 16 Mar 2003 13:39:28 -0000 @@ -9,6 +9,17 @@ # for GCC: http://gcc.gnu.org/onlinedocs/gcc-3.0.4/gcc_3.html#IDX143 .if !defined(NO_WARNS) +. if defined(CSTD) +. if ${CSTD} == "K&R" +CFLAGS += -traditional +. elsif ${CSTD} == "c89" || ${CSTD} == "c90" +CFLAGS += -std=iso9899:1990 +. elsif ${CSTD} == "c94" || ${CSTD} == "c95" +CFLAGS += -std=iso9899:199409 +. elsif ${CSTD} == "c99" +CFLAGS += -std=iso9899:1999 +. endif +. endif . if defined(WARNS) . if ${WARNS} > 0 . if !defined(NO_WERROR) @@ -19,17 +30,20 @@ CFLAGS += -Wall -Wno-format-y2k . endif . if ${WARNS} > 2 -CFLAGS += -W -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith +CFLAGS += -W -Wstrict-prototypes -Wmissing-prototypes \ + -Wpointer-arith . endif . if ${WARNS} > 3 -CFLAGS += -Wreturn-type -Wcast-qual -Wwrite-strings -Wswitch -Wshadow -Wcast-align +CFLAGS += -Wreturn-type -Wcast-qual -Wwrite-strings -Wswitch \ + -Wshadow -Wcast-align . endif . if ${WARNS} > 4 CFLAGS += -Wuninitialized . endif # BDECFLAGS . if ${WARNS} > 5 -CFLAGS += -ansi -pedantic -Wbad-function-cast -Wchar-subscripts -Winline -Wnested-externs -Wredundant-decls +CFLAGS += -pedantic -Wbad-function-cast -Wchar-subscripts \ + -Winline -Wnested-externs -Wredundant-decls . endif . if ${WARNS} > 1 && ${WARNS} < 5 # XXX Delete -Wuninitialized by default for now -- the compiler doesn't @@ -43,7 +57,8 @@ . endif . if defined(WFORMAT) . if ${WFORMAT} > 0 -#CFLAGS += -Wformat-nonliteral -Wformat-security -Wno-format-extra-args +#CFLAGS += -Wformat-nonliteral -Wformat-security \ +# -Wno-format-extra-args CFLAGS += -Wformat=2 -Wno-format-extra-args . if !defined(NO_WERROR) CFLAGS += -Werror --=-=-=-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 7:58:23 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 938D137B401; Sun, 16 Mar 2003 07:58:22 -0800 (PST) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id 09AB243F75; Sun, 16 Mar 2003 07:58:21 -0800 (PST) (envelope-from bde@zeta.org.au) Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id CAA15350; Mon, 17 Mar 2003 02:58:14 +1100 Date: Mon, 17 Mar 2003 02:58:13 +1100 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?= Cc: arch@FreeBSD.ORG, Maxime Henrion Subject: Re: WARNS=6 changes In-Reply-To: Message-ID: <20030317025513.I14238@gamplex.bde.org> References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=X-UNKNOWN Content-Transfer-Encoding: QUOTED-PRINTABLE Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, 16 Mar 2003, Dag-Erling [iso-8859-1] Sm=F8rgrav wrote: > "David O'Brien" writes: > > I am all for this change of making our C standard level C99. > > Do you think we should do this for lower WARNS than 6? As far as > > warnings go, -ansi (aka, -std=3Dc89) is responsable for all the 'long l= ong' > > warnings and that is why it was done at WARNS=3D=3D6. Since that will = go > > away, maybe we should turn on -std=3D at a lower WARNS. > > Hmm, I think it should be a separate knob. We can merge it into WARNS > later, but for now, we should just remove -ansi / -pedantic from > WARNS, and add a CSTD knob which can be either c89 or c99. -ansi -pedantic is required to give a C compiler (C90). Without it you don't even get warnings about errors, so it should be the first warning level. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 8:13:48 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1EA5537B401; Sun, 16 Mar 2003 08:13:47 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6E08643F93; Sun, 16 Mar 2003 08:13:46 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id CABED5308; Sun, 16 Mar 2003 17:13:44 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Bruce Evans Cc: arch@FreeBSD.ORG, Maxime Henrion Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Sun, 16 Mar 2003 17:13:43 +0100 In-Reply-To: <20030317025513.I14238@gamplex.bde.org> (Bruce Evans's message of "Mon, 17 Mar 2003 02:58:13 +1100 (EST)") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030317025513.I14238@gamplex.bde.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans writes: > -ansi -pedantic is required to give a C compiler (C90). Without it you > don't even get warnings about errors, so it should be the first warning > level. My patch adds -std=whatever to CFLAGS independent of WARNS level as long as CSTD is defined. It removes -ansi but leaves -pedantic (at WARNS level 4 or 5 I think). DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 8:30:28 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1AD5737B401 for ; Sun, 16 Mar 2003 08:30:27 -0800 (PST) Received: from net2.dinoex.sub.org (net2.dinoex.sub.org [212.184.201.182]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6525943FB1 for ; Sun, 16 Mar 2003 08:30:22 -0800 (PST) (envelope-from dirk.meyer@dinoex.sub.org) Received: from net2.dinoex.sub.org (dinoex@net2.dinoex.de [212.184.201.182]) by net2.dinoex.sub.org (8.12.8/8.12.8) with ESMTP id h2GGU9mo019551 for ; Sun, 16 Mar 2003 17:30:12 +0100 (CET) (envelope-from dirk.meyer@dinoex.sub.org) X-MDaemon-Deliver-To: X-Authentication-Warning: net2.dinoex.sub.org: Host dinoex@net2.dinoex.de [212.184.201.182] claimed to be net2.dinoex.sub.org Received: from gate.dinoex.sub.org (dinoex@localhost) by net2.dinoex.sub.org (8.12.8/8.12.8/Submit) with BSMTP id h2GGU7nm019537 for ; Sun, 16 Mar 2003 17:30:07 +0100 (CET) (envelope-from dirk.meyer@dinoex.sub.org) To: freebsd-arch@FreeBSD.ORG Message-ID: <9m1dspTDm5@dmeyer.dinoex.sub.org> From: dirk.meyer@dinoex.sub.org (Dirk Meyer) Organization: privat Subject: Re: WARNS=6 changes Date: Sun, 16 Mar 2003 17:28:52 +0100 X-Mailer: Dinoex 1.79 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030317025513.I14238@gamplex.bde.org> X-Gateway: ZCONNECT gate.dinoex.sub.org [UNIX/Connect 0.94] X-Accept-Language: de,en X-PGP-Fingerprint: 44 16 EC 0A D3 3A 4F 28 8A 8A 47 93 F1 CF 2F 12 X-Noad: Please don't send me ad's by mail. I'm bored by this type of mail. X-Copyright: (C) Copyright 2001 by Dirk Meyer -- All rights reserved. X-Note: sending SPAM is a violation of both german and US law and will at least trigger a complaint at your provider's postmaster. X-PGP-Key-Avail: mailto:pgp-public-keys@keys.de.pgp.net Subject:GET 0x331CDA5D X-No-Archive: yes X-ZC-VIA: 20030316000000W+1@dinoex.sub.org Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Bruce Evans schrieb:, > -ansi -pedantic is required to give a C compiler (C90). Without it you > don't even get warnings about errors, so it should be the first warning > level. Carefull, -ansi may create incomatible binaries, It does at least so in stable, C++ ABI behaves diffrent here. I use with success here /etc/make.conf WARN= -W -Wall -Waggregate-return -Wbad-function-cast -Wcast-align -Wcast-qual -Wchar-subscripts -Wcomment -Wconversion -Wformat -Wimplicit -Wimplicit-function-delcaration -Wimplicit-int -Wlong-long -Wmain -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wno-import -Wno-parentheses -Wparentheses -Wpointer-arith -Wredundant-decls -Wreturn-type -Wshadow -Wsign-compare -Wstrict-prototypes -Wswitch -Wtraditional -Wtrigraphs -Wunused -Wwrite-strings PEDANTIC= -Winline -pedantic -Wuninitialized CFLAGS+=${WARN} NO_WERROR= yes kind regards Dirk - Dirk Meyer, Im Grund 4, 34317 Habichtswald, Germany - [dirk.meyer@dinoex.sub.org],[dirk.meyer@guug.de],[dinoex@FreeBSD.org] To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 12:36:57 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 622FD37B401 for ; Sun, 16 Mar 2003 12:36:56 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 309CE43FAF for ; Sun, 16 Mar 2003 12:36:55 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.8/8.12.8) with ESMTP id h2GKaqDs009358 for ; Sun, 16 Mar 2003 21:36:53 +0100 (CET) (envelope-from phk@phk.freebsd.dk) To: arch@freebsd.org Subject: memcpy() with specified direction of copying ? From: Poul-Henning Kamp Date: Sun, 16 Mar 2003 21:36:52 +0100 Message-ID: <9357.1047847012@critter.freebsd.dk> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Is there any standard which has provided an api for mandating the direction of copying from a memcpy() like function ? As I read our man-page, there is no way to know of memcpy() copies from the start and forward or from the end and backward through the two areas. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 12:52:20 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F0EF437B401 for ; Sun, 16 Mar 2003 12:52:19 -0800 (PST) Received: from goliath.cnchost.com (goliath.cnchost.com [207.155.252.47]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6266E43FB1 for ; Sun, 16 Mar 2003 12:52:19 -0800 (PST) (envelope-from bakul@bitblocks.com) Received: from bitblocks.com (adsl-209-204-185-216.sonic.net [209.204.185.216]) by goliath.cnchost.com id PAA05328; Sun, 16 Mar 2003 15:52:10 -0500 (EST) [ConcentricHost SMTP Relay 1.15] Message-ID: <200303162052.PAA05328@goliath.cnchost.com> To: Poul-Henning Kamp Cc: arch@FreeBSD.ORG Subject: Re: memcpy() with specified direction of copying ? In-reply-to: Your message of "Sun, 16 Mar 2003 21:36:52 +0100." <9357.1047847012@critter.freebsd.dk> Date: Sun, 16 Mar 2003 12:52:10 -0800 From: Bakul Shah Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > Is there any standard which has provided an api for mandating the > direction of copying from a memcpy() like function ? > > As I read our man-page, there is no way to know of memcpy() copies > from the start and forward or from the end and backward through the > two areas. The direction is not even relevant for memcpy and if the source and destination overlap, the behavior is undefined. Use memmove() for overlapped src and dst, but if you want the direction reversed for some other reason you're on your own. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 13: 0:12 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8558037B401 for ; Sun, 16 Mar 2003 13:00:11 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9475643F93 for ; Sun, 16 Mar 2003 13:00:10 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.8/8.12.8) with ESMTP id h2GL05Ds009532; Sun, 16 Mar 2003 22:00:06 +0100 (CET) (envelope-from phk@phk.freebsd.dk) To: Bakul Shah Cc: arch@FreeBSD.ORG Subject: Re: memcpy() with specified direction of copying ? From: "Poul-Henning Kamp" In-Reply-To: Your message of "Sun, 16 Mar 2003 12:52:10 PST." <200303162052.PAA05328@goliath.cnchost.com> Date: Sun, 16 Mar 2003 22:00:05 +0100 Message-ID: <9531.1047848405@critter.freebsd.dk> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <200303162052.PAA05328@goliath.cnchost.com>, Bakul Shah writes: >> Is there any standard which has provided an api for mandating the >> direction of copying from a memcpy() like function ? >> >> As I read our man-page, there is no way to know of memcpy() copies >> from the start and forward or from the end and backward through the >> two areas. > >The direction is not even relevant for memcpy and if the >source and destination overlap, the behavior is undefined. >Use memmove() for overlapped src and dst, but if you want the >direction reversed for some other reason you're on your own. Well, in my case it is a matter of shared memory where the order in which I snapshot a data structure is critical for detecting integrity issues. I'll roll my own. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 15:45: 9 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0EB6937B401 for ; Sun, 16 Mar 2003 15:45:08 -0800 (PST) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5274943F3F for ; Sun, 16 Mar 2003 15:45:07 -0800 (PST) (envelope-from mux@freebsd.org) Received: by elvis.mu.org (Postfix, from userid 1920) id 2FA4F2ED407; Sun, 16 Mar 2003 15:45:07 -0800 (PST) Date: Mon, 17 Mar 2003 00:45:07 +0100 From: Maxime Henrion To: Dag-Erling Sm?rgrav Cc: arch@freebsd.org Subject: Re: WARNS=6 changes Message-ID: <20030316234507.GK3819@elvis.mu.org> References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Dag-Erling Sm?rgrav wrote: > des@ofug.org (Dag-Erling Sm?rgrav) writes: > > Hmm, I think it should be a separate knob. We can merge it into WARNS > > later, but for now, we should just remove -ansi / -pedantic from > > WARNS, and add a CSTD knob which can be either c89 or c99. > > See the attached patch. I don't like it. I don't want yet another knob to be added in every damn Makefile in the tree. We should warn by default for these things. Since we adopted GCC3 and often use C99 features these days, it seems clear C99 should be the default standard for warnings. We may need to disable these warnings, but it should be exceptional cases only. We may need to use another C standard for the warnings, but it should be exceptional cases only. With the patch I provided, we can handle these exceptional cases, by lowering the WARNS level for the first case, and by using the WSTD variable for the second case. We also have useful and meaningful default setting, se we don't need to go add another knob in every Makefile when we want to enable warnings about C standard errors. I agree with Bruce when he says that we should even enable these warnings at WARNS=1, which again goes to show that not checking standard warnings by default and requiring a knob to be set for it is a bad idea. Cheers, Maxime To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 15:58:24 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DD38F37B401; Sun, 16 Mar 2003 15:58:22 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2067343F93; Sun, 16 Mar 2003 15:58:22 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id AF5EA5308; Mon, 17 Mar 2003 00:58:20 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Maxime Henrion Cc: arch@freebsd.org Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Mon, 17 Mar 2003 00:58:19 +0100 In-Reply-To: <20030316234507.GK3819@elvis.mu.org> (Maxime Henrion's message of "Mon, 17 Mar 2003 00:45:07 +0100") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030316234507.GK3819@elvis.mu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Maxime Henrion writes: > I don't like it. I don't want yet another knob to be added in every > damn Makefile in the tree. We should warn by default for these things. > Since we adopted GCC3 and often use C99 features these days, it seems > clear C99 should be the default standard for warnings. So put 'CSTD?=c99' in /etc/make.conf and let those of us who are more interested in parking our bikes than in admiring the paint job get on with our lives. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 16:11: 3 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CE99C37B404 for ; Sun, 16 Mar 2003 16:11:01 -0800 (PST) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id BAA8543FA3 for ; Sun, 16 Mar 2003 16:11:00 -0800 (PST) (envelope-from mux@freebsd.org) Received: by elvis.mu.org (Postfix, from userid 1920) id 945792ED3F0; Sun, 16 Mar 2003 16:11:00 -0800 (PST) Date: Mon, 17 Mar 2003 01:11:00 +0100 From: Maxime Henrion To: Dag-Erling Sm?rgrav Cc: arch@freebsd.org Subject: Re: WARNS=6 changes Message-ID: <20030317001100.GM3819@elvis.mu.org> References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030316234507.GK3819@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Dag-Erling Sm?rgrav wrote: > Maxime Henrion writes: > > I don't like it. I don't want yet another knob to be added in every > > damn Makefile in the tree. We should warn by default for these things. > > Since we adopted GCC3 and often use C99 features these days, it seems > > clear C99 should be the default standard for warnings. > > So put 'CSTD?=c99' in /etc/make.conf and let those of us who are more > interested in parking our bikes than in admiring the paint job get on > with our lives. If you really want to see the job done fast, you could have let me commit the patch I posted on arch@ to begin with. Alternately, you could show me how your patch does things better than mine, and how the issues Bruce and I raised are wrong. I'm always open to comments and suggestions, and am ready to change my mind. Being disrespectful and harsh isn't going to get us anywhere, and it's inappropriate, especially since this is a public forum. Cheers, Maxime To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 16:21:37 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4C33837B401 for ; Sun, 16 Mar 2003 16:21:36 -0800 (PST) Received: from dragon.nuxi.com (trang.nuxi.com [66.93.134.19]) by mx1.FreeBSD.org (Postfix) with ESMTP id 88BC143FB1 for ; Sun, 16 Mar 2003 16:21:35 -0800 (PST) (envelope-from obrien@NUXI.com) Received: from dragon.nuxi.com (smmsp@localhost [127.0.0.1]) by dragon.nuxi.com (8.12.7/8.12.7) with ESMTP id h2H0LZFU079699; Sun, 16 Mar 2003 16:21:35 -0800 (PST) (envelope-from obrien@dragon.nuxi.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.12.7/8.12.7/Submit) id h2H0LYK9079698; Sun, 16 Mar 2003 16:21:34 -0800 (PST) Date: Sun, 16 Mar 2003 16:21:34 -0800 From: "David O'Brien" To: Dag-Erling Sm?rgrav Cc: arch@freebsd.org Subject: Re: WARNS=6 changes Message-ID: <20030317002134.GA79649@dragon.nuxi.com> Reply-To: arch@freebsd.org Mail-Followup-To: David O'Brien , Dag-Erling Sm?rgrav , arch@freebsd.org References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD Group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sun, Mar 16, 2003 at 02:52:02PM +0100, Dag-Erling Sm?rgrav wrote: > des@ofug.org (Dag-Erling Sm?rgrav) writes: > > Hmm, I think it should be a separate knob. We can merge it into WARNS > > later, but for now, we should just remove -ansi / -pedantic from > > WARNS, and add a CSTD knob which can be either c89 or c99. > > See the attached patch. This is just getting too convoluated. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 16:29:58 2003 Delivered-To: freebsd-arch@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 664) id 1E27D37B401; Sun, 16 Mar 2003 16:29:57 -0800 (PST) Date: Sun, 16 Mar 2003 16:29:57 -0800 From: David O'Brien To: Bruce Evans Cc: arch@FreeBSD.ORG Subject: Re: WARNS=6 changes Message-ID: <20030316162956.A78205@hub.freebsd.org> Reply-To: arch@freebsd.org References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030317025513.I14238@gamplex.bde.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <20030317025513.I14238@gamplex.bde.org>; from bde@zeta.org.au on Mon, Mar 17, 2003 at 02:58:13AM +1100 X-Operating-System: FreeBSD 4.8-RC Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Mar 17, 2003 at 02:58:13AM +1100, Bruce Evans wrote: > -ansi -pedantic is required to give a C compiler (C90). Without it you > don't even get warnings about errors, so it should be the first warning > level. I purposefully make WARNS=1 be only -Wall as that is all most people outside of FreeBSD use. Setting the standard (for the purpose of warnings) sounds like a fine thing to do at WARNS=2 and above. After reading RU's opinion that WARNS=X to be a constant set of warning options, no variable portion, I have to agree. -- -- David (obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 16:52: 9 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A5B0237B401; Sun, 16 Mar 2003 16:52:07 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id E053443FAF; Sun, 16 Mar 2003 16:52:06 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 661A75309; Mon, 17 Mar 2003 01:52:05 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Maxime Henrion Cc: arch@freebsd.org Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Mon, 17 Mar 2003 01:52:04 +0100 In-Reply-To: <20030317001100.GM3819@elvis.mu.org> (Maxime Henrion's message of "Mon, 17 Mar 2003 01:11:00 +0100") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030316234507.GK3819@elvis.mu.org> <20030317001100.GM3819@elvis.mu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Maxime Henrion writes: > If you really want to see the job done fast, you could have let me > commit the patch I posted on arch@ to begin with. Alternately, you > could show me how your patch does things better than mine, and how the > issues Bruce and I raised are wrong. Bruce wants a solution where time stopped in late 1989 or early 1990. You want a solution which will break everything that isn't c99-ready yet. I suggested a solution which will allow those parts of the tree which we know are safe to take advantage of GCC's c99 support without breaking the rest of the tree. This is generally known as "mechanism, not policy". I don't suppose you've tried to build world with -std=c99 in CFLAGS? I have. It doesn't work. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 16:56: 3 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6994937B404 for ; Sun, 16 Mar 2003 16:56:02 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6D71643FA3 for ; Sun, 16 Mar 2003 16:56:01 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 1D5575309; Mon, 17 Mar 2003 01:56:00 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: arch@freebsd.org Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Mon, 17 Mar 2003 01:55:59 +0100 In-Reply-To: <20030317002134.GA79649@dragon.nuxi.com> ("David O'Brien"'s message of "Sun, 16 Mar 2003 16:21:34 -0800") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030317002134.GA79649@dragon.nuxi.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "David O'Brien" writes: > On Sun, Mar 16, 2003 at 02:52:02PM +0100, Dag-Erling Sm?rgrav wrote: > > See the attached patch. > This is just getting too convoluated. I don't see what's convoluted about it. In fact, I don't see how much simpler it could get (except for accepting only one name for each version of the standard) and still be consistent, because gcc doesn't have short names for all versions of the C standard, and the -std option doesn't work for K&R, so you can't just do -std=${CSTD}. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 16:57:40 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1F63537B401 for ; Sun, 16 Mar 2003 16:57:39 -0800 (PST) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6C7CD43FBD for ; Sun, 16 Mar 2003 16:57:38 -0800 (PST) (envelope-from mux@freebsd.org) Received: by elvis.mu.org (Postfix, from userid 1920) id 4B43E2ED407; Sun, 16 Mar 2003 16:57:38 -0800 (PST) Date: Mon, 17 Mar 2003 01:57:38 +0100 From: Maxime Henrion To: Dag-Erling Sm?rgrav Cc: arch@freebsd.org Subject: Re: WARNS=6 changes Message-ID: <20030317005738.GN3819@elvis.mu.org> References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030316234507.GK3819@elvis.mu.org> <20030317001100.GM3819@elvis.mu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Dag-Erling Sm?rgrav wrote: > Maxime Henrion writes: > > If you really want to see the job done fast, you could have let me > > commit the patch I posted on arch@ to begin with. Alternately, you > > could show me how your patch does things better than mine, and how the > > issues Bruce and I raised are wrong. > > Bruce wants a solution where time stopped in late 1989 or early 1990. > You want a solution which will break everything that isn't c99-ready > yet. I suggested a solution which will allow those parts of the tree > which we know are safe to take advantage of GCC's c99 support without > breaking the rest of the tree. This is generally known as "mechanism, > not policy". > > I don't suppose you've tried to build world with -std=c99 in CFLAGS? > I have. It doesn't work. You must have not read my patch correctly. The only difference it causes is for WARNS=6 programs. It does not break the tree at all, and I do have tested it. Cheers, Maxime To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 17: 7: 6 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3ED7E37B401; Sun, 16 Mar 2003 17:07:05 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 05A4643FCB; Sun, 16 Mar 2003 17:07:04 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 88E6F5308; Mon, 17 Mar 2003 02:07:02 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: Maxime Henrion Cc: arch@freebsd.org Subject: Re: WARNS=6 changes From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Mon, 17 Mar 2003 02:07:02 +0100 In-Reply-To: <20030317005738.GN3819@elvis.mu.org> (Maxime Henrion's message of "Mon, 17 Mar 2003 01:57:38 +0100") Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 References: <20030313192045.GG3819@elvis.mu.org> <20030316062315.GA75492@dragon.nuxi.com> <20030316234507.GK3819@elvis.mu.org> <20030317001100.GM3819@elvis.mu.org> <20030317005738.GN3819@elvis.mu.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Maxime Henrion writes: > You must have not read my patch correctly. The only difference it > causes is for WARNS=6 programs. It does not break the tree at all, > and I do have tested it. If it only sets -std for WARNS=6, it's useless, because most of our tree does not and will never build at WARNS level 6. In the meantime, the parts of our tree which would build fine at WARNS level 5 if only the "C89 does not support long long" warnings would go away are still out in the cold. DES -- Dag-Erling Smorgrav - des@ofug.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 17:19:19 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1B07137B401 for ; Sun, 16 Mar 2003 17:19:18 -0800 (PST) Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id F016A43FAF for ; Sun, 16 Mar 2003 17:19:16 -0800 (PST) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.12.8/8.12.3) with ESMTP id h2H1JBA7015648; Sun, 16 Mar 2003 18:19:14 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Sun, 16 Mar 2003 18:17:52 -0700 (MST) Message-Id: <20030316.181752.16867058.imp@bsdimp.com> To: phk@phk.freebsd.dk Cc: arch@FreeBSD.ORG Subject: Re: memcpy() with specified direction of copying ? From: "M. Warner Losh" In-Reply-To: <9357.1047847012@critter.freebsd.dk> References: <9357.1047847012@critter.freebsd.dk> X-Mailer: Mew version 2.1 on Emacs 21.2 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <9357.1047847012@critter.freebsd.dk> Poul-Henning Kamp writes: : : Is there any standard which has provided an api for mandating the : direction of copying from a memcpy() like function ? : : As I read our man-page, there is no way to know of memcpy() copies : from the start and forward or from the end and backward through the : two areas. memcpy is not defined when overlapping strings are concerned. It is allowed to screw them up in whatever ways are a side effect of the fastest way to copy memory is. memmove is well defined here. It is slower, but guaranteed to work on overlapping strings. A string here is a hunk of memory, not a 'C' string. [#2] The memcpy function copies n characters from the object pointed to by s2 into the object pointed to by s1. If copying takes place between objects that overlap, the behavior is undefined. [#2] The memmove function copies n characters from the object pointed to by s2 into the object pointed to by s1. Copying takes place as if the n characters from the object pointed to by s2 are first copied into a temporary array of n characters that does not overlap the objects pointed to by s1 and s2, and then the n characters from the temporary array are copied into the object pointed to by s1. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 21:58:50 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 344A737B401 for ; Sun, 16 Mar 2003 21:58:48 -0800 (PST) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 10D7343F85 for ; Sun, 16 Mar 2003 21:58:47 -0800 (PST) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.8/8.12.8) with SMTP id h2H5wijK060140 for ; Mon, 17 Mar 2003 00:58:44 -0500 (EST) (envelope-from robert@fledge.watson.org) Date: Mon, 17 Mar 2003 00:58:44 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org To: arch@FreeBSD.org Subject: sizeof(void *)!=sizeof(vm_paddr_t) Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I just committed a new column to our increasingly complicated driver status table on the web site. This column is intended to capture whether or not drivers are able to handle (both compile and run properly in) an environment where the assumption that a physical memory address can be stored in a variable of a pointer type. Intel PAE support will operate only with drivers that meet this assumption. If driver developers could review the table at http://www.FreeBSD.org/projects/busdma/ to make sure their driver is accurately characterized from the perspective of the current criteria: busdma, INTR_MPSAFE, SMPng locked, and p!=a safety. In addition, if your driver is not safe on one or more of these counts, fixing it prior to 5.1-RELEASE would be a very good idea. Drivers not adapted for these requirements will perform less well than drivers that are adapted, run on few hardware architectures, and may not run with large memory systems. I've set the "default" for p!=a safety to "New", but I suspect a moderate number of drivers are already safe from this regard (including syscons, ata, ...) Thanks, Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories ---------- Forwarded message ---------- Date: Sun, 16 Mar 2003 21:44:30 -0800 (PST) From: Robert Watson To: doc-committers@FreeBSD.org, cvs-doc@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: www/en/projects/busdma index.sgml rwatson 2003/03/16 21:44:30 PST FreeBSD doc repository Modified files: en/projects/busdma index.sgml Log: Add a new driver status column to indicate whether the driver can safely handle sizeof(void *) != sizeof(vm_paddr_t) or != sizeof(bus_addr_t). In order for drivers to be supported with PAE, they must be able to handle this, including avoiding casting of physical addresses to pointers for printfs, pointer arithmetic, etc. Thought reasonable by: jake Revision Changes Path 1.50 +88 -0 www/en/projects/busdma/index.sgml To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sun Mar 16 22: 5:24 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E271337B401; Sun, 16 Mar 2003 22:05:21 -0800 (PST) Received: from k6.locore.ca (k6.locore.ca [198.96.117.170]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B72E43FBF; Sun, 16 Mar 2003 22:05:18 -0800 (PST) (envelope-from jake@k6.locore.ca) Received: from k6.locore.ca (localhost.locore.ca [127.0.0.1]) by k6.locore.ca (8.12.8/8.12.8) with ESMTP id h2H69oxS076486; Mon, 17 Mar 2003 01:09:50 -0500 (EST) (envelope-from jake@k6.locore.ca) Received: (from jake@localhost) by k6.locore.ca (8.12.8/8.12.8/Submit) id h2H69oop076485; Mon, 17 Mar 2003 01:09:50 -0500 (EST) Date: Mon, 17 Mar 2003 01:09:49 -0500 From: Jake Burkholder To: Robert Watson Cc: arch@FreeBSD.ORG Subject: Re: sizeof(void *)!=sizeof(vm_paddr_t) Message-ID: <20030317010949.A76446@locore.ca> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from rwatson@FreeBSD.ORG on Mon, Mar 17, 2003 at 12:58:44AM -0500 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Apparently, On Mon, Mar 17, 2003 at 12:58:44AM -0500, Robert Watson said words to the effect of; > > I just committed a new column to our increasingly complicated driver > status table on the web site. This column is intended to capture whether > or not drivers are able to handle (both compile and run properly in) an > environment where the assumption that a physical memory address can be > stored in a variable of a pointer type. Intel PAE support will operate > only with drivers that meet this assumption. If driver developers could > review the table at > > http://www.FreeBSD.org/projects/busdma/ > > to make sure their driver is accurately characterized from the perspective > of the current criteria: busdma, INTR_MPSAFE, SMPng locked, and p!=a > safety. In addition, if your driver is not safe on one or more of these > counts, fixing it prior to 5.1-RELEASE would be a very good idea. Drivers > not adapted for these requirements will perform less well than drivers > that are adapted, run on few hardware architectures, and may not run with > large memory systems. I've set the "default" for p!=a safety to "New", > but I suspect a moderate number of drivers are already safe from this > regard (including syscons, ata, ...) Note that vm_paddr_t doesn't actually exist yet, but it will soon; vm_offset_t can be more or less substituted. The point is to always use an arithmetic type for physical or bus addresses, not a pointer type. In general the only portable way to print these things is with the %j modifier and to cast to uintmax_t. Jake > > Thanks, > > Robert N M Watson FreeBSD Core Team, TrustedBSD Projects > robert@fledge.watson.org Network Associates Laboratories > > ---------- Forwarded message ---------- > Date: Sun, 16 Mar 2003 21:44:30 -0800 (PST) > From: Robert Watson > To: doc-committers@FreeBSD.org, cvs-doc@FreeBSD.org, cvs-all@FreeBSD.org > Subject: cvs commit: www/en/projects/busdma index.sgml > > rwatson 2003/03/16 21:44:30 PST > > FreeBSD doc repository > > Modified files: > en/projects/busdma index.sgml > Log: > Add a new driver status column to indicate whether the driver can > safely handle sizeof(void *) != sizeof(vm_paddr_t) or != > sizeof(bus_addr_t). In order for drivers to be supported with PAE, > they must be able to handle this, including avoiding casting of > physical addresses to pointers for printfs, pointer arithmetic, > etc. > > Thought reasonable by: jake > > Revision Changes Path > 1.50 +88 -0 www/en/projects/busdma/index.sgml > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-arch" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Mar 17 7: 4:13 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F340637B401; Mon, 17 Mar 2003 07:04:09 -0800 (PST) Received: from mailgw.cscoms.com (mailgw.cscoms.com [202.183.255.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4BD8543F75; Mon, 17 Mar 2003 07:04:08 -0800 (PST) (envelope-from job2546@thaimail.com) Received: from cscoms.com (mail.cscoms.com [202.183.255.23]) by mailgw.cscoms.com (8.12.8/8.12.3) with ESMTP id h2HF1pil061565; Mon, 17 Mar 2003 22:01:52 +0700 (ICT) Received: from ME (dial-144.ras-21.bkk.c.cscoms.com [203.170.145.144]) by cscoms.com (8.12.8/8.12.3) with SMTP id h2HEpswo024876; Mon, 17 Mar 2003 21:51:56 +0700 (GMT) Date: Mon, 17 Mar 2003 21:51:54 +0700 (GMT) Message-Id: <200303171451.h2HEpswo024876@cscoms.com> From: job2546@thaimail.com Subject: "ถ้าคุณยังทำสิ่งที่คุณทำอยู่วันนี้ พรุ่งนี้ก็จะเหมือนวันนี้ X-Priority: 1 (Highest) Reply-To: job2546@thaimail.com X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" X-Virus-Scanned: by amavisd-milter (http://amavis.org/) To: undisclosed-recipients: ; Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit "หากคุณล้มเหลวที่จะวางแผน ย่อมแปลว่าคุณวางแผนที่จะล้มเหลว" จิม โรห์น นักปรัชญาอันดับ 1 ของโลก เช่น คุณคิดว่าในชีวิตนี้เราคงไม่มีทางรวย คุณก็ไจะไม่มีทางรวยเลย หรือ "คุณคิดว่าสักวันถึงฉันต้องรวยแน่ๆ" จิม โรห์น บอกว่า "ถ้าคุณยังทำสิ่งที่คุณทำอยู่ทุกวันนี้ อีก 3 ปีข้างหน้าลองคิดดูว่า คุณจะมีโอกาสรวยได้หรือไม่" "ถ้าคำตอบคือ ใช่ คุณกำลังจะรวย" ก็ยินดีกับคุณด้วยครับคุณกำลังจะรวยแล้ว "แต่ถ้าคำตอบคือ ไม่ คุณไม่สามารถรวยได้" คุณต้องเปลี่ยนอะไรสักอย่างในชีวิตคุณแล้ว จิม โรห์น บอกอีกว่า "ถ้าคุณยังทำสิ่งที่คุณทำอยู่วันนี้ พรุ่งนี้ก็จะเหมือนวันนี้ ไปเรื่อยๆไม่มีที่สิ้นสุด" หมายความว่า -ถ้าวันนี้คุณยังต้องวิ่งหาเงิน จ่ายหนี้ต่างๆ -ถ้าวันนี้คุณยังถูกเจ้านายกดขี่ ใช้งานอย่างหนัก -ถ้าวันนี้คุณยังหาทางออกไม่ได้ ลองเปิดโอกาสให้ตัวเองดู เปิดใจของคุณให้กว้างแล้วเดินตามเรามาหรือปล่อยให้โอกาสนี้หลุดลอยไป ============================================================ คุณสามารถเข้าไปดูรายละเอียดเพิ่มเติมและกรอกข้อมูลเพื่อขอรับข้อมูลเบื้องต้นฟรี ! ได้ที่ http://www.geocities.com/thaigetrich/easywork ============================================================ ขออภัยหากข้อความนี้ถูกส่งไปยังคุณโดยบังเอิญ หากคุณไม่ต้องการรับข้อความนี้อีกกรุณา mail มาที่ www.ecommerce.web1000.com/unsub --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Mon Mar 17 7: 7:52 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9AF0937B40C for ; Mon, 17 Mar 2003 07:07:50 -0800 (PST) Received: from mailgw.cscoms.com (mailgw.cscoms.com [202.183.255.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4BD8243FA3 for ; Mon, 17 Mar 2003 07:07:49 -0800 (PST) (envelope-from job2546@thaimail.com) Received: from cscoms.com (mail.cscoms.com [202.183.255.23]) by mailgw.cscoms.com (8.12.8/8.12.3) with ESMTP id h2HF1lip061517; Mon, 17 Mar 2003 22:02:30 +0700 (ICT) Received: from ME (dial-144.ras-21.bkk.c.cscoms.com [203.170.145.144]) by cscoms.com (8.12.8/8.12.3) with SMTP id h2HEpswo024873; Mon, 17 Mar 2003 21:51:55 +0700 (GMT) Date: Mon, 17 Mar 2003 21:51:54 +0700 (GMT) Message-Id: <200303171451.h2HEpswo024873@cscoms.com> From: job2546@thaimail.com Subject: "ถ้าคุณยังทำสิ่งที่คุณทำอยู่วันนี้ พรุ่งนี้ก็จะเหมือนวันนี้ X-Priority: 1 (Highest) Reply-To: job2546@thaimail.com X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" X-Virus-Scanned: by amavisd-milter (http://amavis.org/) To: undisclosed-recipients: ; Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit "หากคุณล้มเหลวที่จะวางแผน ย่อมแปลว่าคุณวางแผนที่จะล้มเหลว" จิม โรห์น นักปรัชญาอันดับ 1 ของโลก เช่น คุณคิดว่าในชีวิตนี้เราคงไม่มีทางรวย คุณก็ไจะไม่มีทางรวยเลย หรือ "คุณคิดว่าสักวันถึงฉันต้องรวยแน่ๆ" จิม โรห์น บอกว่า "ถ้าคุณยังทำสิ่งที่คุณทำอยู่ทุกวันนี้ อีก 3 ปีข้างหน้าลองคิดดูว่า คุณจะมีโอกาสรวยได้หรือไม่" "ถ้าคำตอบคือ ใช่ คุณกำลังจะรวย" ก็ยินดีกับคุณด้วยครับคุณกำลังจะรวยแล้ว "แต่ถ้าคำตอบคือ ไม่ คุณไม่สามารถรวยได้" คุณต้องเปลี่ยนอะไรสักอย่างในชีวิตคุณแล้ว จิม โรห์น บอกอีกว่า "ถ้าคุณยังทำสิ่งที่คุณทำอยู่วันนี้ พรุ่งนี้ก็จะเหมือนวันนี้ ไปเรื่อยๆไม่มีที่สิ้นสุด" หมายความว่า -ถ้าวันนี้คุณยังต้องวิ่งหาเงิน จ่ายหนี้ต่างๆ -ถ้าวันนี้คุณยังถูกเจ้านายกดขี่ ใช้งานอย่างหนัก -ถ้าวันนี้คุณยังหาทางออกไม่ได้ ลองเปิดโอกาสให้ตัวเองดู เปิดใจของคุณให้กว้างแล้วเดินตามเรามาหรือปล่อยให้โอกาสนี้หลุดลอยไป ============================================================ คุณสามารถเข้าไปดูรายละเอียดเพิ่มเติมและกรอกข้อมูลเพื่อขอรับข้อมูลเบื้องต้นฟรี ! ได้ที่ http://www.geocities.com/thaigetrich/easywork ============================================================ ขออภัยหากข้อความนี้ถูกส่งไปยังคุณโดยบังเอิญ หากคุณไม่ต้องการรับข้อความนี้อีกกรุณา mail มาที่ www.ecommerce.web1000.com/unsub --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Mar 18 14:56:56 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B0F4C37B404 for ; Tue, 18 Mar 2003 14:56:54 -0800 (PST) Received: from flood.ping.uio.no (flood.ping.uio.no [129.240.78.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 06D6C43FA3 for ; Tue, 18 Mar 2003 14:56:54 -0800 (PST) (envelope-from des@ofug.org) Received: by flood.ping.uio.no (Postfix, from userid 2602) id 5F3F55308; Tue, 18 Mar 2003 23:56:51 +0100 (CET) X-URL: http://www.ofug.org/~des/ X-Disclaimer: The views expressed in this message do not necessarily coincide with those of any organisation or company with which I am or have been affiliated. To: arch@freebsd.org Subject: OpenBSD compatibility in cvs From: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Tue, 18 Mar 2003 23:56:51 +0100 Message-ID: User-Agent: Gnus/5.090015 (Oort Gnus v0.15) Emacs/21.2 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --=-=-= Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable The attached patch implements the OpenBSD tag, umask and dlimit cvs configuration keywords so our cvs(1) can operate on an OpenBSD repo without warnings. The file it affects is on the vendor branch; should we submit this patch to the vendor or just take the file off the branch? DES --=20 Dag-Erling Sm=F8rgrav - des@ofug.org --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=cvs.diff Index: contrib/cvs/src/parseinfo.c =================================================================== RCS file: /home/ncvs/src/contrib/cvs/src/parseinfo.c,v retrieving revision 1.1.1.11 diff -u -r1.1.1.11 parseinfo.c --- contrib/cvs/src/parseinfo.c 21 Jan 2003 21:53:02 -0000 1.1.1.11 +++ contrib/cvs/src/parseinfo.c 18 Mar 2003 22:53:26 -0000 @@ -340,6 +340,25 @@ goto error_return; } } + else if (strcmp (line, "tag") == 0) { + RCS_setlocalid(p); + } + else if (strcmp (line, "umask") == 0) { + cvsumask = (mode_t)(strtol(p, NULL, 8) & 0777); + } + else if (strcmp (line, "dlimit") == 0) { +#ifdef BSD +#include + struct rlimit rl; + + if (getrlimit(RLIMIT_DATA, &rl) != -1) { + rl.rlim_cur = atoi(p); + rl.rlim_cur *= 1024; + + (void) setrlimit(RLIMIT_DATA, &rl); + } +#endif /* BSD */ + } else if (strcmp (line, "PreservePermissions") == 0) { if (strcmp (p, "no") == 0) --=-=-=-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Tue Mar 18 21:36:53 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 60D0E37B404 for ; Tue, 18 Mar 2003 21:36:52 -0800 (PST) Received: from canning.wemm.org (canning.wemm.org [192.203.228.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id EE0E543F85 for ; Tue, 18 Mar 2003 21:36:51 -0800 (PST) (envelope-from peter@wemm.org) Received: from wemm.org (localhost [127.0.0.1]) by canning.wemm.org (Postfix) with ESMTP id C617F2A8BB; Tue, 18 Mar 2003 21:36:51 -0800 (PST) (envelope-from peter@wemm.org) X-Mailer: exmh version 2.5 07/13/2001 with nmh-1.0.4 To: des@ofug.org (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Cc: arch@freebsd.org Subject: Re: OpenBSD compatibility in cvs In-Reply-To: Date: Tue, 18 Mar 2003 21:36:51 -0800 From: Peter Wemm Message-Id: <20030319053651.C617F2A8BB@canning.wemm.org> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?= wrote: > The attached patch implements the OpenBSD tag, umask and dlimit cvs > configuration keywords so our cvs(1) can operate on an OpenBSD repo > without warnings. The file it affects is on the vendor branch; should > we submit this patch to the vendor or just take the file off the > branch? FWIW, this is fine with me. Cheers, -Peter -- Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Mar 19 7: 1:39 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9F35837B425; Wed, 19 Mar 2003 07:01:29 -0800 (PST) Received: from mailgw.cscoms.com (mailgw.cscoms.com [202.183.255.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id E590243FB1; Wed, 19 Mar 2003 07:01:23 -0800 (PST) (envelope-from wowwwhealthy@thaimail.com) Received: from cscoms.com (mail.cscoms.com [202.183.255.23]) by mailgw.cscoms.com (8.12.8/8.12.3) with ESMTP id h2JF0Oil006854; Wed, 19 Mar 2003 22:00:29 +0700 (ICT) Received: from ME (dial-255.ras-7.bkk.c.cscoms.com [203.170.141.193]) by cscoms.com (8.12.8/8.12.3) with SMTP id h2JEwNwo003940; Wed, 19 Mar 2003 21:58:38 +0700 (GMT) Date: Wed, 19 Mar 2003 21:58:23 +0700 (GMT) Message-Id: <200303191458.h2JEwNwo003940@cscoms.com> From: wowwwhealthy@thaimail.com Subject: ท่านทราบหรือไม่ว่าคนอ้วนจะเสี่ยงต่อการเป็นเบาหวานมากกว่าคนน้ำหนักปกติถึง 30 เท่า X-Priority: 1 (Highest) Reply-To: wowwwhealthy@thaimail.com X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" X-Virus-Scanned: by amavisd-milter (http://amavis.org/) To: undisclosed-recipients: ; Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit คนไทยกำลังเป็นโรคอ้วนมากขึ้นทุกที พ.อ.หญิง รศ. พ.ญ. พรฑิตา ชัยอำนวย ผู้อำนวยการเวชศาสตร์ฟื้นฟู โรงพยาบาลพระมงกุฏเกล้า บรรยายเรื่อง "กินอย่างไรให้ห่างไกลโรคหัวใจและโรคอ้วน" ในตอนหนึ่งของการบรรยาย ผู้บรรยายกล่าวว่า "สิ่งที่พึงตระหนักคือ ผู้ชายไม่ควรให้รอบเอวเกิน 36 นิ้ว หญิงไม่ควรเกิน 32 นิ้ว ถ้ามากกว่านี้ต้องเร่งลดน้ำหนัก" เพราะถ้าหากท่านวัดรอบเอวแล้วได้ตัวเลขเกินกว่ามาตราฐานนี้ แสดงว่าท่านกำลังเป็นโรคอ้วน คนเป็นโรคอ้วนมีความเสี่ยงที่จะต้อง พบกับโรคร้ายต่างๆ มากมาย นับตั้งแต่ โรคหัวใจ เบาหวาน ไขมันในเลือดสูง ความดันโลหิตสูง อัมพาต และท่านอาจจะหยุดหายใจขณะหลับ จนเกิดภาวะพร่องออกซิเจน ตื่นนอนจะมีอาการมึน เป็นต้อหินง่ายเนื่องจากเลือดขาดออกซิเจน เป็นโรคข้อ เพราะแบกรับน้ำหนักมาก เป็นเกาต์ มะเร็ง นิ่วในถุงน้ำดี มีลูกยาก โรคเกี่ยวกับระบบหายใจ โรคถุงน้ำดี ท่านทราบหรือไม่ว่าคนอ้วนจะเสี่ยงต่อการเป็นเบาหวานมากกว่าคนน้ำหนักปกติถึง 30 เท่า เสี่ยงเป็นโรคหลอดเลือดหัวใจตีบกว่าคนทั่วไป 15 เท่า โรคอัมพาต 11 เท่า โรคมะเร็งลำไส้ 2 เท่า คนเป็นโรคอ้วนเป็นโรคร้ายตายง่ายอย่างนี้ถ้าไม่เรียกคนที่มีรอบเอวเกินมาตราฐานว่า รอบเอวมรณะ แล้วจะเรียกว่าอะไรล่ะครับ วิธีถอดห่วงยาง (ลดเอว) คุณหมอบอกว่า วิธีรักษาโรคอ้วนสามารถทำได้ด้วยการควบคุมแคลอรีของอาหารที่รับประทาน คือพยายามให้ลดลงวันละ 600 แคลอรี ซึ่งภายใน 7 วันท่านจะสามารถลดน้ำหนักได้0.6 กิโลกรัม เพราะไขมัน 1 กิโลกรัม เท่ากับ 7,000 แคลอรี ประการที่สำคัญ ต้องออกกำลังกายอย่างสม่ำเสมอทุกวันครับ อย่างน้อย 20 นาที ถ้าออกกำลังกายได้ 60 นาทีจะยิ่งเป็นผลดี คุณหมอบอกว่าเราควรให้สนใจใฝ่ศึกษาหาความรู้ด้านโภชนาการให้มาก ๆ คือให้ศึกษาว่าอาหารชนิดไหนให้พลังงานน้อย พลังมากแค่ไหน และ ควรสร้างความสุขที่ได้บริโภคอาหารไขมันต่ำ ๆ ในการรับประทานอาหารควรเคี้ยวให้ช้าๆ จะรู้สึกอิ่มทั้งๆ ที่บริโภคน้อย อ้อ ! budpage แนะนำว่าท่านควรซื้อสายวัดมาเก็บไว้สักเส้นนะครับ ทุก ๆ เช้าคอยวัดเอวตัวเอง และควรจดบันทึกเป็นสถิติไว้ทุกวันด้วย สนุกดีครับ อีกทั้งยังเป็นการท้าทายให้เรามีความตื่นตัวที่จะลดความอ้วนอยู่เสมออีกด้วย สุดท้ายนี้ขอให้ทุก ๆ ท่านมีรอบเอวในระดับมาตราฐานที่ปลอดภัยกันทุก ๆ ท่านนะครับ (จบบทความนี้ เวบมาสเตอร์ คงขอตัวไปซื้อสายวัดมาควบคุมน้ำหนักด้วยคนนะครับ สวัสดี ) ขอเชิญชาวพุทธมาช่วยกันระดมความคิดในหัวข้อ "วิธีออกกำลังกายให้สนุก" ลองมาดูกันว่าใครจะมีวิธีการเด็ดๆ ที่จะทำให้คนอ้วนอยากออกกำลังกายโดยไม่ฝืนใจกันบ้าง แล้วพบกันใหม่กับเอกสารสาระที่มีประโยชน์ฉบับหน้าค่ะ ***************************************************************** ถ้าท่านต้องการข้อมูลที่มีประโยชน์ในด้านโภชนาการเพื่อสุขภาพที่แข็งแรง หรือต้องการลดน้ำหนักโดยวิธีธรรมชาติ สามารถขอข้อมูลได้จาก ... http://www.geocities.com/healthclub999/easythin ***************************************************************** หากไม่ต้องการรับข้อมูลข่าวสารอีก กรุณาเข้าไปแจ้งที่ www.unsubhealthclub.web1000.com --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Mar 19 7:16:58 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A23FF37B404 for ; Wed, 19 Mar 2003 07:16:56 -0800 (PST) Received: from mailgw.cscoms.com (mailgw.cscoms.com [202.183.255.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5001143F3F for ; Wed, 19 Mar 2003 07:16:55 -0800 (PST) (envelope-from wowwwhealthy@thaimail.com) Received: from cscoms.com (mail.cscoms.com [202.183.255.23]) by mailgw.cscoms.com (8.12.8/8.12.3) with ESMTP id h2JFDXil015208; Wed, 19 Mar 2003 22:13:34 +0700 (ICT) Received: from ME (dial-255.ras-7.bkk.c.cscoms.com [203.170.141.193]) by cscoms.com (8.12.8/8.12.3) with SMTP id h2JF9rwo010441; Wed, 19 Mar 2003 22:09:55 +0700 (GMT) Date: Wed, 19 Mar 2003 22:09:53 +0700 (GMT) Message-Id: <200303191509.h2JF9rwo010441@cscoms.com> From: wowwwhealthy@thaimail.com Subject: ท่านทราบหรือไม่ว่าคนอ้วนจะเสี่ยงต่อการเป็นเบาหวานมากกว่าคนน้ำหนักปกติถึง 30 เท่า X-Priority: 1 (Highest) Reply-To: wowwwhealthy@thaimail.com X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" X-Virus-Scanned: by amavisd-milter (http://amavis.org/) To: undisclosed-recipients: ; Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit คนไทยกำลังเป็นโรคอ้วนมากขึ้นทุกที พ.อ.หญิง รศ. พ.ญ. พรฑิตา ชัยอำนวย ผู้อำนวยการเวชศาสตร์ฟื้นฟู โรงพยาบาลพระมงกุฏเกล้า บรรยายเรื่อง "กินอย่างไรให้ห่างไกลโรคหัวใจและโรคอ้วน" ในตอนหนึ่งของการบรรยาย ผู้บรรยายกล่าวว่า "สิ่งที่พึงตระหนักคือ ผู้ชายไม่ควรให้รอบเอวเกิน 36 นิ้ว หญิงไม่ควรเกิน 32 นิ้ว ถ้ามากกว่านี้ต้องเร่งลดน้ำหนัก" เพราะถ้าหากท่านวัดรอบเอวแล้วได้ตัวเลขเกินกว่ามาตราฐานนี้ แสดงว่าท่านกำลังเป็นโรคอ้วน คนเป็นโรคอ้วนมีความเสี่ยงที่จะต้อง พบกับโรคร้ายต่างๆ มากมาย นับตั้งแต่ โรคหัวใจ เบาหวาน ไขมันในเลือดสูง ความดันโลหิตสูง อัมพาต และท่านอาจจะหยุดหายใจขณะหลับ จนเกิดภาวะพร่องออกซิเจน ตื่นนอนจะมีอาการมึน เป็นต้อหินง่ายเนื่องจากเลือดขาดออกซิเจน เป็นโรคข้อ เพราะแบกรับน้ำหนักมาก เป็นเกาต์ มะเร็ง นิ่วในถุงน้ำดี มีลูกยาก โรคเกี่ยวกับระบบหายใจ โรคถุงน้ำดี ท่านทราบหรือไม่ว่าคนอ้วนจะเสี่ยงต่อการเป็นเบาหวานมากกว่าคนน้ำหนักปกติถึง 30 เท่า เสี่ยงเป็นโรคหลอดเลือดหัวใจตีบกว่าคนทั่วไป 15 เท่า โรคอัมพาต 11 เท่า โรคมะเร็งลำไส้ 2 เท่า คนเป็นโรคอ้วนเป็นโรคร้ายตายง่ายอย่างนี้ถ้าไม่เรียกคนที่มีรอบเอวเกินมาตราฐานว่า รอบเอวมรณะ แล้วจะเรียกว่าอะไรล่ะครับ วิธีถอดห่วงยาง (ลดเอว) คุณหมอบอกว่า วิธีรักษาโรคอ้วนสามารถทำได้ด้วยการควบคุมแคลอรีของอาหารที่รับประทาน คือพยายามให้ลดลงวันละ 600 แคลอรี ซึ่งภายใน 7 วันท่านจะสามารถลดน้ำหนักได้0.6 กิโลกรัม เพราะไขมัน 1 กิโลกรัม เท่ากับ 7,000 แคลอรี ประการที่สำคัญ ต้องออกกำลังกายอย่างสม่ำเสมอทุกวันครับ อย่างน้อย 20 นาที ถ้าออกกำลังกายได้ 60 นาทีจะยิ่งเป็นผลดี คุณหมอบอกว่าเราควรให้สนใจใฝ่ศึกษาหาความรู้ด้านโภชนาการให้มาก ๆ คือให้ศึกษาว่าอาหารชนิดไหนให้พลังงานน้อย พลังมากแค่ไหน และ ควรสร้างความสุขที่ได้บริโภคอาหารไขมันต่ำ ๆ ในการรับประทานอาหารควรเคี้ยวให้ช้าๆ จะรู้สึกอิ่มทั้งๆ ที่บริโภคน้อย อ้อ ! budpage แนะนำว่าท่านควรซื้อสายวัดมาเก็บไว้สักเส้นนะครับ ทุก ๆ เช้าคอยวัดเอวตัวเอง และควรจดบันทึกเป็นสถิติไว้ทุกวันด้วย สนุกดีครับ อีกทั้งยังเป็นการท้าทายให้เรามีความตื่นตัวที่จะลดความอ้วนอยู่เสมออีกด้วย สุดท้ายนี้ขอให้ทุก ๆ ท่านมีรอบเอวในระดับมาตราฐานที่ปลอดภัยกันทุก ๆ ท่านนะครับ (จบบทความนี้ เวบมาสเตอร์ คงขอตัวไปซื้อสายวัดมาควบคุมน้ำหนักด้วยคนนะครับ สวัสดี ) ขอเชิญชาวพุทธมาช่วยกันระดมความคิดในหัวข้อ "วิธีออกกำลังกายให้สนุก" ลองมาดูกันว่าใครจะมีวิธีการเด็ดๆ ที่จะทำให้คนอ้วนอยากออกกำลังกายโดยไม่ฝืนใจกันบ้าง แล้วพบกันใหม่กับเอกสารสาระที่มีประโยชน์ฉบับหน้าค่ะ ***************************************************************** ถ้าท่านต้องการข้อมูลที่มีประโยชน์ในด้านโภชนาการเพื่อสุขภาพที่แข็งแรง หรือต้องการลดน้ำหนักโดยวิธีธรรมชาติ สามารถขอข้อมูลได้จาก ... http://www.geocities.com/healthclub999/easythin ***************************************************************** หากไม่ต้องการรับข้อมูลข่าวสารอีก กรุณาเข้าไปแจ้งที่ www.unsubhealthclub.web1000.com --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Wed Mar 19 9:36:44 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 30C6F37B401 for ; Wed, 19 Mar 2003 09:36:43 -0800 (PST) Received: from smtp1.server.rpi.edu (smtp1.server.rpi.edu [128.113.2.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 53A1F43FB1 for ; Wed, 19 Mar 2003 09:36:42 -0800 (PST) (envelope-from drosih@rpi.edu) Received: from [128.113.24.47] (gilead.netel.rpi.edu [128.113.24.47]) by smtp1.server.rpi.edu (8.12.8/8.12.7) with ESMTP id h2JHaeBg031120; Wed, 19 Mar 2003 12:36:41 -0500 Mime-Version: 1.0 X-Sender: drosih@mail.rpi.edu Message-Id: In-Reply-To: References: Date: Wed, 19 Mar 2003 12:36:39 -0500 To: des@ofug.org (Dag-Erling =?iso-8859-1?Q?Sm=F8rgrav?= ), arch@FreeBSD.ORG From: Garance A Drosihn Subject: Re: OpenBSD compatibility in cvs Content-Type: text/plain; charset="iso-8859-1" ; format="flowed" Content-Transfer-Encoding: quoted-printable X-Scanned-By: MIMEDefang 2.28 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG At 11:56 PM +0100 3/18/03, Dag-Erling Sm=F8rgrav wrote: >The attached patch implements the OpenBSD tag, umask and dlimit >cvs configuration keywords so our cvs(1) can operate on an >OpenBSD repo without warnings. The file it affects is on the >vendor branch; should we submit this patch to the vendor or just >take the file off the branch? I'll just say that I would very much like to have the compatibility with openbsd's CVS. It is obviously better if the vendor would rapidly incorporate the patch, but if there's any snag with that process then I think the compatibility is worth taking the file off the vendor branch. -- Garance Alistair Drosehn =3D gad@gilead.netel.rpi.edu Senior Systems Programmer or gad@freebsd.org Rensselaer Polytechnic Institute or drosih@rpi.edu To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Mar 21 2:55:50 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6F66E37B401; Fri, 21 Mar 2003 02:55:49 -0800 (PST) Received: from mailgw.cscoms.com (mailgw.cscoms.com [202.183.255.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id E729343F93; Fri, 21 Mar 2003 02:55:47 -0800 (PST) (envelope-from Economic2003@thaimail.com) Received: from cscoms.com (mail.cscoms.com [202.183.255.23]) by mailgw.cscoms.com (8.12.8/8.12.3) with ESMTP id h2LAreER021850; Fri, 21 Mar 2003 17:53:41 +0700 (ICT) Received: from ME (dial-111.ras-7.bkk.c.cscoms.com [203.170.129.111]) by cscoms.com (8.12.8/8.12.3) with SMTP id h2LApPwo013104; Fri, 21 Mar 2003 17:51:26 +0700 (GMT) Date: Fri, 21 Mar 2003 17:51:25 +0700 (GMT) Message-Id: <200303211051.h2LApPwo013104@cscoms.com> From: Economic2003@thaimail.com Subject: สหรัฐ รบกับอิรัก เศรษฐกิจะดีขึ้นจริง ความมั่นคงในงานมีจริงหรือ? X-Priority: 1 (Highest) Reply-To: Economic2003@thaimail.com X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" X-Virus-Scanned: by amavisd-milter (http://amavis.org/) To: undisclosed-recipients: ; Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit สภาพความเป็นจริงของงานประจำคือไม่มีความมั่นคง ใครกล้ายืนยัน แม้ว่า สหรัฐ รบกับอิรัก เศรษฐกิจะดีขึ้นจริง ความมั่นคงในงานมีจริงหรือ? - โดยสภาวะทั่วไปนั้น งานประจำจะถูกจำกัดด้วยขั่วโมงทำงานที่ยาว - ทั้งนี้ยังจำกัดรายได้ที่ต่ำเมื่อเทียบกับความทุ่มเทที่เราให้แก่งาน - อีกทั้งผลงานก็ถูกวินิจฉัยโดยเจ้านาย หรือเจ้าของกิจการ - ที่สำคัญก็คือ ผลงานโดนเบียดบังหรือลดความสำคัญโดยเพื่อน ร่วมงานผู้ซึ่งช่างประจบเจ้านาย อีกเจ้านายก็มักชอบเสียด้วย - ภาพความเป็นจริงดังกล่าวสร้างความเครียด และลบล้างอิสรภาพ - สภาพความมั่นคงไม่มี มีเพียงความมั่นคงของบริษัทและบางคนถูก คัดเลือกให้เป็นผู้เสียสละในชั่วโมงที่บริษัทอยู่ในฐานะย่ำแย่ - ลองเริ่มงานพิเศษเผื่อว่าสักวันจะได้หลุดพ้นสภาวะดังกล่าวคือ มีอิสรภาพทางด้านรายได้ ตลอดจนถึงอิสรภาพทางเวลา - สามารถสร้างรายได้เพิ่มอีกเดือนละ 10,000-20,000 บาทเป็น ขั้นต่ำโดยใช้เวลาสัปดาห์ละ 10-12 ชั่วโมง - สามารถแปรเป็นงานประจำไว้รองรับในกรณีฉุกเฉินได้เป็นอย่างดี - ทำงานโดยใข้ระบบ internet,fax หรือสื่ออีเล็คทรอนิคส์อื่น และสื่อชนิดอื่นๆตามความถนัดแต่ละบุคคล ที่สำคัญมากมาก คืออิสรภาพทางจิตใจ สามารถทำงานด้วยความ เบิกบาน หากคุณแน่ใจว่าคิดเช่นนั้น แม้ว่าคุณยังศึกษาอยู่ก็ตาม สามารถเริ่มเตรียมตัวหลีกสภาพดังกล่าว ผู้ที่ประสบอยู่แล้วก็ สามารถที่จะเริ่มหลีกเลี่ยง เพื่อการเก็บออม หากมีความสนใจให้ดูรายละเอียดและกรอกรายละเอียดที่ www.geocities.com/thaigetrich/easywork __________________________________________________________________ หากท่านไม่ประสงค์รับวารสารจากเราอีกต่อไป กรุณาส่ง E-Mail Addressไปที่ : easywork@maildozy.com ระบบจะทำการตรวจสอบและลบชื่อของท่านออกจากฐานข้อมูลทันที (กรุณาส่งเป็น mail address ไม่ใช่ display name) _____________________________________________________________________ You can unsubscibe by submit your E-mail address at srs_ctcv@yahoo.com. Please give specific address not your display name. --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Mar 21 8:38:28 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9789A37B401; Fri, 21 Mar 2003 08:38:26 -0800 (PST) Received: from mailgw.cscoms.com (mailgw.cscoms.com [202.183.255.5]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5C31343FE0; Fri, 21 Mar 2003 08:38:12 -0800 (PST) (envelope-from FreeBooklet@thaimail.com) Received: from cscoms.com (mail.cscoms.com [202.183.255.23]) by mailgw.cscoms.com (8.12.8/8.12.3) with ESMTP id h2LGZNET032256; Fri, 21 Mar 2003 23:35:38 +0700 (ICT) Received: from ME (dial-49.ras-7.bkk.c.cscoms.com [203.170.129.49]) by cscoms.com (8.12.8/8.12.3) with SMTP id h2LGV4wo017065; Fri, 21 Mar 2003 23:31:10 +0700 (GMT) Date: Fri, 21 Mar 2003 23:31:04 +0700 (GMT) Message-Id: <200303211631.h2LGV4wo017065@cscoms.com> From: FreeBooklet@thaimail.com Subject: แจกฟรี ! หนังสือคู่มือคนเคยจน สำหรับผู้สนใจ.... X-Priority: 1 (Highest) Reply-To: FreeBooklet@thaimail.com X-Mailer: Microsoft Outlook Express 5.00.2615.200 MIME-Version: 1.0 Content-type: multipart/mixed; boundary="#MYBOUNDARY#" X-Virus-Scanned: by amavisd-milter (http://amavis.org/) To: undisclosed-recipients: ; Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --#MYBOUNDARY# Content-Type: text/plain; charset=ansi Content-Transfer-Encoding: 8bit >>>>ทำงานที่ยากที่สุดก่อน >>>> >>ผมยิ่งมีชีวิตอยู่นานเท่าไหร่ ผมยิ่งมั่นใจมากขึ้นเท่านั้น >>ว่าความแตกต่างอันยิ่งใหญ่ระหว่างมนุษย์... >>ระหว่าคนที่อ่อนแอและคนทีอำนาจ....... >>ระหว่างคนที่ยิ่งใหญ่และคนที่ไม่สำคัญ ก็คือ >>เรี่ยวแรงของ....ความตั้งใจแน่วแน่ที่ไม่อาจทำลายได้.... >>จุดประสงค์ที่เมื่อตั้งขึ้นแล้ว ถ้าไม่ตายก็ต้องชนะ >>-เซอร์โธมัส ฟาวเวล บั๊กซ์ตัน >>หนึ่งในเทคนิคที่ดีที่สุดในการเอาชนะนิสัยผัดวันประกันพรุ่ง >>และทำงานได้มากขึ้นและเร็วขึ้นก็คือลงมือทำงานที่ยากที่สุดของคุณก่อน >>นี่คือการ " กินกบของคุณ " ที่แท้จริง มันเป็นทักษะส่วนบุคคลในการบริหาร >>ที่ยากที่สุดและสำคัญที่สุดเริ่มต้นตอนเช้าด้วยงานที่ใหญ่ที่สุดและสำคัญที่สุด >>คือ สิ่งตรงข้ามกับที่คนส่วนใหญ่ทำ ระเบียบวินัยนี้จะทำให้คุณเลิกนิสัย ผัดวัน >>ประกันพรุ่งและทำให้อนาคตอยู่ในกำมือคุณ >>>>>>>>การเริ่มต้นแต่ละวันด้วยงานที่ยากที่สุดเป็นการเริ่มต้นแบบก้าวกระโดด >>ที่ดี คุณจะมีไฟมากขึ้น และจะทำงานได้ผลดีมากขึ้น >>>>>>>>ในวันที่คุณเริ่มลงมือทำงานสำคัญโดยทันทีทันควัน คุณจะรู้สึกดีกับตัว >>คุณเองและกับงานของคุณมากกว่าคนอื่นๆ คุณจะรู้สึกมีอำนาจมากขึ้น ควบคุม >>ตัวเองได้มากขึ้นและรับผิดชอบดูแลชีวิตตัวเองได้มากกว่าเวลาอื่น >>>>>>>สร้างนิสัยเริ่มทำงานที่ยากที่สุดก่อนแล้วคุณจะไม่ต้องมองย้อนกลับ >>คุณจะกลายเป็น หนึ่งในคนที่มีประสิทธิภาพมากที่สุดในคนรุ่นคุณ............... >>กินกบตัวนั้นซะ!!! จงมองตัวเองว่าเป็นงานที่กำลังคืบหน้า จงเทใจให้กับการเพาะนิสัย >>เป็นคนมีผลงานสูงด้วยการฝึกซ้ำแล้วซ้ำเล่าจนกระทั่งมันกลายเป็นเรื่องอัตโนมัติและ >>กลายเป็นเรื่องง่าย >>>>>>>>หนึ่งในวลีที่มีอนุภาพมากที่สุดซึ่งคุณสามารถเรียนรู้และนำมาใช้ได้ก็คือ >>" เพื่อวันนี้เท่านั้น! "อย่าวิตกเรื่องการเปลี่ยนแปลงชีวิตตัวเอง ถ้ามันฟังเหมือนเป็น >>ความคิดที่ดี จงทำมัน" เพื่อวันนี้เท่านั้น" >>>>>>>>บอกกับตัวเองว่า " เพื่อวันนี้เท่านั้น ฉันจะวางแผนเตรียมการ และเริ่มต้นงาน >>ที่ยากที่สุดก่อนจะทำอย่างอื่น "แล้วคุณจะต้องทึ่งกับความแตกต่างที่เกิดขึ้นในชีวิตคุณ ---------------------------------------------------------------------------------------------- คุณ พร้อมแล้วรึยัง กับรูปแบบการทำงานง่ายๆจากที่บ้าน Click Here! www.geocities.com/thaigetrich/easywork , หรือ Tel. 0-2277-7850 กด 25 ----------------------------------------------------------------------------------------------- ขออภัยหากเป็นการรบกวน และหากไม่ต้องการให้ส่งข่าวสารมายังท่านอีก กรุณาเมลล์มาที่ easywork@maildozy.com หัวข้อ unsub --#MYBOUNDARY#-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Mar 21 12:19:35 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D223237B407 for ; Fri, 21 Mar 2003 12:19:32 -0800 (PST) Received: from mail.speakeasy.net (mail14.speakeasy.net [216.254.0.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4741A43FBF for ; Fri, 21 Mar 2003 12:19:32 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 27787 invoked from network); 21 Mar 2003 20:19:38 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail14.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 21 Mar 2003 20:19:38 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.8/8.12.8) with ESMTP id h2LKJTOv081491 for ; Fri, 21 Mar 2003 15:19:29 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.4 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Date: Fri, 21 Mar 2003 15:19:29 -0500 (EST) From: John Baldwin To: arch@FreeBSD.org Subject: Convert process at_foo events to eventhandlers Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I'd like to convert the process at_fork, at_exec, and at_exit events to be regular eventhandlers instead. This way I get to leverage the locking of the existing eventhandlers w/o having to duplicate it in three other places. The patch to do this is at http://www.FreeBSD.org/~jhb/patches/proc_event.patch. Note that the old API (at_foo, rm_at_foo) has been removed as I can not easily implement the rm_at_foo functionality using eventhandlers since eventhandlers allow for multiple instances of a function in a list and use cookies instead of using the function pointer directly to remove events. There is precedent for this in that at_shutdown() also died when at_shutdown() was converted to an eventhandler. This patch also defines some generic eventhandler priorities so that users of eventhandlers don't always have to define new constants for priorities. Comments? -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Mar 21 14:45:54 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 18EE337B401 for ; Fri, 21 Mar 2003 14:45:52 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 250BF43F93 for ; Fri, 21 Mar 2003 14:45:51 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.8/8.12.8) with ESMTP id h2LMjl1f011640 for ; Fri, 21 Mar 2003 23:45:48 +0100 (CET) (envelope-from phk@phk.freebsd.dk) To: arch@freebsd.org Subject: GEOM ioctl issue. From: Poul-Henning Kamp Date: Fri, 21 Mar 2003 23:45:47 +0100 Message-ID: <11639.1048286747@critter.freebsd.dk> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I am trying to fix some issues relating to removable devices and GEOM, and have run into an either/or issue with GEOM's state-engine. A bit of background: ioctl will automagically do copyin(9)/copyout(9) of the primary argument which often is a struct. The way this works is that the ioctl identifier, which is an integer, has 13 bits dedicated to the length, so primary arguments can be up to 8191 bytes long. (The alert reader will notice that this is one byte short of being able to accomodate a UFS bootblock.) The ioctl syscall handler will extract this length and two flags which encode if the primary argument should be copied into the kernel before and out of the kernel after handling the ioctl, and do the appropriate copyin(9) and copyout(9). (See for how this encoding is done.) Think of this as a zeroth order marshalling layer. If the primary argument is a struct containing pointer(s) to something else, a string or maybe another structure, these secondary arguments are not handled in the generic ioctl syscall code, it becomes the responsibility of the ioctl implementor to explicity call copyin(9)/copyout(9) on these arguments. The way we have implemented copyin(9) and copyout(9) depends strongly on the fact that they are executed in the corresponding thread, it is not possible to access userland for one thread with copyin/out from another thread, userland or kernel. GEOM abandons the original thread as the very first thing, there are a multitude of reasons for this, the primary being prevention of kernel stack overrun and the second realible and simple serialization. If an ioctl is called on /dev/da0, what will happen is that the ioctl gets as far as to geom_dev.c (which is a normal device driver), where the ioctl arguments are packed into a special kind of struct bio, which then is shipped down-stream in the dedicated GEOM io-path threads. It will relatively fast hit geom_disk.c which is the GEOM class which interfaces to disk device drivers. geom_disk.c recognizing the potential need for copyin/copyout will return the request with a special error code and a function pointer. The special struct bio will eventually get delivered to geom_dev.c into the original userland thread, and special case code on seeing the magic error code will call the provided function pointer to really execute the ioctl. If the disk device driver at this point gets an interrupt and finds out that its hardware has departed the system, things explode in a nice display of fireworks, because there is no way to lock this scenario without causing deadlocks. So I am faced with an Either/Or decision: Either I support ioctls in the disk device drivers Or we get removable devices working robustly. Three drivers today use the ioctl interface, (notice that we are only talking GEOM disk device drivers here, CDROM drives for instance are not affected). "afd" uses ioctl to implement two primitivs for opening and closing the device tray. "mlx" uses it for management tasks and "da" uses it to find the corresponding "pass" device for a given "da" device. Close inspection of libcam has not shown that this ioctl is actually used however. Finally RaidFrame uses ioctl for configuration issues. For all I can tell, the code in "da" can be dropped and nobody will notice. The "mlx" and "raidframe" can probably more logically implement a "mlx.ctl" and "rf.ctl" control device which is used soleley for OAM issues, this would be in line with the md(4) and ccd(4) drivers. That leaves the "afd" drivers "open/close tray" ioctls, which currently are #ifdef'ed out pending further study of how we actually want to interface with removable devices in general (this subject is out of scope for this email). On the other hand, the SANE2002 conference handed out "USB-keys" to all in attendance and everybody and his dad has a digital camera these days, so getting removable devices working robustly is not even open for discussion. So the decision is really a foregone conclusion: We cannot possibly support the copyin/copyout semantics of ioctls in GEOM disk device drivers. One option would be to simply drop the support for doing copyin/copyout in the ioctl handing code, but this would mean that we suddenly have two kinds of ioctls in the system, and it would leave another issue unresolved: the serialization between regular I/O and ioctls. The replacement mechanism will therefore be to pass the BIO_GETATTR/BIO_SETATTR struct bio requests through to the device drivers and marshal ioctls into these at the geom_dev.c level is required. I have not completed the patches to carry this transformation out yet, but this is the next item on my TODO list, so expect a patch to be floated for test and review in a few days time. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Fri Mar 21 15:24:55 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2202837B401 for ; Fri, 21 Mar 2003 15:24:54 -0800 (PST) Received: from stork.mail.pas.earthlink.net (stork.mail.pas.earthlink.net [207.217.120.188]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3404A43FB1 for ; Fri, 21 Mar 2003 15:24:53 -0800 (PST) (envelope-from tlambert2@mindspring.com) Received: from pool0094.cvx22-bradley.dialup.earthlink.net ([209.179.198.94] helo=mindspring.com) by stork.mail.pas.earthlink.net with asmtp (SSLv3:RC4-MD5:128) (Exim 3.33 #1) id 18wVsU-0002Rm-00; Fri, 21 Mar 2003 15:24:47 -0800 Message-ID: <3E7B9EC3.212B866@mindspring.com> Date: Fri, 21 Mar 2003 15:22:43 -0800 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Poul-Henning Kamp Cc: arch@freebsd.org Subject: Re: GEOM ioctl issue. References: <11639.1048286747@critter.freebsd.dk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-ELNK-Trace: b1a02af9316fbb217a47c185c03b154d40683398e744b8a4a2ff71aa52cbfe8ff1574c30f1285c66350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Poul-Henning Kamp wrote: > If the primary argument is a struct containing pointer(s) to something > else, a string or maybe another structure, these secondary arguments > are not handled in the generic ioctl syscall code, it becomes the > responsibility of the ioctl implementor to explicity call > copyin(9)/copyout(9) on these arguments. > > The way we have implemented copyin(9) and copyout(9) depends strongly > on the fact that they are executed in the corresponding thread, it is > not possible to access userland for one thread with copyin/out from > another thread, userland or kernel. > > GEOM abandons the original thread as the very first thing, there > are a multitude of reasons for this, the primary being prevention > of kernel stack overrun and the second realible and simple serialization. Go ahead and abandon the thread, but before you do, allocate a glue structure that contains: pointer to first argument pointer to thread to be abandoned Then, when you need it, you can recover the thread context to do the copyin/copyout, as necessary. If you are willing to reduce the overall size that you allow for the data, then you can "steal" it up front. You probably don't need this, because it's not like it's performance critical to not allocated and deallocate a glue structure. Otherwise, you could halve the size, and take a bit to mean "do not do early abandonment of the thread". That's probably overkill. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sat Mar 22 7: 5: 5 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ED25D37B404 for ; Sat, 22 Mar 2003 07:05:04 -0800 (PST) Received: from aslan.scsiguy.com (mail.scsiguy.com [63.229.232.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id C94DF43FA3 for ; Sat, 22 Mar 2003 07:05:03 -0800 (PST) (envelope-from gibbs@scsiguy.com) Received: from aslan.scsiguy.com (aslan.scsiguy.com [63.229.232.106]) by aslan.scsiguy.com (8.12.8/8.12.8) with ESMTP id h2MF4QIh063905; Sat, 22 Mar 2003 08:04:26 -0700 (MST) (envelope-from gibbs@scsiguy.com) Date: Sat, 22 Mar 2003 08:04:26 -0700 From: "Justin T. Gibbs" To: Poul-Henning Kamp , arch@FreeBSD.ORG Subject: Re: GEOM ioctl issue. Message-ID: <660822704.1048345466@aslan.scsiguy.com> In-Reply-To: <11639.1048286747@critter.freebsd.dk> References: <11639.1048286747@critter.freebsd.dk> X-Mailer: Mulberry/3.0.2 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > The way we have implemented copyin(9) and copyout(9) depends strongly > on the fact that they are executed in the corresponding thread, it is > not possible to access userland for one thread with copyin/out from > another thread, userland or kernel. Well, if you look at the AIO code, it is possible, it is just a pain in the but. It would be really nice to formalize the correct strategy (is what AIO does correct?) for doing this into copyin_thread(), copyout_thread(), etc. since this is the real cause of your problem. Not that I disagree with your cleanup of the da driver. I like that for aesthetic reasons. I just think that it is unacceptable to say that you cannot have an ioctl handler in a geom class device when all that is stopping you is some vmspace manipulation. -- Justin To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sat Mar 22 8:58: 6 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 523B337B401 for ; Sat, 22 Mar 2003 08:58:05 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3B88643F3F for ; Sat, 22 Mar 2003 08:58:04 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.8/8.12.8) with ESMTP id h2MGw11f074274; Sat, 22 Mar 2003 17:58:02 +0100 (CET) (envelope-from phk@phk.freebsd.dk) To: "Justin T. Gibbs" Cc: arch@FreeBSD.ORG Subject: Re: GEOM ioctl issue. From: "Poul-Henning Kamp" In-Reply-To: Your message of "Sat, 22 Mar 2003 08:04:26 MST." <660822704.1048345466@aslan.scsiguy.com> Date: Sat, 22 Mar 2003 17:58:01 +0100 Message-ID: <74273.1048352281@critter.freebsd.dk> Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message <660822704.1048345466@aslan.scsiguy.com>, "Justin T. Gibbs" writes: >> The way we have implemented copyin(9) and copyout(9) depends strongly >> on the fact that they are executed in the corresponding thread, it is >> not possible to access userland for one thread with copyin/out from >> another thread, userland or kernel. > >Well, if you look at the AIO code, it is possible, it is just a pain >in the but. It would be really nice to formalize the correct strategy >(is what AIO does correct?) for doing this into copyin_thread(), >copyout_thread(), etc. since this is the real cause of your problem. > >Not that I disagree with your cleanup of the da driver. I like that >for aesthetic reasons. I just think that it is unacceptable to say >that you cannot have an ioctl handler in a geom class device when all >that is stopping you is some vmspace manipulation. Hang on. There will be a configuration path to all geom nodes, including disk device drivers. It will just not have traditional ioctl semantics on the kernel side. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message From owner-freebsd-arch Sat Mar 22 11:49:21 2003 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D16A637B401 for ; Sat, 22 Mar 2003 11:49:20 -0800 (PST) Received: from magic.adaptec.com (magic-mail.adaptec.com [208.236.45.100]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3D5CD43FBD for ; Sat, 22 Mar 2003 11:49:20 -0800 (PST) (envelope-from gibbs@scsiguy.com) Received: from redfish.adaptec.com (redfish.adaptec.com [162.62.50.11]) by magic.adaptec.com (8.11.6/8.11.6) with ESMTP id h2MJmSl09193; Sat, 22 Mar 2003 11:48:28 -0800 Received: from btc.btc.adaptec.com (btc.btc.adaptec.com [10.100.0.52]) by redfish.adaptec.com (8.8.8+Sun/8.8.8) with ESMTP id LAA06908; Sat, 22 Mar 2003 11:48:44 -0800 (PST) Received: from [10.100.253.70] (aslan [10.100.253.70]) by btc.btc.adaptec.com (8.8.8+Sun/8.8.8) with ESMTP id MAA06657; Sat, 22 Mar 2003 12:48:38 -0700 (MST) Date: Sat, 22 Mar 2003 12:48:39 -0700 From: "Justin T. Gibbs" Reply-To: "Justin T. Gibbs" To: Poul-Henning Kamp , Bakul Shah Cc: arch@freebsd.org Subject: Re: memcpy() with specified direction of copying ? Message-ID: <8980000.1048362518@aslan.btc.adaptec.com> In-Reply-To: <9531.1047848405@critter.freebsd.dk> References: <9531.1047848405@critter.freebsd.dk> X-Mailer: Mulberry/3.0.2 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG > Well, in my case it is a matter of shared memory where the order in > which I snapshot a data structure is critical for detecting integrity > issues. Without memory barriers, the order is undefined on many cpus irrespective of the direction of copy. So, for a data structure like this: start_tag some data ... end_tag A client knows that the data is stable if start_tag and end_tag are equal only if the data is written as: start_tag = new_tag; mb(); Fill the middle in whatever order is convenient; mb(); end_tag = new_tag; -- Justin To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message