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=-10.4 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT,USER_IN_DEF_DKIM_WL 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 F0C9BC31E5B for ; Tue, 18 Jun 2019 18:09:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C27A42063F for ; Tue, 18 Jun 2019 18:09:05 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="CeY+n5ea" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730215AbfFRSJE (ORCPT ); Tue, 18 Jun 2019 14:09:04 -0400 Received: from mail-pl1-f202.google.com ([209.85.214.202]:45195 "EHLO mail-pl1-f202.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729491AbfFRSJE (ORCPT ); Tue, 18 Jun 2019 14:09:04 -0400 Received: by mail-pl1-f202.google.com with SMTP id y9so8251366plp.12 for ; Tue, 18 Jun 2019 11:09:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:message-id:mime-version:subject:from:to:cc; bh=Wep6s4agu8rdLcULIO3ntDstkZX56019pOAE+BsZxVM=; b=CeY+n5eaOCWxgLRYJddzsMjZnGLLh/cNYbOTpV/yh1G5G47CjqTogtjgtE6Qxan7oH 3lGoViGmZuwtsoIrNWRBA+GuIRKjf2mEYFwGtvdx5JK4RUCjpNZ6t1ZAstlg988Buk5c RNGz7ioviSX8m3uln1xCbgheu8upyT1frht7fSuKV6KSARhElBDJind2zYpCcjXGBu8Y nNKodq6anm2pj21qdlAauNxuYYq0g3bcjkFwQnUu+3ngX8sJWTPYaPAIF3IAivS+oB9Q yWeMsWbsgiOwLNxZzfvbrGBAH+lD3m8nBGG8gddeI7eyzn4R+5Qd09jziGwSWc2jO1c8 Wnmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:message-id:mime-version:subject:from:to:cc; bh=Wep6s4agu8rdLcULIO3ntDstkZX56019pOAE+BsZxVM=; b=inEYDQnxORBwyZ4ncs6S4kszm5Lc4VZCKua3kvBk7DehtWM2Kq9LbkC9lXgJOJg6Qw KgjqQ043o5kKIsfNsX+QDideLK4NyogzT7cBIdJVyQc95O6JIEb1Sg+Ph/kGdQwh6l06 FRiFagLfXgzx4gYH3cdYsLm3E+6JoJCnSbxfQhi2jltUPhaQFVUyIJE6nzxGaFQGZ4ay nY49DKJuT7ys5e1pbf5ZaiAFR3epDQego0Iuuv0bQYeSOf0rN2hniepzWQEUmRkIgYD4 8fMwkyY3sKRuIdm1c3bgZ4pz2s26oN4cYrjcSQp4RiCvF/n229lmGc/2pdfGhFnRQiW1 TzbA== X-Gm-Message-State: APjAAAVx7/r5fUvmvQjbQaVhyg6+yNGXXOLNB19ZzPDf1VyZPEwcJVoN g6vkl4ZLKq2ZeeC0GE5HaDQPugVBOT6qNQ== X-Google-Smtp-Source: APXvYqwwhvK12TLGfLFKq72tFbt0tjcWizrm1Nn8hKLmnIW06t7GfcVlpewcc5lsenen1oP6ybvpJABN3voawg== X-Received: by 2002:a17:902:3a5:: with SMTP id d34mr30399011pld.239.1560881343584; Tue, 18 Jun 2019 11:09:03 -0700 (PDT) Date: Tue, 18 Jun 2019 11:08:58 -0700 Message-Id: <20190618180900.88939-1-edumazet@google.com> Mime-Version: 1.0 X-Mailer: git-send-email 2.22.0.410.gd8fdbe21b5-goog Subject: [PATCH net-next 0/2] inet: fix defrag units dismantle races From: Eric Dumazet To: "David S . Miller" Cc: netdev , Eric Dumazet , Eric Dumazet Content-Type: text/plain; charset="UTF-8" Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org This series add a new pre_exit() method to struct pernet_operations to solve a race in defrag units dismantle, without adding extra delays to netns dismantles. Eric Dumazet (2): netns: add pre_exit method to struct pernet_operations inet: fix various use-after-free in defrags units include/net/inet_frag.h | 8 ++++++- include/net/ipv6_frag.h | 2 ++ include/net/net_namespace.h | 5 +++++ net/core/net_namespace.c | 28 +++++++++++++++++++++++++ net/ieee802154/6lowpan/reassembly.c | 13 ++++++++++-- net/ipv4/inet_fragment.c | 19 ++++------------- net/ipv4/ip_fragment.c | 14 +++++++++++-- net/ipv6/netfilter/nf_conntrack_reasm.c | 10 +++++++-- net/ipv6/reassembly.c | 10 +++++++-- 9 files changed, 85 insertions(+), 24 deletions(-) -- 2.22.0.410.gd8fdbe21b5-goog