From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wg0-f43.google.com (mail-wg0-f43.google.com [74.125.82.43]) by dpdk.org (Postfix) with ESMTP id 014C65917 for ; Tue, 28 Oct 2014 10:56:22 +0100 (CET) Received: by mail-wg0-f43.google.com with SMTP id n12so388893wgh.14 for ; Tue, 28 Oct 2014 03:05:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding:content-type; bh=n7uMQU5fB4WDRgrkPLf2QTe3n4Qdr+ry7zK1gs4Ipso=; b=hK4rb/h8u65kXct6A1j1ft5oBEwtPqTTh4nriDWwBncCkDsKiLpb8JYN2RfiJwkLMv 6DAuUrrAlEiXjngTw2QPB+GXf49i1Ac9BZjz4UCdNLRSnZU1P6nDY792syvOAQqN66hP wfSgeO+arWsqgJOuhZecE1+2K5T/peuZSBnvJf1Y2Wx65t442U5g3ssN2q25Yw9xRbd7 01nVFFaBJWV0sNH0yxO2nLw1VIw7KS5EQtFNzaSFircEr1VZQYUS03dXiggAxXCRpKqM 5bz2iOhgYYM42MeZdbp5BBTy9lwAIF3Jx1C5a/fKIu4+muF9Bkbc2y183ABo7wsus/EW FIgQ== X-Gm-Message-State: ALoCoQlFj2Z4x0hnS5hkgKqfiY2cTD0WgEybFg3vUXBlO/zSNpywPKADLJOau1QX/Avb7yM5dzsi X-Received: by 10.194.243.164 with SMTP id wz4mr1736288wjc.129.1414490709572; Tue, 28 Oct 2014 03:05:09 -0700 (PDT) Received: from xps13.localnet (136-92-190-109.dsl.ovh.fr. [109.190.92.136]) by mx.google.com with ESMTPSA id wx3sm1243308wjc.19.2014.10.28.03.05.08 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 Oct 2014 03:05:08 -0700 (PDT) From: Thomas Monjalon To: "Zhang, Helin" Date: Tue, 28 Oct 2014 11:04:51 +0100 Message-ID: <1959774.p5xijEU5zU@xps13> Organization: 6WIND User-Agent: KMail/4.14.2 (Linux/3.17.1-1-ARCH; KDE/4.14.2; x86_64; ; ) In-Reply-To: References: <1411634427-746-1-git-send-email-helin.zhang@intel.com> <2549150.oVMv5n2oYl@xps13> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH v3 7/8] ethdev: support of multiple sizes of redirection table X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Oct 2014 09:56:23 -0000 2014-10-28 00:37, Zhang, Helin: > From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com] > > 2014-10-22 19:53, Helin Zhang: > > > +#define RTE_BIT_WIDTH_64 (CHAR_BIT * sizeof(uint64_t)) > > > > How can it be different of 64? > > Using 64 would be simpler to understand than RTE_BIT_WIDTH_64. > > > > > + uint8_t reta[RTE_BIT_WIDTH_64]; /**< 64 redirection table entries. */ > We always try to use macro in code to replace numeric, this can get the numeric more understandable. How bit width 64 is more understandable than 64? Especially when you count a number of entries, not a bit width. RETA_ENTRIES_MAX would be more understandable. -- Thomas