From owner-freebsd-arch Fri Mar 29 11:32:28 2002 Delivered-To: freebsd-arch@freebsd.org Received: from mail14.speakeasy.net (mail14.speakeasy.net [216.254.0.214]) by hub.freebsd.org (Postfix) with ESMTP id 8CA2437B416 for ; Fri, 29 Mar 2002 11:32:21 -0800 (PST) Received: (qmail 7463 invoked from network); 29 Mar 2002 19:32:19 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail14.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 29 Mar 2002 19:32:19 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.11.6/8.11.6) with ESMTP id g2TJX7v01230 for ; Fri, 29 Mar 2002 14:33:07 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.2 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Date: Fri, 29 Mar 2002 14:32:22 -0500 (EST) From: John Baldwin To: arch@FreeBSD.org Subject: curthread vs. passing thread pointers around Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG During a discussion on the smp@ list about changes to the suser() API to make use of td_ucred, it was brought up that the new suser() would be assuming that the passed in thread pointer was curthread so why not just use curthread in suser() and not pass in a pointer at all. There are several places in the kernel where the same assumption is made. Thus, my question is: which general approach should we follow, and should we perhaps switch to using explicit curthread's everywhere and stop passing thread pointers around on the stack? -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message