Received: by 2002:a25:ef43:0:0:0:0:0 with SMTP id w3csp483862ybm; Thu, 28 May 2020 07:47:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzffx9rt+mg1Bvc/ctfq/XvHIIgVUQF1NTAFbp6Uk2xCR1sEUfYQ5MRjN5MCVi03Uw5AD52 X-Received: by 2002:a17:906:6c82:: with SMTP id s2mr3242222ejr.215.1590677230911; Thu, 28 May 2020 07:47:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590677230; cv=none; d=google.com; s=arc-20160816; b=G66tNv7d52TC/fjWhhUTFOdcRqsrBDxPgVsSVVdA+0xOnnOrrGP7RTJ5WhZYhoQIYb VI9yhqWFu5cI9W096zHVwcHamJi+xxzpVDIYXfnVsLjOT89514Iwb0ZR9J7cK3hanZLN FjaivTqgpvnJ5xmG0T0IrIFhDF561uZTVrJxaqRSmWFLtrRZbD0P9rjpvZnsJtOtEszW SZ+xSAJX6TUqfx/NmeyI8tZbs02JKyKAIeNK8wPTz7rMnwnnu+IrgRQNGCeLEjVHRkJZ P+mkrHBqzb7/a4LkJNasU5vkseZoR4akEUzugqaCH3h8uUMhUaZvDJj/OGNKi84+H1kl HNnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=csrpHsYgBXrn0ufgXqOjLydFR7WTiYxM0MetL98CFXQ=; b=sWbLCV5Jogu9QUF4rfW+ydlEBKWmSI8luutw1JeodszGaa6lxj+8EBIFBD4MJBmkD2 fWzRvbnoZnFhevwYHwSOLnI3ZHQiBfaPgi4nS/9xKPGdl0YzNZ4SjPbndikczJYO6Ro9 cHxOx/nz8t2m4Y+Mu+EsNtsjscG+5iUF65BD5G26KC93sSBW2iiuFb+E76d75CL46RF3 n0h7+T2L8sESm8fxKhaxVId+I4XXxfzgkJNCrTifT3n4qotn/V+Uh4yDR6qHesC2mrN0 7InTN4CtxtwNb9mXfWYZTGTka+gSa8eY9Kjfhnm1jx1R7hzSo1LQS+7Ol0WduXjeAkKm CLQA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=l2E2WVro; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b8si415981edr.398.2020.05.28.07.46.47; Thu, 28 May 2020 07:47:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=l2E2WVro; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728572AbgE1OpC (ORCPT + 99 others); Thu, 28 May 2020 10:45:02 -0400 Received: from mail.kernel.org ([198.145.29.99]:54578 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725922AbgE1OpA (ORCPT ); Thu, 28 May 2020 10:45:00 -0400 Received: from localhost (fw-tnat.cambridge.arm.com [217.140.96.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5BEB6207D3; Thu, 28 May 2020 14:44:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1590677100; bh=X9YK+GDEsdW2T8WyDGxweojlNXR+vB7BnE1HKRUoVxo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=l2E2WVrocVGuy1b/MoQhvijltZBfFRIPA1HuIMFqM5dN6XLFuQWc89P9MA+V3Em7x 9Rgm9qI719tIY6fUpzodZNDu7Nt24Upte5jX83v0rzQGTFaN+0PlHnIxzjfDBJ8YwR f5bCGf7jklLlgV/qFq/P4M6JnQzRot0Ta1CnpqS0= Date: Thu, 28 May 2020 15:44:56 +0100 From: Mark Brown To: Bartosz Golaszewski Cc: John Crispin , Sean Wang , Mark Lee , "David S . Miller" , Jakub Kicinski , Matthias Brugger , netdev@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, Fabien Parent , Stephane Le Provost , Pedro Tsai , Andrew Perepech , Bartosz Golaszewski Subject: Re: [PATCH v2 1/2] regmap: provide helpers for simple bit operations Message-ID: <20200528144456.GG3606@sirena.org.uk> References: <20200528142241.20466-1-brgl@bgdev.pl> <20200528142241.20466-2-brgl@bgdev.pl> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="RMedoP2+Pr6Rq0N2" Content-Disposition: inline In-Reply-To: <20200528142241.20466-2-brgl@bgdev.pl> X-Cookie: Small is beautiful. User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --RMedoP2+Pr6Rq0N2 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, May 28, 2020 at 04:22:40PM +0200, Bartosz Golaszewski wrote: > + return (val & bits) == bits ? 1 : 0; The tenery here is redundant, it's converting a boolean value into a boolean value. Otherwise this looks good. --RMedoP2+Pr6Rq0N2 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAl7PzmcACgkQJNaLcl1U h9DzXAf9EwegJko8ZtKiJNAmWI/0roZMdNBpTkKJLOfFqs0LbMZdg1Tg3UA+jOe6 AM9PSwU009hn4dmLdAbnqIfXhp1e1zPUb537lozVi/6cAbc6yzwzZBxajJjUxjk9 amrt61H/LZBJyyP1qrY4a/vNtu0R558ozAuMmINAfkEsFdGQq6WZ63N+bcJzPiF4 kxSTX7Mewb0jyB6ZAilOMkuRFNR+bCGjV0MNVd41MUT+zEcgaMP7Dv6eJ/PUBJ2y klySoD2xOzlpxBUpKblFYuso9Q8iRrGGjr49/rh1rYuKjRz/wt8cbwe4NjrG0N+q E8vZUZWNgG2ZVnG3DbKIx5QlNJxtDA== =EkdN -----END PGP SIGNATURE----- --RMedoP2+Pr6Rq0N2--