From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 3D8D4A00BE; Mon, 27 Apr 2020 16:55:42 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 4757B1D559; Mon, 27 Apr 2020 16:55:41 +0200 (CEST) Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id E17001D54E for ; Mon, 27 Apr 2020 16:55:39 +0200 (CEST) IronPort-SDR: cgjOYNSWZ0fcBOww66BfUhnp4stKrMAnS2HYCHSAIQ7eRiQYhJYdG577W/5yH3Ef+BZ6Tspl1r 6bf1blzjoBFw== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Apr 2020 07:55:38 -0700 IronPort-SDR: IX41bZ8KqQbMGln4DjjhH48xQHiM0Njg9l+2KmNGezVL5cQh/T0N2cy7r7Fc0PLPvcDcM8Hsjr Q5SgAH0Id0hw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,324,1583222400"; d="scan'208";a="257290320" Received: from orsmsx108.amr.corp.intel.com ([10.22.240.6]) by orsmga003.jf.intel.com with ESMTP; 27 Apr 2020 07:55:38 -0700 Received: from orsmsx155.amr.corp.intel.com (10.22.240.21) by ORSMSX108.amr.corp.intel.com (10.22.240.6) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 27 Apr 2020 07:55:34 -0700 Received: from ORSEDG001.ED.cps.intel.com (10.7.248.4) by ORSMSX155.amr.corp.intel.com (10.22.240.21) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 27 Apr 2020 07:55:34 -0700 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (104.47.58.101) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 27 Apr 2020 07:55:33 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WjPFKOy4fgBKB48ParRpaN7zSDjLnwNf7zCcPsh5ITdidCrCr24E2EmGn1NGITx3V9zJeyq2sJh8i2kVKYaibNB6h92gbQJQ120wf05/CQxxVXu4ckbNFVQVk9hqw8AMWZvts5MkqSB3s4A8sncERtL8wsnUpQiHMjdxUoRwhNH2tymZa5SuVQEdEjlzhrgVZb4XU3JCbQttwfR08e911enT4H9kKYcp+fjZB0wA301pIXGG6Gaqkcvxd31URkPCh31rsg/kVZtC88RVEhMSq+WKD1FEycrTwXperPRg5aHS7/GuDhgNUQyOGHX8wsHiL/pWgaiEg+2DeIaMycVvug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=jOrcBZtqYN29qabtaHYr2rh1QzrM3ZCikZLB4dsgsnU=; b=EbH9fkOemYKqHaldaHGWNqP2v8LJAeXunPGx57PzZfJ3qGbVF5kKGBm+bCCo+BaaqO6Su2sYJY6fnK3y1mMO4XOzmUYrEHf4bfF0b1huqKkUGhiB9b6mXAZQGGdVCeU0GjIqM2bwsZQNwOvedHcVzF6mFu6qWyK98jZMQzhHL3R0ZVyIg83NXcv5aQ0hUfY/Hnd3EStwn5Utjj2KuQv9lfLi6+Z+2phXlrRmzi/68drtqC4AEp+CxZhUtvrkzrBE6fA3mNkSKvsq6eoPqPwM8Qybvy8C7BjWJ92/luUhaeQB3FF52pl/SWJCLsKExd9kXJuGp/tQGwfSmuR1KRrW5Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=jOrcBZtqYN29qabtaHYr2rh1QzrM3ZCikZLB4dsgsnU=; b=gTqFBp4IWWmK0ywVwMADF4vw0Yz1WNr62uuxYr6C8WcXySdP1pkCae5HW1+tcmecjqxnHlU3QSwu5thMP1wL39IS/Hb/eNZV36kC2N3loBlMgK8qXzPN9wJtHGZSJ7RG8H0fD2BM046zS1EkLB/vvoPTMQ33O6FIeAW0rqmuX6o= Received: from BYAPR11MB3301.namprd11.prod.outlook.com (2603:10b6:a03:7f::26) by BYAPR11MB3735.namprd11.prod.outlook.com (2603:10b6:a03:b4::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2937.22; Mon, 27 Apr 2020 14:55:32 +0000 Received: from BYAPR11MB3301.namprd11.prod.outlook.com ([fe80::f8cb:58cd:e958:fff4]) by BYAPR11MB3301.namprd11.prod.outlook.com ([fe80::f8cb:58cd:e958:fff4%6]) with mapi id 15.20.2937.023; Mon, 27 Apr 2020 14:55:32 +0000 From: "Ananyev, Konstantin" To: David Marchand , "dev@dpdk.org" CC: Honnappa Nagarahalli Thread-Topic: [PATCH 1/3] ring: fix build with -Wswitch-enum Thread-Index: AQHWHJc+/oCdNJDqcUqI1NsFPqcmuqiNDnQw Date: Mon, 27 Apr 2020 14:55:31 +0000 Message-ID: References: <20200427132341.27681-1-david.marchand@redhat.com> <20200427132341.27681-2-david.marchand@redhat.com> In-Reply-To: <20200427132341.27681-2-david.marchand@redhat.com> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.2.0.6 authentication-results: spf=none (sender IP is ) smtp.mailfrom=konstantin.ananyev@intel.com; x-originating-ip: [192.198.151.166] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 93ddb8a9-c9dd-4201-aa28-08d7eabb08b0 x-ms-traffictypediagnostic: BYAPR11MB3735: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:612; x-forefront-prvs: 0386B406AA x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BYAPR11MB3301.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(366004)(396003)(346002)(136003)(376002)(39860400002)(52536014)(66946007)(5660300002)(7696005)(66556008)(66446008)(6506007)(66476007)(64756008)(71200400001)(76116006)(186003)(26005)(316002)(110136005)(33656002)(4326008)(86362001)(478600001)(55016002)(9686003)(81156014)(8676002)(8936002)(2906002); DIR:OUT; SFP:1102; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: EvNwZTknQbWKj3bcUsZO2AikH0n5cMwdTK6PhHjEggsWf1bHOqW37peP4SxAbLrVjNhchihbkV6RUkRBeSvbhdA5gw587stMKOj51rWAOojBd0lYGnQSOP3+vvZRk9MTKT+nmTu7xLzn5hsKSfjwVGSrcG0N2zOkQjFhbfOUE2qC4X8MT1eOo5r1jhw20BBKq0S7ZInv55ssOm88iMc39t9xD2ldGozpWTyNfVjjvEhablfzk0PmdBy2hiaQWWF4J4zUWXzzx7+Z3RP1Am4KcXWGB5Q37aoqByo5ltxeIftXdzkSK4IGC6I5w3oUtyhZt3zvt5XdvDx2Ix880e49/bc2/WBBYxsZB2aCrbfhuib3w6EkC1hTsgszR9rbg40ToRVKxUpk0YBTH5BCphGHOQY8JoqT9eWFfVNgCY8wkABjY9labHhHZE3yKlCP1FJ6 x-ms-exchange-antispam-messagedata: 9G+BGRSugz9NppJEJKRoOuiw2kDOd6xrt1O7cwjJhbCseyT3PyCtJQ7Oej6CVvqQL7AWHLTR3OTss+47g2/nN8dMMjsCq1Ngnbjh5GlCEJ1dqZgrWOH4UvjduAFJxbYqz6m1agyGd66a/LFM1mshujYsWotaySaGDIZVeNJw/tVldKfPo7CVprNoJth7C97g3HVJNdXg311lIek5e8Yc3KgypjBJubZt3Gdpjft59tc/ZLCLK0vh2rQ1uaoWqM2dqOnt43Aki/RFbszh1VvTxiu4GQAAhXbLvpFyCgaWl/veO0+cQ4+etshxcyBeSLY1EIoBi+fy9I70kQ+WG3UdPW04WWlGgx4ALxPWYuZbYEuBTQW3c29reIC6UH+TeYDkD5NH4xDPzgvFI0YxjaiQD1B2ityWxI2kF0jcV6TADgsPOho/EuOqYUYMc8fVVOsKUBvNVtFJMwShfhAbiRlbHDN6/Q7O/UYCBjXDzzp7vdSgYZ4VU+JOW675XPxc3F4nNI8F0zjJXPelKHqfKG9APylxCi0MCP70bVZgJk9l79z0mYafqg/xXlsgWNTPChMyUzhy7n7fr3BHvtKIK/KhtYeFYeiuVRILienJ4JOn5Awdfdi6iXA7htF5ThAx92tyRbYGDlNMjdKf8E+WhN7P5acx0CWWIsBrB1DmUZb3YoyxKT+lObpDQNx2Jhtbi3XziHxI1TRKiBpOI2yYLK6ukgO5t/Vz/Fnjs/cpoRQlAoskGaPYYAwPwHL6pGUrp2DyugkjmmClYQhEup7wV6SZ8YxOOfTnhIyo8Sd+bC9PC/y99jDAzZmWwc6LkpPr9bBK x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 93ddb8a9-c9dd-4201-aa28-08d7eabb08b0 X-MS-Exchange-CrossTenant-originalarrivaltime: 27 Apr 2020 14:55:31.9775 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: R3YIbnMgjYdgOQVPHFfNdHzDzTLTqk/wvX7EoeYyMLAG6KfznpR9O5EiBwBRUo6xGN25ZpiMpB5Z6kfoa4DZz1T40pkVmw3JzlCM4JEM63g= X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR11MB3735 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH 1/3] ring: fix build with -Wswitch-enum 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" >=20 > Some popular vswitch implementation might use a gcc option that > complains about missing enums in switch statements. > Fix this by listing all possible values. >=20 > Fixes: 664ff4b1729b ("ring: introduce peek style API") >=20 > Signed-off-by: David Marchand > --- > lib/librte_ring/rte_ring_peek.h | 8 ++++++++ > 1 file changed, 8 insertions(+) >=20 > diff --git a/lib/librte_ring/rte_ring_peek.h b/lib/librte_ring/rte_ring_p= eek.h > index 9e7f4db323..d5e6ea1cf3 100644 > --- a/lib/librte_ring/rte_ring_peek.h > +++ b/lib/librte_ring/rte_ring_peek.h > @@ -68,6 +68,8 @@ __rte_ring_do_enqueue_start(struct rte_ring *r, uint32_= t n, > n =3D __rte_ring_hts_move_prod_head(r, n, behavior, > &head, &free); > break; > + case RTE_RING_SYNC_MT: > + case RTE_RING_SYNC_MT_RTS: > default: > /* unsupported mode, shouldn't be here */ > RTE_ASSERT(0); > @@ -217,6 +219,8 @@ rte_ring_enqueue_elem_finish(struct rte_ring *r, cons= t void *obj_table, > __rte_ring_enqueue_elems(r, tail, obj_table, esize, n); > __rte_ring_hts_set_head_tail(&r->hts_prod, tail, n, 1); > break; > + case RTE_RING_SYNC_MT: > + case RTE_RING_SYNC_MT_RTS: > default: > /* unsupported mode, shouldn't be here */ > RTE_ASSERT(0); > @@ -263,6 +267,8 @@ __rte_ring_do_dequeue_start(struct rte_ring *r, void = *obj_table, > n =3D __rte_ring_hts_move_cons_head(r, n, behavior, > &head, &avail); > break; > + case RTE_RING_SYNC_MT: > + case RTE_RING_SYNC_MT_RTS: > default: > /* unsupported mode, shouldn't be here */ > RTE_ASSERT(0); > @@ -414,6 +420,8 @@ rte_ring_dequeue_elem_finish(struct rte_ring *r, unsi= gned int n) > n =3D __rte_ring_hts_get_tail(&r->hts_cons, &tail, n); > __rte_ring_hts_set_head_tail(&r->hts_cons, tail, n, 0); > break; > + case RTE_RING_SYNC_MT: > + case RTE_RING_SYNC_MT_RTS: > default: > /* unsupported mode, shouldn't be here */ > RTE_ASSERT(0); > -- Acked-by: Konstantin Ananyev > 2.23.0