From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg0-f51.google.com (mail-pg0-f51.google.com [74.125.83.51]) by dpdk.org (Postfix) with ESMTP id B20642BAF for ; Tue, 6 Dec 2016 23:41:52 +0100 (CET) Received: by mail-pg0-f51.google.com with SMTP id p66so153961148pga.2 for ; Tue, 06 Dec 2016 14:41:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=rjnrf+9o1KMIG9wkbj8n2vz0gni6GE8n7ziOqfRbAWo=; b=BTsrkoso4VYGfFTxe+v11bSPCuaQ/OiDyLYlqKwiBELLnRK/hB6ThQce/DZCsjObDC pV7lQrvksj1F3ZG4SUQ4BkRUJJ1Lb2B3MvQNdw9YdLJsQYKet7thBrZVTUXQK6JhRM7X m0nPVThcUyN/ckrMolD4+dUvoM5t2L2CzCLBtgXQTnWqyLwfwiNnHofsVw5vDPZtCI5m l/FSXFzOL3j1JLC03jtd6FQthiorNGfSrHFRc0U2qGDlBHcCYAOX5fLuiYo+ViQx0DU6 omXKOT36EDUyFCTfmXqgwS3wzS3U92XyCwCkyWlmL14A2eGc5aN2EA0XrX9ASCQ77pTY eFQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rjnrf+9o1KMIG9wkbj8n2vz0gni6GE8n7ziOqfRbAWo=; b=ZOZPfePGr999qUY3t0Wq2TlmsAu7YbjcPZaxWPuqEl+LHFIcghXMgESaLO6ExdAuzb OIa/7P95blSxAjvbRYsOfgtTJmVcxbV56Us31Aq9tvq4gkhYmpmuIcapAaAj4Oi5HNQm e1jCO0qE+uhM4+KsBtmRR+UdiPB1t0S8/TMyihRALYSWreMKE3eoeWNdQSOdz9g1PDRO SJS3V8k6t1wRCObRl4ELT5dRhS+xJrh8DHUpIPDsRTnN+IiX5/y8AnAnbObWGTP+py2n JhEhJDL+njOj5XEOGqzlxhjhSBiuBpnK2MKvX5Ai0RpGDd4PK1AvC7ZqMWKfXxG959G2 lEnw== X-Gm-Message-State: AKaTC00YT2jMJUS9HKV7KXAUjFxS5AnQkK6AzbajexcKxC5bhMwk5rtWVtTzpk+efe2NlQ== X-Received: by 10.99.21.65 with SMTP id 1mr116019662pgv.163.1481064112049; Tue, 06 Dec 2016 14:41:52 -0800 (PST) Received: from xeon-e3 (204-195-18-65.wavecable.com. [204.195.18.65]) by smtp.gmail.com with ESMTPSA id 13sm37175773pfz.30.2016.12.06.14.41.51 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 06 Dec 2016 14:41:51 -0800 (PST) Date: Tue, 6 Dec 2016 14:41:44 -0800 From: Stephen Hemminger To: Qiming Yang Cc: dev@dpdk.org Message-ID: <20161206144144.1d68d40b@xeon-e3> In-Reply-To: <1480761783-36467-2-git-send-email-qiming.yang@intel.com> References: <1480761783-36467-1-git-send-email-qiming.yang@intel.com> <1480761783-36467-2-git-send-email-qiming.yang@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 1/3] net/e1000: optimize Rx/Tx log message level X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Dec 2016 22:41:53 -0000 On Sat, 3 Dec 2016 18:43:01 +0800 Qiming Yang wrote: > > +#ifdef RTE_LIBRTE_E1000_DEBUG_RX_FREE > +#define PMD_RX_FREE_LOG(level, fmt, args...) \ > + RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args) > +#else > +#define PMD_RX_FREE_LOG(level, fmt, args...) do { } while (0) > +#endif If you have to copy/paste same code in more than one driver, that looks like a missing interface. I.e Do not Repeat Yourself.