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=-9.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham 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 DC201C43603 for ; Tue, 10 Dec 2019 17:25:04 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B1ED62077B for ; Tue, 10 Dec 2019 17:25:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="J+U58fmQ" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727555AbfLJRZD (ORCPT ); Tue, 10 Dec 2019 12:25:03 -0500 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:32857 "EHLO out3-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727882AbfLJRY5 (ORCPT ); Tue, 10 Dec 2019 12:24:57 -0500 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id EF68020765; Tue, 10 Dec 2019 12:24:56 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Tue, 10 Dec 2019 12:24:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; bh=HvLIROF3WVQqKIjCtK1Vukx849K/qxU16qVb4Kyia28=; b=J+U58fmQ Z3x4PCUVD3VtZCwI0+q50HBvjnH51+8N68MS4BOSlAj8Cwv1M8+e80Lk5WsLsHNW HgYSSTjLsaF9tliGKpnlFGpk2MHJkbO84Y9F/gumND2TnwKFAVJ3yRd8quI53aqa kJA4I2f4XW/QOJ4hWQzj/4PMB1CSwqTzNup15qwanLdZnjAOUiO8SmQvhigAvpsZ dk6WkLuvMxoDRDiE4myaWaivWcJ8YXQGRmPxfuLYDnH+GYrtk1JxtaBzUigbl1dO TKdWUj+7SkCY8o8sBDD34kqkZi5XlXezeTNCW3LlBPq+mFjuCvKPATWsHQEPs7tN fUrBISSOhktMCg== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedufedrudelfedgleelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkofgjfhgggfestdekre dtredttdenucfhrhhomhepkfguohcuufgthhhimhhmvghluceoihguohhstghhsehiugho shgthhdrohhrgheqnecukfhppeduleefrdegjedrudeihedrvdehudenucfrrghrrghmpe hmrghilhhfrhhomhepihguohhstghhsehiughoshgthhdrohhrghenucevlhhushhtvghr ufhiiigvpedu X-ME-Proxy: Received: from splinter.mtl.com (unknown [193.47.165.251]) by mail.messagingengine.com (Postfix) with ESMTPA id 77D8680059; Tue, 10 Dec 2019 12:24:55 -0500 (EST) From: Ido Schimmel To: netdev@vger.kernel.org Cc: davem@davemloft.net, jiri@mellanox.com, dsahern@gmail.com, roopa@cumulusnetworks.com, mlxsw@mellanox.com, Ido Schimmel Subject: [PATCH net-next 6/9] ipv4: Handle route deletion notification during flush Date: Tue, 10 Dec 2019 19:23:59 +0200 Message-Id: <20191210172402.463397-7-idosch@idosch.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20191210172402.463397-1-idosch@idosch.org> References: <20191210172402.463397-1-idosch@idosch.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Ido Schimmel In a similar fashion to previous patch, when a route is deleted as part of table flushing, promote the next route in the list, if exists. Otherwise, simply emit a delete notification. Signed-off-by: Ido Schimmel --- net/ipv4/fib_trie.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c index 2d338469d4f2..60947a44d363 100644 --- a/net/ipv4/fib_trie.c +++ b/net/ipv4/fib_trie.c @@ -1995,6 +1995,8 @@ int fib_table_flush(struct net *net, struct fib_table *tb, bool flush_all) continue; } + fib_notify_alias_delete(net, n->key, &n->leaf, fa, + NULL); call_fib_entry_notifiers(net, FIB_EVENT_ENTRY_DEL, n->key, KEYLENGTH - fa->fa_slen, fa, -- 2.23.0