From owner-freebsd-arch@FreeBSD.ORG Fri Jan 10 17:12:41 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 F341D3AD for ; Fri, 10 Jan 2014 17:12:40 +0000 (UTC) Received: from mail-qa0-x22b.google.com (mail-qa0-x22b.google.com [IPv6:2607:f8b0:400d:c00::22b]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id AD3C51D8E for ; Fri, 10 Jan 2014 17:12:40 +0000 (UTC) Received: by mail-qa0-f43.google.com with SMTP id k15so4228478qaq.16 for ; Fri, 10 Jan 2014 09:12:39 -0800 (PST) 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=cJWCAXsOC6s/HR2ZrsGZN2nmhMwXWayt0pXx/0rg7bE=; b=qWvk4ApddGPQNcHg/EE5QhTeGxv9Ch2GUv/gZzebdRmeGExovzEIFzHFFuUzUsQdfZ 1hFI7rV6lhVk7eGbINns/kXWyMrkzL7ja61ZKSsRuJNo+WI3mt+icsKV3zQHS60QQrXO lpaoduGTXJxGDB3kdVoZDoGtUqPvLKJOGI6oNcVEafyiDZNao1KCmV13cV7zqdUPZAtE y5SMVK8lH2B2mZaTxQaKsl7VdBLB3/9vaWyI99NFJi2UFV72NdjlH+MTL9XhH0x1ARb/ Whi9FP+WihPfr5Y+KJrFWQn9itz+Fd/V5v5xqcY/AnGv/1J9usYPF7kPSl7DpaeT+ryO AKsw== MIME-Version: 1.0 X-Received: by 10.49.24.211 with SMTP id w19mr9696894qef.9.1389373959474; Fri, 10 Jan 2014 09:12:39 -0800 (PST) Sender: adrian.chadd@gmail.com Received: by 10.224.52.8 with HTTP; Fri, 10 Jan 2014 09:12:39 -0800 (PST) In-Reply-To: <20140110222640.F2338@besplex.bde.org> References: <9C1291B5-215B-440E-B8B0-6308840F755C@bsdimp.com> <5821DA91-E9C7-4D1A-A108-63E74CFF1FC5@bsdimp.com> <20140108152632.L969@besplex.bde.org> <20140109092602.M957@besplex.bde.org> <20140110222640.F2338@besplex.bde.org> Date: Fri, 10 Jan 2014 09:12:39 -0800 X-Google-Sender-Auth: gxBXcsE2SQXzKWSFaRfoesEWoVs Message-ID: Subject: Re: Using sys/types.h types in sys/socket.h From: Adrian Chadd To: Bruce Evans Content-Type: text/plain; charset=ISO-8859-1 Cc: "freebsd-arch@freebsd.org" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 Jan 2014 17:12:41 -0000 Hi, On 10 January 2014 03:38, Bruce Evans wrote: >> /* >> * sendfile(2) kqueue information >> */ >> struct sf_hdtr_kq { >> __uintptr_t kq_ident; /* ident (from userland?) */ >> void *kq_udata; /* user data pointer */ >> __uint32_t kq_flags; /* extra flags to pass in */ >> int kq_fd; /* kq fd to post completion events on */ >> }; >> >> Ok, so I've removed one tab from the comments and added a tab after >> void/int. >> >> How's that? > > > Now the last comment is misindented. Ok, I'll fix that. > This also has the unrelated change of using __ufoo instead of ufoo. I > think that is only correct if the types are supposed to be almost opaque, > with the details not part of the API. Peter raised a point on irc - if I define uint32_t/uintptr_t in the header, then code that includes sys/socket.h will be able to use uint32_t / uintptr_t without including sys/types.h. What should be done there? -a