Message ID | 1488100203-31976-6-git-send-email-talatb@mellanox.com |
---|---|
State | New |
Headers | show
Return-Path: <kernel-team-bounces@lists.ubuntu.com> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) by ozlabs.org (Postfix) with ESMTP id 3vYDpY4RX8z9sNC; Wed, 1 Mar 2017 23:12:21 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=Mellanox.com header.i=@Mellanox.com header.b="kXG4RWbM"; dkim-atps=neutral Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.76) (envelope-from <kernel-team-bounces@lists.ubuntu.com>) id 1cj37A-0005Z6-LW; Wed, 01 Mar 2017 12:12:16 +0000 Received: from mail-db5eur01on0051.outbound.protection.outlook.com ([104.47.2.51] helo=EUR01-DB5-obe.outbound.protection.outlook.com) by huckleberry.canonical.com with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from <talatb@mellanox.com>) id 1chuqT-0007pk-8b for kernel-team@lists.canonical.com; Sun, 26 Feb 2017 09:10:21 +0000 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; bh=KBCylaudpmyvoiusGs/iiWdSELK78JyeyjPYerSt2/M=; b=kXG4RWbMlRGuZp6bTbZnW3vk3c2ClBovGNIKHNLrDLyklr3tGCZcvh1T/mg039Dgtj68CSUeOPKIms3FR70qDenUjUNr8cb8ZBhdYKWQXuq3sz13As//gkfcQMzwW9KjwOxawucp9+7g5VBO86FNVr8/s2NPXqq3c7kTrgKE6Kw= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=talatb@mellanox.com; Received: from dev-h-vrt-005.mth.labs.mlnx (193.47.165.251) by HE1PR05MB1306.eurprd05.prod.outlook.com (10.162.250.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.919.13; Sun, 26 Feb 2017 09:10:19 +0000 From: Talat Batheesh <talatb@mellanox.com> To: <kernel-team@lists.canonical.com> Subject: [PATCH 06/18] net/mlx5e: TC ipv4 tunnel encap offload cosmetic changes Date: Sun, 26 Feb 2017 11:09:51 +0200 Message-ID: <1488100203-31976-6-git-send-email-talatb@mellanox.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1488100203-31976-1-git-send-email-talatb@mellanox.com> References: <1488100203-31976-1-git-send-email-talatb@mellanox.com> MIME-Version: 1.0 X-Originating-IP: [193.47.165.251] X-ClientProxiedBy: AM4PR02CA0026.eurprd02.prod.outlook.com (10.165.239.164) To HE1PR05MB1306.eurprd05.prod.outlook.com (10.162.250.151) X-MS-Office365-Filtering-Correlation-Id: c4cb8a82-5fc7-4810-940e-08d45e2749a2 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(48565401081); SRVR:HE1PR05MB1306; X-Microsoft-Exchange-Diagnostics: 1; HE1PR05MB1306; 3:XNO6zWREl7h8KCyPfqiYUfzE6W25UgfclwCv3/X8zEVoH8NaZsGsmROv0qYe1XYjvXi95d14odqX4XBe7pdiyYQy6EQuls6A8kt0vCgLFgOc8dfNWwksxfA8YrCb44N8IAHOtif4xTeW/goiQDRVWzyYtRFXO5DhUNfKxiqkYVAPWWjxpnjY1t0PsVSxyPrwsVpkfpDTOVxHTrfypAcFqjvITFFbD46M2zkP2UlMCWjoVMeJ0Hx9AWBEQgFwMHjyYvmmrCwkHNMKC9txDtLHv0vG2/OfRsxUWGSqCiuaWvs=; 25:0NckLCFlQ0Wh6r6i8tGZipLthydFTW9k77sF9LupsXp6HS+7W17R4RFNR8RaQxYVH9MoPKQzleaGysEYtO4hn7lVirrFSXJX9sI576NUXhSWT2I/8DcaG0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umKZ/kWPwuj1XYhOvsUL2wvs+E6Vp6x/Ns3wcVPf07ZBQTP3ox3XDnRx7BSE0HvXB733R X-Microsoft-Antispam-PRVS: <HE1PR05MB1306EE482BDF4508ECDA7DB3AB540@HE1PR05MB1306.eurprd05.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(211254476889703)(24339691489775); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046)(6055026)(6041248)(20161123558025)(20161123562025)(20161123555025)(20161123560025)(20161123564025)(6072148); SRVR:HE1PR05MB1306; BCL:0; PCL:0; RULEID:; SRVR:HE1PR05MB1306; X-Microsoft-Exchange-Diagnostics: 1; HE1PR05MB1306; 4:qw+sJYb5NXez/C73Qof5P+fYvwQVCH5lIgpC9ERhsS22p4HW6IB9E3asuAKNUZqYi+GWCM2DcIQKAQ/XRcNJ0YaY6SwWPYc4pUp7j0SYpf/Mti5RczKKvnXqGnEV8hcLtO7HdJuNrj6gfnbyAEmlIC9xri160zaVjJMb6mRBwi5/FXn2QaHr+Q4XmGmmDQxUzR8u5lXLzpO1Pakqm6tVqGE11FNO4oQcJUE/7HUGQCrrEDHhTQD5DNZSRcP0zM924G+daMfVHdCYoOsuEEL1q4SboieGRgPXu0ECpG97B9RLz93q6i5jsv0cfa6JW00RjqpcwZtu2dS18X/VlGvYXR5rZEhNIrK2Nc9sCQpW6IHXvU0XKMXo2+DWPUt36SjOgUJCmBhUHSgbVaZYtHgDXHxO9F8+VSp7N05oEKgBZnhZwloJYyzmo1/Qul6kakxe/q+F8Z+pfpEQMkwVlHAv6s6fjQqX7vxzx/h4RqxoRF7pS5PJ+Gn1UNXmUvevBWVE7JPtzFqnhBlGHN+xy8dNsJCvRl3FddTIQOU3erXZQVGuivWQ+ybXhPN3AJdJlB3vFjk0/cYWuZEid2QJv8roawJObLmA1nv2X67WQTyczm7Ar/gyj2lZuUgnKSgfYDxZc9MNTOvKlz/jnks0bNBvgE+wmfkTwDZvA8bkXN/9cKiOJY0AlhMjoR9ERcx0Th/ot0jgblxy9WEzTDd4wWwPBg== X-Forefront-PRVS: 0230B09AC4 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(7916002)(39410400002)(39450400003)(39850400002)(39840400002)(199003)(189002)(68736007)(81166006)(8676002)(6512007)(81156014)(50226002)(3846002)(6116002)(50466002)(6506006)(48376002)(66066001)(6306002)(25786008)(47776003)(6666003)(2950100002)(5003940100001)(6916009)(6486002)(36756003)(5660300001)(101416001)(189998001)(92566002)(7736002)(107886003)(110136004)(33646002)(97736004)(105586002)(38730400002)(106356001)(2351001)(305945005)(76176999)(50986999)(4326007)(53936002)(2906002)(86362001)(575784001)(42186005)(450100001); DIR:OUT; SFP:1101; SCL:1; SRVR:HE1PR05MB1306; H:dev-h-vrt-005.mth.labs.mlnx; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: mellanox.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; HE1PR05MB1306; 23:0Zb0aYKZLTV+ujZhCSUjzm4+iWxM40q/pq5dzr1QY?= =?us-ascii?Q?IbIYSY/t8dOGc/TGqcHpvxLEEJbCbXW40dDT7DtGH3MGCscHqkjsMvXsC7pA?= =?us-ascii?Q?/wHE/0gJ/Dvn3t/rxlzCap5DWI/jnxAl+sebQ8vvZv4mslFcuLAz4UR10fE1?= =?us-ascii?Q?qAZkr/s7UID2wrgmB6KGWY2j4cxwtuAa/b+Ye8SRGkWwsH18/efXi5kH5Ho8?= =?us-ascii?Q?SgHZEwDGQlVsrs4b0Bfyh3x1b10czT6NQrn3qAOqEFTjf+aB9wZSNXtV9mb9?= =?us-ascii?Q?KK+6H8ypBiC268FhhLcU1UC6xwDLUIRxWbMh0e3TO/zO+4kLAK/Pn8SR88RJ?= =?us-ascii?Q?p/DDYsuNOfFUbT12UUQ4CC25nBGWKq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?R1zl24suuyaKTUHGv9rQZ6ctBFxI/u6O1cPyNXdBRVSJLXG20+xC0XDz2HhL?= =?us-ascii?B?dz09?= X-Microsoft-Exchange-Diagnostics: 1; HE1PR05MB1306; 6:dt2udGcQdKFMb+yq637zJJf6LVgIo/7XZR4n+j4oqDKT8UGyb38JdJBBd8JCw94YM/2Q9foHSL17ywzbywxLVaWkdAvyuA1at3065/PXnhZ9ydmmCd93kKZY5Q5FYmCxMDylML849lf4qxDA6od0Q4GYK5EYN+LH5hCs+UXuqstVhbO8m/OJH1ibe2VZ89l3guRjWJ5NSIV1bLr/4ckWZcdXgzyW9BB08GeW8VIn982eRiM13P8KqBvdAY2Qe3Bld8giBWGXesoD0kuJygkzRsZk4PZAQ96vXNTpOoArqFwamyHrfiu+pbDdHUqSthVCn8unuTQqbU10XFm71LOO3OhfDqCtlnwdJ0YJrFX9HBqTEjHl3BE21bRELleGermdGUyv1Khm+ernNWGlxc/HYwhOc28qw7KfUwe5VrS5Kik=; 5:kIYRvAjLi5ZebkchSWVPe3zeY2xq+m2WJKa+WNHej2gPfm+njbraEp9QFO04NZ7oMSnxZ9+QTtZU1SOFWQKwhY9qwxVL/LGyn+C8HAdqES2sFtCJJgtkima9cUFQ8r7+B+cLXc9yxgQEfsFMo7T5MM9CuRjItDq198VOyLRCxsI=; 24:28XwDO6Hw+NXWIDiKH7/Q3x/vHVgrEyxhOzsIVLJ+MNoFprXSfJVzwm5kjLPIh3xJaVIrz1YBOJRjFbfVe9CRQCfUI2xB4kZqsMkKjOIvIY= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; HE1PR05MB1306; 7:Cyd6NoLRzFACMAshB68O+RFE4epph3RS7A0VcEiTSiaT3sHysTHiU3MCKSyhBFMqwyX3EXRag+kJVnft3y5bIgQMN4e1abztRDYZash+mO8Poifai1AzaWg6ohlEfY7dEsDnwCSb9nBevbIZDni0CwGE6m/43gnaVkOsWnj/5eVDnFsSzyhy+dRFf7qJlxJtddF+lU0rxW4Okd7YB0HA7CeCGZvHbLc65KrToYNDSmXAr9jQ1vWaRwYs2Nz+QUWGVo1V7GOiYbtEraXZEFxRR2o1rZWsfndSrG/f8oZnTIiM2vZzvgGNlLFcLEJbGOP6MzYqVBRd7WwN1uheQSe98g== X-OriginatorOrg: Mellanox.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Feb 2017 09:10:19.3305 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR05MB1306 X-Mailman-Approved-At: Wed, 01 Mar 2017 12:12:14 +0000 Cc: talatb@mellanox.com X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.14 Precedence: list List-Id: Kernel team discussions <kernel-team.lists.ubuntu.com> List-Unsubscribe: <https://lists.ubuntu.com/mailman/options/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe> List-Archive: <https://lists.ubuntu.com/archives/kernel-team> List-Post: <mailto:kernel-team@lists.ubuntu.com> List-Help: <mailto:kernel-team-request@lists.ubuntu.com?subject=help> List-Subscribe: <https://lists.ubuntu.com/mailman/listinfo/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: kernel-team-bounces@lists.ubuntu.com |
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c b/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c index 2cf47e7..aafb518 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_tc.c @@ -690,7 +690,6 @@ static int mlx5e_route_lookup_ipv4(struct mlx5e_priv *priv, struct mlx5_eswitch *esw = priv->mdev->priv.eswitch; struct rtable *rt; struct neighbour *n = NULL; - int ttl; #if IS_ENABLED(CONFIG_INET) int ret; @@ -708,7 +707,7 @@ static int mlx5e_route_lookup_ipv4(struct mlx5e_priv *priv, else *out_dev = rt->dst.dev; - ttl = ip4_dst_hoplimit(&rt->dst); + *out_ttl = ip4_dst_hoplimit(&rt->dst); n = dst_neigh_lookup(&rt->dst, &fl4->daddr); ip_rt_put(rt); if (!n) @@ -716,7 +715,7 @@ static int mlx5e_route_lookup_ipv4(struct mlx5e_priv *priv, *out_n = n; *saddr = fl4->saddr; - *out_ttl = ttl; + *out_dev = rt->dst.dev; return 0; } @@ -791,15 +790,15 @@ static int mlx5e_create_encap_header_ipv4(struct mlx5e_priv *priv, if (err) goto out; - e->n = n; - e->out_dev = *out_dev; - if (!(n->nud_state & NUD_VALID)) { pr_warn("%s: can't offload, neighbour to %pI4 invalid\n", __func__, &fl4.daddr); err = -EOPNOTSUPP; goto out; } + e->n = n; + e->out_dev = *out_dev; + neigh_ha_snapshot(e->h_dest, n, *out_dev); switch (e->tunnel_type) {