From owner-freebsd-arch@FreeBSD.ORG Sun Sep 7 00:01:53 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 636A75A6 for ; Sun, 7 Sep 2014 00:01:53 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 05F411561 for ; Sun, 7 Sep 2014 00:01:52 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s8701ntU089040 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Sat, 6 Sep 2014 18:01:49 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s8701nF0089037; Sat, 6 Sep 2014 18:01:49 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Sat, 6 Sep 2014 18:01:49 -0600 (MDT) From: Warren Block To: Warner Losh Subject: Re: Improving /etc/motd and ANSI In-Reply-To: Message-ID: References: User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Sat, 06 Sep 2014 18:01:49 -0600 (MDT) Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Sep 2014 00:01:53 -0000 On Sat, 6 Sep 2014, Warner Losh wrote: > On Sep 6, 2014, at 5:01 PM, Warren Block wrote: > >> As an experiment, this version uses ANSI underline escape sequences: >> http://www.wonkity.com/~wblock/motd/motd.ansi >> >> That reads better, is less likely to be misunderstood, and will work on normal consoles and most terminal emulations in use today. >> >> It will not display correctly on things that do not understand VT100/VT220 or ANSI codes, but I suspect that is a vanishingly small portion of the user base. Those users are also likely to be familiar with the problem. >> >> Is there some showstopper reason not to commit this ANSI version? > > It embeds the notion that all the world is a VT100 and interprets the ANSI escape code identically. > > In years past, this definitely wasn?t the case. But in those years we had many different breeds > of terminal roaming the earth, and these terminals were all somewhat different (even at the same > installation you?d have a heterogeneous setup because different departments got different > vendors to supply their gear). These changes would break that. Well, the stock motd would not display correctly. > One of the nice things about > Unix has always been it played very nicely in a heterogeneous environment and all fancy > smancy curses action was done through a layer of indirection so it would work everywhere, > unlike VMS where things were more hard-coded and it was always hard to use non-DEC > gear. > > It also assumes that all users want to see the fancy ANSI version with underlines and such. While > rather innocuous, one needn?t look any farther than gnu?s color ls to see what madness lies not > too far down this path. This assumption was already made in the previous motd, which used troff-style single-quotes to distinguish commands. We've all seen instructions like 'Type "search terms" (without the quotes)' that manage to contradict themselves within the same sentence. > Finally, console scraping code may be affected in some minor way and you?ll wind up with > text that looks weird. Again, just for /etc/motd, unless the escape codes do bad things to some types of emulations. > None of these are huge show-stoppers. But it is a very nice camel?s nose at the moment, and > I?d hate to see the rest of the camel?[*] I agree, but the only other real out-of-band delimiters we have are whitespace. Vertical space is limited by the 24/25 lines (less prompt) of a standard terminal. (Note how I sneakily did not say that was due to the VT100...except just there, but ignore that.) As another experiment, here is a version using whitespace: http://www.wonkity.com/~wblock/motd/motd.whitespace While it's not as clear as the ANSI version, it is better than the troff-style quotes version. Still requires 7-bit ASCII, though. :) From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 01:44:46 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id E66DD18A for ; Mon, 8 Sep 2014 01:44:46 +0000 (UTC) Received: from na01-by2-obe.outbound.protection.outlook.com (mail-by2lp0243.outbound.protection.outlook.com [207.46.163.243]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mail.protection.outlook.com", Issuer "MSIT Machine Auth CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id AF9A21830 for ; Mon, 8 Sep 2014 01:44:45 +0000 (UTC) Received: from BY2PR05MB728.namprd05.prod.outlook.com (10.141.223.25) by BY2PR05MB952.namprd05.prod.outlook.com (10.141.220.153) with Microsoft SMTP Server (TLS) id 15.0.1019.16; Mon, 8 Sep 2014 01:44:39 +0000 Received: from BY2PR05CA010.namprd05.prod.outlook.com (10.242.32.40) by BY2PR05MB728.namprd05.prod.outlook.com (10.141.223.25) with Microsoft SMTP Server (TLS) id 15.0.1024.12; Mon, 8 Sep 2014 01:44:38 +0000 Received: from BL2FFO11FD015.protection.gbl (2a01:111:f400:7c09::197) by BY2PR05CA010.outlook.office365.com (2a01:111:e400:2c2a::40) with Microsoft SMTP Server (TLS) id 15.0.1024.12 via Frontend Transport; Mon, 8 Sep 2014 01:44:38 +0000 Received: from P-EMF01-SAC.jnpr.net (66.129.239.15) by BL2FFO11FD015.mail.protection.outlook.com (10.173.160.223) with Microsoft SMTP Server (TLS) id 15.0.1019.14 via Frontend Transport; Mon, 8 Sep 2014 01:44:37 +0000 Received: from magenta.juniper.net (172.17.27.123) by P-EMF01-SAC.jnpr.net (172.24.192.21) with Microsoft SMTP Server (TLS) id 14.3.146.0; Sun, 7 Sep 2014 18:44:36 -0700 Received: from chaos.jnpr.net (chaos.jnpr.net [172.21.16.28]) by magenta.juniper.net (8.11.3/8.11.3) with ESMTP id s881iZn92284; Sun, 7 Sep 2014 18:44:35 -0700 (PDT) (envelope-from sjg@juniper.net) Received: from chaos (localhost [127.0.0.1]) by chaos.jnpr.net (Postfix) with ESMTP id 8907E580A2; Sun, 7 Sep 2014 18:44:35 -0700 (PDT) To: Warren Block Subject: Re: Improving /etc/motd and ANSI In-Reply-To: References: Comments: In-reply-to: Warren Block message dated "Sat, 06 Sep 2014 18:01:49 -0600." From: "Simon J. Gerraty" X-Mailer: MH-E 7.82+cvs; nmh 1.3; GNU Emacs 22.3.1 Date: Sun, 7 Sep 2014 18:44:35 -0700 Message-ID: <20140908014435.8907E580A2@chaos.jnpr.net> MIME-Version: 1.0 Content-Type: text/plain X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:66.129.239.15; CTRY:US; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(6009001)(199003)(189002)(76176999)(50986999)(76482001)(15975445006)(77156001)(102176002)(81542001)(74502001)(74662001)(46102001)(106466001)(50466002)(81156004)(110136001)(15202345003)(21056001)(48376002)(105596002)(107046002)(90896003)(85852003)(83072002)(64706001)(80022001)(95666004)(90102001)(44976005)(69596002)(19580395003)(83322001)(70486001)(89996001)(85306004)(81342001)(6806004)(93546004)(93916002)(87286001)(92726001)(79102001)(99396002)(62966002)(50226001)(33656002)(86362001)(4396001)(77982001)(87936001)(88136002)(57986006)(101356003)(76506005)(558084003)(20776003)(47776003)(118176001)(42262002); DIR:OUT; SFP:; SCL:1; SRVR:BY2PR05MB728; H:P-EMF01-SAC.jnpr.net; FPR:; MLV:sfv; PTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;UriScan:;UriScan:; X-Forefront-PRVS: 03283976A6 Received-SPF: SoftFail (protection.outlook.com: domain of transitioning juniper.net discourages use of 66.129.239.15 as permitted sender) Authentication-Results: spf=softfail (sender IP is 66.129.239.15) smtp.mailfrom=sjg@juniper.net; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:; X-OriginatorOrg: juniper.net Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 01:44:47 -0000 >As another experiment, here is a version using whitespace: >http://www.wonkity.com/~wblock/motd/motd.whitespace FWIW I find this quite reasonable. The ansi one wasn't readable as a web page ;-) and I second Warner's concernes about escapes. From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 05:32:53 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 682A8357 for ; Mon, 8 Sep 2014 05:32:53 +0000 (UTC) Received: from h2.funkthat.com (gate2.funkthat.com [208.87.223.18]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "funkthat.com", Issuer "funkthat.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 282BE1732 for ; Mon, 8 Sep 2014 05:32:52 +0000 (UTC) Received: from h2.funkthat.com (localhost [127.0.0.1]) by h2.funkthat.com (8.14.3/8.14.3) with ESMTP id s885Wo2i089278 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 7 Sep 2014 22:32:51 -0700 (PDT) (envelope-from jmg@h2.funkthat.com) Received: (from jmg@localhost) by h2.funkthat.com (8.14.3/8.14.3/Submit) id s885Wo7u089277; Sun, 7 Sep 2014 22:32:50 -0700 (PDT) (envelope-from jmg) Date: Sun, 7 Sep 2014 22:32:50 -0700 From: John-Mark Gurney To: Warren Block Subject: Re: Improving /etc/motd and ANSI Message-ID: <20140908053250.GE82175@funkthat.com> Mail-Followup-To: Warren Block , Warner Losh , freebsd-arch@freebsd.org References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Operating-System: FreeBSD 7.2-RELEASE i386 X-PGP-Fingerprint: 54BA 873B 6515 3F10 9E88 9322 9CB1 8F74 6D3F A396 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html X-TipJar: bitcoin:13Qmb6AeTgQecazTWph4XasEsP7nGRbAPE X-to-the-FBI-CIA-and-NSA: HI! HOW YA DOIN? can i haz chizburger? X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.2.2 (h2.funkthat.com [127.0.0.1]); Sun, 07 Sep 2014 22:32:51 -0700 (PDT) Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 05:32:53 -0000 Warren Block wrote this message on Sat, Sep 06, 2014 at 18:01 -0600: > As another experiment, here is a version using whitespace: > http://www.wonkity.com/~wblock/motd/motd.whitespace > > While it's not as clear as the ANSI version, it is better than the > troff-style quotes version. Still requires 7-bit ASCII, though. :) The whitespace one is good, but you should have a : after the with... Also, we should reference a url for questions or problems, and not include questions@ in the motd... The url can better include information, and other places to find help, like for forums.. P.S. I've always been confused what command means.. Does it mean the program, or the program w/ the arguments? The sh man page does not define it, but uses command to mean both the program ("set built-in command") and the program with arguments ("commands can be typed directly"). Even the wikipedia page is confuses the two... Is there no good way to tell the distinguish the two? The reason I ask is that me knowing too much thought of this: $ "man man" man man: not found But that's just me. -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not." From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 06:08:29 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id AC1A19B5 for ; Mon, 8 Sep 2014 06:08:29 +0000 (UTC) Received: from mail.0x20.net (mail.0x20.net [217.69.76.211]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 64DDA1A11 for ; Mon, 8 Sep 2014 06:08:28 +0000 (UTC) Received: from e-new.0x20.net (mail.0x20.net [IPv6:2001:aa8:fffb:1::3]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.0x20.net (Postfix) with ESMTPS id 9405E6A6002; Mon, 8 Sep 2014 08:08:25 +0200 (CEST) Received: from e-new.0x20.net (localhost [127.0.0.1]) by e-new.0x20.net (8.14.7/8.14.7) with ESMTP id s8868Pvw001698; Mon, 8 Sep 2014 08:08:25 +0200 (CEST) (envelope-from lars@e-new.0x20.net) Received: (from lars@localhost) by e-new.0x20.net (8.14.7/8.14.7/Submit) id s8868OrK001463; Mon, 8 Sep 2014 08:08:24 +0200 (CEST) (envelope-from lars) Date: Mon, 8 Sep 2014 08:08:24 +0200 From: Lars Engels To: Warren Block , Warner Losh , freebsd-arch@freebsd.org Subject: Re: Improving /etc/motd and ANSI Message-ID: <20140908060824.GO57121@e-new.0x20.net> References: <20140908053250.GE82175@funkthat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="2wyf/X6i9kneRjiV" Content-Disposition: inline In-Reply-To: <20140908053250.GE82175@funkthat.com> X-Editor: VIM - Vi IMproved 7.4 X-Operation-System: FreeBSD 8.4-RELEASE-p4 User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 06:08:29 -0000 --2wyf/X6i9kneRjiV Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Sep 07, 2014 at 10:32:50PM -0700, John-Mark Gurney wrote: > Warren Block wrote this message on Sat, Sep 06, 2014 at 18:01 -0600: > > As another experiment, here is a version using whitespace: > > http://www.wonkity.com/~wblock/motd/motd.whitespace > >=20 > > While it's not as clear as the ANSI version, it is better than the=20 > > troff-style quotes version. Still requires 7-bit ASCII, though. :) >=20 > The whitespace one is good, but you should have a : after the with... >=20 > Also, we should reference a url for questions or problems, and not > include questions@ in the motd... The url can better include > information, and other places to find help, like for forums.. +1 for adding https://forums.freebsd.org to motd. Both motd and the forums are there to help newbies. --2wyf/X6i9kneRjiV Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (FreeBSD) iQF8BAEBCgBmBQJUDUfYXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ4RjQwMDE3RTRERjUzMTI1N0FGRTUxNDlF NTRDQjM3RDNBMDg5RDZEAAoJEOVMs306CJ1t4SQH/A5VUcqiFYnoDrGNMAwMEXfL SZnZ79LEDuwdCOlCGtFPaLvkCy/dG6R1WNjHQWKnjMPz3AB7aOH8W7z4cky8Vi9u mDLLdOI+Gn26Qbk2qRqmdhvg5wNyEffCz3g0qhxcYZoxX/YSSLGmKwInZrFJ9JRz DM2Ft+AjIL3hP8accffK2hILaeH+Sg2xkiWhdh6JjpeA9pOH4eSRM+4IYRzPt+iN 9Dc0NekVebURfIRafldZqjxQxFsiY5AK3ojdEeglTImNPf1aBw7ywSabKC+OzHS9 54OAEve81GxjBnX/Ji/ihPwWKMHqNoO2T6PrZxHq4PM4POKOqo6eTl31mYeZwnk= =nBI/ -----END PGP SIGNATURE----- --2wyf/X6i9kneRjiV-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 06:41:51 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9E5A0F44 for ; Mon, 8 Sep 2014 06:41:51 +0000 (UTC) Received: from smtp2.wemm.org (smtp2.wemm.org [192.203.228.78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp2.wemm.org", Issuer "StartCom Class 1 Primary Intermediate Server CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 808781D4D for ; Mon, 8 Sep 2014 06:41:51 +0000 (UTC) Received: from overcee.wemm.org (canning.wemm.org [192.203.228.65]) by smtp2.wemm.org (Postfix) with ESMTP id 83B26398; Sun, 7 Sep 2014 23:41:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=wemm.org; s=m20140428; t=1410158510; bh=8WP4t6UOF6jDDVXdm/IKUvPgNys1Y5SP9V3DEXlw/mE=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=rl5GcdTc8F/63pDniWBuMHBX2Urj3x1dH1OEoPPXA8dSROE2k+JE+V65sV1PXcsaK 9f7gKjWMU1NWXf01buASJaJISHGfmnm3oFVBGrK/3TsYv6U9lObPQek/x76cb5Cnx1 yNdpOTp1dt9/K9R9lvaYhkevV7FIdxlgNBaE1WIQ= From: Peter Wemm To: freebsd-arch@freebsd.org Subject: Re: Improving /etc/motd and ANSI Date: Sun, 07 Sep 2014 23:41:50 -0700 Message-ID: <1431595.ma7TjrrcPZ@overcee.wemm.org> User-Agent: KMail/4.12.5 (FreeBSD/11.0-CURRENT; KDE/4.12.5; amd64; ; ) In-Reply-To: References: MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart4174929.VbNiA9keo6"; micalg="pgp-sha1"; protocol="application/pgp-signature" Cc: Warren Block , freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 06:41:51 -0000 --nextPart4174929.VbNiA9keo6 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="us-ascii" On Saturday, September 06, 2014 06:01:49 PM Warren Block wrote: > As another experiment, here is a version using whitespace: > http://www.wonkity.com/~wblock/motd/motd.whitespace One comment on this.. you can use convenience urls: http://www.freebsd.org/handbook/ http://www.freebsd.org/faq/ .. that's a little easier for remeber if you're looking at the 80x25 co= nsole=20 and you're trying to type it on another machine. =2D-=20 Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com; KI= 6FJV UTF-8: for when a ' or ... just won\342\200\231t do\342\200\246 --nextPart4174929.VbNiA9keo6 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAABAgAGBQJUDU+uAAoJEDXWlwnsgJ4E+H0H/07WsFSX3aiW7Jf2+4EHNjJu UoFZhIQYjNDpNyhj8IY9/ggBRDJd0z/NXtxqKCMdQXzJXvM3UaAY4vlsL8ds7Pz0 6jKj1o0ZR0MRhUYONrp5O0MssSNhvE3DU7PSM5BuN2+xMiYb19mU63zar0t/GpBO VqTUQtHEFcEFXDN5UbDoXK7LEoMHq4+8BU46gs4EHdGtuu+i50Wi4HFT9nVE6RJp n8yvbAG6POMwd0wgpUJKsBLRmgVrIt+2X00PIQEBiWyIvwcX3WCDqxikEBNcxemC YHBp80iPJVu2/WT3qZa3582EVKvKu+6jw/d8/1qNfnaR/PLyNoh9E0LDaCdKrNw= =yrO2 -----END PGP SIGNATURE----- --nextPart4174929.VbNiA9keo6-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 07:37:09 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5CF4FA11; Mon, 8 Sep 2014 07:37:09 +0000 (UTC) Received: from onlyone.friendlyhosting.spb.ru (onlyone.friendlyhosting.spb.ru [IPv6:2a01:4f8:131:60a2::2]) by mx1.freebsd.org (Postfix) with ESMTP id 20D32125C; Mon, 8 Sep 2014 07:37:09 +0000 (UTC) Received: from lion.home.serebryakov.spb.ru (unknown [94.19.235.70]) (Authenticated sender: lev@serebryakov.spb.ru) by onlyone.friendlyhosting.spb.ru (Postfix) with ESMTPSA id A0DE556403; Mon, 8 Sep 2014 11:37:07 +0400 (MSK) Date: Mon, 8 Sep 2014 11:37:04 +0400 From: Lev Serebryakov Reply-To: lev@FreeBSD.org Organization: FreeBSD X-Priority: 3 (Normal) Message-ID: <764889423.20140908113704@serebryakov.spb.ru> To: =?utf-8?Q?Edward_Tomasz_Napiera=C5=82a?= Subject: Re: [CFT] Autofs. In-Reply-To: <20140904124330.GB4152@pc5.home> References: <20140730071933.GA20122@pc5.home> <53F0878E.3000401@beastielabs.net> <20140817145059.GA5497@pc5.home> <5407FFB0.80203@beastielabs.net> <20140904124330.GB4152@pc5.home> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: freebsd-current@FreeBSD.org, Hans Ottevanger , freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 07:37:09 -0000 Hello, Edward. You wrote 4 =D1=81=D0=B5=D0=BD=D1=82=D1=8F=D0=B1=D1=80=D1=8F 2014 =D0=B3., = 16:43:30: ETN> It's a bug. Or rather, a missing feature. The problem here is that ETN> the "/" export "shadows" the rest. To handle this correctly, automoun= td(8) ETN> would need to mount the "/" share, then mount autofs on "/usr" etc, and ETN> then call it done. This part is easy. The problem is: how to expire ETN> (automatically unmount) it? Because of autofs mounts, the "/" share ETN> will always be busy, and thus won't ever get automatically unmounted. ETN> So, for now, we don't even try to handle this situation. I have same problem with /usr + /usr/home, which make autofs pretty useless for me :( Looks like, "autofs" mounts should not be considered "busy" for other automounted filesystems and should be processed separately... --=20 // Black Lion AKA Lev Serebryakov From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 09:57:45 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6ABDDDF9 for ; Mon, 8 Sep 2014 09:57:45 +0000 (UTC) Received: from mail.made4.biz (mail.made4.biz [IPv6:2001:41d0:2:c018::1:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2EC7412AD for ; Mon, 8 Sep 2014 09:57:45 +0000 (UTC) Received: from 2a02-8428-011b-e000-0290-f5ff-fe9d-b78c.rev.sfr.net ([2a02:8428:11b:e000:290:f5ff:fe9d:b78c] helo=magellan.dumbbell.fr) by mail.made4.biz with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.83 (FreeBSD)) (envelope-from ) id 1XQvhf-00022D-Ce for freebsd-arch@FreeBSD.org; Mon, 08 Sep 2014 11:57:43 +0200 Message-ID: <540D7D91.9000104@FreeBSD.org> Date: Mon, 08 Sep 2014 11:57:37 +0200 From: =?UTF-8?B?SmVhbi1Tw6liYXN0aWVuIFDDqWRyb24=?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: freebsd-arch@FreeBSD.org Subject: Linux kernel API wrapper: using OFED's one in other drivers Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="7n62iuQcScCsmIiNsXRUACQwREFsxhBxC" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 09:57:45 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --7n62iuQcScCsmIiNsXRUACQwREFsxhBxC Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi! OFED (sys/ofed) comes with a Linux kernel API wrapper. Beside OFED itself, it's currently used in sys/dev/cxgb and sys/dev/cxgbe. I'm playing with this wrapper to add a new feature to the i915 GPU driver [1]. Don't pay attention to the current patch as this is not the final approach I have in mind. However, the idea is there: I'd like to use it in sys/dev/drm2. The benefit of using such a wrapper in the DRM drivers are obvious: 1. It greatly reduces the diff between FreeBSD code and Linux original code. 2. It speeds up the integration of new changes in FreeBSD. 3. It eases the report of bugfixes to Linux. Those arguments are true for any driver. But in this particular case, this would allow us to reduce the gap with Linux in the graphics stack area more quickly (and we deeply need that). DragonFlyBSD is already doing that. Of course, using this wrapper as it is today isn't practicle: the code is located in a driver and it's not even part of GENERIC. The proposal is to move it outside of OFED and add it to GENERIC. I don't have a patch to show yet. I'd like to get feedback first. What do you think about that? OFED maintainers, would you be ok? [1] https://wiki.freebsd.org/Graphics/Add_HW_context_support_to_i915 --=20 Jean-S=C3=A9bastien P=C3=A9dron --7n62iuQcScCsmIiNsXRUACQwREFsxhBxC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJUDX2XXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTMngAP/3FJiq/qG81azDdC8sHkgqJy X1qv3zSMAq74YwDlCUCRRbWJafLx0TKJrE2SFgzarc1iQcQ+8HPxL2OcEvMZOqrB TLMM4aApocVlJ2KeDfVma0qrU/idNbImLKQFdeduQ7tVWELYG5wAqSUPlkjZnyF0 OLu7k8LVWiRA51hR4VLPUMDFPxwEu61YzYiWx89WrGWT4RZ6rpWPfXaCEzoVDKU6 b5LtGaUE0GXkmm75wiZo5dekTSPWWudSskgV/VgF+zXWrIgcYFi6IHJkQp0oCw1U OzM7rZ+lPKBIUwpqNz6mOKIWR3V+SXK2BXmSX39aoMvdafqAo3GKzkkc5tvv5Mj4 iQ+rTM8LEDvdygzsKb6L/vw8JkYfdYeQRO6s0GUm7BkdvHp6se6Zn1gryu7o+WHy dtKy0T5JzJWFfI7uHLQZTXJnerS84SOOtThk4VnwcGxni7Q4HDYA4Z+OTxAO4Vbc ZA6m8091r+J1p82jcTDjV0o51RJkkY5qt8b+Edxs5mtq+z17dtdYcF9G55pEW6wY VKakdbzFgnSBY4kThqH7897OryI3GU0DQZbU79rsYpGG6JA1l8ntwJ5hdcZvRbLs o2WAWG8klja+eHNvvtCI96qWaTq0sM+4IxLYBttAPjlSIPPYdy84MQAvNafIJQ79 hbO5iFrElgz70xol46N0 =NlPC -----END PGP SIGNATURE----- --7n62iuQcScCsmIiNsXRUACQwREFsxhBxC-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 10:39:14 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id BB4706A5; Mon, 8 Sep 2014 10:39:14 +0000 (UTC) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4364A183B; Mon, 8 Sep 2014 10:39:14 +0000 (UTC) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.14.9/8.14.9) with ESMTP id s88Ad8as054079 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 8 Sep 2014 13:39:08 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.9.2 kib.kiev.ua s88Ad8as054079 Received: (from kostik@localhost) by tom.home (8.14.9/8.14.9/Submit) id s88Ad8Vv054078; Mon, 8 Sep 2014 13:39:08 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Mon, 8 Sep 2014 13:39:08 +0300 From: Konstantin Belousov To: Jean-S??bastien P??dron Subject: Re: Linux kernel API wrapper: using OFED's one in other drivers Message-ID: <20140908103908.GZ2737@kib.kiev.ua> References: <540D7D91.9000104@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="+9Mf+ORMRPqeJE8p" Content-Disposition: inline In-Reply-To: <540D7D91.9000104@FreeBSD.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on tom.home Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 10:39:14 -0000 --+9Mf+ORMRPqeJE8p Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 08, 2014 at 11:57:37AM +0200, Jean-S??bastien P??dron wrote: > Hi! >=20 > OFED (sys/ofed) comes with a Linux kernel API wrapper. Beside OFED > itself, it's currently used in sys/dev/cxgb and sys/dev/cxgbe. >=20 > I'm playing with this wrapper to add a new feature to the i915 GPU > driver [1]. Don't pay attention to the current patch as this is not the > final approach I have in mind. However, the idea is there: I'd like to > use it in sys/dev/drm2. >=20 > The benefit of using such a wrapper in the DRM drivers are obvious: > 1. It greatly reduces the diff between FreeBSD code and Linux > original code. See below. > 2. It speeds up the integration of new changes in FreeBSD. > 3. It eases the report of bugfixes to Linux. >=20 > Those arguments are true for any driver. But in this particular case, > this would allow us to reduce the gap with Linux in the graphics stack > area more quickly (and we deeply need that). DragonFlyBSD is already > doing that. >=20 > Of course, using this wrapper as it is today isn't practicle: the code > is located in a driver and it's not even part of GENERIC. The proposal > is to move it outside of OFED and add it to GENERIC. >=20 > I don't have a patch to show yet. I'd like to get feedback first. What > do you think about that? OFED maintainers, would you be ok? >=20 > [1] https://wiki.freebsd.org/Graphics/Add_HW_context_support_to_i915 My main objections to use OFED wrappers for drm2 are: 1. It tightly binds different drivers with non-coordinating maintainers to the version of the Linux KPI. The Linux drivers interface is not known for its stability, and constant drift there in both formal spelling of interfaces and in semantic requires to have all drivers using the wrapper to be at the same upstream version. This objection is not specific to drm code, but so far we only speek about infiniband and drm. 2. This cause is probably very drm-specific. Comparing with infiniband, drm integration with very core of the FreeBSD kernel is quite significant. In particular, its coupling with the VM subsystem has no prior examples among the drivers, even if you consider the removed zero-copy sockets code or any driver providing dev_mmap cdevsw method. Even NVidia blob did not got that level of integration with the VM, but probably would benefit from it. The only remotely close example is vbox, but I usually avoid reading that code. I mean things like managed fictitious pages, new device pager page fault handler, or CPU cache management. All of this is used both by i195/GEM and TTM. With the use of the listed facilities, ported driver code 'feels' like FreeBSD code, not Linux code. Mix of the Linux KPI-compatible wrappers for shallow facilities, and native interfaces for anything more involved, makes the code which is hard to understand for either FreeBSD or Linux developers. This was the reason why I selected the 'no wrappers' approach for initial port of GEM, and continue to prefer it now. --+9Mf+ORMRPqeJE8p Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJUDYdMAAoJEJDCuSvBvK1BcoMQAJnXWaT2Xw+gwva01fnhiTTS u9tGgI7M9RvVVOFSlRZnXYMeFTnqsWaYiGdtjHys6jXKN9BV+AuvPtKKrDnBlgjY f8d/XI49oFJyXNbnda/6g2ttMVi9bmssuM9mHg9CWP2iZEr78PmIFbpiz6B9U4Rd jIDCYwDvnHHSJBCnxTqzNeGST3rEhi6vARtowOn1YgMPBtRI2Qjf0SF3IvmEdIua d6VGfzt1DY9Q9xAtqNv6YVKsCfauCv98f47Ar52tu3tM9VoHeSXQGiu0wP3iUyKd vaVwX9gBH3591hbpUI8xvvZxuwYSn0TsdnGk4Y2GzQfXwlO0xiopwSDAPNOcrD2m p3q32rOxeUj8WLNEz9qask7keVlJC9aQpW5AAYhjsDvPJAJjsutr1sYCjmJIyG66 aA3FABC2ECg2Qsx7O+OM1TDXAwAgHkh1FJUkxEDD/XV1Hl/AI27T7mzYOu+JAWjL 9qRntkcJZNqOj23gpGtFcOpP2lpcWAr/jB1oPo4SbyDyzismFaJD/t20Lxir6iuV pHg0Yt/zLLb0MkmV2q2iEvPal5MNdJAlqFREGfoUzbeTk8hVx4IxO1oTty+mVjO0 d6gAp34RsKfvJj8prUF5E5NhRew0GN2CHyMIpx8GNah0kRKtAcDkZ4hxM8r+up8g zbhihsgXocJHayBqs+Zu =vMSn -----END PGP SIGNATURE----- --+9Mf+ORMRPqeJE8p-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 11:16:56 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 2235834B for ; Mon, 8 Sep 2014 11:16:56 +0000 (UTC) Received: from smtp.des.no (smtp.des.no [194.63.250.102]) by mx1.freebsd.org (Postfix) with ESMTP id D65DF1CEE for ; Mon, 8 Sep 2014 11:16:55 +0000 (UTC) Received: from nine.des.no (smtp.des.no [194.63.250.102]) by smtp-int.des.no (Postfix) with ESMTP id C96FB7753; Mon, 8 Sep 2014 11:16:54 +0000 (UTC) Received: by nine.des.no (Postfix, from userid 1001) id 49E8C3A1; Mon, 8 Sep 2014 13:16:47 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Peter Wemm Subject: Re: Improving /etc/motd and ANSI References: <1431595.ma7TjrrcPZ@overcee.wemm.org> Date: Mon, 08 Sep 2014 13:16:47 +0200 In-Reply-To: <1431595.ma7TjrrcPZ@overcee.wemm.org> (Peter Wemm's message of "Sun, 07 Sep 2014 23:41:50 -0700") Message-ID: <86ioky1hwg.fsf@nine.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: Warren Block , freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 11:16:56 -0000 Peter Wemm writes: > One comment on this.. you can use convenience urls: > http://www.freebsd.org/handbook/ > http://www.freebsd.org/faq/ You can even drop the www in front... DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 13:15:02 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id EC395323 for ; Mon, 8 Sep 2014 13:15:02 +0000 (UTC) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id CDEA81B3B for ; Mon, 8 Sep 2014 13:15:02 +0000 (UTC) Received: from marvin.lab.vangyzen.net (c-24-125-214-90.hsd1.va.comcast.net [24.125.214.90]) by smtp.vangyzen.net (Postfix) with ESMTPSA id BA2CD56444; Mon, 8 Sep 2014 08:15:01 -0500 (CDT) Message-ID: <540DABD4.20908@vangyzen.net> Date: Mon, 08 Sep 2014 09:15:00 -0400 From: Eric van Gyzen User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Warren Block , freebsd-arch@freebsd.org Subject: Re: Improving /etc/motd and ANSI References: <20140908053250.GE82175@funkthat.com> In-Reply-To: <20140908053250.GE82175@funkthat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 13:15:03 -0000 On 09/08/2014 01:32, John-Mark Gurney wrote: > Also, we should reference a url for questions or problems, and not > include questions@ in the motd... The url can better include > information, and other places to find help, like for forums. Warren: Thank you for your effort to maintain this. As another possibility, how about putting just the following in /etc/motd: ==== Welcome to FreeBSD! For help getting started, please visit: http://freebsd.org/welcome Edit /etc/motd to change this login announcement. ==== That URL would contain the information currently in /etc/motd. We could easily maintain it to match the real world. Always up-to-date information, extreme flexibility for presentation, small motd, zero risk of terminal incompatibility, no confusing quotes. Eric From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 13:39:23 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id F0D96C2F for ; Mon, 8 Sep 2014 13:39:23 +0000 (UTC) Received: from land.berklix.org (land.berklix.org [144.76.10.75]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 793C11DB8 for ; Mon, 8 Sep 2014 13:39:23 +0000 (UTC) Received: from mart.js.berklix.net (p5DCBE65F.dip0.t-ipconnect.de [93.203.230.95]) (authenticated bits=128) by land.berklix.org (8.14.5/8.14.5) with ESMTP id s88Daqrq032975; Mon, 8 Sep 2014 13:36:53 GMT (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (fire.js.berklix.net [192.168.91.41]) by mart.js.berklix.net (8.14.3/8.14.3) with ESMTP id s88DdB3P085204; Mon, 8 Sep 2014 15:39:11 +0200 (CEST) (envelope-from jhs@berklix.com) Received: from fire.js.berklix.net (localhost [127.0.0.1]) by fire.js.berklix.net (8.14.7/8.14.7) with ESMTP id s88DcY7Q018096; Mon, 8 Sep 2014 15:38:46 +0200 (CEST) (envelope-from jhs@berklix.com) Message-Id: <201409081338.s88DcY7Q018096@fire.js.berklix.net> To: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= Subject: Re: Improving /etc/motd and ANSI From: "Julian H. Stacey" Organization: http://berklix.com BSD Unix Linux Consultants, Munich Germany User-agent: EXMH on FreeBSD http://berklix.com/free/ X-URL: http://www.berklix.com In-reply-to: Your message "Mon, 08 Sep 2014 13:16:47 +0200." <86ioky1hwg.fsf@nine.des.no> Date: Mon, 08 Sep 2014 15:38:34 +0200 Cc: Warren Block , freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 13:39:24 -0000 =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= wrote: > Peter Wemm writes: > > One comment on this.. you can use convenience urls: > > http://www.freebsd.org/handbook/ > > http://www.freebsd.org/faq/ > > You can even drop the www in front... Best keep www. prepended : A decade or so back I noticed http://freebsd.org answered as well as http://www.freebsd.org & so I started dropping the www, but webmaster@ corrected me, pointing out some of the freebsd host[s] answering the DNS A record for the cluster might then or in future not be served by httpd. ( Similarly, I'm gradually restoring the www. prefix I previously stripped off some of my own http://www.berklix.com URLs, as I've realised there may be times when I want browsers to access only the www DNS A rec. httpd served subset of my berklix.com cluster (eg when I'm reconfiguring/ upgrading one host etc) ) I believe though some browsers automatically prepend a www. [if original URL first fails?] but some do not prepend www. Cheers, Julian -- Julian Stacey, BSD Linux Unix C Sys Eng Consultant Munich http://berklix.com Interleave replies Below, like a play script. From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 14:03:15 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0EFE21C9 for ; Mon, 8 Sep 2014 14:03:15 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id B641B10C5 for ; Mon, 8 Sep 2014 14:03:14 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88E34iE059399 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 08:03:05 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88E34bd059396; Mon, 8 Sep 2014 08:03:04 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 08:03:04 -0600 (MDT) From: Warren Block To: Eric van Gyzen Subject: Re: Improving /etc/motd and ANSI In-Reply-To: <540DABD4.20908@vangyzen.net> Message-ID: References: <20140908053250.GE82175@funkthat.com> <540DABD4.20908@vangyzen.net> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 08:03:05 -0600 (MDT) Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 14:03:15 -0000 On Mon, 8 Sep 2014, Eric van Gyzen wrote: > On 09/08/2014 01:32, John-Mark Gurney wrote: >> Also, we should reference a url for questions or problems, and not >> include questions@ in the motd... The url can better include >> information, and other places to find help, like for forums. > > Warren: Thank you for your effort to maintain this. > > As another possibility, how about putting just the following in /etc/motd: > > ==== > > Welcome to FreeBSD! For help getting started, please visit: > > http://freebsd.org/welcome > > Edit /etc/motd to change this login announcement. > > ==== > > That URL would contain the information currently in /etc/motd. We could > easily maintain it to match the real world. Always up-to-date > information, extreme flexibility for presentation, small motd, zero risk > of terminal incompatibility, no confusing quotes. It was pointed out to me not that long ago that we have no web browser in the base install. Having a URL-only introduction would make it more difficult for some users to read that introduction. From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 14:11:08 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A8833645 for ; Mon, 8 Sep 2014 14:11:08 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 5AB6311F3 for ; Mon, 8 Sep 2014 14:11:08 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88EB6gS061454 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 08:11:07 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88EB6or061451; Mon, 8 Sep 2014 08:11:06 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 08:11:06 -0600 (MDT) From: Warren Block To: Peter Wemm Subject: Re: Improving /etc/motd and ANSI In-Reply-To: <1431595.ma7TjrrcPZ@overcee.wemm.org> Message-ID: References: <1431595.ma7TjrrcPZ@overcee.wemm.org> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 08:11:07 -0600 (MDT) Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 14:11:08 -0000 On Sun, 7 Sep 2014, Peter Wemm wrote: > On Saturday, September 06, 2014 06:01:49 PM Warren Block wrote: > >> As another experiment, here is a version using whitespace: >> http://www.wonkity.com/~wblock/motd/motd.whitespace > > One comment on this.. you can use convenience urls: > http://www.freebsd.org/handbook/ > http://www.freebsd.org/faq/ > .. that's a little easier for remeber if you're looking at the 80x25 console > and you're trying to type it on another machine. Much easier, I'd say. Done, and web versions updated: http://www.wonkity.com/~wblock/motd/motd http://www.wonkity.com/~wblock/motd/motd.diff http://www.wonkity.com/~wblock/motd/motd.ansi http://www.wonkity.com/~wblock/motd/motd.whitespace From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 14:20:39 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6E0EFA9D for ; Mon, 8 Sep 2014 14:20:39 +0000 (UTC) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id 4E9F41306 for ; Mon, 8 Sep 2014 14:20:39 +0000 (UTC) Received: from marvin.lab.vangyzen.net (c-24-125-214-90.hsd1.va.comcast.net [24.125.214.90]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 634C856444; Mon, 8 Sep 2014 09:20:38 -0500 (CDT) Message-ID: <540DBB35.6070003@vangyzen.net> Date: Mon, 08 Sep 2014 10:20:37 -0400 From: Eric van Gyzen User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Warren Block Subject: Re: Improving /etc/motd and ANSI References: <20140908053250.GE82175@funkthat.com> <540DABD4.20908@vangyzen.net> In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 14:20:39 -0000 On 09/08/2014 10:03, Warren Block wrote: > On Mon, 8 Sep 2014, Eric van Gyzen wrote: > >> On 09/08/2014 01:32, John-Mark Gurney wrote: >>> Also, we should reference a url for questions or problems, and not >>> include questions@ in the motd... The url can better include >>> information, and other places to find help, like for forums. >> >> Warren: Thank you for your effort to maintain this. >> >> As another possibility, how about putting just the following in >> /etc/motd: >> >> ==== >> >> Welcome to FreeBSD! For help getting started, please visit: >> >> http://freebsd.org/welcome >> >> Edit /etc/motd to change this login announcement. >> >> ==== >> >> That URL would contain the information currently in /etc/motd. We could >> easily maintain it to match the real world. Always up-to-date >> information, extreme flexibility for presentation, small motd, zero risk >> of terminal incompatibility, no confusing quotes. > > It was pointed out to me not that long ago that we have no web browser > in the base install. Having a URL-only introduction would make it > more difficult for some users to read that introduction. So, there are users who install FreeBSD as the _only_ operating system on the _only_ web-capable device in their vicinity, yet need the assistance provided by this introduction? Please help me understand this kind of user, as my imagination fails me. Eric From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 14:25:57 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 09B2FDBA for ; Mon, 8 Sep 2014 14:25:57 +0000 (UTC) Received: from mail.made4.biz (mail.made4.biz [IPv6:2001:41d0:2:c018::1:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BF50013E0 for ; Mon, 8 Sep 2014 14:25:56 +0000 (UTC) Received: from 2a02-8428-011b-e000-0290-f5ff-fe9d-b78c.rev.sfr.net ([2a02:8428:11b:e000:290:f5ff:fe9d:b78c] helo=magellan.dumbbell.fr) by mail.made4.biz with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.83 (FreeBSD)) (envelope-from ) id 1XQztC-0003dy-5U; Mon, 08 Sep 2014 16:25:54 +0200 Message-ID: <540DBC64.7050302@FreeBSD.org> Date: Mon, 08 Sep 2014 16:25:40 +0200 From: =?windows-1252?Q?Jean-S=E9bastien_P=E9dron?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Konstantin Belousov Subject: Re: Linux kernel API wrapper: using OFED's one in other drivers References: <540D7D91.9000104@FreeBSD.org> <20140908103908.GZ2737@kib.kiev.ua> In-Reply-To: <20140908103908.GZ2737@kib.kiev.ua> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="p5mxqV1VW8IGhjcTf095IU0DxIa5mM0qW" Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 14:25:57 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --p5mxqV1VW8IGhjcTf095IU0DxIa5mM0qW Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 08.09.2014 12:39, Konstantin Belousov wrote: > My main objections to use OFED wrappers for drm2 are: >=20 > 1. It tightly binds different drivers with non-coordinating maintainers= > to the version of the Linux KPI. The Linux drivers interface is not= > known for its stability, and constant drift there in both formal > spelling of interfaces and in semantic requires to have all drivers > using the wrapper to be at the same upstream version. >=20 > This objection is not specific to drm code, but so far we only speek= > about infiniband and drm. A small note before going on: cxgb(4) and cxgbe(4) use OFED's wrapper too= =2E > 2. This cause is probably very drm-specific. Comparing with infiniband= , > drm integration with very core of the FreeBSD kernel is quite > significant. In particular, its coupling with the VM subsystem > has no prior examples among the drivers, even if you consider the > removed zero-copy sockets code or any driver providing dev_mmap > cdevsw method. Even NVidia blob did not got that level of integratio= n > with the VM, but probably would benefit from it. The only remotely > close example is vbox, but I usually avoid reading that code. >=20 > I mean things like managed fictitious pages, new device pager > page fault handler, or CPU cache management. All of this is used > both by i195/GEM and TTM. >=20 > With the use of the listed facilities, ported driver code 'feels' li= ke > FreeBSD code, not Linux code. Mix of the Linux KPI-compatible wrapp= ers > for shallow facilities, and native interfaces for anything more > involved, makes the code which is hard to understand for either Free= BSD > or Linux developers. This was the reason why I selected the > 'no wrappers' approach for initial port of GEM, and continue to > prefer it now. You're right the Linux interface instability is even a documented feature [1]. And yes, I was only considering facilities such as data structures (list, idr), taskqueues/workqueues, malloc/kmalloc or some printf()/KASSERT() macros. I don't want to eliminate the diff with Linux, only reduce it. The integration with the VM is out of the scope of this proposal and locking primitives are to be considered carefully if we want to wrap them (ie. out of the scope for now too). The facilities I mention are a small piece of code. I believe they are far more easy to maintain than replacing every single calls to malloc() and friends and then handling conflicts when trying to import new changes= =2E To address the instability problem, we could have a directory for each used versions and a directory for the common files. For instance: linux/common/linux/types.h linux/3.8/linux/idr.h linux/3.8/linux/idr.c (the hierarchy and files are fake) And in idr.c, we could have idr_for_each_38() (hidden behind a macro in idr.h) if the API changed since eg. Linux 3.4. A consumer of this wrapper would need to include both directories: -I.../linux/3.8 -I.../linux/common I can't comment on the frequency of disruptive changes in the Linux API. By quickly looking at the history for eg. idr.[ch], it's hard to tell. If you feel that it moves too fast, then I don't mind having a DRM-specific wrapper. About the difficulty to read the code and the absence of "feels like home" impression, it's true that the reader would need to know both kernels. But a FreeBSD contributor who wants to work on this component already has to read Linux source anyway, because today, the code only flows in one direction. I find this problem acceptable compared to the benefit. My main point is that we already struggle with the maintenance of the DRM subsystem and two drivers. I believe a wrapper would remove a lot from that "pain". [1] https://www.kernel.org/doc/Documentation/stable_api_nonsense.txt --=20 Jean-S=E9bastien P=E9dron --p5mxqV1VW8IGhjcTf095IU0DxIa5mM0qW Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJUDbxxXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTMB4EP/i42W7pYSwHBlV6tBeyXX6qY 4BPVcP5Vve/+KTErEWavNud4JCeVnLHqO7+hpMjyesab3p6qju1TZC7KjkEoyys7 O1OjJX07057HvhD1ihX9WN/JbNH1HDjVQWtGYOfLetu31gPt53h8uKpBTY5BwjXu BQhPutpwhOtmOLmL9+8y8JG0ccAhilo+wgbmK495mHSX28BTiace8BgnYLC0sGmh N9AakjYAnGEmCA3BGUkjnHWiZLjMKELMh8O3YtINS3CXGEYGebizCt8SIwV8Hgeu kb+2nvXcb9IDxmDUZ7/S7TTQsjdK/BktMYVllnFFoRS5NKiBs5K54b3cdhkjI3FA fy2a49dz8jRu2LVKh3ye3kLXxw40F6gZTTyUK7FD7uSDlvnMVbyuC2auuSzYv3wT 4tdtyUeBNgs2db2cjdjVoy2YgagVnucUyDmnZH5yF3/UvwiVAwgRnLOINDY+8cAZ OWX9ZvDZmWZ/TDba0kT7v927COwqQy81pfq11xP03eil0SZqe8KG3zRC+5Se9XlS DGDr7Lg/ia3/mg56UL2i62tqb3YDvcWxxcvAqST84u/FBUEYLj7iwdSC34epa96E NOfO1vF/1p5luhEamFJeYjP0hZtYYPil0KLYnSp82ZGuWLFc7Fh3j14iFk6nD7JO arfUNZo16VyApJe1QFln =MfNd -----END PGP SIGNATURE----- --p5mxqV1VW8IGhjcTf095IU0DxIa5mM0qW-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 14:36:22 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CC6D0272 for ; Mon, 8 Sep 2014 14:36:22 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 77599159D for ; Mon, 8 Sep 2014 14:36:22 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88EaKWe067827 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 08:36:20 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88EaKJp067824; Mon, 8 Sep 2014 08:36:20 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 08:36:20 -0600 (MDT) From: Warren Block To: Eric van Gyzen Subject: Re: Improving /etc/motd and ANSI In-Reply-To: <540DBB35.6070003@vangyzen.net> Message-ID: References: <20140908053250.GE82175@funkthat.com> <540DABD4.20908@vangyzen.net> <540DBB35.6070003@vangyzen.net> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 08:36:21 -0600 (MDT) Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 14:36:22 -0000 On Mon, 8 Sep 2014, Eric van Gyzen wrote: > On 09/08/2014 10:03, Warren Block wrote: >> It was pointed out to me not that long ago that we have no web browser >> in the base install. Having a URL-only introduction would make it >> more difficult for some users to read that introduction. > > So, there are users who install FreeBSD as the _only_ operating system > on the _only_ web-capable device in their vicinity, yet need the > assistance provided by this introduction? Please help me understand > this kind of user, as my imagination fails me. Mostly my view also, but look at it the other way: here is the operating system, and here are the documents, ...but not in a form that can be read with the operating system just installed. For now, the hybrid approach of both URLs and text covers all users. It just makes presenting a readable, compact introduction more difficult. From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 14:49:34 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7CAEBAAC for ; Mon, 8 Sep 2014 14:49:34 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 297DC1844 for ; Mon, 8 Sep 2014 14:49:33 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88EnWL1071055 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 08:49:32 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88EnU2C071050; Mon, 8 Sep 2014 08:49:32 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 08:49:30 -0600 (MDT) From: Warren Block To: Peter Wemm Subject: Re: Improving /etc/motd and ANSI In-Reply-To: <1431595.ma7TjrrcPZ@overcee.wemm.org> Message-ID: References: <1431595.ma7TjrrcPZ@overcee.wemm.org> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 08:49:32 -0600 (MDT) Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 14:49:34 -0000 On Sun, 7 Sep 2014, Peter Wemm wrote: > On Saturday, September 06, 2014 06:01:49 PM Warren Block wrote: > >> As another experiment, here is a version using whitespace: >> http://www.wonkity.com/~wblock/motd/motd.whitespace > > One comment on this.. you can use convenience urls: > http://www.freebsd.org/handbook/ > http://www.freebsd.org/faq/ > .. that's a little easier for remeber if you're looking at the 80x25 console > and you're trying to type it on another machine. Is there a shorter form for the mailing list web pages, like https://lists.freebsd.org/mailman/listinfo/freebsd-questions ? From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 15:16:13 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9DAB5EA9 for ; Mon, 8 Sep 2014 15:16:13 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 481EC1BD4 for ; Mon, 8 Sep 2014 15:16:13 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88FGAam077786 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 09:16:11 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88FGAW0077783; Mon, 8 Sep 2014 09:16:10 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 09:16:10 -0600 (MDT) From: Warren Block To: John-Mark Gurney Subject: Re: Improving /etc/motd and ANSI In-Reply-To: <20140908053250.GE82175@funkthat.com> Message-ID: References: <20140908053250.GE82175@funkthat.com> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 09:16:11 -0600 (MDT) Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 15:16:13 -0000 On Sun, 7 Sep 2014, John-Mark Gurney wrote: > Also, we should reference a url for questions or problems, and not > include questions@ in the motd... The url can better include > information, and other places to find help, like for forums.. ... > P.S. I've always been confused what command means.. Does it mean the > program, or the program w/ the arguments? Could be either, it's context-sensitive, but point taken. New whitespace version: http://www.wonkity.com/~wblock/motd/motd.whitespace-url This one includes the URL rather than questions@, includes the forum URL, and removes "command". From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 15:23:25 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id AA0FDC8 for ; Mon, 8 Sep 2014 15:23:25 +0000 (UTC) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id 89AF41CB7 for ; Mon, 8 Sep 2014 15:23:25 +0000 (UTC) Received: from marvin.lab.vangyzen.net (c-24-125-214-90.hsd1.va.comcast.net [24.125.214.90]) by smtp.vangyzen.net (Postfix) with ESMTPSA id 275BF56444; Mon, 8 Sep 2014 10:23:24 -0500 (CDT) Message-ID: <540DC9EB.4000905@vangyzen.net> Date: Mon, 08 Sep 2014 11:23:23 -0400 From: Eric van Gyzen User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Warren Block , John-Mark Gurney Subject: Re: Improving /etc/motd and ANSI References: <20140908053250.GE82175@funkthat.com> In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 15:23:25 -0000 On 09/08/2014 11:16, Warren Block wrote: > On Sun, 7 Sep 2014, John-Mark Gurney wrote: > >> Also, we should reference a url for questions or problems, and not >> include questions@ in the motd... The url can better include >> information, and other places to find help, like for forums.. > ... >> P.S. I've always been confused what command means.. Does it mean the >> program, or the program w/ the arguments? > > Could be either, it's context-sensitive, but point taken. > > New whitespace version: > http://www.wonkity.com/~wblock/motd/motd.whitespace-url > > This one includes the URL rather than questions@, includes the forum > URL, and removes "command". This looks really good. Eric From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 15:37:55 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 725B7804 for ; Mon, 8 Sep 2014 15:37:55 +0000 (UTC) Received: from mail.made4.biz (mail.made4.biz [IPv6:2001:41d0:2:c018::1:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 32D381E34 for ; Mon, 8 Sep 2014 15:37:55 +0000 (UTC) Received: from 2a02-8428-011b-e000-0290-f5ff-fe9d-b78c.rev.sfr.net ([2a02:8428:11b:e000:290:f5ff:fe9d:b78c] helo=magellan.dumbbell.fr) by mail.made4.biz with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.83 (FreeBSD)) (envelope-from ) id 1XR10r-00042b-2M for freebsd-arch@freebsd.org; Mon, 08 Sep 2014 17:37:53 +0200 Message-ID: <540DCD4C.2000001@FreeBSD.org> Date: Mon, 08 Sep 2014 17:37:48 +0200 From: =?windows-1252?Q?Jean-S=E9bastien_P=E9dron?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: freebsd-arch@freebsd.org Subject: Re: Improving /etc/motd and ANSI References: <20140908053250.GE82175@funkthat.com> In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Bhr3fVbLS1en6qjSWIhDRv8rD6PohXCrd" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 15:37:55 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --Bhr3fVbLS1en6qjSWIhDRv8rD6PohXCrd Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 08.09.2014 17:16, Warren Block wrote: > New whitespace version: > http://www.wonkity.com/~wblock/motd/motd.whitespace-url Maybe normalize "FreeBSD" in the URL domain names? Likewise for the protocol (http vs. https). --=20 Jean-S=E9bastien P=E9dron --Bhr3fVbLS1en6qjSWIhDRv8rD6PohXCrd Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJUDc1QXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTMqBMQAOQiNPQrYXWIu7x0N8dMRtgr Hp4pjcQXTzIqCk6327AGWoWxsS4w3wbicYXVb5xYjfR4taGBGk8B8my32KwLxyN/ PWTkafm5mY+XdWTViGwQLjbcIegEtw2vNyuWXfjwdrk44c0SmaV7hkwfPLo2J1i0 qep8bhQtopgVRQUYaCvAf+YPmManSQydl1FqVJM/giJy0odsdsioN5i4r6zYJZ/f J8casuUlGGirXp+3c/X42MS1f79PC5A5o8tgBdha+7Hnh3vx3CHv77NvtHrA+dDP DqwwbzxHMYfMtPcWO6vDgK8F6CNlHXFw2GsdG7tMCFfUjomxrbOLFTAxxHeKjVJ1 L7N4jgYIf3jexNqD/98w9bgWUwcB0JqB82FMWwyYFnz8Ho0f2+IPCjbwjTiIvb48 l5Q4jodmQJ6o4Y1bR7tD/vTSb6Ix6Pfnd8ujcvlwdXJrM5DcHXS0yrWlm/RthzY1 iLRQhzJb/5+yfl42CeN+BJqPAie1rf0nW0n8OjYQli1IqHnf4zdDnE2wNkpvAttr P5JVxvL0w+jgBsdVHnynzIQPbdafvTeTCFWxDs8ZSNzkYglFojMZJRzai0etYxCx Qsk2xpPd/6SY+Cl7OTQcL49zE6aTyoZg/n1T8yA7crZVBJDragbmjBEqG5UYDWGH BG+cpMPMQ7BfS6YfXLqS =Fgv5 -----END PGP SIGNATURE----- --Bhr3fVbLS1en6qjSWIhDRv8rD6PohXCrd-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 16:12:10 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0030CB04 for ; Mon, 8 Sep 2014 16:12:09 +0000 (UTC) Received: from mho-01-ewr.mailhop.org (mho-03-ewr.mailhop.org [204.13.248.66]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C57491340 for ; Mon, 8 Sep 2014 16:12:09 +0000 (UTC) Received: from [73.34.117.227] (helo=ilsoft.org) by mho-01-ewr.mailhop.org with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.72) (envelope-from ) id 1XR1Xt-000Glh-WB; Mon, 08 Sep 2014 16:12:02 +0000 Received: from [172.22.42.240] (revolution.hippie.lan [172.22.42.240]) by ilsoft.org (8.14.9/8.14.9) with ESMTP id s88GC09b021703; Mon, 8 Sep 2014 10:12:00 -0600 (MDT) (envelope-from ian@FreeBSD.org) X-Mail-Handler: Dyn Standard SMTP by Dyn X-Originating-IP: 73.34.117.227 X-Report-Abuse-To: abuse@dyndns.com (see http://www.dyndns.com/services/sendlabs/outbound_abuse.html for abuse reporting information) X-MHO-User: U2FsdGVkX1+iSJCTOhRo4sBAs6ZrMVd8 X-Authentication-Warning: paranoia.hippie.lan: Host revolution.hippie.lan [172.22.42.240] claimed to be [172.22.42.240] Subject: Re: Improving /etc/motd and ANSI From: Ian Lepore To: Warren Block In-Reply-To: References: <20140908053250.GE82175@funkthat.com> Content-Type: text/plain; charset="us-ascii" Date: Mon, 08 Sep 2014 10:11:59 -0600 Message-ID: <1410192719.1150.403.camel@revolution.hippie.lan> Mime-Version: 1.0 X-Mailer: Evolution 2.32.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: John-Mark Gurney , freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 16:12:10 -0000 On Mon, 2014-09-08 at 09:16 -0600, Warren Block wrote: > On Sun, 7 Sep 2014, John-Mark Gurney wrote: > > > Also, we should reference a url for questions or problems, and not > > include questions@ in the motd... The url can better include > > information, and other places to find help, like for forums.. > ... > > P.S. I've always been confused what command means.. Does it mean the > > program, or the program w/ the arguments? > > Could be either, it's context-sensitive, but point taken. > > New whitespace version: > http://www.wonkity.com/~wblock/motd/motd.whitespace-url > > This one includes the URL rather than questions@, includes the forum > URL, and removes "command". This is supposedly for low-information users, yet it uses the quintessential unix-geek-shorthand "hier(7)" to reference a manpage. Even if they take the advice of consulting 'man man' there's nothing in there that helps a newbie decode 'hier(7)'. Since there's only one hier topic system wide, maybe we should point them directly to the command 'man hier'. (Aside... I've been working with freebsd since 1996, and I only discovered the existance of hier(7) a couple years ago. I guess that's because 'rm /etc/motd' is one of the first things I do on a new system.) -- Ian From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 16:29:58 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id B623249F; Mon, 8 Sep 2014 16:29:58 +0000 (UTC) Received: from mail-pd0-x230.google.com (mail-pd0-x230.google.com [IPv6:2607:f8b0:400e:c02::230]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 753A91535; Mon, 8 Sep 2014 16:29:58 +0000 (UTC) Received: by mail-pd0-f176.google.com with SMTP id y13so3363123pdi.35 for ; Mon, 08 Sep 2014 09:29:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; bh=xy98zS2EBXKB+95tKZQalslzwxGaZJfM2OfOD+vWUss=; b=Sgvwo6pzih+InVcM96KUcchB4k5ieFqd8aXZVHB01c+hPlQ1/R7QX3i6xpUe4rFpGm FHjiouSrWMvbvuLHJ8lMtUsddxNAQWjYR+2qqsN8D7Ul6Hpvi9nn/GUBOonL1zSqnkl8 UwVQ5VUVWZUKJCwl+hxl+uyZ6qxr6MNFTFaS4lhHMNI/eAlgqzcq2/1WH0ELD+BWML1V TtSI2Gk8BCeTGNsBjaMjSN94VMVYc6dC9CcC7LQR16bm1zhQ2WG03gxoJGaw5e4iVLtq pveuVhm+MGEjnLyLVvS0qOC1o5wotDurbp1G4ufOLN2wT86nO4rmcqp0F3BVQI0nx0dK yPEA== X-Received: by 10.68.189.137 with SMTP id gi9mr21854229pbc.87.1410193797794; Mon, 08 Sep 2014 09:29:57 -0700 (PDT) Received: from ?IPv6:2601:8:ab80:7d6:9024:45ea:9d5:4ede? ([2601:8:ab80:7d6:9024:45ea:9d5:4ede]) by mx.google.com with ESMTPSA id bn4sm9304385pbc.40.2014.09.08.09.29.56 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 08 Sep 2014 09:29:57 -0700 (PDT) Content-Type: multipart/signed; boundary="Apple-Mail=_DCF9E948-C3D1-40D6-B4C1-306E23171DF3"; protocol="application/pgp-signature"; micalg=pgp-sha512 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: [RFC] Add __arraycount from NetBSD to sys/cdefs.h From: yaneurabeya@gmail.com In-Reply-To: <8D279BDC-7D40-4750-8DA7-A4535DD2E458@bsdimp.com> Date: Mon, 8 Sep 2014 09:29:54 -0700 Message-Id: <146C3E96-7461-4D30-8B7F-5E20F72CF061@gmail.com> References: <8D279BDC-7D40-4750-8DA7-A4535DD2E458@bsdimp.com> To: Warner Losh X-Mailer: Apple Mail (2.1878.6) Cc: Julio Merino , "rpaulo@freebsd.org" , "freebsd-arch@FreeBSD.org Arch" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 16:29:58 -0000 --Apple-Mail=_DCF9E948-C3D1-40D6-B4C1-306E23171DF3 Content-Type: multipart/mixed; boundary="Apple-Mail=_F8F39904-E01A-40C8-9E24-7132A67CC7A4" --Apple-Mail=_F8F39904-E01A-40C8-9E24-7132A67CC7A4 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 On Sep 3, 2014, at 21:17, Warner Losh wrote: > On Sep 3, 2014, at 9:45 PM, Garrett Cooper = wrote: >=20 >> Hi all, >> In order to ease porting code and reduce divergence with NetBSD >> when importing code (a large chunk of which for me are tests), I = would >> like to move nitems to sys/cdefs.h and alias __arraycount to nitems. >> Here's the __arraycount #define in lib/libnetbsd/sys/cdefs.h: >>=20 >> 44 /* >> 45 * Return the number of elements in a statically-allocated array, >> 46 * __x. >> 47 */ >> 48 #define __arraycount(__x) (sizeof(__x) / sizeof(__x[0])) >>=20 >> Here's the nitems #define in sys/sys/param.h: >>=20 >> 277 #define nitems(x) (sizeof((x)) / sizeof((x)[0])) >>=20 >> sys/cdefs.h gets pulled in automatically with sys/param.h, so >> anything using nitems will continue to function like before (see = below >> for more details). I've attached a patch which addresses all = hardcoded >> definitions in the tree added by FreeBSD developers. >> If there aren't any major concerns with my proposed change, I'll >> put it up for review on Phabricator. >> Thank you! >> -Garrett >>=20 >> $ cat cdefs_pound_define.c >> #include >>=20 >> #ifdef _SYS_CDEFS_H_ >> #warning "sys/cdefs.h has been included" >> #endif >> $ cc -c cdefs_pound_define.c >> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" = [-W#warnings] >> #warning "sys/cdefs.h has been included" >> ^ >> 1 warning generated. >> $ cc -D_KERNEL -c cdefs_pound_define.c >> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" = [-W#warnings] >> #warning "sys/cdefs.h has been included" >> ^ >> 1 warning generated. >> $ gcc -c cdefs_pound_define.c >> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been = included" >> $ gcc -D_KERNEL -c cdefs_pound_define.c >> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been = included=94 >=20 > I wouldn=92t bother changing the nitems #define. There=92s no need, = really, to do that. Rethinking my proposal, I agree. I had lofty hopes for unifying the = macros, but the functional duplication (1 line) is harmless. > I=92d also be more inclined to believe the test if you tested what the = thing does rather than test for an artificial, implementation defined = side effect. Sure. I provided a lazy proof instead of a full proof :). > But honestly the amount of duplication saved here is rather tiny=85 Indeed! Thank you for the input :) =97 I=92ve attached a new patch which = doesn=92t disturb nitems or sys/param.h. Thanks! -Garrett --Apple-Mail=_F8F39904-E01A-40C8-9E24-7132A67CC7A4 Content-Disposition: attachment; filename=0001-Add-__arraycount-macro-from-NetBSD-to-ease-porting.patch Content-Type: application/octet-stream; name="0001-Add-__arraycount-macro-from-NetBSD-to-ease-porting.patch" Content-Transfer-Encoding: quoted-printable =46rom=20ba220f306a1849948ecb198c6f2424ed6cfec6bc=20Mon=20Sep=2017=20= 00:00:00=202001=0AFrom:=20Garrett=20Cooper=20=0A= Date:=20Thu,=204=20Sep=202014=2013:30:19=20-0700=0ASubject:=20[PATCH]=20= Add=20__arraycount=20macro=20from=20NetBSD=20to=20ease=20porting=0A=0A= __arraycount=20is=20used=20for=20counting=20the=20number=20of=20items=20= in=20a=20static=0Aarray,=20so=20you=20could=20do=20something=20like=20= so:=0A=0A=20=20#include=20=0A=20=20#include=20=0A=20= =20#include=20=0A=0A=20=20int=0A=20=20main(void)=0A=20=20{=0A=20= =20=20=20char=20arr[20];=0A=20=20=20=20unsigned=20int=20i;=0A=0A=20=20=20= =20memset(arr,=20'a',=20__arraycount(arr));=0A=0A=20=20=20=20for=20(i=20= =3D=200;=20i=20<=20__arraycount(arr);=20i++)=0A=20=20=20=20=20=20= putchar(arr[i]);=0A=20=20=20=20return=20(0);=0A=20=20}=0A=0A__arraycount=20= is=20functionally=20equivalent=20to=20the=20nitems=20macro=20in=20= sys/param.h=0A=0AGarbage=20collect=20all=20ad=20hoc=20definitions=20in=20= the=20tree=20that=20aren't=20protected=0Aby=20#ifndef=20__arraycount=20= not=20provided=20by=20a=20third-party=20source=0A=0ASponsored=20by:=20= EMC=20/=20Isilon=20Storage=20Division=0A---=0A=20= contrib/libc-vis/unvis.c=20=20=20=20=20=20=20=20=20=20=20|=206=20------=0A= =20lib/libnetbsd/sys/cdefs.h=20=20=20=20=20=20=20=20=20=20|=206=20------=0A= =20sys/kern/stack_protector.c=20=20=20=20=20=20=20=20=20|=201=20-=0A=20= sys/sys/cdefs.h=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= |=206=20++++++=0A=20usr.sbin/bluetooth/btpand/btpand.h=20|=204=20----=0A=20= 5=20files=20changed,=206=20insertions(+),=2017=20deletions(-)=0A=0Adiff=20= --git=20a/contrib/libc-vis/unvis.c=20b/contrib/libc-vis/unvis.c=0Aindex=20= 9cf112c..83ff2a0=20100644=0A---=20a/contrib/libc-vis/unvis.c=0A+++=20= b/contrib/libc-vis/unvis.c=0A@@=20-51,12=20+51,6=20@@=20= __FBSDID("$FreeBSD$");=0A=20=0A=20#define=09_DIAGASSERT(x)=09assert(x)=0A= =20=0A-/*=0A-=20*=20Return=20the=20number=20of=20elements=20in=20a=20= statically-allocated=20array,=0A-=20*=20__x.=0A-=20*/=0A-#define=09= __arraycount(__x)=09(sizeof(__x)=20/=20sizeof(__x[0]))=0A-=0A=20#ifdef=20= __weak_alias=0A=20__weak_alias(strnunvisx,_strnunvisx)=0A=20#endif=0A= diff=20--git=20a/lib/libnetbsd/sys/cdefs.h=20b/lib/libnetbsd/sys/cdefs.h=0A= index=2009a7ca4..616141b=20100644=0A---=20a/lib/libnetbsd/sys/cdefs.h=0A= +++=20b/lib/libnetbsd/sys/cdefs.h=0A@@=20-41,10=20+41,4=20@@=0A=20= #define=20__dead=0A=20#endif=0A=20=0A-/*=0A-=20*=20Return=20the=20number=20= of=20elements=20in=20a=20statically-allocated=20array,=0A-=20*=20__x.=0A= -=20*/=0A-#define=09__arraycount(__x)=09(sizeof(__x)=20/=20= sizeof(__x[0]))=0A-=0A=20#endif=20/*=20_LIBNETBSD_SYS_CDEFS_H_=20*/=0A= diff=20--git=20a/sys/kern/stack_protector.c=20= b/sys/kern/stack_protector.c=0Aindex=20b5f9973..63acb90=20100644=0A---=20= a/sys/kern/stack_protector.c=0A+++=20b/sys/kern/stack_protector.c=0A@@=20= -17,7=20+17,6=20@@=20__stack_chk_fail(void)=0A=20=09panic("stack=20= overflow=20detected;=20backtrace=20may=20be=20corrupted");=0A=20}=0A=20=0A= -#define=20__arraycount(__x)=09(sizeof(__x)=20/=20sizeof(__x[0]))=0A=20= static=20void=0A=20__stack_chk_init(void=20*dummy=20__unused)=0A=20{=0A= diff=20--git=20a/sys/sys/cdefs.h=20b/sys/sys/cdefs.h=0Aindex=20= 4c4c2af..731bcf8=20100644=0A---=20a/sys/sys/cdefs.h=0A+++=20= b/sys/sys/cdefs.h=0A@@=20-739,4=20+739,10=20@@=0A=20#define=20__NO_TLS=20= 1=0A=20#endif=0A=20=0A+/*=0A+=20*=20Return=20the=20number=20of=20= elements=20in=20a=20statically-allocated=20array,=0A+=20*=20__x.=0A+=20= */=0A+#define=09__arraycount(__x)=09(sizeof(__x)=20/=20sizeof(__x[0]))=0A= +=0A=20#endif=20/*=20!_SYS_CDEFS_H_=20*/=0Adiff=20--git=20= a/usr.sbin/bluetooth/btpand/btpand.h=20= b/usr.sbin/bluetooth/btpand/btpand.h=0Aindex=20c5f7204..b20c6c5=20100644=0A= ---=20a/usr.sbin/bluetooth/btpand/btpand.h=0A+++=20= b/usr.sbin/bluetooth/btpand/btpand.h=0A@@=20-43,10=20+43,6=20@@=0A=20=0A=20= #include=20"event.h"=0A=20=0A-#ifndef=20__arraycount=0A-#define=20= __arraycount(__x)=09(int)(sizeof((__x))=20/=20sizeof((__x)[0]))=0A= -#endif=0A-=0A=20#ifndef=09L2CAP_PSM_INVALID=0A=20#define=09= L2CAP_PSM_INVALID(psm)=09(((psm)=20&=200x0101)=20!=3D=200x0001)=0A=20= #endif=0A--=20=0A2.0.0=0A=0A= --Apple-Mail=_F8F39904-E01A-40C8-9E24-7132A67CC7A4 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=windows-1252 --Apple-Mail=_F8F39904-E01A-40C8-9E24-7132A67CC7A4-- --Apple-Mail=_DCF9E948-C3D1-40D6-B4C1-306E23171DF3 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJUDdmDAAoJEMZr5QU6S73eGRUH/j5TGlNsx3OmPnbXZZhYX7WM v10KOXbrhgW6uVFkOIgX16vuHPwQuI3QpyYIAL7qzsM92AEK9tE5GRYkgJvsqu2x 1V7oVQ612JcCRc5hvYgQVBFcZ20TzBiac03aNkWwwSTBhSeSABysanajVo+HQL8i 5WObB404W/TMzigYjO8yubMC7ovLUMCN4VV4+EGnr2M4l5sWYgC1FQYYu6YEV73f UnaoeNiNmRq6JEGa3kJjBGS/zVAF+41z0AvTg4WY+XqZnDgiQ2p1qb0bSLI+s8lo J3XU6hODhPUPtikAXwaZJJ/I0XFXmpT/FNFQnRTMOul6fl727n62O+Jyu7BHBAI= =2sXE -----END PGP SIGNATURE----- --Apple-Mail=_DCF9E948-C3D1-40D6-B4C1-306E23171DF3-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 17:09:11 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A14B9DCB for ; Mon, 8 Sep 2014 17:09:11 +0000 (UTC) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 77C7C1BDC for ; Mon, 8 Sep 2014 17:09:11 +0000 (UTC) Received: from ralph.baldwin.cx (pool-173-70-85-31.nwrknj.fios.verizon.net [173.70.85.31]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 788ECB9B9; Mon, 8 Sep 2014 13:09:10 -0400 (EDT) From: John Baldwin To: freebsd-arch@freebsd.org Subject: Re: Improving /etc/motd and ANSI Date: Mon, 08 Sep 2014 11:08:12 -0400 Message-ID: <3492555.LII5bndYoC@ralph.baldwin.cx> User-Agent: KMail/4.10.5 (FreeBSD/10.0-STABLE; KDE/4.10.5; amd64; ; ) In-Reply-To: References: <540DBB35.6070003@vangyzen.net> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Mon, 08 Sep 2014 13:09:10 -0400 (EDT) Cc: Warren Block , Eric van Gyzen X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 17:09:11 -0000 On Monday, September 08, 2014 08:36:20 AM Warren Block wrote: > On Mon, 8 Sep 2014, Eric van Gyzen wrote: > > On 09/08/2014 10:03, Warren Block wrote: > >> It was pointed out to me not that long ago that we have no web browser > >> in the base install. Having a URL-only introduction would make it > >> more difficult for some users to read that introduction. > > > > So, there are users who install FreeBSD as the _only_ operating system > > on the _only_ web-capable device in their vicinity, yet need the > > assistance provided by this introduction? Please help me understand > > this kind of user, as my imagination fails me. > > Mostly my view also, but look at it the other way: here is the operating > system, and here are the documents, ...but not in a form that can be > read with the operating system just installed. > > For now, the hybrid approach of both URLs and text covers all users. It > just makes presenting a readable, compact introduction more difficult. I actually lean more towards Eric's suggestion. You could also have 'welcome' be a regular FDP doc so that during installs a copy is in /usr/share/doc. The motd could reference that as well (i.e. you can go to this webpage or look at /usr/share/doc/foobar for a text version). That will let you keep the motd short while having room for a slightly longer 'welcome' guide. Also, to your original question: I don't believe that VGA text mode includes a way to handle underlines (you can just set colors and optionally blink). This means that /etc/motd with ASCII wouldn't work on syscons(4) or on vt(4) when VGA text mode is used. -- John Baldwin From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 19:08:14 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 00991607 for ; Mon, 8 Sep 2014 19:08:13 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id A3D7E1BE9 for ; Mon, 8 Sep 2014 19:08:13 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88J8BdO036292 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Mon, 8 Sep 2014 13:08:11 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88J8BdW036289 for ; Mon, 8 Sep 2014 13:08:11 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 13:08:11 -0600 (MDT) From: Warren Block To: freebsd-arch@FreeBSD.org Subject: /etc/motd summary Message-ID: User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 13:08:11 -0600 (MDT) X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 19:08:14 -0000 Summarizing the responses and changes to /etc/motd: Using ANSI has both philosphical and practical problems, and should be avoided. In short, it has cooties. Extra horizontal whitespace is the least likely to cause problems as command delimiters, and inoffensive to most responders. Rearranging the information into a list of URLs is a net win. Shorter is better. A simpler motd that links to a single web page might be acceptable. My suggestions: Short-term: Here is the most popular/least objectionable version with all of the suggestions implemented as best I could: http://www.wonkity.com/~wblock/motd/motd.whitespace-url I suggest that I commit this in time for 10.1. Longer-term: Creating a "FreeBSD Technical Support Resources" page, or updating an existing one, is something we can and should do anyway. Once we have that, it can be used in motd. (Or proposed, anyway. To me, it seems like a conceptually bigger step than using ANSI. Fahrradschuppen ahoy!) man(1) is very weak for new users. A doc PR just showed up today mentioning that it does not describe the various sections. That is actually in intro(1), intro(2), and so on. Congratulations if you remember those, it's usually a hunt for me. Man page notation is also a problem for new users, and also not explained in man(1). Is it explained anywhere in the man pages? Even if it is, some examples in man(1) would help. From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 19:27:49 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id D4FF94CE for ; Mon, 8 Sep 2014 19:27:49 +0000 (UTC) Received: from mail-la0-x22b.google.com (mail-la0-x22b.google.com [IPv6:2a00:1450:4010:c03::22b]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5C3591E34 for ; Mon, 8 Sep 2014 19:27:49 +0000 (UTC) Received: by mail-la0-f43.google.com with SMTP id gi9so6666794lab.30 for ; Mon, 08 Sep 2014 12:27:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=jzydkxbi4aJ9tIM115P7gS+vRtLJnm7o40dtbUQ3JLA=; b=TFV+IZqR4xoCGtyFz3CrhvEquesM9Vet3pYZ/EPUCfkybA5xz89sTvnF4jdQKxRNe3 viKuC3+a24XE/pz+5N4q6rbBXm4Xvyb73iwnmdgwoIViLAt7pU7BOLPodMDeDCUdSDDH JC1Iugj2Hnl071z1XzrSPdZ/w8Ag3+wEMSPwz4kp2zf0KOIywI1OVL7cD7T3mEecapju XEQzmlQU1XF7hJtblw4PpfDYB6VIb6aM8//RCF9bYFfVFrjbm4pVl7sl5m3Fs0vMK81p qo/YPN8JXcShs+pbazIE0xTLbYaj8i4no6y748NWiRVcRBxhLB7qJIBzDxa7C4WPV3Dg Av3Q== MIME-Version: 1.0 X-Received: by 10.152.20.1 with SMTP id j1mr17638009lae.57.1410204467130; Mon, 08 Sep 2014 12:27:47 -0700 (PDT) Sender: crodr001@gmail.com Received: by 10.112.22.72 with HTTP; Mon, 8 Sep 2014 12:27:47 -0700 (PDT) In-Reply-To: References: Date: Mon, 8 Sep 2014 12:27:47 -0700 X-Google-Sender-Auth: _WmlHthtTOt-GXmie3tAE8oqJt4 Message-ID: Subject: Re: /etc/motd summary From: Craig Rodrigues To: Warren Block Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 19:27:50 -0000 On Mon, Sep 8, 2014 at 12:08 PM, Warren Block wrote: > > > http://www.wonkity.com/~wblock/motd/motd.whitespace-url > > I suggest that I commit this in time for 10.1. > > That looks good. > > Longer-term: > > Creating a "FreeBSD Technical Support Resources" page, or updating an > existing one, is something we can and should do anyway. > The content on this page could be updated: https://www.freebsd.org/support.html If that page's content was streamlined to have the same content as in your motd.whitespace-url, it would be far better than what is there today. -- Craig From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 19:43:00 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 77B99D41; Mon, 8 Sep 2014 19:43:00 +0000 (UTC) Received: from smtp.vangyzen.net (hotblack.vangyzen.net [IPv6:2607:fc50:1000:7400:216:3eff:fe72:314f]) by mx1.freebsd.org (Postfix) with ESMTP id 5882E104D; Mon, 8 Sep 2014 19:43:00 +0000 (UTC) Received: from marvin.lab.vangyzen.net (c-24-125-214-90.hsd1.va.comcast.net [24.125.214.90]) by smtp.vangyzen.net (Postfix) with ESMTPSA id DA66C56444; Mon, 8 Sep 2014 14:42:59 -0500 (CDT) Message-ID: <540E06C1.2010600@vangyzen.net> Date: Mon, 08 Sep 2014 15:42:57 -0400 From: Eric van Gyzen User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Craig Rodrigues , Warren Block Subject: Re: /etc/motd summary References: In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 19:43:00 -0000 On 09/08/2014 15:27, Craig Rodrigues wrote: > On Mon, Sep 8, 2014 at 12:08 PM, Warren Block wrote: > >> >> http://www.wonkity.com/~wblock/motd/motd.whitespace-url >> >> I suggest that I commit this in time for 10.1. >> >> > That looks good. Agreed. Eric From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 21:00:35 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3C22F443 for ; Mon, 8 Sep 2014 21:00:35 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 04C151B9D for ; Mon, 8 Sep 2014 21:00:35 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.9/8.14.9) with ESMTP id s88L0Ygw049908 for ; Mon, 8 Sep 2014 21:00:34 GMT (envelope-from bdrewery@freefall.freebsd.org) Received: (from bdrewery@localhost) by freefall.freebsd.org (8.14.9/8.14.9/Submit) id s88L0YU8049907 for freebsd-arch@FreeBSD.org; Mon, 8 Sep 2014 21:00:34 GMT (envelope-from bdrewery) Received: (qmail 64722 invoked from network); 8 Sep 2014 16:00:32 -0500 Received: from unknown (HELO ?10.10.0.24?) (freebsd@shatow.net@10.10.0.24) by sweb.xzibition.com with ESMTPA; 8 Sep 2014 16:00:32 -0500 Message-ID: <540E18ED.1070003@FreeBSD.org> Date: Mon, 08 Sep 2014 16:00:29 -0500 From: Bryan Drewery Organization: FreeBSD User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.1.0 MIME-Version: 1.0 To: Warren Block , freebsd-arch@FreeBSD.org Subject: Re: /etc/motd summary References: In-Reply-To: OpenPGP: id=6E4697CF; url=http://www.shatow.net/bryan/bryan2.asc Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="7xMvCga03V5Twva00LNdOKXGXE501R1MG" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 21:00:35 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --7xMvCga03V5Twva00LNdOKXGXE501R1MG Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 9/8/2014 2:08 PM, Warren Block wrote: > Summarizing the responses and changes to /etc/motd: >=20 > Using ANSI has both philosphical and practical problems, and should b= e > avoided. In short, it has cooties. >=20 > Extra horizontal whitespace is the least likely to cause problems as > command delimiters, and inoffensive to most responders. Rearranging > the information into a list of URLs is a net win. >=20 > Shorter is better. A simpler motd that links to a single web page > might be acceptable. >=20 > My suggestions: >=20 > Short-term: >=20 > Here is the most popular/least objectionable version with all of the > suggestions implemented as best I could: >=20 > http://www.wonkity.com/~wblock/motd/motd.whitespace-url For other languages, replace "en" with a language code like de or fr. Should de and fr also be quoted? I don't mean to bikeshed on this but I find the spaced commands confusing. I find quoted commands more readable: Please include the output of 'uname -a' and any relevant error messages= =2E.. Use 'man man' for an introduction to manual pages. 'man hier' describes the. or `cmd` or `cmd' --=20 Regards, Bryan Drewery --7xMvCga03V5Twva00LNdOKXGXE501R1MG Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (MingW32) iQEcBAEBAgAGBQJUDhjtAAoJEDXXcbtuRpfPL+sH/1aoRrQL8MCCXi9zCTNWvtuz qcvWen8Z4VF4/FJ+lmb1+ZXJ4GTJKRTdV3ZGzte+cfkHdyxJt7DFu8OmVfJ/voA2 uEvOlnMg17/q0ZNhQGT5QXUBlOYBHyz0S7QW7zaK17aCYfso3BZY4PmBaNI6IH5c fzxKg/58NwO1j9IA65XtjeU2Je16kCXFSuRlDXS7vvn7by3TkMFiXFoFUJH1+Jkd mvmP7YY4Q3gLsPOfpcUXt0l3wiwufL+RufWiwWR8PRa+CHiS+q9j2/RmoE6VLI+3 G9J9w0yAUHVXwuo0KRORZ4CJEq7cgFPAlDwKICXwMIvMDAmwykbzSUzZa1nByAE= =Gcv6 -----END PGP SIGNATURE----- --7xMvCga03V5Twva00LNdOKXGXE501R1MG-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 21:38:42 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5E9724A2; Mon, 8 Sep 2014 21:38:42 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 12FE71012; Mon, 8 Sep 2014 21:38:41 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88LcdfK074301 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 15:38:39 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88Lcdqh074298; Mon, 8 Sep 2014 15:38:39 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 15:38:39 -0600 (MDT) From: Warren Block To: Bryan Drewery Subject: Re: /etc/motd summary In-Reply-To: <540E18ED.1070003@FreeBSD.org> Message-ID: References: <540E18ED.1070003@FreeBSD.org> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 15:38:39 -0600 (MDT) Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 21:38:42 -0000 On Mon, 8 Sep 2014, Bryan Drewery wrote: > On 9/8/2014 2:08 PM, Warren Block wrote: >> Summarizing the responses and changes to /etc/motd: >> >> Using ANSI has both philosphical and practical problems, and should be >> avoided. In short, it has cooties. >> >> Extra horizontal whitespace is the least likely to cause problems as >> command delimiters, and inoffensive to most responders. Rearranging >> the information into a list of URLs is a net win. >> >> Shorter is better. A simpler motd that links to a single web page >> might be acceptable. >> >> My suggestions: >> >> Short-term: >> >> Here is the most popular/least objectionable version with all of the >> suggestions implemented as best I could: >> >> http://www.wonkity.com/~wblock/motd/motd.whitespace-url > > For other languages, replace "en" with a language code like de or fr. > > Should de and fr also be quoted? That was intentional. The "en" being the part that the user is to replace, there is no ambiguity with those quotes--they don't exist in the source. With the de and fr, no quotes are shown so the user is not tempted to enter them, and the de alone shows that the final period after fr is not part of the language code. > I don't mean to bikeshed on this but I find the spaced commands > confusing. I find quoted commands more readable: > > Please include the output of 'uname -a' and any relevant error messages... > Use 'man man' for an introduction to manual pages. 'man hier' > describes the. > > or `cmd` or `cmd' Right, but you are used to the conventions. The idea here is to only show the reader what they have to type* without forcing them to interpret. % 'uname -a' uname -a: Command not found. % 'man man' man man: Command not found. % `man hier` Unknown user: ftp;. % `man hier' Unmatched `. The third one is particularly intriguing. [*: admittedly, we are not telling them that they have to press Enter. There is just not enough space for a quick intro on entering CLI commands. But we could have one on a "FreeBSD Support Links" page.] From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 21:48:06 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 15765925 for ; Mon, 8 Sep 2014 21:48:06 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EAE2411A0 for ; Mon, 8 Sep 2014 21:48:05 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.9/8.14.9) with ESMTP id s88Lm5Bi063283 for ; Mon, 8 Sep 2014 21:48:05 GMT (envelope-from bdrewery@freefall.freebsd.org) Received: (from bdrewery@localhost) by freefall.freebsd.org (8.14.9/8.14.9/Submit) id s88Lm5cq063282 for freebsd-arch@FreeBSD.org; Mon, 8 Sep 2014 21:48:05 GMT (envelope-from bdrewery) Received: (qmail 79959 invoked from network); 8 Sep 2014 16:48:04 -0500 Received: from unknown (HELO ?10.10.0.24?) (freebsd@shatow.net@10.10.0.24) by sweb.xzibition.com with ESMTPA; 8 Sep 2014 16:48:04 -0500 Message-ID: <540E2410.30404@FreeBSD.org> Date: Mon, 08 Sep 2014 16:48:00 -0500 From: Bryan Drewery Organization: FreeBSD User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.1.0 MIME-Version: 1.0 To: Warren Block Subject: Re: /etc/motd summary References: <540E18ED.1070003@FreeBSD.org> In-Reply-To: OpenPGP: id=6E4697CF; url=http://www.shatow.net/bryan/bryan2.asc Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="6MlkGhRbEDuBaicX6bNUw75QCw73acbKi" Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 21:48:06 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --6MlkGhRbEDuBaicX6bNUw75QCw73acbKi Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 9/8/2014 4:38 PM, Warren Block wrote: > On Mon, 8 Sep 2014, Bryan Drewery wrote: >=20 >> On 9/8/2014 2:08 PM, Warren Block wrote: >>> Summarizing the responses and changes to /etc/motd: >>> >>> Using ANSI has both philosphical and practical problems, and should= be >>> avoided. In short, it has cooties. >>> >>> Extra horizontal whitespace is the least likely to cause problems a= s >>> command delimiters, and inoffensive to most responders. Rearrangin= g >>> the information into a list of URLs is a net win. >>> >>> Shorter is better. A simpler motd that links to a single web page >>> might be acceptable. >>> >>> My suggestions: >>> >>> Short-term: >>> >>> Here is the most popular/least objectionable version with all of the >>> suggestions implemented as best I could: >>> >>> http://www.wonkity.com/~wblock/motd/motd.whitespace-url >> >> For other languages, replace "en" with a language code like de or fr.= >> >> Should de and fr also be quoted? >=20 > That was intentional. The "en" being the part that the user is to > replace, there is no ambiguity with those quotes--they don't exist in > the source. With the de and fr, no quotes are shown so the user is not= > tempted to enter them, and the de alone shows that the final period > after fr is not part of the language code. >=20 >> I don't mean to bikeshed on this but I find the spaced commands >> confusing. I find quoted commands more readable: >> >> Please include the output of 'uname -a' and any relevant error >> messages... >> Use 'man man' for an introduction to manual pages. 'man hier' >> describes the. >> >> or `cmd` or `cmd' >=20 > Right, but you are used to the conventions. The idea here is to only > show the reader what they have to type* without forcing them to interpr= et. >=20 > % 'uname -a' > uname -a: Command not found. > % 'man man' > man man: Command not found. > % `man hier` > Unknown user: ftp;. > % `man hier' > Unmatched `. >=20 > The third one is particularly intriguing. >=20 > [*: admittedly, we are not telling them that they have to press Enter. > There is just not enough space for a quick intro on entering CLI > commands. But we could have one on a "FreeBSD Support Links" page.] I understand what you're saying, although I've never had someone complain to me that they ran 'cmd' literally. On the other hand, the spaces are very unclear that it is even a command that can be ran in 'man man' and 'man hier' uses. The old motd has `cmd' syntax. --=20 Regards, Bryan Drewery --6MlkGhRbEDuBaicX6bNUw75QCw73acbKi Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (MingW32) iQEcBAEBAgAGBQJUDiQRAAoJEDXXcbtuRpfPryMH/1+/7QmAWT1I825Uf7rbr65J GgsULkDOKlK9auwv9T+a+h1r01QfxqERUF2hLF+C3/jfC2dVQoHybe/jV4eXEyuZ aJnbED5CjewAwJ2chitMRGzgB03EHVAHTachL+48+MajtSNR4S7qfyWXAkdNPl8Z sheegjGGUB4SdNTBW8af9ZOmW1YU476RZSXJDv+AiVrua+umUg2LVFpm00tH17/L U0UgAXqbvgAWQBWh5+/GGAY+9hybtUOFfJQ81W+E95j3UGFT2Wfk2HDTOv7fB5ME UCM4gBqPg9vhvpcbYpy80PskWPA1r/Ts0ckk3ySGtGs1OxGxCzMtSIflhyN5gxg= =S+Gy -----END PGP SIGNATURE----- --6MlkGhRbEDuBaicX6bNUw75QCw73acbKi-- From owner-freebsd-arch@FreeBSD.ORG Mon Sep 8 22:16:12 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C5AA518A; Mon, 8 Sep 2014 22:16:12 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 7641014E6; Mon, 8 Sep 2014 22:16:12 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s88MGA3N083726 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 16:16:11 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s88MGA6i083723; Mon, 8 Sep 2014 16:16:10 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 16:16:10 -0600 (MDT) From: Warren Block To: Bryan Drewery Subject: Re: /etc/motd summary In-Reply-To: <540E2410.30404@FreeBSD.org> Message-ID: References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 16:16:11 -0600 (MDT) Cc: freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2014 22:16:12 -0000 On Mon, 8 Sep 2014, Bryan Drewery wrote: > I understand what you're saying, although I've never had someone > complain to me that they ran 'cmd' literally. We've had users in the forums type literal strings including the prompts. > On the other hand, the spaces are very unclear that it is even a command > that can be ran in 'man man' and 'man hier' uses. > > The old motd has `cmd' syntax. Yes... Okay, another slight variation: http://www.wonkity.com/~wblock/motd/motd.vertical From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 00:25:33 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3210ACE4; Tue, 9 Sep 2014 00:25:33 +0000 (UTC) Received: from mail-qa0-x22c.google.com (mail-qa0-x22c.google.com [IPv6:2607:f8b0:400d:c00::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D5921B89; Tue, 9 Sep 2014 00:25:32 +0000 (UTC) Received: by mail-qa0-f44.google.com with SMTP id j7so14767595qaq.17 for ; Mon, 08 Sep 2014 17:25:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=2bQrQ1b67+uzHD1aVsMdfcHN7jVLPLOPJvlPZzrLQ3Q=; b=URxcBq+V6xoKcot7uLxuXtQVtx08Vmzytg/almnucgl0AWP7E13duhiLSBsJkLQ+GL /6sHmnr4nmyr4QNXaFx5YZiBtDOkoi7xuUSacByHCa5U/6vjhf1vCeVpmK/yjpYAUgyA BJXunqyrEoBAbyGaj/EA7ASCKg9FDw2KcqfeXhzuxvvDdfrHmtMxahMJed3t5ZIbuwr6 8Pb4JaKNRZ4UIMlJt3hliM6VoQkSKhhELUVN64WFyYrWABODxpUHwjs63hDfOo++M5Ld FaMP/prhk0/0yqkEDOEXMHEQQ+Hz3D17Coabw+qzlaiGBBz3VTWSlzLJ4ht+SuJOlJCC E3Fg== MIME-Version: 1.0 X-Received: by 10.140.19.201 with SMTP id 67mr44767963qgh.28.1410222331848; Mon, 08 Sep 2014 17:25:31 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.224.39.139 with HTTP; Mon, 8 Sep 2014 17:25:31 -0700 (PDT) In-Reply-To: References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> Date: Mon, 8 Sep 2014 17:25:31 -0700 X-Google-Sender-Auth: Vgf6uebkqlyuFn688c11PbsM1XA Message-ID: Subject: Re: /etc/motd summary From: Adrian Chadd To: Warren Block Content-Type: text/plain; charset=UTF-8 Cc: "freebsd-arch@freebsd.org" , Bryan Drewery X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 00:25:33 -0000 for maximum bikeshed: what about adding a 'motd' command that, I dunno, re-displays the motd? :P -a From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 02:01:49 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9EDAD96E; Tue, 9 Sep 2014 02:01:49 +0000 (UTC) Received: from spindle.one-eyed-alien.net (spindle.one-eyed-alien.net [199.48.129.229]) by mx1.freebsd.org (Postfix) with ESMTP id 1E8BBD22; Tue, 9 Sep 2014 00:46:25 +0000 (UTC) Received: by spindle.one-eyed-alien.net (Postfix, from userid 3001) id 943895A9F24; Tue, 9 Sep 2014 00:46:24 +0000 (UTC) Date: Tue, 9 Sep 2014 00:46:24 +0000 From: Brooks Davis To: Adrian Chadd Subject: Re: /etc/motd summary Message-ID: <20140909004624.GA24341@spindle.one-eyed-alien.net> References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="VbJkn9YxBvnuCH5J" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Cc: Warren Block , Bryan Drewery , "freebsd-arch@freebsd.org" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 02:01:49 -0000 --VbJkn9YxBvnuCH5J Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: > for maximum bikeshed: what about adding a 'motd' command that, I > dunno, re-displays the motd? :P How would someone who didn't know about /etc/motd ever find that? -- Brooks --VbJkn9YxBvnuCH5J Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlQOTd8ACgkQXY6L6fI4GtRAMACgrMFO4ohEQ6iSD+G1+63Fu7UT JSIAoOOfnSVvMxHj06J4MIHZb+Y7RH3g =VvLr -----END PGP SIGNATURE----- --VbJkn9YxBvnuCH5J-- From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 02:05:53 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8E439ADC; Tue, 9 Sep 2014 02:05:53 +0000 (UTC) Received: from mail-qg0-x230.google.com (mail-qg0-x230.google.com [IPv6:2607:f8b0:400d:c04::230]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 28F45183F; Tue, 9 Sep 2014 02:05:53 +0000 (UTC) Received: by mail-qg0-f48.google.com with SMTP id z107so16579111qgd.35 for ; Mon, 08 Sep 2014 19:05:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=zoxT6G7Lw6DhDg9VwpEqHDzdvomEo4GJl5QO8Dm1PDU=; b=mK9SL8c5eV6TSsXDfNEVg3ndwF4ZAcptnY0Loc8cq1cieMg3exTUzRzIp9mhLTf88v O08o52BrcfD2uVX52OPFPf/qnW/va3WOpY78rnzxvqmGW69rRpBmaLVttyadryeWuU4N RISpKsXYVxxK2z7NRmDciky//aUb3gr7VO7fJRinxjdvPDJhtcyFe84x1pwfKI3xjLyW UlD2G7UQi3REsGJeFwymC0tQGDthmXejQWiJg7PmrfXBlGhoknXYXh66IJwB9MJssPrf Hv6dLWIjWFDf6QgveZhQ9vo/PRwpC90FOrORFmeaTv5+JNdCwl+07ENmYq+drnTJYfsZ V0OA== MIME-Version: 1.0 X-Received: by 10.140.31.75 with SMTP id e69mr45321197qge.2.1410228352206; Mon, 08 Sep 2014 19:05:52 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.224.39.139 with HTTP; Mon, 8 Sep 2014 19:05:52 -0700 (PDT) In-Reply-To: <20140909004624.GA24341@spindle.one-eyed-alien.net> References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> <20140909004624.GA24341@spindle.one-eyed-alien.net> Date: Mon, 8 Sep 2014 19:05:52 -0700 X-Google-Sender-Auth: 152OraRw0NDBtQHJ6Els1dxetRw Message-ID: Subject: Re: /etc/motd summary From: Adrian Chadd To: Brooks Davis Content-Type: text/plain; charset=UTF-8 Cc: Warren Block , Bryan Drewery , "freebsd-arch@freebsd.org" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 02:05:53 -0000 On 8 September 2014 17:46, Brooks Davis wrote: > On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: >> for maximum bikeshed: what about adding a 'motd' command that, I >> dunno, re-displays the motd? :P > > How would someone who didn't know about /etc/motd ever find that? Putting "Type 'motd' to see this information again" in the motd. -a From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 02:11:49 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 36C76C25; Tue, 9 Sep 2014 02:11:49 +0000 (UTC) Received: from homiemail-a70.g.dreamhost.com (sub4.mail.dreamhost.com [69.163.253.135]) by mx1.freebsd.org (Postfix) with ESMTP id AFADEE59; Tue, 9 Sep 2014 00:55:14 +0000 (UTC) Received: from homiemail-a70.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a70.g.dreamhost.com (Postfix) with ESMTP id 2374E76805C; Mon, 8 Sep 2014 17:55:07 -0700 (PDT) Received: from dreadnaught (ip68-100-185-59.dc.dc.cox.net [68.100.185.59]) (Authenticated sender: trhodes@fbsdsecure.org) by homiemail-a70.g.dreamhost.com (Postfix) with ESMTPA id B8044768057; Mon, 8 Sep 2014 17:55:06 -0700 (PDT) Date: Mon, 8 Sep 2014 20:55:05 -0400 From: Tom Rhodes To: Adrian Chadd Subject: Re: /etc/motd summary Message-Id: <20140908205505.421ddf62.trhodes@FreeBSD.org> In-Reply-To: References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> X-Mailer: Sylpheed version 1.0.6 (GTK+ 1.2.10; x86_64-unknown-freebsd10.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 02:11:49 -0000 On Mon, 8 Sep 2014 17:25:31 -0700 Adrian Chadd wrote: > for maximum bikeshed: what about adding a 'motd' command that, I > dunno, re-displays the motd? :P Oh, lets start a discussion on who can make it the smallest shell and binary possible. -- Tom Rhodes From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 02:24:02 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DAC64F40; Tue, 9 Sep 2014 02:24:02 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 8957619C9; Tue, 9 Sep 2014 02:24:02 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s892O04D045638 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 8 Sep 2014 20:24:00 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s892O0V9045635; Mon, 8 Sep 2014 20:24:00 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Mon, 8 Sep 2014 20:24:00 -0600 (MDT) From: Warren Block To: Adrian Chadd Subject: Re: /etc/motd summary In-Reply-To: Message-ID: References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> <20140909004624.GA24341@spindle.one-eyed-alien.net> User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Mon, 08 Sep 2014 20:24:00 -0600 (MDT) Cc: "freebsd-arch@freebsd.org" , Brooks Davis , Bryan Drewery X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 02:24:03 -0000 On Mon, 8 Sep 2014, Adrian Chadd wrote: > On 8 September 2014 17:46, Brooks Davis wrote: >> On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: >>> for maximum bikeshed: what about adding a 'motd' command that, I >>> dunno, re-displays the motd? :P >> >> How would someone who didn't know about /etc/motd ever find that? > > Putting "Type 'motd' to see this information again" in the motd. Or leave it the way it is, /etc/motd is just a file that is displayed, but instead of dumping it to stdout, interpret some kind of markup in it. That's relatively high overhead considering the layout will still be limited to 80x24. We'd probably be better off leaving it as is and moving most of the information to a man page, say support(1), which is mentioned by /etc/motd. From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 03:08:25 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from hub.FreeBSD.org (hub.freebsd.org [IPv6:2001:1900:2254:206c::16:88]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 48214BE9; Tue, 9 Sep 2014 03:08:24 +0000 (UTC) Date: Mon, 8 Sep 2014 23:08:20 -0400 From: Glen Barber To: Adrian Chadd Subject: Re: /etc/motd summary Message-ID: <20140909030820.GX48287@hub.FreeBSD.org> References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="jn/MQTzma+jNUHFC" Content-Disposition: inline In-Reply-To: X-Operating-System: FreeBSD 11.0-CURRENT amd64 X-SCUD-Definition: Sudden Completely Unexpected Dataloss X-SULE-Definition: Sudden Unexpected Learning Event User-Agent: Mutt/1.5.23 (2014-03-12) Cc: Warren Block , "freebsd-arch@freebsd.org" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 03:08:25 -0000 --jn/MQTzma+jNUHFC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: > for maximum bikeshed: what about adding a 'motd' command that, I > dunno, re-displays the motd? :P >=20 Recently, there was a thread on one of the internal lists regarding technical discussion happening on public lists. For reference, see the "This is why we can't have nice things" thread, and its inevitable fallout. With such replies as above, I fail to see the difference in the quality of feedback, especially given the infrequency of actual technical discussion internally, and that they eventually are taken to a public list. Glen --jn/MQTzma+jNUHFC Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCAAGBQJUDm8kAAoJELls3eqvi17QMV4P/j00dstd183RLGVDgP+GuHgU ekfK+G96VXxfw+axpcIxNdX6f7HQkZei79kmxCAfdl+VNBgbjEioFGMW+HtsmZzW XfIZtcY81cKKPVZ2fdDog42YDSnoyRTSRFm0fXN87+LJ2HiNIZc1cDKSIKqb//xK 1P7HTweEmQ/I8Vzy/waNJdkYou8XKwZ//Zvt3gH55dQ0VmmTAD+BEm5/iWFnnD9f dwcwWfMWRZmmjm0GSjkhdk20XFdAd8dvvAN97DgxIpLm+civYeUxCVZoWcGmz9uk EgE+aGd5GyesLdqaNcojn45bYxufkyJ1DsjhPrLqziBPujLBTtirz+M2RRsD5ghz bCnsuVpmkSE228+wR73MMm78J/Ujm5MieZegsPwQJLoZaUtcMlzcl5fF+KbUfhXp 5yI7dZLvJqEELuSLvhYJL4tHTwZW/oMGYVFGEpSY37tudY9tJsF9+kfdA0QpVQZA tj09j1B8XbEm//52LyqogvHabS1pRDQq7u/cDEf3X30tkycNKE2mvh0eUR1/EwJq uoEgFw4j7mKC4lzQYxcm7cXlmVgOrXIZtCsjhosEhhm4JtjVlUS7cKvjGofRfodg baUzGpJBKg/b5JbK59xB7287BFtVVg2EdFnCZFj+4PpR7ngfziOPkmHgtyZYDdCW pU0KD0RRecckhTJQvY/F =aoG7 -----END PGP SIGNATURE----- --jn/MQTzma+jNUHFC-- From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 03:21:05 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 263A6264; Tue, 9 Sep 2014 03:21:05 +0000 (UTC) Received: from mail-pd0-x229.google.com (mail-pd0-x229.google.com [IPv6:2607:f8b0:400e:c02::229]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E774C19F; Tue, 9 Sep 2014 03:21:04 +0000 (UTC) Received: by mail-pd0-f169.google.com with SMTP id fp1so2542326pdb.14 for ; Mon, 08 Sep 2014 20:21:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:mail-followup-to :references:mime-version:content-type:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=Q4LRA/mbPb5wq38G9yqEJdQXVzRCHxYQCjiF3GpnU/o=; b=L1gAFO/XIt6UsofwFe/Wn61uetYOBDgEZvvX70vb9hr5jG8pXtXffFWdvAQZ8eHptf KtB0zqWUmxvnPjQ2keIqB+ECBcakrh2Fk+HEmemWAqjvSxeg03dUlP8AWtkxpZffkKab WyRjQ/RdAxwTSfY5pcP4SpzA9yeJ+UkyN97DLeHJdPM7aMhlQzlBPXXEXetXxQ1HHw8H APfEar0n70NTDwUCQXHoEM4MdpVCPdzhcaiWU3BfyM4poXSb/NJacfEbnqgpxVmcnk6Y X7Ue3pL3CLSQfKYFXbr/K2FsVqtDy6LhJ6n6XsafZPlwS/d0sUgKowf1awivHPqGKs3D DC/A== X-Received: by 10.70.132.73 with SMTP id os9mr53607290pdb.63.1410232864364; Mon, 08 Sep 2014 20:21:04 -0700 (PDT) Received: from ox ([24.6.44.228]) by mx.google.com with ESMTPSA id yr3sm10815527pac.1.2014.09.08.20.21.02 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Mon, 08 Sep 2014 20:21:03 -0700 (PDT) Sender: Navdeep Parhar Date: Mon, 8 Sep 2014 20:20:56 -0700 From: Navdeep Parhar To: =?iso-8859-1?Q?Jean-S=E9bastien_P=E9dron?= Subject: Re: Linux kernel API wrapper: using OFED's one in other drivers Message-ID: <20140909032056.GA3835@ox> Mail-Followup-To: =?iso-8859-1?Q?Jean-S=E9bastien_P=E9dron?= , Konstantin Belousov , freebsd-arch@FreeBSD.org References: <540D7D91.9000104@FreeBSD.org> <20140908103908.GZ2737@kib.kiev.ua> <540DBC64.7050302@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <540DBC64.7050302@FreeBSD.org> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: Konstantin Belousov , freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 03:21:05 -0000 On Mon, Sep 08, 2014 at 04:25:40PM +0200, Jean-Sébastien Pédron wrote: > On 08.09.2014 12:39, Konstantin Belousov wrote: > > My main objections to use OFED wrappers for drm2 are: > > > > 1. It tightly binds different drivers with non-coordinating maintainers > > to the version of the Linux KPI. The Linux drivers interface is not > > known for its stability, and constant drift there in both formal > > spelling of interfaces and in semantic requires to have all drivers > > using the wrapper to be at the same upstream version. > > > > This objection is not specific to drm code, but so far we only speek > > about infiniband and drm. > > A small note before going on: cxgb(4) and cxgbe(4) use OFED's wrapper too. Not so. You were correct in your original email where you said the wrappers are used within sys/dev/cxgb and sys/dev/cxgbe. There is a subtle difference. cxgbe(4) is the if_cxgbe module. It is a native FreeBSD driver and there is no possibility that it will ever use anything from any Linux shim layer that may be available on FreeBSD. iw_cxgbe, that lives within sys/dev/cxgbe too, is an iWARP driver that relies on OFED and is forced to use the Linux shims because the FreeBSD OFED port works that way (include any ofed header and it pulls in a lot of Linux shim headers). A native FreeBSD OFED would have been much nicer imho but that's water under the bridge. Regards, Navdeep From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 05:43:28 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id BFEE6EED; Tue, 9 Sep 2014 05:43:28 +0000 (UTC) Received: from mail.turbocat.net (mail.turbocat.net [IPv6:2a01:4f8:d16:4514::2]) (using TLSv1.1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 813EA129; Tue, 9 Sep 2014 05:43:28 +0000 (UTC) Received: from laptop015.home.selasky.org (cm-176.74.213.204.customer.telag.net [176.74.213.204]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id CCE9A1FE027; Tue, 9 Sep 2014 07:43:25 +0200 (CEST) Message-ID: <540E9376.9000905@selasky.org> Date: Tue, 09 Sep 2014 07:43:18 +0200 From: Hans Petter Selasky User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0 MIME-Version: 1.0 To: =?ISO-8859-1?Q?Jean-S=E9bastien_P=E9dron?= , Konstantin Belousov , freebsd-arch@FreeBSD.org Subject: Re: Linux kernel API wrapper: using OFED's one in other drivers References: <540D7D91.9000104@FreeBSD.org> <20140908103908.GZ2737@kib.kiev.ua> <540DBC64.7050302@FreeBSD.org> <20140909032056.GA3835@ox> In-Reply-To: <20140909032056.GA3835@ox> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 05:43:28 -0000 On 09/09/14 05:20, Navdeep Parhar wrote: > On Mon, Sep 08, 2014 at 04:25:40PM +0200, Jean-Sébastien Pédron wrote: >> On 08.09.2014 12:39, Konstantin Belousov wrote: >>> My main objections to use OFED wrappers for drm2 are: >>> >>> 1. It tightly binds different drivers with non-coordinating maintainers >>> to the version of the Linux KPI. The Linux drivers interface is not >>> known for its stability, and constant drift there in both formal >>> spelling of interfaces and in semantic requires to have all drivers >>> using the wrapper to be at the same upstream version. >>> >>> This objection is not specific to drm code, but so far we only speek >>> about infiniband and drm. >> >> A small note before going on: cxgb(4) and cxgbe(4) use OFED's wrapper too. > > Not so. You were correct in your original email where you said the > wrappers are used within sys/dev/cxgb and sys/dev/cxgbe. There is a > subtle difference. > > cxgbe(4) is the if_cxgbe module. It is a native FreeBSD driver and > there is no possibility that it will ever use anything from any Linux > shim layer that may be available on FreeBSD. > > iw_cxgbe, that lives within sys/dev/cxgbe too, is an iWARP driver that > relies on OFED and is forced to use the Linux shims because the FreeBSD > OFED port works that way (include any ofed header and it pulls in a lot > of Linux shim headers). A native FreeBSD OFED would have been much > nicer imho but that's water under the bridge. > Hi, I think if the linux layer had its own namespace in the kernel, like a function name prefix, it would be more acceptable, and that we could have a script to do the automatic renaming of functions. Still it would serve the function to make maintaining cross platform code in a more easy way. --HPS From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 08:33:40 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 2793EAC4 for ; Tue, 9 Sep 2014 08:33:40 +0000 (UTC) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BE18E298 for ; Tue, 9 Sep 2014 08:33:39 +0000 (UTC) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.14.9/8.14.9) with ESMTP id s898XX0t073396 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 9 Sep 2014 11:33:33 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.9.2 kib.kiev.ua s898XX0t073396 Received: (from kostik@localhost) by tom.home (8.14.9/8.14.9/Submit) id s898XXQM073395; Tue, 9 Sep 2014 11:33:33 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Tue, 9 Sep 2014 11:33:33 +0300 From: Konstantin Belousov To: yaneurabeya@gmail.com Subject: Re: [RFC] Add __arraycount from NetBSD to sys/cdefs.h Message-ID: <20140909083333.GA2737@kib.kiev.ua> References: <8D279BDC-7D40-4750-8DA7-A4535DD2E458@bsdimp.com> <146C3E96-7461-4D30-8B7F-5E20F72CF061@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="RJWZ9TQ7tP81YmMW" Content-Disposition: inline In-Reply-To: <146C3E96-7461-4D30-8B7F-5E20F72CF061@gmail.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on tom.home Cc: "freebsd-arch@FreeBSD.org Arch" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 08:33:40 -0000 --RJWZ9TQ7tP81YmMW Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Sep 08, 2014 at 09:29:54AM -0700, yaneurabeya@gmail.com wrote: > On Sep 3, 2014, at 21:17, Warner Losh wrote: >=20 > > On Sep 3, 2014, at 9:45 PM, Garrett Cooper wrot= e: > >=20 > >> Hi all, > >> In order to ease porting code and reduce divergence with NetBSD > >> when importing code (a large chunk of which for me are tests), I would > >> like to move nitems to sys/cdefs.h and alias __arraycount to nitems. > >> Here's the __arraycount #define in lib/libnetbsd/sys/cdefs.h: > >>=20 > >> 44 /* > >> 45 * Return the number of elements in a statically-allocated array, > >> 46 * __x. > >> 47 */ > >> 48 #define __arraycount(__x) (sizeof(__x) / sizeof(__x[0])) > >>=20 > >> Here's the nitems #define in sys/sys/param.h: > >>=20 > >> 277 #define nitems(x) (sizeof((x)) / sizeof((x)[0])) > >>=20 > >> sys/cdefs.h gets pulled in automatically with sys/param.h, so > >> anything using nitems will continue to function like before (see below > >> for more details). I've attached a patch which addresses all hardcoded > >> definitions in the tree added by FreeBSD developers. > >> If there aren't any major concerns with my proposed change, I'll > >> put it up for review on Phabricator. > >> Thank you! > >> -Garrett > >>=20 > >> $ cat cdefs_pound_define.c > >> #include > >>=20 > >> #ifdef _SYS_CDEFS_H_ > >> #warning "sys/cdefs.h has been included" > >> #endif > >> $ cc -c cdefs_pound_define.c > >> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" [-W= #warnings] > >> #warning "sys/cdefs.h has been included" > >> ^ > >> 1 warning generated. > >> $ cc -D_KERNEL -c cdefs_pound_define.c > >> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" [-W= #warnings] > >> #warning "sys/cdefs.h has been included" > >> ^ > >> 1 warning generated. > >> $ gcc -c cdefs_pound_define.c > >> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been incl= uded" > >> $ gcc -D_KERNEL -c cdefs_pound_define.c > >> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been incl= uded? > >=20 > > I wouldn?t bother changing the nitems #define. There?s no need, really,= to do that. >=20 > Rethinking my proposal, I agree. I had lofty hopes for unifying the macro= s, but the functional duplication (1 line) is harmless. >=20 > > I?d also be more inclined to believe the test if you tested what the th= ing does rather than test for an artificial, implementation defined side ef= fect. >=20 > Sure. I provided a lazy proof instead of a full proof :). >=20 > > But honestly the amount of duplication saved here is rather tiny? >=20 > Indeed! Thank you for the input :) ? I?ve attached a new patch which does= n?t disturb nitems or sys/param.h. Since this is seriously discussed on arch@, I think it is worth look at the following: git grep -e 'sizeof.*/sizeof' -- | grep -v '^contrib' | grep '#.*define' | = wc -l 118 These are only defines, not uses, not counting direct use of sizeof(x)/sizeof(x[0]) in the code. Not all of them are for equiv macros, but significant part repeats ntimes() in variations. At least Linuxish ARRAY_SIZE/DRM_ARRAY_SIZE is much more popular than __arraysize() which appears three (!) times. I do not see any reason to pollute central header cdefs.h with sparcely used macro for some compat code. --RJWZ9TQ7tP81YmMW Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJUDrtdAAoJEJDCuSvBvK1BN4cQAJHrDO928nZq4p0WUfrGjj/N cCekP+TnQxuaBn8sm6fEuoff9ZF/eh48s/0/i+ULNwrY085OZfmhvczeTP9Xj+kh Lm2MDKY3uLeQRLPtG+2KLd7ROH8M4oGM0Md7kuBgsr+uQ5kV7zEkHXyiBcbVqgDy Sj2Fe+j88BiHwfGM8iWSNoQQze9zNYjpqADg/TlPUlCkxNlZp3YR1CWTajePYhiY faf5QO7JPLulQOzabezfLKi5SYh6l0lVhDD6/+pkXibCpX8hemeeRR5zB3ccuSMs Ba0ZPOLG9gysZFGHYUSOw4KnzJp8Un1um9HVhr98NqZ299LLgG6AwjSAXRi1/Ui3 ZwMqHkmorxQ/jE1+4zDISGfH28JEXSvxIWVVMPCnJ9iFvoQImjouunPCRsogR3e4 4vBX03MifrxszprVRsPfhCTX45htX+ip23iietx9ojuYcK1bxUjRtYW00rlkXDl+ w87/thxkQHw2LsGCXtxwPsMP0TPaqWOHEF5qnqqGohcRsLcngcakyQosoUXBIeks 7DiXW0jLIWZRikFWQFDEOSRsh2nLCgKK5KIbv/W/q4IrgDC7oOd6zEg9X3ZDOfRr j3r4VbLmmxrACe1iQ9azAP+hgiyPjv3j5Uh6ghkdyk8XhDdLSNuBCys4CxKZHXCX Alg91A8xEkmPWHpnj1Gu =lFuI -----END PGP SIGNATURE----- --RJWZ9TQ7tP81YmMW-- From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 10:13:50 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 1907ED86 for ; Tue, 9 Sep 2014 10:13:50 +0000 (UTC) Received: from mail-pd0-x22d.google.com (mail-pd0-x22d.google.com [IPv6:2607:f8b0:400e:c02::22d]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id DB7BFEB9 for ; Tue, 9 Sep 2014 10:13:49 +0000 (UTC) Received: by mail-pd0-f173.google.com with SMTP id ft15so6643929pdb.18 for ; Tue, 09 Sep 2014 03:13:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to; bh=P9OA+CKHE0n/MZPCCi9DG6q6AaaETqAgH2zIuPFTkf8=; b=fnJQz9NnGa0flxJWiECFreHDrl4xct/U3xdUnrkFXW7i397ZUY+zc+vZK9FTjFqXQg MEJhHxpb9+AsetOkUbhGIgSOOQAoDwM7PbmZi9bOgL8E8389vENfocRD3ZXRiLdB8tc8 XXsvKJw6+tIQdSLTBBIFTvZ4+V6VQat3MiSUGWzTsm7fOTpPPLP3O93fvH+01l3sALL4 XP153nzbbw9T+/9wjo4SMTDsAidcDIqxXAo7CNahk2B2UZgD2vDNFk9KeMd3GW1VyFAr nqnUOgqgSOg1VkRZlTTAQjSNnGgvbDf9SKENBNuPZ3QENIgH1lNrIrLmrs7ScScFKj6a RRYQ== X-Received: by 10.66.242.47 with SMTP id wn15mr56678135pac.64.1410257629409; Tue, 09 Sep 2014 03:13:49 -0700 (PDT) Received: from ?IPv6:2601:8:ab80:7d6:a5b6:317c:4de0:54e? ([2601:8:ab80:7d6:a5b6:317c:4de0:54e]) by mx.google.com with ESMTPSA id x1sm11333931pdm.13.2014.09.09.03.13.46 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Sep 2014 03:13:46 -0700 (PDT) Content-Type: multipart/signed; boundary="Apple-Mail=_C7E4E3CD-90FE-4FEB-A167-21EC9CF454F4"; protocol="application/pgp-signature"; micalg=pgp-sha512 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: [RFC] Add __arraycount from NetBSD to sys/cdefs.h From: yaneurabeya@gmail.com In-Reply-To: <20140909083333.GA2737@kib.kiev.ua> Date: Tue, 9 Sep 2014 03:13:45 -0700 Message-Id: References: <8D279BDC-7D40-4750-8DA7-A4535DD2E458@bsdimp.com> <146C3E96-7461-4D30-8B7F-5E20F72CF061@gmail.com> <20140909083333.GA2737@kib.kiev.ua> To: Konstantin Belousov X-Mailer: Apple Mail (2.1878.6) Cc: "freebsd-arch@FreeBSD.org Arch" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 10:13:50 -0000 --Apple-Mail=_C7E4E3CD-90FE-4FEB-A167-21EC9CF454F4 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 Hi kib@! On Sep 9, 2014, at 1:33, Konstantin Belousov = wrote: > On Mon, Sep 08, 2014 at 09:29:54AM -0700, yaneurabeya@gmail.com wrote: >> On Sep 3, 2014, at 21:17, Warner Losh wrote: >>=20 >>> On Sep 3, 2014, at 9:45 PM, Garrett Cooper = wrote: >>>=20 >>>> Hi all, >>>> In order to ease porting code and reduce divergence with NetBSD >>>> when importing code (a large chunk of which for me are tests), I = would >>>> like to move nitems to sys/cdefs.h and alias __arraycount to = nitems. >>>> Here's the __arraycount #define in lib/libnetbsd/sys/cdefs.h: >>>>=20 >>>> 44 /* >>>> 45 * Return the number of elements in a statically-allocated = array, >>>> 46 * __x. >>>> 47 */ >>>> 48 #define __arraycount(__x) (sizeof(__x) / sizeof(__x[0])) >>>>=20 >>>> Here's the nitems #define in sys/sys/param.h: >>>>=20 >>>> 277 #define nitems(x) (sizeof((x)) / sizeof((x)[0])) >>>>=20 >>>> sys/cdefs.h gets pulled in automatically with sys/param.h, so >>>> anything using nitems will continue to function like before (see = below >>>> for more details). I've attached a patch which addresses all = hardcoded >>>> definitions in the tree added by FreeBSD developers. >>>> If there aren't any major concerns with my proposed change, I'll >>>> put it up for review on Phabricator. >>>> Thank you! >>>> -Garrett >>>>=20 >>>> $ cat cdefs_pound_define.c >>>> #include >>>>=20 >>>> #ifdef _SYS_CDEFS_H_ >>>> #warning "sys/cdefs.h has been included" >>>> #endif >>>> $ cc -c cdefs_pound_define.c >>>> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" = [-W#warnings] >>>> #warning "sys/cdefs.h has been included" >>>> ^ >>>> 1 warning generated. >>>> $ cc -D_KERNEL -c cdefs_pound_define.c >>>> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" = [-W#warnings] >>>> #warning "sys/cdefs.h has been included" >>>> ^ >>>> 1 warning generated. >>>> $ gcc -c cdefs_pound_define.c >>>> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been = included" >>>> $ gcc -D_KERNEL -c cdefs_pound_define.c >>>> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been = included? >>>=20 >>> I wouldn?t bother changing the nitems #define. There?s no need, = really, to do that. >>=20 >> Rethinking my proposal, I agree. I had lofty hopes for unifying the = macros, but the functional duplication (1 line) is harmless. >>=20 >>> I?d also be more inclined to believe the test if you tested what the = thing does rather than test for an artificial, implementation defined = side effect. >>=20 >> Sure. I provided a lazy proof instead of a full proof :). >>=20 >>> But honestly the amount of duplication saved here is rather tiny? >>=20 >> Indeed! Thank you for the input :) ? I?ve attached a new patch which = doesn?t disturb nitems or sys/param.h. >=20 > Since this is seriously discussed on arch@, I think it is worth look > at the following: >=20 > git grep -e 'sizeof.*/sizeof' -- | grep -v '^contrib' | grep = '#.*define' | wc -l > 118 > These are only defines, not uses, not counting direct use of > sizeof(x)/sizeof(x[0]) in the code. It=92s a bit less painful if you omit cddl, crypto, and gnu: $ git grep -e 'sizeof.*/sizeof' -- | egrep -v = '^(cddl|contrib|crypto|gnu)' | grep '#.*define' | wc -l 105 > Not all of them are for equiv macros, but significant part repeats = ntimes() > in variations. At least Linuxish ARRAY_SIZE/DRM_ARRAY_SIZE is much = more > popular than __arraysize() which appears three (!) times. Hmm.. that=92s a bit surprising. > I do not see any reason to pollute central header cdefs.h with = sparcely > used macro for some compat code. This is one compelling reason =97 it=92s used 225 times in the test code = in NetBSD, spanning 92 files, and 15 times spanning 10 files in the rump = kernel. $ grep -rl __arraycount netbsd/src/tests/ | wc -l; grep -r __arraycount = netbsd/src/tests/ | wc -l 92 225 $ grep -rl __arraycount netbsd/src/sys/rump | wc -l; grep -r = __arraycount netbsd/src/sys/rump | wc -l 10 15 My goal is to pull in as much test code from NetBSD that I=92ve done on = my github fork and apply it to FreeBSD with as little deviations as = possible, wherever possible. The less we deviate and can push back and = forth between FreeBSD and NetBSD, the easier it will be in the long run = for both parties to develop and maintain test code and other code from = NetBSD. That being said, there might be a compromise that could be struck where = the compat code can stay confined to libnetbsd. If I change the code = bsd.test.mk or contributed code to explicitly use -include or -I, then = point to the lib/libnetbsd/sys/cdefs.h header, then this could become a = non-issue: -include filename Adds an implicit #include into the predefines buffer which is = read before the source file is preprocessed. -Idirectory Add the specified directory to the search path for include = files. Does that seem like an appropriate solution? Thanks! -Garrett PS For what it=92s worth, nitems use has caught on like wildfire (it = beats out __arraycount and the ad hoc sizeof): $ git grep -e nitems -- | egrep -v '^(cddl|contrib|crypto|gnu)' | wc -l 551 --Apple-Mail=_C7E4E3CD-90FE-4FEB-A167-21EC9CF454F4 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQEcBAEBCgAGBQJUDtLZAAoJEMZr5QU6S73e4xUH/jjB6W8ng18g5kMRZ2K/6ySi WPvmKZE3FTpAXzKSFtT5OJo9T1rqfV4+YhsncXkvUhtlLCDuyDjJwqTuWKRdhg47 zDRHSjVOEMH7InWN+OzaI8FfDC1TYI++hKfMHcdUYs8zgLxOWYTrKV/ZPgBFRDE0 PDWA4E+c4956Jaqd2Ixyrb9vY1S0gaUW2Gq1yrxNf9+66UXyWCIfZ0qRUEDPcU65 MtUMwJ6cHcyJZ9Yso144GSZXAZQOn/PNe1/+3AroJj/9DzYQGj39XlgNLBHdVzPs dU2y3oMFkvgKNGM5c2REqGZJbznE9JBVutUthx60Vn0qjATqsnvh09elo6l+tTs= =nxsF -----END PGP SIGNATURE----- --Apple-Mail=_C7E4E3CD-90FE-4FEB-A167-21EC9CF454F4-- From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 15:30:17 2014 Return-Path: Delivered-To: freebsd-arch@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 23F7B8DC; Tue, 9 Sep 2014 15:30:17 +0000 (UTC) Received: from mail.made4.biz (mail.made4.biz [IPv6:2001:41d0:2:c018::1:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DA872B82; Tue, 9 Sep 2014 15:30:16 +0000 (UTC) Received: from 2a02-8428-011b-e000-0290-f5ff-fe9d-b78c.rev.sfr.net ([2a02:8428:11b:e000:290:f5ff:fe9d:b78c] helo=magellan.dumbbell.fr) by mail.made4.biz with esmtpsa (TLSv1.2:DHE-RSA-AES128-SHA:128) (Exim 4.83 (FreeBSD)) (envelope-from ) id 1XRNN1-000JtP-2F; Tue, 09 Sep 2014 17:30:15 +0200 Message-ID: <540F1D02.4040203@FreeBSD.org> Date: Tue, 09 Sep 2014 17:30:10 +0200 From: =?UTF-8?B?SmVhbi1Tw6liYXN0aWVuIFDDqWRyb24=?= User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Jakub Klama Subject: evdev GSoc and libinput/Weston? Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="IvqD13OTP9ASk5k6f1BFf65dep9UCdN7d" Cc: =?UTF-8?B?RWR3YXJkIFRvbWFzeiBOYXBpZXJhxYJh?= , freebsd-arch@FreeBSD.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 15:30:17 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --IvqD13OTP9ASk5k6f1BFf65dep9UCdN7d Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hello Jakub! I understand that you completed your GSoC project about implementing evdev on FreeBSD, congratulations! I'm glad we're getting that in FreeBSD= :) I plan to try your branch in the coming weeks. I'm especially interested in playing with libinput [1] and Weston [2]. Did you try that already? Could you please provide a patch against HEAD? Or better, create a review in Phabricator [3]? It will be easier for people to test and review your code. No matter what you choose, add a link in the wiki as well :) Thank you! [1] http://freedesktop.org/wiki/Software/libinput/ [2] http://wayland.freedesktop.org/ [3] Phabricator: https://reviews.freebsd.org/ User guide: https://wiki.freebsd.org/CodeReview --=20 Jean-S=C3=A9bastien P=C3=A9dron --IvqD13OTP9ASk5k6f1BFf65dep9UCdN7d Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQJ8BAEBCgBmBQJUDx0GXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NzA4N0ZEMUFFQUUwRTEyREJDNkE2RjAz OUU5OTc2MUE1RkQ5NENDAAoJEDnpl2Gl/ZTM7gEP/RL0RYBKf/2/J8WL9W5HtJRo r7/I/HkpU8kj2y4ZPejYO4lFNg/ZKGriVXdMFzJ42VwHZq95CBTmviZx4itsljjc fJ/kyXPPXr4d4VytofrF4wg+nzZMrLjO0pNWE2i2nlOLSY74DRBkqtx+fRxuVnag bPs7x0hmQMdDFJONdi+qDROSWYCI2oy293CjdMrRkqHizONuIF/LUv8VEi7H4aRG WTXrMl6iCMSa8NCyA0M0roX1l1WuLub1B7dIK53PmYpOGOjRl1D9zgvYPxijF/9f ZxWgrGEF7UWUsdxryMFdwi6X6zEsUzcPCCSzVVVhG69nKCWvTkxhSl8fqVVoaHKH ELi3NlyC7oFtcRPDqo0GCJ9/FLWJogAnRncUXJivJifg0oFc58xriujeCsTpO4v/ 8XPTQgJcys45rmPlLFkn6myJuJr/qeCHopnVebHFCjZyIl51hVLUJ6WN8yy7FD0Q dA1n7v+YwD+WLHusrrH2FVTwt/v5Nyt9xpNfZHxusGddhG01HtKuizO4WJw2ujO+ X0pEzeqM505iXR+vR2dwQ2Q7hCOkxMDBRCwe1rFFg1LI0sX2iL4nvktnUZWU1Hte jTz0JagGGVedNujoZbTwa2kRoiGt2ufgc6d/TfWzZMmk67sbzkRvZTLTKaOGrNrV z5KMyWHdRYuokGODFBnB =mxn5 -----END PGP SIGNATURE----- --IvqD13OTP9ASk5k6f1BFf65dep9UCdN7d-- From owner-freebsd-arch@FreeBSD.ORG Tue Sep 9 21:03:35 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 170A0551 for ; Tue, 9 Sep 2014 21:03:35 +0000 (UTC) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ADD698DF for ; Tue, 9 Sep 2014 21:03:34 +0000 (UTC) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.14.9/8.14.9) with ESMTP id s89L3TdM056813 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 10 Sep 2014 00:03:29 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.9.2 kib.kiev.ua s89L3TdM056813 Received: (from kostik@localhost) by tom.home (8.14.9/8.14.9/Submit) id s89L3T4C056812; Wed, 10 Sep 2014 00:03:29 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Wed, 10 Sep 2014 00:03:29 +0300 From: Konstantin Belousov To: yaneurabeya@gmail.com Subject: Re: [RFC] Add __arraycount from NetBSD to sys/cdefs.h Message-ID: <20140909210329.GE2737@kib.kiev.ua> References: <8D279BDC-7D40-4750-8DA7-A4535DD2E458@bsdimp.com> <146C3E96-7461-4D30-8B7F-5E20F72CF061@gmail.com> <20140909083333.GA2737@kib.kiev.ua> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="WEBrq8xPpGVQldHe" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on tom.home Cc: "freebsd-arch@FreeBSD.org Arch" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Sep 2014 21:03:35 -0000 --WEBrq8xPpGVQldHe Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Sep 09, 2014 at 03:13:45AM -0700, yaneurabeya@gmail.com wrote: > Hi kib@! >=20 > On Sep 9, 2014, at 1:33, Konstantin Belousov wrote: >=20 > > On Mon, Sep 08, 2014 at 09:29:54AM -0700, yaneurabeya@gmail.com wrote: > >> On Sep 3, 2014, at 21:17, Warner Losh wrote: > >>=20 > >>> On Sep 3, 2014, at 9:45 PM, Garrett Cooper wr= ote: > >>>=20 > >>>> Hi all, > >>>> In order to ease porting code and reduce divergence with NetBSD > >>>> when importing code (a large chunk of which for me are tests), I wou= ld > >>>> like to move nitems to sys/cdefs.h and alias __arraycount to nitems. > >>>> Here's the __arraycount #define in lib/libnetbsd/sys/cdefs.h: > >>>>=20 > >>>> 44 /* > >>>> 45 * Return the number of elements in a statically-allocated array, > >>>> 46 * __x. > >>>> 47 */ > >>>> 48 #define __arraycount(__x) (sizeof(__x) / sizeof(__x[0])) > >>>>=20 > >>>> Here's the nitems #define in sys/sys/param.h: > >>>>=20 > >>>> 277 #define nitems(x) (sizeof((x)) / sizeof((x)[0])) > >>>>=20 > >>>> sys/cdefs.h gets pulled in automatically with sys/param.h, so > >>>> anything using nitems will continue to function like before (see bel= ow > >>>> for more details). I've attached a patch which addresses all hardcod= ed > >>>> definitions in the tree added by FreeBSD developers. > >>>> If there aren't any major concerns with my proposed change, I'll > >>>> put it up for review on Phabricator. > >>>> Thank you! > >>>> -Garrett > >>>>=20 > >>>> $ cat cdefs_pound_define.c > >>>> #include > >>>>=20 > >>>> #ifdef _SYS_CDEFS_H_ > >>>> #warning "sys/cdefs.h has been included" > >>>> #endif > >>>> $ cc -c cdefs_pound_define.c > >>>> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" [= -W#warnings] > >>>> #warning "sys/cdefs.h has been included" > >>>> ^ > >>>> 1 warning generated. > >>>> $ cc -D_KERNEL -c cdefs_pound_define.c > >>>> cdefs_pound_define.c:4:2: warning: "sys/cdefs.h has been included" [= -W#warnings] > >>>> #warning "sys/cdefs.h has been included" > >>>> ^ > >>>> 1 warning generated. > >>>> $ gcc -c cdefs_pound_define.c > >>>> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been in= cluded" > >>>> $ gcc -D_KERNEL -c cdefs_pound_define.c > >>>> cdefs_pound_define.c:4:2: warning: #warning "sys/cdefs.h has been in= cluded? > >>>=20 > >>> I wouldn?t bother changing the nitems #define. There?s no need, reall= y, to do that. > >>=20 > >> Rethinking my proposal, I agree. I had lofty hopes for unifying the ma= cros, but the functional duplication (1 line) is harmless. > >>=20 > >>> I?d also be more inclined to believe the test if you tested what the = thing does rather than test for an artificial, implementation defined side = effect. > >>=20 > >> Sure. I provided a lazy proof instead of a full proof :). > >>=20 > >>> But honestly the amount of duplication saved here is rather tiny? > >>=20 > >> Indeed! Thank you for the input :) ? I?ve attached a new patch which d= oesn?t disturb nitems or sys/param.h. > >=20 > > Since this is seriously discussed on arch@, I think it is worth look > > at the following: > >=20 > > git grep -e 'sizeof.*/sizeof' -- | grep -v '^contrib' | grep '#.*define= ' | wc -l > > 118 > > These are only defines, not uses, not counting direct use of > > sizeof(x)/sizeof(x[0]) in the code. >=20 > It?s a bit less painful if you omit cddl, crypto, and gnu: >=20 > $ git grep -e 'sizeof.*/sizeof' -- | egrep -v '^(cddl|contrib|crypto|gnu)= ' | grep '#.*define' | wc -l > 105 >=20 > > Not all of them are for equiv macros, but significant part repeats ntim= es() > > in variations. At least Linuxish ARRAY_SIZE/DRM_ARRAY_SIZE is much more > > popular than __arraysize() which appears three (!) times. >=20 > Hmm.. that?s a bit surprising. >=20 > > I do not see any reason to pollute central header cdefs.h with sparcely > > used macro for some compat code. >=20 > This is one compelling reason ? it?s used 225 times in the test code in N= etBSD, spanning 92 files, and 15 times spanning 10 files in the rump kernel. >=20 > $ grep -rl __arraycount netbsd/src/tests/ | wc -l; grep -r __arraycount n= etbsd/src/tests/ | wc -l > 92 > 225 > $ grep -rl __arraycount netbsd/src/sys/rump | wc -l; grep -r __arraycount= netbsd/src/sys/rump | wc -l > 10 > 15 >=20 > My goal is to pull in as much test code from NetBSD that I?ve done on my = github fork and apply it to FreeBSD with as little deviations as possible, = wherever possible. The less we deviate and can push back and forth between = FreeBSD and NetBSD, the easier it will be in the long run for both parties = to develop and maintain test code and other code from NetBSD. >=20 > That being said, there might be a compromise that could be struck where t= he compat code can stay confined to libnetbsd. If I change the code bsd.tes= t.mk or contributed code to explicitly use -include or -I, then point to th= e lib/libnetbsd/sys/cdefs.h header, then this could become a non-issue: >=20 > -include filename > Adds an implicit #include into the predefines buffer which is = read > before the source file is preprocessed. >=20 > -Idirectory > Add the specified directory to the search path for include fil= es. >=20 > Does that seem like an appropriate solution? If it is isolated to tests, I have no objections nor comments. >=20 > Thanks! > -Garrett >=20 > PS For what it?s worth, nitems use has caught on like wildfire (it beats = out __arraycount and the ad hoc sizeof): >=20 > $ git grep -e nitems -- | egrep -v '^(cddl|contrib|crypto|gnu)' | wc -l > 551 It might be worth to clean up the __arraycount or other equivalent macros in the non-contributed code (only because the issue is already discussed much more than it worth). E.g., sys/kern/stack_protector.c can happily use nitems(), I am sure that there are much more such places. --WEBrq8xPpGVQldHe Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJUD2sgAAoJEJDCuSvBvK1BZaEP/3bYiHQmUOOCUA3O3w0EllCm dJPm7PSfnbd0oAeFm6Y47dtH/napTcbctYGKe+/Dznd2wUz8sgFVhjXynlxBEazl LShyizXEel3c0et5KCZ9bkP58oio9Cd20jhb82KcX8hvvlN97UcuvHr59M9Zpxu6 Vs/p5WCNCv70uTcPn06R0GFO8ldgy2pTPSj9AvavfcNk++rb/rpvkl/Gt2h+74S5 UjiNI7gNn+MACYcgtaDvAbsug2M6X4d0aaS5b0YWuwj7YCx8QG/+1N8R2KCn6SrF r5BmgQ/1ngw7pbazvZ5cdc5AQ+qfMX/EmBeBYwkCthR9+RAh0FNJyRTbXB36D820 1X5nQw9buFZZNrFrAriiSkLQN4lYg4csHgQkErA88pcG8U7yNTnAScqQmFK7iFRK xfm5HeAsUw6qr2naCRoMnz75n0WODP5+TmcT1Np57/4nw5RpYFCexQNP1D0Wd7N4 XK8+OwrtBGgM52aVgJF9Dle9oxJntRtq6bdZyYCq613tS7OmBMd9lavCnWGht6cR BHwMTMs/Y7ijASa5whxHTCTtGQ5FIIVKqNlQT5d1YgzrXiNLARDDu9Z6UYK/UjiZ pbRmyIhdi3o/J5qgLW9pOcI4O6FcDwe0NxRaN+GqjxjSgRUQlGX5D5xAIv0kezuH DkUa3IeS11cnR/wHmKD4 =fmQy -----END PGP SIGNATURE----- --WEBrq8xPpGVQldHe-- From owner-freebsd-arch@FreeBSD.ORG Wed Sep 10 15:59:09 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3D5AE660; Wed, 10 Sep 2014 15:59:09 +0000 (UTC) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [IPv6:2001:470:1f11:75::1]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 13A9D1718; Wed, 10 Sep 2014 15:59:09 +0000 (UTC) Received: from ralph.baldwin.cx (pool-173-70-85-31.nwrknj.fios.verizon.net [173.70.85.31]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id EBD51B992; Wed, 10 Sep 2014 11:59:07 -0400 (EDT) From: John Baldwin To: freebsd-arch@freebsd.org Subject: Re: /etc/motd summary Date: Wed, 10 Sep 2014 10:06:47 -0400 Message-ID: <1412347.AsDd5CXCVa@ralph.baldwin.cx> User-Agent: KMail/4.10.5 (FreeBSD/10.0-STABLE; KDE/4.10.5; amd64; ; ) In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Wed, 10 Sep 2014 11:59:08 -0400 (EDT) Cc: Warren Block , Adrian Chadd , Brooks Davis , Bryan Drewery X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Sep 2014 15:59:09 -0000 On Monday, September 08, 2014 08:24:00 PM Warren Block wrote: > On Mon, 8 Sep 2014, Adrian Chadd wrote: > > On 8 September 2014 17:46, Brooks Davis wrote: > >> On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: > >>> for maximum bikeshed: what about adding a 'motd' command that, I > >>> dunno, re-displays the motd? :P > >> > >> How would someone who didn't know about /etc/motd ever find that? > > > > Putting "Type 'motd' to see this information again" in the motd. > > Or leave it the way it is, /etc/motd is just a file that is displayed, > but instead of dumping it to stdout, interpret some kind of markup in > it. > > That's relatively high overhead considering the layout will still be > limited to 80x24. We'd probably be better off leaving it as is and > moving most of the information to a man page, say support(1), which is > mentioned by /etc/motd. Yes. You can use formatting if you have a 'man welcome'. That might be the best way to provide a local, formatted copy of the proposed "welcome" page from earlier. You could even create a very simple 'welcome' wrapper script that runs 'man welcome' so that in the motd you just have to say "run the welcome command". No need for having to worry about having to figure out how to separate arguments from the command that way (which is the the problem we have now that requires double spaces since all the examples are commands that take arguments like 'man man'). For a command with no arguments you don't have to do that I think. -- John Baldwin From owner-freebsd-arch@FreeBSD.ORG Wed Sep 10 16:42:24 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 89E441E0; Wed, 10 Sep 2014 16:42:24 +0000 (UTC) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 412F41D2F; Wed, 10 Sep 2014 16:42:24 +0000 (UTC) Received: from slw by zxy.spb.ru with local (Exim 4.82 (FreeBSD)) (envelope-from ) id 1XRkyM-0009hT-DY; Wed, 10 Sep 2014 20:42:22 +0400 Date: Wed, 10 Sep 2014 20:42:22 +0400 From: Slawa Olhovchenkov To: Tom Rhodes Subject: Re: /etc/motd summary Message-ID: <20140910164222.GA36856@zxy.spb.ru> References: <540E18ED.1070003@FreeBSD.org> <540E2410.30404@FreeBSD.org> <20140908205505.421ddf62.trhodes@FreeBSD.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140908205505.421ddf62.trhodes@FreeBSD.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false Cc: Adrian Chadd , freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Sep 2014 16:42:24 -0000 On Mon, Sep 08, 2014 at 08:55:05PM -0400, Tom Rhodes wrote: > On Mon, 8 Sep 2014 17:25:31 -0700 > Adrian Chadd wrote: > > > for maximum bikeshed: what about adding a 'motd' command that, I > > dunno, re-displays the motd? :P > > Oh, lets start a discussion on who can make it the smallest > shell and binary possible. http://dadv.livejournal.com/105161.html 512 bytes. From owner-freebsd-arch@FreeBSD.ORG Wed Sep 10 17:10:12 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 09BB1AFB for ; Wed, 10 Sep 2014 17:10:12 +0000 (UTC) Received: from mail-ie0-f173.google.com (mail-ie0-f173.google.com [209.85.223.173]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C26181FB0 for ; Wed, 10 Sep 2014 17:10:11 +0000 (UTC) Received: by mail-ie0-f173.google.com with SMTP id x19so3879183ier.4 for ; Wed, 10 Sep 2014 10:10:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:content-type:mime-version:subject:from :in-reply-to:date:cc:message-id:references:to; bh=oqTIFnBlOGnu0yGPILSi7SxU+slRuDsOA2Sh2TLzzPA=; b=NAw5E0NFRnJvWi0NQvXotJNnr1m84w7Ir/CPMv+75NpVI1H/IbxtVvZEmSc9PKpmKh P1VDo/eHMSboTGeM1rNs41+v8GUMZb77lYYukqQcrSyW/dJ6JoRyZPb9Rii3hGS24DGl FlcXg7MKHCTFUjRUWSsqjOOevtZmJCJTgkZ+SMqbloPv6SGmcuscwiS36DcbbAqkFB1w wAkDfK4ynBhMY/7dnwGpGgOMSQ7JIaC0DlALmdEaeMuHZ65R4jT4NLzo4YIWFiXhtmbf b+/FpRFNjxoKXFkB4Loq2+B846pHHFv1ba/NxoIJG6DYiy2HEuvGGUDyXkWRwD8frS4Q rKXQ== X-Gm-Message-State: ALoCoQnlBZ2eA/Wx+YQcPheSRzsLrGfCyoessCUKoxaA5eiWzLTGuI72VWGBcdyhKLZ9++MsXbKD X-Received: by 10.42.254.129 with SMTP id ne1mr46549410icb.29.1410369010868; Wed, 10 Sep 2014 10:10:10 -0700 (PDT) Received: from bsdimp.bsdimp.com (50-78-194-198-static.hfc.comcastbusiness.net. [50.78.194.198]) by mx.google.com with ESMTPSA id ci9sm2487626igb.17.2014.09.10.10.10.09 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 10 Sep 2014 10:10:10 -0700 (PDT) Sender: Warner Losh Content-Type: multipart/signed; boundary="Apple-Mail=_211892D1-BF4C-40BC-965B-9F406FAE39F7"; protocol="application/pgp-signature"; micalg=pgp-sha512 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: /etc/motd summary From: Warner Losh In-Reply-To: <1412347.AsDd5CXCVa@ralph.baldwin.cx> Date: Wed, 10 Sep 2014 11:10:07 -0600 Message-Id: <91F578E3-F1E3-47C4-9DE8-DB796F52A382@bsdimp.com> References: <1412347.AsDd5CXCVa@ralph.baldwin.cx> To: John Baldwin X-Mailer: Apple Mail (2.1878.6) Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Sep 2014 17:10:12 -0000 --Apple-Mail=_211892D1-BF4C-40BC-965B-9F406FAE39F7 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 On Sep 10, 2014, at 8:06 AM, John Baldwin wrote: > On Monday, September 08, 2014 08:24:00 PM Warren Block wrote: >> On Mon, 8 Sep 2014, Adrian Chadd wrote: >>> On 8 September 2014 17:46, Brooks Davis wrote: >>>> On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: >>>>> for maximum bikeshed: what about adding a 'motd' command that, I >>>>> dunno, re-displays the motd? :P >>>>=20 >>>> How would someone who didn't know about /etc/motd ever find that? >>>=20 >>> Putting "Type 'motd' to see this information again" in the motd. >>=20 >> Or leave it the way it is, /etc/motd is just a file that is = displayed, >> but instead of dumping it to stdout, interpret some kind of markup in >> it. >>=20 >> That's relatively high overhead considering the layout will still be >> limited to 80x24. We'd probably be better off leaving it as is and >> moving most of the information to a man page, say support(1), which = is >> mentioned by /etc/motd. >=20 > Yes. You can use formatting if you have a 'man welcome'. That might = be the=20 > best way to provide a local, formatted copy of the proposed "welcome" = page=20 > from earlier. You could even create a very simple 'welcome' wrapper = script=20 > that runs 'man welcome' so that in the motd you just have to say "run = the=20 > welcome command". No need for having to worry about having to figure = out how=20 > to separate arguments from the command that way (which is the the = problem we=20 > have now that requires double spaces since all the examples are = commands that=20 > take arguments like 'man man'). For a command with no arguments you = don't=20 > have to do that I think. Stepping back from this problem a bit and refocusing on the original ask = (I want to put ANSI escape sequences to punch things up a bit): We have the terminal set (usually) by the time we cat /etc/motd. = login.conf controls this with the welcome=3D parameter. We have two = choices here. One, allow the welcome string to start with | and have it be the command = to run. This could be =93man welcome=94 or something else canned. = Flexible, but maybe not the best. Another vector to this approach would be to allow /etc/motd to start = with #!/usr/bin/man (or some other magic) and have it run through a = fixed program like man (and only man) instead of just being cat=92d out. = This would allow proper rendering on all devices in a way that=92s = backwards compatible as well, but maybe with less security concerns. I = like this better because it puts the message of the day file in control = of today=92s message... These tools would allow for a fancier rendition of whatever text is = decided here as well as not violating POLA. Warner --Apple-Mail=_211892D1-BF4C-40BC-965B-9F406FAE39F7 Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - https://gpgtools.org iQIcBAEBCgAGBQJUEIXvAAoJEGwc0Sh9sBEArs4P/iGVXTM4fbFiTcE53daMhFmN awc/Pe2L/1v6GcMlo5VZ7IvtPa92IPGjH2iK5L7xYbSfT3ABdyd1fyX120aXRsL3 iFkObt5vqYu9oVndXPdGJe4PeiM4iB0aau82NF3s9ApTxNpsQAd5JSfrAiYqdT2b Eb2gjNE6BkhB0ctrPHIAhH8QVuONDjC8ik1TMdqm4IW9I458L+1Pg4XBj9DnQrZ0 YmfEBdSX49VEcEh9EhC15IldEpPQ3WCrc6D2JjT2ENHbyg1bH+Ah6Glcl27ppNNQ TQhxfU+gDVid3gn2UGXTwFHekmGZW8WyeLsT6PCJnSXPzeSahqQwPEQE6sR0iYKk +i0lcA+FwQDbhI/GKkb4AfMt5rwMSY7bWz+iCoIManPCg4OEppkSeto6iMpTBn/7 V3CFwl5yAdtRXeCq5FuhDWOjOhXSrO2j6yPpnK4mzIFpU7q01hl3BwgsSflhpLbR cE02fu3dWTl2ehu7w7UxVA6FDkOG+eFsOPFMmgRrvcT6CCLcAFt2Zn0wfI1RWxcH 79ynHmn8U5aqAt44r5SqNlko3Yex4YSRffR5jlgOcD6C4cY38LtYgPmR4WzD28bq Xd4wwGY6jf+UdiLBuOXyE4plHMHIdZbUJytpN9roRroCH8DV7O8rpPWLZSFqXsv+ 34HaOd26uEYYet3WGbrk =h2My -----END PGP SIGNATURE----- --Apple-Mail=_211892D1-BF4C-40BC-965B-9F406FAE39F7-- From owner-freebsd-arch@FreeBSD.ORG Wed Sep 10 17:25:59 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 65B72FBB; Wed, 10 Sep 2014 17:25:59 +0000 (UTC) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 198E01E8; Wed, 10 Sep 2014 17:25:59 +0000 (UTC) Received: from slw by zxy.spb.ru with local (Exim 4.82 (FreeBSD)) (envelope-from ) id 1XRleW-000AZc-9G; Wed, 10 Sep 2014 21:25:56 +0400 Date: Wed, 10 Sep 2014 21:25:56 +0400 From: Slawa Olhovchenkov To: Warner Losh Subject: Re: /etc/motd summary Message-ID: <20140910172556.GA40066@zxy.spb.ru> References: <1412347.AsDd5CXCVa@ralph.baldwin.cx> <91F578E3-F1E3-47C4-9DE8-DB796F52A382@bsdimp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <91F578E3-F1E3-47C4-9DE8-DB796F52A382@bsdimp.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Sep 2014 17:25:59 -0000 On Wed, Sep 10, 2014 at 11:10:07AM -0600, Warner Losh wrote: > > On Sep 10, 2014, at 8:06 AM, John Baldwin wrote: > > > On Monday, September 08, 2014 08:24:00 PM Warren Block wrote: > >> On Mon, 8 Sep 2014, Adrian Chadd wrote: > >>> On 8 September 2014 17:46, Brooks Davis wrote: > >>>> On Mon, Sep 08, 2014 at 05:25:31PM -0700, Adrian Chadd wrote: > >>>>> for maximum bikeshed: what about adding a 'motd' command that, I > >>>>> dunno, re-displays the motd? :P > >>>> > >>>> How would someone who didn't know about /etc/motd ever find that? > >>> > >>> Putting "Type 'motd' to see this information again" in the motd. > >> > >> Or leave it the way it is, /etc/motd is just a file that is displayed, > >> but instead of dumping it to stdout, interpret some kind of markup in > >> it. > >> > >> That's relatively high overhead considering the layout will still be > >> limited to 80x24. We'd probably be better off leaving it as is and > >> moving most of the information to a man page, say support(1), which is > >> mentioned by /etc/motd. > > > > Yes. You can use formatting if you have a 'man welcome'. That might be the > > best way to provide a local, formatted copy of the proposed "welcome" page > > from earlier. You could even create a very simple 'welcome' wrapper script > > that runs 'man welcome' so that in the motd you just have to say "run the > > welcome command". No need for having to worry about having to figure out how > > to separate arguments from the command that way (which is the the problem we > > have now that requires double spaces since all the examples are commands that > > take arguments like 'man man'). For a command with no arguments you don't > > have to do that I think. > > Stepping back from this problem a bit and refocusing on the original ask (I want to put ANSI escape sequences to punch things up a bit): > > We have the terminal set (usually) by the time we cat /etc/motd. login.conf controls this with the welcome= parameter. We have two choices here. > > One, allow the welcome string to start with | and have it be the command to run. This could be "man welcome" or something else canned. Flexible, but maybe not the best. > > Another vector to this approach would be to allow /etc/motd to start with #!/usr/bin/man (or some other magic) and have it run through a fixed program like man (and only man) instead of just being cat'd out. This would allow proper rendering on all devices in a way that's backwards compatible as well, but maybe with less security concerns. I like this better because it puts the message of the day file in control of today's message... > > These tools would allow for a fancier rendition of whatever text is decided here as well as not violating POLA. May be simple reduce /etc/motd to one line (FreeBSD ... 2014) and rest of information by some programs, similar to fortune or man (from login script). From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 16:49:45 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id CBB4C296 for ; Thu, 11 Sep 2014 16:49:45 +0000 (UTC) Received: from mail-lb0-x236.google.com (mail-lb0-x236.google.com [IPv6:2a00:1450:4010:c04::236]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 542EA6E5 for ; Thu, 11 Sep 2014 16:49:45 +0000 (UTC) Received: by mail-lb0-f182.google.com with SMTP id v6so7117162lbi.13 for ; Thu, 11 Sep 2014 09:49:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=qU1VBfFdi/DtYeCiqh2THg0du9K5eLlLEBn7AxIg8sA=; b=iIfkiSetfIWVHZ/ghfYZTVOf0HN66Yh/e8oqK7P3VRwJ1WK+CVf8CCwE4I2nNV9GaO ewVVm+tPsWSO9ZQ+EKbMtgbBoeEnmo5pQaT+Qfwi8w7LlJlyuMKKuM9kuBwjkQd7GjXp hLNZSurxoFAcAbZi9twA3z6YOpeEcVKndxTvLsNapL4mXwcGYOyjw5355P4N6T8oK1oW Tn05nIQlkBNhvAOME9KIkqAuhgJF5rtz8tpQXucQhDcT4YOmBPLsZ1BKkI3+Q1DofYgf xcb4KcMGr621hN0xwQyqO83lNn7KxN+jchN9rjgAk016URyMQxmNMjJHjHVOH+aFW0IL rdpQ== MIME-Version: 1.0 X-Received: by 10.152.20.1 with SMTP id j1mr2514034lae.57.1410454183082; Thu, 11 Sep 2014 09:49:43 -0700 (PDT) Sender: crodr001@gmail.com Received: by 10.112.22.72 with HTTP; Thu, 11 Sep 2014 09:49:42 -0700 (PDT) In-Reply-To: References: Date: Thu, 11 Sep 2014 09:49:42 -0700 X-Google-Sender-Auth: TMXMcTxt7tqfwdFYiQX0TWdaRT8 Message-ID: Subject: Re: /etc/motd summary From: Craig Rodrigues To: Warren Block Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 16:49:45 -0000 On Mon, Sep 8, 2014 at 12:08 PM, Warren Block wrote: > > http://www.wonkity.com/~wblock/motd/motd.whitespace-url > > > Can you go ahead and commit this, and then after 3 days submit a request to re@ to MFC this to stable/10 so we can get this in 10.1? The suggestions brought up in this thread are good, but will take some time to implement. Your changes to motd update the content to more current sources of help, and do improve things a bit. It is good to get this in. -- Craig From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 18:18:21 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 72FF87A5; Thu, 11 Sep 2014 18:18:21 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 22F30DA; Thu, 11 Sep 2014 18:18:20 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s8BIIH2x054595 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 11 Sep 2014 12:18:17 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s8BIIHF8054592; Thu, 11 Sep 2014 12:18:17 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Thu, 11 Sep 2014 12:18:17 -0600 (MDT) From: Warren Block To: Craig Rodrigues Subject: Re: /etc/motd summary In-Reply-To: Message-ID: References: User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Thu, 11 Sep 2014 12:18:17 -0600 (MDT) Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 18:18:21 -0000 On Thu, 11 Sep 2014, Craig Rodrigues wrote: > On Mon, Sep 8, 2014 at 12:08 PM, Warren Block wrote: > >> >> http://www.wonkity.com/~wblock/motd/motd.whitespace-url >> >> >> > Can you go ahead and commit this, and then after 3 days submit > a request to re@ to MFC this to stable/10 so we can get this in 10.1? > > The suggestions brought up in this thread are good, but will take some time > to implement. Your changes to motd update the content to more current > sources of help, and do improve things a bit. It is good to get this in. Actually, I was going to commit the vertical version: http://www.wonkity.com/~wblock/motd/motd.vertical Nobody complained about it, and that's as good as downright approval in this thread. From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 18:25:55 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 63E69CAA; Thu, 11 Sep 2014 18:25:55 +0000 (UTC) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 10B9A1AD; Thu, 11 Sep 2014 18:25:54 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.9/8.14.9) with ESMTP id s8BIPr52056460 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Thu, 11 Sep 2014 12:25:53 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.9/8.14.9/Submit) with ESMTP id s8BIPr2D056457; Thu, 11 Sep 2014 12:25:53 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Thu, 11 Sep 2014 12:25:53 -0600 (MDT) From: Warren Block To: Craig Rodrigues Subject: Re: /etc/motd summary In-Reply-To: Message-ID: References: User-Agent: Alpine 2.11 (BSF 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Thu, 11 Sep 2014 12:25:53 -0600 (MDT) Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 18:25:55 -0000 On Thu, 11 Sep 2014, Warren Block wrote: > On Thu, 11 Sep 2014, Craig Rodrigues wrote: > >> On Mon, Sep 8, 2014 at 12:08 PM, Warren Block wrote: >> >>> >>> http://www.wonkity.com/~wblock/motd/motd.whitespace-url >>> >>> >>> >> Can you go ahead and commit this, and then after 3 days submit >> a request to re@ to MFC this to stable/10 so we can get this in 10.1? >> >> The suggestions brought up in this thread are good, but will take some time >> to implement. Your changes to motd update the content to more current >> sources of help, and do improve things a bit. It is good to get this in. > > Actually, I was going to commit the vertical version: > http://www.wonkity.com/~wblock/motd/motd.vertical > > Nobody complained about it, and that's as good as downright approval in this > thread. A slightly shorter version has been committed. From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 18:30:04 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C2A7FD98; Thu, 11 Sep 2014 18:30:04 +0000 (UTC) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.freebsd.org (Postfix) with ESMTP id 852F51D1; Thu, 11 Sep 2014 18:30:04 +0000 (UTC) Received: from critter.freebsd.dk (unknown [192.168.48.2]) by phk.freebsd.dk (Postfix) with ESMTP id F33E11578; Thu, 11 Sep 2014 18:29:56 +0000 (UTC) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.14.9/8.14.9) with ESMTP id s8BITs62040213; Thu, 11 Sep 2014 18:29:54 GMT (envelope-from phk@phk.freebsd.dk) To: Warren Block Subject: Re: /etc/motd summary In-reply-to: From: "Poul-Henning Kamp" References: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <40211.1410460194.1@critter.freebsd.dk> Content-Transfer-Encoding: quoted-printable Date: Thu, 11 Sep 2014 18:29:54 +0000 Message-ID: <40212.1410460194@critter.freebsd.dk> Cc: Craig Rodrigues , freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 18:30:04 -0000 -------- In message , Warren Block= writ es: >A slightly shorter version has been committed. Can we please also rename /etc/motd to /etc/bikeshed ? KTHX, bye! -- = 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= . From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 19:02:51 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0122A2EF; Thu, 11 Sep 2014 19:02:50 +0000 (UTC) Received: from mx0.gid.co.uk (mx0.gid.co.uk [194.32.164.250]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 99A75767; Thu, 11 Sep 2014 19:02:50 +0000 (UTC) Received: from [194.32.164.24] (80-46-130-69.static.dsl.as9105.com [80.46.130.69]) by mx0.gid.co.uk (8.14.2/8.14.2) with ESMTP id s8BIrK77034162; Thu, 11 Sep 2014 19:53:21 +0100 (BST) (envelope-from rb@gid.co.uk) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: /etc/motd summary From: Bob Bishop In-Reply-To: <40212.1410460194@critter.freebsd.dk> Date: Thu, 11 Sep 2014 19:53:15 +0100 Content-Transfer-Encoding: quoted-printable Message-Id: <44518E21-2F44-41A4-8DBD-0B7BEE990A63@gid.co.uk> References: <40212.1410460194@critter.freebsd.dk> To: Poul-Henning Kamp X-Mailer: Apple Mail (2.1878.6) Cc: Warren Block , Craig Rodrigues , freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 19:02:51 -0000 Hi, On 11 Sep 2014, at 19:29, Poul-Henning Kamp wrote: > -------- > In message , Warren = Block writ > es: >=20 >> A slightly shorter version has been committed. >=20 > Can we please also rename /etc/motd to /etc/bikeshed ? Please file a bug report so this valuable suggestion doesn't get lost. > KTHX, bye! >=20 > --=20 > Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 > phk@FreeBSD.ORG | TCP/IP since RFC 956 > FreeBSD committer | BSD since 4.3-tahoe =20 > Never attribute to malice what can adequately be explained by = incompetence. > _______________________________________________ > freebsd-arch@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to = "freebsd-arch-unsubscribe@freebsd.org" >=20 -- Bob Bishop rb@gid.co.uk From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 22:11:58 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0FDA84FE; Thu, 11 Sep 2014 22:11:58 +0000 (UTC) Received: from mail-yh0-x22a.google.com (mail-yh0-x22a.google.com [IPv6:2607:f8b0:4002:c01::22a]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B814CCD4; Thu, 11 Sep 2014 22:11:57 +0000 (UTC) Received: by mail-yh0-f42.google.com with SMTP id i57so753623yha.1 for ; Thu, 11 Sep 2014 15:11:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=wdhHhg7xdsDnZILjVKJGNw5ixgUeRcNSVKJaCOER+Sg=; b=ptrp/awT5KgHKfiU928uawhrPRy83gWPAcObfPII3HsbhLcqUqrdlk22H0uINzMEAe LK0Ncnp92NRukJkCaWFYoMPK0aL0LBuIo6oSXrBCyH/0rSrylQUIB6ymtWraUv/MRXqG 1jIYnEeOa4kpNWlqRaRMajc/4ABzQFy9U5YYOMWjmBR9SOq7fjsHpCI3VwrSXtrrjpo4 4iv1rRrzmPckYbzp+MWrFElKt2zy7ImQ54DKMLu2b/RZwRb5xgvJmJX44cFZX7OlRtFD sC6ijkS5An5bJKwOu/y/8SAaieOYayLCsT1wmpStH0ncjK3j6+EG926sJ9Hsg13w8kxa NLmA== MIME-Version: 1.0 X-Received: by 10.236.85.10 with SMTP id t10mr4627330yhe.86.1410473516836; Thu, 11 Sep 2014 15:11:56 -0700 (PDT) Received: by 10.170.218.197 with HTTP; Thu, 11 Sep 2014 15:11:56 -0700 (PDT) In-Reply-To: References: Date: Thu, 11 Sep 2014 15:11:56 -0700 Message-ID: Subject: Re: /etc/motd summary From: Mehmet Erol Sanliturk To: Warren Block Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: Craig Rodrigues , freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 22:11:58 -0000 On Thu, Sep 11, 2014 at 11:18 AM, Warren Block wrote: > On Thu, 11 Sep 2014, Craig Rodrigues wrote: > > On Mon, Sep 8, 2014 at 12:08 PM, Warren Block wrote: >> >> >>> http://www.wonkity.com/~wblock/motd/motd.whitespace-url >>> >>> >>> >>> Can you go ahead and commit this, and then after 3 days submit >> a request to re@ to MFC this to stable/10 so we can get this in 10.1? >> >> The suggestions brought up in this thread are good, but will take some >> time >> to implement. Your changes to motd update the content to more current >> sources of help, and do improve things a bit. It is good to get this in. >> > > Actually, I was going to commit the vertical version: > http://www.wonkity.com/~wblock/motd/motd.vertical > > Nobody complained about it, and that's as good as downright approval in > this thread. > _______________________________________________ > > This is a very nice text which contains all the necessary information in a concise structure . Thank you very much . Mehmet Erol Sanliturk From owner-freebsd-arch@FreeBSD.ORG Thu Sep 11 22:31:28 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 580FDAB1 for ; Thu, 11 Sep 2014 22:31:28 +0000 (UTC) Received: from mail-la0-x229.google.com (mail-la0-x229.google.com [IPv6:2a00:1450:4010:c03::229]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D532FE3D for ; Thu, 11 Sep 2014 22:31:27 +0000 (UTC) Received: by mail-la0-f41.google.com with SMTP id s18so12702207lam.0 for ; Thu, 11 Sep 2014 15:31:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=/o+FLpn50wjZOo37IxnlMMVGICTYdSx121v+USF2QfU=; b=06iov713Df/WAv/U0XYTXGtyW0qBNOkut2lVw+iY7AB+JrLZv1kzRGWEY7/hoFGBEM RfQG7StGCUKUGxHxWY8XInhmO/MLPDvZ2yBjL4WtbxIVzNc1/OTf3iamHPN0d/QiWL8B biwD4BCN2m/Ms0B87kkwRMMB1DA9LqNrz0O1xZWfFODPJFbceBqqra+cikU7q4bu8tFI ttgT1NJCAlQY9IHU3kV8tZMpn2let3VewgFGZxRx9COOpnupOIZQvs9ST4bG26oYl6Zd nd8AGMIzRmdpVMLNFUY6Dvhs6CnT8RoTXjg0WzTfJMBxtn/NduhRR5KNgZ5FzWTqB5n1 Eo6w== MIME-Version: 1.0 X-Received: by 10.152.19.167 with SMTP id g7mr4554295lae.46.1410474685645; Thu, 11 Sep 2014 15:31:25 -0700 (PDT) Sender: crodr001@gmail.com Received: by 10.112.22.72 with HTTP; Thu, 11 Sep 2014 15:31:25 -0700 (PDT) In-Reply-To: References: Date: Thu, 11 Sep 2014 15:31:25 -0700 X-Google-Sender-Auth: w6OPUlumRUJyc_aILXHlt-_OcTo Message-ID: Subject: Re: /etc/motd summary From: Craig Rodrigues To: Warren Block Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: freebsd-arch X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Sep 2014 22:31:28 -0000 On Thu, Sep 11, 2014 at 11:18 AM, Warren Block wrote: > > Actually, I was going to commit the vertical version: > http://www.wonkity.com/~wblock/motd/motd.vertical > > Nobody complained about it, and that's as good as downright approval in > this thread. > Cool. Thank you for doing this. Your attention to detail is much appreciated. -- Craig From owner-freebsd-arch@FreeBSD.ORG Sat Sep 13 10:45:19 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 67074C51 for ; Sat, 13 Sep 2014 10:45:19 +0000 (UTC) Received: from mail-la0-x236.google.com (mail-la0-x236.google.com [IPv6:2a00:1450:4010:c03::236]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E8460A10 for ; Sat, 13 Sep 2014 10:45:18 +0000 (UTC) Received: by mail-la0-f54.google.com with SMTP id ge10so2363167lab.27 for ; Sat, 13 Sep 2014 03:45:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=m2nctwkNuMZUCxtZ4WQnsaL+Pd7K7hH5uP/emWwExEc=; b=VszgSX49fyQ2VhTXWxFg8R/lZ9MWwPvqS7MW3gjpBPvS/QQvej+jS1jh1yjiZp6Tku 0vYMxI0XVZoLN4onky2B//mq0xUf5sF2FzFvqWYaxcwbGTT9hTErYy19+M66a2+nLlL7 Pc8Amwk3wP1KUJ5166TSrWaOYqTU98Khuh0QWRW34iQNISQL4Y01raMCoow+A0S8/r+J q6VhtblMpsV7JRfSy/urS/AyL9NNaWm0J91DMBOaqStHtwJWURG2rAMPwZtW6JTpZdqQ z0i75s2KJV23JsLUk2ZgH9PvxczEs6A98l0TYohNEE+qH66kaq2b2EtWX7V0v8PcN9xX 1H1w== MIME-Version: 1.0 X-Received: by 10.152.18.199 with SMTP id y7mr15436019lad.0.1410605116616; Sat, 13 Sep 2014 03:45:16 -0700 (PDT) Received: by 10.25.42.83 with HTTP; Sat, 13 Sep 2014 03:45:16 -0700 (PDT) Date: Sat, 13 Sep 2014 12:45:16 +0200 Message-ID: Subject: Intel MPX (Skylake ISA) support? From: Carsten Mattner To: freebsd-arch@freebsd.org Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Sep 2014 10:45:19 -0000 Are there any plans to include the necessary (kernel, libc) support for Intel MPX (https://en.wikipedia.org/wiki/Intel_MPX)? From owner-freebsd-arch@FreeBSD.ORG Sat Sep 13 16:21:05 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 910E9B90 for ; Sat, 13 Sep 2014 16:21:05 +0000 (UTC) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 00DC2AA5 for ; Sat, 13 Sep 2014 16:21:04 +0000 (UTC) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.14.9/8.14.9) with ESMTP id s8DGKx4V037702 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 13 Sep 2014 19:20:59 +0300 (EEST) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.9.2 kib.kiev.ua s8DGKx4V037702 Received: (from kostik@localhost) by tom.home (8.14.9/8.14.9/Submit) id s8DGKxFC037701; Sat, 13 Sep 2014 19:20:59 +0300 (EEST) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sat, 13 Sep 2014 19:20:59 +0300 From: Konstantin Belousov To: Carsten Mattner Subject: Re: Intel MPX (Skylake ISA) support? Message-ID: <20140913162059.GU2737@kib.kiev.ua> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="2/GGPHUoweZ2WGWr" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Status: No, score=-2.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on tom.home Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Sep 2014 16:21:05 -0000 --2/GGPHUoweZ2WGWr Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sat, Sep 13, 2014 at 12:45:16PM +0200, Carsten Mattner wrote: > Are there any plans to include the necessary (kernel, libc) support for > Intel MPX (https://en.wikipedia.org/wiki/Intel_MPX)? I looked at this several times. The 319433 (Instructions Set Extensions prog reference) even at the current revision 20 still seems to not provide the complete documentation on the CPU side. E.g., could you point me at the description of the save area for MPX ? It is required since usermode bndcfg register can only be set by restoring from the XSAVE area. That said, I believe that most, if not all, of the needed kernel-side support is already there by the generic XSAVE code. I never see any specification of runtime services expected by the code generated by mpx-enabled gcc. --2/GGPHUoweZ2WGWr Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBAgAGBQJUFG7rAAoJEJDCuSvBvK1BYXwP/06nzQAyXijTOJyZ2PB0CSG+ JP/oGqS2DgzoCTZPeX+wNlP8OnJ6bzhXn9AxvIpuH6TDHr11x6gE8SiEnLlG9P2x pv7BNy7MOo0LRKazZq2Vma80KNduoHESVJXMUUoumFJ3iKsRI+vcaBx4b0jTNtzn WLhwMJWzNcU6WdYdrQVFAkbz8pM4yuOy0Dix9DAFlYx3nWhOKeSizgySGgTTQUJS MuvnoocXKS65+q8Z6Uk0XqbTjrrii81baam14BMB6o9wNTAvAhjMT7akr0cJRKzD IhsMzzY4T/h1uIT76cjZivNzDahm+8rKk9cZkKZjKCqBLK1hw1f41ivvOWjKASvn /Uza6bl1XEDQ8/LrDYz8YR/3sif/wcWiaDHs4kcTdP0PXOGf7ZpNjhfwJrbNSmla LJ2u0SfO1GPXNPhBBdmQhqY3/kczGuDIJi4b67D+vJaCHVN4IZin//G/SbjJQp/h bIxUbKt0d83LEcC9bapS6GXtqzGYdvO1PJxNojTyYrNyyAk1k/o/ZcNn/USyhO02 Cle7nGuKFUCq/6ArHTqaRgdybCnazw727faW/K+4r/x7usmuM169/ItrrqTFfkCz 6X+ATD7sVMSk7lTcFZa4qGR74DxPw7vtehkQYQddKgUSPK0mh1aVDZw1U/K2vu8W Ft1V4Pk1V2yVE7MAPE9R =GDM0 -----END PGP SIGNATURE----- --2/GGPHUoweZ2WGWr-- From owner-freebsd-arch@FreeBSD.ORG Sat Sep 13 19:47:13 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 61BB0FDC for ; Sat, 13 Sep 2014 19:47:13 +0000 (UTC) Received: from mail-la0-x22e.google.com (mail-la0-x22e.google.com [IPv6:2a00:1450:4010:c03::22e]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id DF5EECD for ; Sat, 13 Sep 2014 19:47:12 +0000 (UTC) Received: by mail-la0-f46.google.com with SMTP id el20so2712075lab.19 for ; Sat, 13 Sep 2014 12:47:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=ynjAVIWfjqquwbA8CO1mc+eaYM2T2fQm+2GyPkKxug8=; b=jijbLvmE2c4lfHzxyHjIWGOfpvYJeFWNgMAWeHCFUA/XYrI+jDMqXxqnHpTHr5T3mu qDmOKlX/1DMY9YJJNjisUgTCq6uWxUvmUJZ+Z6DU+Ophdr8HMa2hunwzQ8NpeBsMkLuy Qz1Q3YvUFJC5mzCD3ot5X7cYorWBkpRa4Lb2+xfMuJ7P6YlUnnTpw5r9pRXgaqDC1+Oy MSKy3oT9gtbGt8ipUTNw+y/iQNK2rAx5sxv6UcRDWKjA3sHdVgNbmuWBqBpatYEX5tt9 lFQWzxscL89pk0e3QumCxdToIWH8ah+C24tW9XVgn1AoJKaHA0+bcEgUPLTeAV2DuUvR LsaA== MIME-Version: 1.0 X-Received: by 10.152.36.37 with SMTP id n5mr4595073laj.93.1410637630745; Sat, 13 Sep 2014 12:47:10 -0700 (PDT) Received: by 10.25.42.83 with HTTP; Sat, 13 Sep 2014 12:47:10 -0700 (PDT) In-Reply-To: <20140913162059.GU2737@kib.kiev.ua> References: <20140913162059.GU2737@kib.kiev.ua> Date: Sat, 13 Sep 2014 21:47:10 +0200 Message-ID: Subject: Re: Intel MPX (Skylake ISA) support? From: Carsten Mattner To: Konstantin Belousov Content-Type: text/plain; charset=UTF-8 Cc: freebsd-arch@freebsd.org X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Sep 2014 19:47:13 -0000 On Sat, Sep 13, 2014 at 6:20 PM, Konstantin Belousov wrote: > On Sat, Sep 13, 2014 at 12:45:16PM +0200, Carsten Mattner wrote: >> Are there any plans to include the necessary (kernel, libc) support for >> Intel MPX (https://en.wikipedia.org/wiki/Intel_MPX)? > > I looked at this several times. The 319433 (Instructions Set Extensions > prog reference) even at the current revision 20 still seems to not provide > the complete documentation on the CPU side. E.g., could you point me at > the description of the save area for MPX ? It is required since usermode > bndcfg register can only be set by restoring from the XSAVE area. > > That said, I believe that most, if not all, of the needed kernel-side > support is already there by the generic XSAVE code. > > I never see any specification of runtime services expected by the code > generated by mpx-enabled gcc. Is https://lkml.org/lkml/2014/9/11/182 helpful?