From nobody Fri Oct 7 14:48:29 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4MkWQf1zBvz4dv6B for ; Fri, 7 Oct 2022 14:48:42 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-ej1-x630.google.com (mail-ej1-x630.google.com [IPv6:2a00:1450:4864:20::630]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4MkWQf1ZD8z3xdB for ; Fri, 7 Oct 2022 14:48:42 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-ej1-x630.google.com with SMTP id qw20so11196875ejc.8 for ; Fri, 07 Oct 2022 07:48:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20210112.gappssmtp.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=1JZZcHVyYEunLf4fe5PzdoQ3j+MrveE913G5pLB3FUk=; b=CeWElNRA8DC2KXXcmDeMueo5hUsMv3RZGA7gxZL1DdoTgx4WT+UHcxVMmPQpAZ685k Fmcm6FsMgPcCeA+YHpqe6GHN/mHmaNL36kyR72Uj+En79A30zlcPrQXwTTLlIDAzHb4+ fBWTe75AcZPZ63TvcdX6JmSzlHMKzkOjmmHRd4DXooOlvBhzzdL4HR1mIOsnUu4kNFSQ 1sVmkExg57xznFryUAAQrjvAZw33BL0rAeT9jWKYI4lDKcr1CoaE7VCy6KZWXvVat+o9 C61ptminy0YlOy5qxyqr4UAcOosMdX6Zi03uD3bwivDUdlgmzTqsRFdaCsfBXycR14pe KbGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=1JZZcHVyYEunLf4fe5PzdoQ3j+MrveE913G5pLB3FUk=; b=tpKxaNLQbvHt+z2OaRTCQzDU97P6sg3jar2LuEbtc4Ca1dDvJkms3oexlP5DPhC4G6 tC3eLa42tv+RAcaz80ZzU/cBqDZG6GWcavLSYz3mY+53JFhtHWiKYt4TTLCIpIql+sfa t+Cfq8ZpWpqR9cCnROpIeYDu4mB2WD1Nn1of6QhEfemWkl9W5h8Uu51H+Z5wI6LoNR/O 3JCQX9B8jrnoSA8B2IiSjFm77eUbnOSSyVhg74kb+NV+pSL7sfi5dfdzrfbS8v906Fu/ GrE3SGkqHn0v334MsXeuhzZGSkqcC/7C0Q6v0MvtnaSVebYnM//7OcCpkX/l4ONLoGjS tYzQ== X-Gm-Message-State: ACrzQf1pb2lJbDo/6UXps6ZLzDxIC0ZnTy9lSy453kCMCLfp4okNxNy9 PCdrtkqNJFv+EtvmItkfFV3DjnfmwQ6rT9UYE1LFvA== X-Google-Smtp-Source: AMsMyM5Tq5nqIc1LVOyR53z7zmKok+24rwNGWhNZKYLoIVMsi2/xG4s4gndhHEPHIEDgJfeGYLjfNqDA61UpiLfIKQE= X-Received: by 2002:a17:907:2e0d:b0:77e:999f:dea3 with SMTP id ig13-20020a1709072e0d00b0077e999fdea3mr4220286ejc.317.1665154120920; Fri, 07 Oct 2022 07:48:40 -0700 (PDT) List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 References: <202210071141.297BfcjN071407@gitrepo.freebsd.org> In-Reply-To: From: Warner Losh Date: Fri, 7 Oct 2022 08:48:29 -0600 Message-ID: Subject: Re: git: 62d42655bca1 - main - usb(4): Substitute "unsigned int" using the equivalent and shorter "unsigned" keyword. To: Hans Petter Selasky Cc: "Piotr P. Stefaniak" , src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Content-Type: multipart/alternative; boundary="000000000000dfc7e905ea72e794" X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Rspamd-Queue-Id: 4MkWQf1ZD8z3xdB X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-ThisMailContainsUnwantedMimeParts: N --000000000000dfc7e905ea72e794 Content-Type: text/plain; charset="UTF-8" On Fri, Oct 7, 2022 at 8:21 AM Hans Petter Selasky wrote: > On 10/7/22 15:21, Piotr P. Stefaniak wrote: > > On 2022-10-07 14:03:51, Hans Petter Selasky wrote: > >> On 10/7/22 13:48, Piotr P. Stefaniak wrote: > >>> On 2022-10-07 11:41:38, Hans Petter Selasky wrote: > >>> > >>>> usb(4): Substitute "unsigned int" using the equivalent and shorter > >>>> "unsigned" keyword. > >>> > >>> Why? Just because it's shorter? > >> > >> Yes, just because "int" is the redundant. > > > > Definitely that's true for computers. In case of humans it's debatable. > > Would uint32_t be more clear? > I don't think it would be that much clearer. The only places I might be tempted to use uint32_t is for any of the structs that were unsigned int that are externally defined to be 32-bit unsigned integers, which is a tiny fraction of what you changed (I noticed only a few structures and I didn't look further to see if they are internal to the USB stack, or data returned from a device). Warner --000000000000dfc7e905ea72e794 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Fri, Oct 7, 2022 at 8:21 AM Hans P= etter Selasky <hps@selasky.org>= ; wrote:
On 10/7= /22 15:21, Piotr P. Stefaniak wrote:
> On 2022-10-07 14:03:51, Hans Petter Selasky wrote:
>> On 10/7/22 13:48, Piotr P. Stefaniak wrote:
>>> On 2022-10-07 11:41:38, Hans Petter Selasky wrote:
>>>
>>>> =C2=A0=C2=A0 usb(4): Substitute "unsigned int" u= sing the equivalent and shorter
>>>> "unsigned" keyword.
>>>
>>> Why? Just because it's shorter?
>>
>> Yes, just because "int" is the redundant.
>
> Definitely that's true for computers. In case of humans it's d= ebatable.

Would uint32_t be more clear?

I don'= ;t think it would be that much clearer.

The only p= laces I might be tempted to use uint32_t is for any of the structs that wer= e unsigned int that are externally defined to be 32-bit unsigned integers, = which is a tiny fraction of what you changed=C2=A0(I noticed only a few str= uctures and I didn't look further to see if they are internal to the US= B stack, or data returned from a device).

Warner= =C2=A0
--000000000000dfc7e905ea72e794--