From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-f172.google.com (mail-wi0-f172.google.com [209.85.212.172]) by dpdk.org (Postfix) with ESMTP id C4B67C6C4 for ; Thu, 30 Jul 2015 21:19:24 +0200 (CEST) Received: by wibud3 with SMTP id ud3so4673237wib.0 for ; Thu, 30 Jul 2015 12:19:24 -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=npv9oB+uSYWmxao8bawxFIPEhgwBzxf/dofAIHznTxw=; b=BP4jUKfI4m6L1vgW9aGY+GtaQRBOJfF63vTBO7wZXhRKC1hNg6Hnlv1LqObby4HAZA JvvY8Vqt4FOQfu2zDn7LYdBU0kG1pBlOppFuvLIJpzY8oMGV89Sc+2PYpparc8SCoN9v usG8KNapZzokFLnOeAIGuuvE1edR3Oz7sJeLdZc4gQBLNfhmWnDXxWxBamRRlzhcg17I 6vwK8+th/J38VpvWUb1zjEUWVELPAmzVE1zndJmkXqy110k+3PIvNnJVvaNgV2lGll// gZ5MErMDKtP0zN+oEcBAsc5QaC4BMHtC9lcE1ef7OTXDMKPpRX60dT+vpYVqGDmsiksK xhoA== X-Gm-Message-State: ALoCoQkXYcdOo/kKUodI3jj98/oxngkNEculkKBI3pKG5NYdxMSrHu76Q9k6sZyIl0RL4wLKKNI4 X-Received: by 10.194.175.65 with SMTP id by1mr100460269wjc.152.1438283964561; Thu, 30 Jul 2015 12:19:24 -0700 (PDT) Received: from xps13.localnet (145.16.90.92.rev.sfr.net. [92.90.16.145]) by smtp.gmail.com with ESMTPSA id fa8sm591430wib.14.2015.07.30.12.19.22 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 30 Jul 2015 12:19:23 -0700 (PDT) From: Thomas Monjalon To: Stephen Hemminger Date: Thu, 30 Jul 2015 21:18:06 +0200 Message-ID: <8905831.sre1Q7tU6v@xps13> Organization: 6WIND User-Agent: KMail/4.14.8 (Linux/4.0.4-2-ARCH; KDE/4.14.8; x86_64; ; ) In-Reply-To: <20150730100338.76cd581b@urahara> References: <1428514670-7982-1-git-send-email-stephen@networkplumber.org> <1428514670-7982-2-git-send-email-stephen@networkplumber.org> <20150730100338.76cd581b@urahara> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH v2] enic: silence log message unless debug enabled 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: Thu, 30 Jul 2015 19:19:25 -0000 2015-07-30 10:03, Stephen Hemminger: > --- a/drivers/net/enic/enic_compat.h > +++ b/drivers/net/enic/enic_compat.h > @@ -82,7 +82,11 @@ > #define dev_err(x, args...) dev_printk(ERR, args) > #define dev_info(x, args...) dev_printk(INFO, args) > #define dev_warning(x, args...) dev_printk(WARNING, args) > +#ifdef RTE_LIBRTE_ENIC_DEBUG > #define dev_debug(x, args...) dev_printk(DEBUG, args) > +#else > +#define dev_debug(x, args...) do { } while(0) > +#endif I don't understand why it is needed: dev_debug won't print anything if the log level is higher than DEBUG.