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 X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 172C6C43331 for ; Fri, 6 Sep 2019 10:08:53 +0000 (UTC) Received: from dpdk.org (dpdk.org [92.243.14.124]) by mail.kernel.org (Postfix) with ESMTP id 9E8DB20854 for ; Fri, 6 Sep 2019 10:08:52 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9E8DB20854 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=solarflare.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=dev-bounces@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8357D1F2E1; Fri, 6 Sep 2019 12:08:51 +0200 (CEST) Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [67.231.154.164]) by dpdk.org (Postfix) with ESMTP id EF97B1F2DA for ; Fri, 6 Sep 2019 12:08:49 +0200 (CEST) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mx1-us1.ppe-hosted.com (PPE Hosted ESMTP Server) with ESMTPS id 725EFB00055; Fri, 6 Sep 2019 10:08:48 +0000 (UTC) Received: from [192.168.38.17] (91.220.146.112) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Fri, 6 Sep 2019 11:08:42 +0100 To: =?UTF-8?Q?Ga=c3=abtan_Rivet?= CC: Stephen Hemminger , , "Ivan Ilchenko" References: <1567699852-31693-1-git-send-email-arybchenko@solarflare.com> <1567699852-31693-3-git-send-email-arybchenko@solarflare.com> <20190905093615.2c3bbb57@hermes.lan> <20190906092433.nlcqic77c4nr2ayf@bidouze.vm.6wind.com> From: Andrew Rybchenko Message-ID: <8b9b7ee3-c9f1-001c-354e-c0a48b0c74a2@solarflare.com> Date: Fri, 6 Sep 2019 13:08:39 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <20190906092433.nlcqic77c4nr2ayf@bidouze.vm.6wind.com> Content-Language: en-GB X-Originating-IP: [91.220.146.112] X-ClientProxiedBy: ocex03.SolarFlarecom.com (10.20.40.36) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-12.5.0.1300-8.5.1010-24892.003 X-TM-AS-Result: No-13.557900-8.000000-10 X-TMASE-MatchedRID: vEvJ7Rh1lGi8rRvefcjeTQR6aubfrqNo69aS+7/zbj+qvcIF1TcLYCiq snPUKvF66gbZwEHaj0fJI5NrSJkuqoqZfRJoRyqbgRTWSf0X8xmeGEaE+eZYS8M5LQWFwBdKKlg CasXEiGKGIkvn/RVOz7/2t8OHAbmsijnP0AA+QkGqNnzrkU+2mg/o5bNHEsCTilveF+mAqDVAkI /ofvcD5IWmFmt1ENMxrkOiPvIbhYK433sKec1LAYicBKfMHlV8icCHz0eydvQda1Vk3RqxOO5uH vBUFusfpEYBIO560cqv8TAvJrvuV3Ho2p42VhyY5rnnDTmVbKog/CIfleX9D4qxMBrs575iLFlX Zd2HA7CdfbUqhtxNNxQIax+Sq2uDOHOT3z1mU7YHGzB42DcRoYWQKSQHRQw2myiLZetSf8my5/t FZu9S3GNgbF0oRDZ0hzoKXqK5N/wCrMnRff054bHTU64Zlo8e18/8/tt8MKyRxGf22O8la4f58x f3VYjPk2vgeh0OlRwsSSk4pZ7fbY3Gq7yYf9iFi5f+zHkN9Oc= X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--13.557900-8.000000 X-TMASE-Version: SMEX-12.5.0.1300-8.5.1010-24892.003 X-MDID: 1567764529-d92k6ZwGVTUH Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH 02/13] net/failsafe: check code of promiscuous mode switch 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On 9/6/19 12:24 PM, Gaƫtan Rivet wrote: > On Thu, Sep 05, 2019 at 07:38:23PM +0300, Andrew Rybchenko wrote: >> On 9/5/19 7:36 PM, Stephen Hemminger wrote: >>> On Thu, 5 Sep 2019 17:10:40 +0100 >>> Andrew Rybchenko wrote: >>> >>>> + if (ret != 0) { >>>> + ERROR("Failed to apply promiscuous mode"); >>>> + return ret; >>>> + } >>> Just return the error as normal and let caller deal with it. >>> Additional logging is not necessary. >> In this particular case we simply follow style around. >> No strong opinion. Up to Gaetan. >> > Ok, actually I missed a few things. > You should leave the error message in and keep it consistent with the rest. > > However, you should test ret against fs_err(sdev, ret), you can find > other uses of it elsewhere in the file. When rte_eth_promiscuous_enable > returns -ENODEV, it is not an error for failsafe (as an absent device is > expected at some point). I see. Will fix in the next version. > Stephen if you would prefer never to have messages, it should be changed > all throughout the driver instead. If prefer it I would accept > a patch about it. Just want to keep it consistent. >