From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.3 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 035EFC47404 for ; Wed, 9 Oct 2019 17:09:36 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C60A5218DE for ; Wed, 9 Oct 2019 17:09:35 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="F0VAbQYV" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C60A5218DE Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.intel.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=DXUYDkQFJ1X1UfELflUQjt7kxBhSDH+JlKiZ4+UDWuw=; b=F0VAbQYV47N2Q/ JMUAnskdPhc0zwEkTpK/+7S74axkCznMUY/0q5U3tkOyBIcVyvUuWyPYHED4gK/o57UUouctC8Fek czIw3mJx/+G8oBrstA1Kp5l9aupWF70pjoCRtkQVgIxT25P9JSdNXdlwR2nufleSIPBVJexodW+Tt GBePgc+5nn00pwusdHn1PbTgXEasuqYxOT0OMHK8iiZQm2hyf7iqG+YSaY6bumNWjB5t61eDqxYJO v1DNBZHom2bz/OQ/V8ZUC9b04YnduwbOBhBW/DqU9Uab/f3Kihb3kZdvBvghgay7qklrkkFDKPy2a HBxAwlUYONvS3Ud4QJqQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.2 #3 (Red Hat Linux)) id 1iIFSs-00031A-Ek; Wed, 09 Oct 2019 17:09:30 +0000 Received: from mga18.intel.com ([134.134.136.126]) by bombadil.infradead.org with esmtps (Exim 4.92.2 #3 (Red Hat Linux)) id 1iIFSp-000307-8c for linux-arm-kernel@lists.infradead.org; Wed, 09 Oct 2019 17:09:28 +0000 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga106.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Oct 2019 10:09:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.67,277,1566889200"; d="scan'208";a="206918443" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by fmsmga001.fm.intel.com with ESMTP; 09 Oct 2019 10:09:19 -0700 Received: from andy by smile with local (Exim 4.92.2) (envelope-from ) id 1iIFSf-00036t-U0; Wed, 09 Oct 2019 20:09:17 +0300 Date: Wed, 9 Oct 2019 20:09:17 +0300 From: Andy Shevchenko To: Masahiro Yamada Subject: Re: [PATCH v17 01/14] bitops: Introduce the for_each_set_clump8 macro Message-ID: <20191009170917.GG32742@smile.fi.intel.com> References: <893c3b4f03266c9496137cc98ac2b1bd27f92c73.1570633189.git.vilhelm.gray@gmail.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191009_100927_346456_E4FA3952 X-CRM114-Status: GOOD ( 14.82 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arch , Arnd Bergmann , "open list:GPIO SUBSYSTEM" , Linus Walleij , Linux PM mailing list , Rasmus Villemoes , Linux Kernel Mailing List , morten.tiljeset@prevas.dk, William Breathitt Gray , Bartosz Golaszewski , Lukas Wunner , Geert Uytterhoeven , sean.nyekjaer@prevas.dk, Andrew Morton , preid@electromag.com.au, linux-arm-kernel Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Oct 10, 2019 at 01:28:08AM +0900, Masahiro Yamada wrote: > On Thu, Oct 10, 2019 at 12:27 AM William Breathitt Gray > wrote: > > > > This macro iterates for each 8-bit group of bits (clump) with set bits, > > within a bitmap memory region. For each iteration, "start" is set to the > > bit offset of the found clump, while the respective clump value is > > stored to the location pointed by "clump". Additionally, the > > bitmap_get_value8 and bitmap_set_value8 functions are introduced to > > respectively get and set an 8-bit value in a bitmap memory region. > Why is the return type "unsigned long" where you know > it return the 8-bit value ? Because bitmap API operates on unsigned long type. This is not only consistency, but for sake of flexibility in case we would like to introduce more calls like clump16 or so. Same comment for the rest. -- With Best Regards, Andy Shevchenko _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel