From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR04-VI1-obe.outbound.protection.outlook.com (mail-eopbgr80057.outbound.protection.outlook.com [40.107.8.57]) by dpdk.org (Postfix) with ESMTP id 09E942965 for ; Sun, 28 Oct 2018 13:53:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=w5F2FqR36BbmFc6QYN2E5CMLtcw7TijGmvG0MB6GlV8=; b=QKKLG6fAgN03N9ocrJzg2uU68STGS3sP3jsD/Jc9lGKNrXaGJ3l98Jd9w3Zrg12xMbvs0YobElRfRYzvuwzXkp6slaRaem4Nhx+6U50NyQIKKsbWUOxkMzKkCzWnJJPxRMC859ifWyj4OGGFYFn1lyfwv7CwUchlgkb+uHxlc5s= Received: from DB7PR05MB4426.eurprd05.prod.outlook.com (52.134.109.15) by DB7PR05MB4251.eurprd05.prod.outlook.com (52.134.108.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1273.26; Sun, 28 Oct 2018 12:53:35 +0000 Received: from DB7PR05MB4426.eurprd05.prod.outlook.com ([fe80::80e:e6b:baf2:d973]) by DB7PR05MB4426.eurprd05.prod.outlook.com ([fe80::80e:e6b:baf2:d973%3]) with mapi id 15.20.1273.025; Sun, 28 Oct 2018 12:53:35 +0000 From: Shahaf Shuler To: Yongseok Koh CC: "dev@dpdk.org" Thread-Topic: [PATCH 1/2] net/mlx5: fix bit width of flow items Thread-Index: AQHUbX/P9UMqc+mWF02/XVt7WoexYqU0j1pA Date: Sun, 28 Oct 2018 12:53:35 +0000 Message-ID: References: <20181025085351.15738-1-shahafs@mellanox.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=shahafs@mellanox.com; x-originating-ip: [193.47.165.251] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; DB7PR05MB4251; 6:05bPrC766MRCzyc66Wc0v68eT/lRvlT535kRqW4yo9s8q4V4fWQknI28VRkb3FzCvHiTU+UkK1VCRmCYEeVJbv6NbtxPF8cSC4buIsU2N5TjIG1u82NdyO44BA2jcLLs16xRZsRNd0sT58T56uZpZb+BcwgRHg369uL1K0nfj/Z28omL9X0yDPn2KtJ+JqQnkG1pflvMqdTZ96XkoeoHmDd0b+YZ1VBzzV53a7cBc9jDBFbCD6pzYpdb99D1kN6XMZg9AwI3KQdGwGQqzVMfLRskQtI53IGUEn34dT6ej09VpYxEiAOiLKJc4D4idVFCwyeclfWwJnEKPDbD1FaNLCXTrrYShiQtArz73rZ5dBJMLzS0jvYE60pvkmPnhLKoTy5w0D7dB2mmRlCnGmnhBy1nHxgtVKnUUx20822LiX4PVJvnVEpXQuqDd4WWoipZ11cU9HxvQR1kotCFVE6BuQ==; 5:/yn9xpLnEfPG2ijRvSGKat+7Xjo6EltIjg64tAoKjmrlTtPDU1q/ad/Kzpsplo1zgj5qZfJfuCftKDRSM92+p2VDmpBfdRUjJgQY9OYium+9KAKPuIH/xQaKajsur2uz2LxlXQokIPjGVmy+hfFBWTLwZukHf9tAZdPbeSrvJlc=; 7:T9ny0uOtGGFgKnLPE1ym2Nlb+Z4hrB6fQq6HLwAjiFmI6ORRSGOko5mgTkDHqSWZsEDlrEGC9AiiMYJTob1oeoiGAT5KGzWHxypqEwyX8Grl6T1QVGggcl8N1CMZsRAfPgJdrD5I2XbE/k6Ij6au1A== x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-correlation-id: 3f6e1f38-c940-4872-f61d-08d63cd45f74 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989299)(5600074)(711020)(4618075)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7153060)(7193020); SRVR:DB7PR05MB4251; x-ms-traffictypediagnostic: DB7PR05MB4251: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:; x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3231382)(944501410)(52105095)(3002001)(10201501046)(93006095)(93001095)(6055026)(148016)(149066)(150057)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(20161123560045)(20161123564045)(20161123558120)(201708071742011)(7699051)(76991095); SRVR:DB7PR05MB4251; BCL:0; PCL:0; RULEID:; SRVR:DB7PR05MB4251; x-forefront-prvs: 0839D067E7 x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(39860400002)(396003)(346002)(366004)(376002)(136003)(199004)(189003)(71200400001)(9686003)(486006)(71190400001)(6246003)(186003)(7736002)(53936002)(305945005)(229853002)(2906002)(97736004)(4326008)(106356001)(55016002)(105586002)(476003)(6436002)(86362001)(575784001)(6862004)(25786009)(33656002)(6116002)(14444005)(3846002)(68736007)(256004)(6506007)(2900100001)(316002)(76176011)(7696005)(11346002)(81156014)(26005)(446003)(66066001)(99286004)(478600001)(74316002)(14454004)(5250100002)(53546011)(8676002)(6636002)(102836004)(81166006)(5660300001)(8936002); DIR:OUT; SFP:1101; SCL:1; SRVR:DB7PR05MB4251; H:DB7PR05MB4426.eurprd05.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: ZM9IVi1K98vZ5diR/iibkjyRR7mWQvPToP7G9qftqW0P6s1E1Uw8YrCWqp3ElLpIq/HFU2xxPsanH2va/1J9r0ugTW28nqnl/UmBz5DOpnh/mo2w2DxGKePauOFbKQ3hlkUwdY1j5OXbdac0EM8B2Vkue5tYJp7d0PKjbQMJQEqiFmVj9zsPgr+H+ru2QHyzSFD6LJJxessR4onkLMPfNKdQnwTB7kWpNFuOYd7DeOmmkQFwMCUb56OEbJquti1b9ESUcFWPYe8tLPudRk7xpx4YjNRp+O40NcaRTnpqn8crSqi4g4+A3RaiFbngTuPZbZgBPQYvTenMvYTMUXZ2Hnfp/HX2/sF2qr+3d2uVs1I= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3f6e1f38-c940-4872-f61d-08d63cd45f74 X-MS-Exchange-CrossTenant-originalarrivaltime: 28 Oct 2018 12:53:35.1047 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: a652971c-7d2e-4d9b-a6a4-d149256f461b X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB7PR05MB4251 Subject: Re: [dpdk-dev] [PATCH 1/2] net/mlx5: fix bit width of flow items 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: Sun, 28 Oct 2018 12:53:36 -0000 Saturday, October 27, 2018 2:01 AM, Yongseok Koh: > Subject: Re: [PATCH 1/2] net/mlx5: fix bit width of flow items >=20 >=20 > > On Oct 25, 2018, at 1:53 AM, Shahaf Shuler > wrote: > > > > Apply the changes from commit c744f6b1b969 ("net/mlx5: fix bit width > > of item and action flags") in some places that were overlooked. > > > > Fixes: c744f6b1b969 ("net/mlx5: fix bit width of item and action > > flags") > > Fixes: 23c1d42c7138 ("net/mlx5: split flow validation to dedicated > > function") > > > > Signed-off-by: Shahaf Shuler > > --- > Acked-by: Yongseok Koh Series applied to next-net-mlx, thanks.=20 >=20 > Thanks >=20 > > drivers/net/mlx5/mlx5_flow.c | 10 +++++----- > > drivers/net/mlx5/mlx5_flow.h | 4 ++-- > > 2 files changed, 7 insertions(+), 7 deletions(-) > > > > diff --git a/drivers/net/mlx5/mlx5_flow.c > > b/drivers/net/mlx5/mlx5_flow.c index 280af0abce..87189a3405 100644 > > --- a/drivers/net/mlx5/mlx5_flow.c > > +++ b/drivers/net/mlx5/mlx5_flow.c > > @@ -275,7 +275,7 @@ static const uint32_t > > priority_map_5[][MLX5_PRIORITY_MAP_MAX] =3D { > > > > /* Tunnel information. */ > > struct mlx5_flow_tunnel_info { > > - uint32_t tunnel; /**< Tunnel bit (see MLX5_FLOW_*). */ > > + uint64_t tunnel; /**< Tunnel bit (see MLX5_FLOW_*). */ > > uint32_t ptype; /**< Tunnel Ptype (see RTE_PTYPE_*). */ }; > > > > @@ -1079,7 +1079,7 @@ mlx5_flow_validate_item_eth(const struct > > rte_flow_item *item, */ int mlx5_flow_validate_item_vlan(const struct > > rte_flow_item *item, > > - int64_t item_flags, > > + uint64_t item_flags, > > struct rte_flow_error *error) > > { > > const struct rte_flow_item_vlan *spec =3D item->spec; @@ -1091,11 > > +1091,11 @@ mlx5_flow_validate_item_vlan(const struct rte_flow_item > *item, > > uint16_t vlan_tag =3D 0; > > const int tunnel =3D !!(item_flags & MLX5_FLOW_LAYER_TUNNEL); > > int ret; > > - const uint32_t l34m =3D tunnel ? (MLX5_FLOW_LAYER_INNER_L3 | > > + const uint64_t l34m =3D tunnel ? (MLX5_FLOW_LAYER_INNER_L3 | > > MLX5_FLOW_LAYER_INNER_L4) : > > (MLX5_FLOW_LAYER_OUTER_L3 | > > MLX5_FLOW_LAYER_OUTER_L4); > > - const uint32_t vlanm =3D tunnel ? MLX5_FLOW_LAYER_INNER_VLAN : > > + const uint64_t vlanm =3D tunnel ? MLX5_FLOW_LAYER_INNER_VLAN : > > MLX5_FLOW_LAYER_OUTER_VLAN; > > > > if (item_flags & vlanm) > > @@ -1145,7 +1145,7 @@ mlx5_flow_validate_item_vlan(const struct > > rte_flow_item *item, */ int mlx5_flow_validate_item_ipv4(const struct > > rte_flow_item *item, > > - int64_t item_flags, > > + uint64_t item_flags, > > struct rte_flow_error *error) > > { > > const struct rte_flow_item_ipv4 *mask =3D item->mask; diff --git > > a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h index > > 61299d66b3..c24d26ed45 100644 > > --- a/drivers/net/mlx5/mlx5_flow.h > > +++ b/drivers/net/mlx5/mlx5_flow.h > > @@ -336,7 +336,7 @@ int mlx5_flow_validate_item_gre(const struct > rte_flow_item *item, > > uint8_t target_protocol, > > struct rte_flow_error *error); > > int mlx5_flow_validate_item_ipv4(const struct rte_flow_item *item, > > - int64_t item_flags, > > + uint64_t item_flags, > > struct rte_flow_error *error); > > int mlx5_flow_validate_item_ipv6(const struct rte_flow_item *item, > > uint64_t item_flags, > > @@ -355,7 +355,7 @@ int mlx5_flow_validate_item_udp(const struct > rte_flow_item *item, > > uint8_t target_protocol, > > struct rte_flow_error *error); > > int mlx5_flow_validate_item_vlan(const struct rte_flow_item *item, > > - int64_t item_flags, > > + uint64_t item_flags, > > struct rte_flow_error *error); > > int mlx5_flow_validate_item_vxlan(const struct rte_flow_item *item, > > uint64_t item_flags, > > -- > > 2.12.0 > >