From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Hemminger Subject: Re: [PATCH 2/5] cxgbe: add cxgbe poll mode driver. Date: Fri, 22 May 2015 09:43:20 -0700 Message-ID: <20150522094320.1e10251d@urahara> References: <25f06823ef87d05bf57d996df387478e7fbc966f.1432300701.git.rahul.lakkireddy@chelsio.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org, Felix Marti , Kumar Sanghvi , Nirranjan Kirubaharan To: Rahul Lakkireddy Return-path: Received: from mail-pd0-f169.google.com (mail-pd0-f169.google.com [209.85.192.169]) by dpdk.org (Postfix) with ESMTP id A11FE5A4B for ; Fri, 22 May 2015 18:43:17 +0200 (CEST) Received: by pdea3 with SMTP id a3so23579596pde.2 for ; Fri, 22 May 2015 09:43:17 -0700 (PDT) In-Reply-To: <25f06823ef87d05bf57d996df387478e7fbc966f.1432300701.git.rahul.lakkireddy@chelsio.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Fri, 22 May 2015 18:54:20 +0530 Rahul Lakkireddy wrote: > +/** > + * fls - find last (most-significant) bit set > + * @x: the word to search > + * > + * This is defined the same way as ffs. > + * Note fls(0) = 0, fls(1) = 1, fls(0x80000000) = 32. > + */ > +static inline int fls(int x) Isn't there a Gcc intrinsic already for this?