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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B6F4C54EE9 for ; Mon, 19 Sep 2022 13:46:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229884AbiISNp7 (ORCPT ); Mon, 19 Sep 2022 09:45:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54794 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230177AbiISNpw (ORCPT ); Mon, 19 Sep 2022 09:45:52 -0400 Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7718A17066 for ; Mon, 19 Sep 2022 06:45:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1663595151; x=1695131151; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=YM1dRxbPZHCQXuHcTFNhP5mVRzQg8TEYi3/O2RyVXbk=; b=mdDIeNVH1lUortLCdmIDyhs9OmG956eSIzei2lBSlzFCNcL7BD+6VcAK Ys4CcZCwnlVt4Uucx2CxF9XAdT0CD93h0a15ePHkZK1eyqgGfnGzKU24l 45IKuN/H2GyceCYUD8x3Jfp8YunEvI78Q9jYNDSi0tnW4VEvIdosHwljG l0we+aw6PQp0nmuYd+QkAFGWr6aidAtboGgH95OHUQ2TGd6VHEEWEP2pB 0Lqyut1N5wTdUtBrNj8KncsSB8MyBETFg7QfbfJLYibTxf4PpCp0GQsgZ AyVTU5GBdl2YqjUehHyJhqIgEYCGxfDzdNwHJVOThODUQg1IaMp1i2MtE g==; X-IronPort-AV: E=McAfee;i="6500,9779,10475"; a="279131316" X-IronPort-AV: E=Sophos;i="5.93,327,1654585200"; d="scan'208";a="279131316" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Sep 2022 06:45:51 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,327,1654585200"; d="scan'208";a="744120637" Received: from smile.fi.intel.com ([10.237.72.54]) by orsmga004.jf.intel.com with ESMTP; 19 Sep 2022 06:45:47 -0700 Received: from andy by smile.fi.intel.com with local (Exim 4.96) (envelope-from ) id 1oaH5l-004Zc7-0N; Mon, 19 Sep 2022 16:45:45 +0300 Date: Mon, 19 Sep 2022 16:45:44 +0300 From: Andy Shevchenko To: Yury Norov Cc: Linus Torvalds , linux-kernel@vger.kernel.org, Alexey Klimov , Andy Whitcroft , Catalin Marinas , David Laight , Dennis Zhou , Guenter Roeck , Kees Cook , Rasmus Villemoes , Valentin Schneider , Sven Schnelle , Russell King Subject: Re: [PATCH v4 2/4] lib/find_bit: create find_first_zero_bit_le() Message-ID: References: <20220915020730.852234-1-yury.norov@gmail.com> <20220915020730.852234-3-yury.norov@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220915020730.852234-3-yury.norov@gmail.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Sep 14, 2022 at 07:07:28PM -0700, Yury Norov wrote: > find_first_zero_bit_le() is an alias to find_next_zero_bit_le(), > despite that 'next' is known to be slower than 'first' version. > > Now that we have common FIND_FIRST_BIT() macro helper, it's trivial > to implement find_first_zero_bit_le() as a real function. ... > +#ifdef __BIG_ENDIAN Probably you want to add a blank line here. > +#ifndef find_first_zero_bit_le > +/* > + * Find the first cleared bit in an LE memory region. > + */ > +unsigned long _find_first_zero_bit_le(const unsigned long *addr, unsigned long size) > +{ > + return FIND_FIRST_BIT(~addr[idx], swab, size); > +} > +EXPORT_SYMBOL(_find_first_zero_bit_le); > +#endif > + > +#endif /* __BIG_ENDIAN */ -- With Best Regards, Andy Shevchenko