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=-1.0 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS,URIBL_BLOCKED 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 26638C43381 for ; Sat, 16 Feb 2019 01:33:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DE2BA222D0 for ; Sat, 16 Feb 2019 01:33:00 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="b0oeRVkQ" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729962AbfBPBbx (ORCPT ); Fri, 15 Feb 2019 20:31:53 -0500 Received: from mail-pl1-f172.google.com ([209.85.214.172]:36488 "EHLO mail-pl1-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726125AbfBPBbx (ORCPT ); Fri, 15 Feb 2019 20:31:53 -0500 Received: by mail-pl1-f172.google.com with SMTP id g9so5819147plo.3 for ; Fri, 15 Feb 2019 17:31:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=flrGdjC+YiUYq2Wzk67i2Nl76Aw7vlHdGechljOJbNE=; b=b0oeRVkQnSaN8HxtpNrltBo6gS5GIfmtcWIkTl9oZIxazd7tjvzW/ONqeJ7Px6NvKY Xi5RWg76uiXLa61zwrCrGwH1p/2EC4DlBZKO04QR8/8kOtsc3bMtV+TFO7Pi24O+pGV7 DN2RXuOXDUeKb301Dfr0AsOcqMlpwAGK6XmxQeFJBTvnsM5pNeiWlmZ0J9k9cSCHFy+D ARJRVdIlUrcAr/k1ZxMKOYUoW8vLBOKWWjNR3vGYgeuIpBocf0KkbYqbLINg5IwIVmSI LFTAoqU5IHcsqzsEvt8qlXgJcIzwV50K9o1xGt9uQojaz6Lb1Jcfh7xGGTLjQpnhI6nm Tmfg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=flrGdjC+YiUYq2Wzk67i2Nl76Aw7vlHdGechljOJbNE=; b=A0FFLTcYwkrIcA8etHGXlSDJv23dck9Bm/5TxxaZyb9lktBScgPzdCXhYPAYYNXWfA fZpVsGDpgTzYJKP1KLFBrDGwUqBy7DejBoJDLXu0c607Ewjibgk9dqRd09oxkNYUqNM4 OPJRjI4tSRvc2UUBd0fv6ZergNXKpWkuSPAt57WtuSZjDW92oRxGV0Simbil9TFFwSjo B6DLI1EepwOji8vJFiiWync1l1zG6VBSCGPthnMxPg3GDD5Yb+NS9ZRTfzVYQL10xt6X LmIx83xLafoSANgX0OM+pNW85s0R2dqw142T/D5o6YN/Ws1XLMdYOxw9u65mo9Qs4N6s /eFg== X-Gm-Message-State: AHQUAuZ8rQkBN8C/lQcfHCQ9ei54TH3rsHGNr6elVqOm+vouTvstDozb 0Wqd7sTzvv7Hs+Nspabdzc7VsS9T/a1W8Y6SNv4vi7Nb X-Google-Smtp-Source: AHgI3IZL4y1w5nGQ9L7jGIeQUIobXIyoHec7pWVJUZ0R9vV04OcvDL3kcXZ+eixERFK5v2AEonjG0v9iE0a5sXYPu6w= X-Received: by 2002:a17:902:9893:: with SMTP id s19mr13266837plp.165.1550280713019; Fri, 15 Feb 2019 17:31:53 -0800 (PST) MIME-Version: 1.0 References: <20190215.124125.1781326145216021027.davem@davemloft.net> In-Reply-To: <20190215.124125.1781326145216021027.davem@davemloft.net> From: Cong Wang Date: Fri, 15 Feb 2019 17:31:41 -0800 Message-ID: Subject: Re: [MERGE HELP] cls_tcindex.c To: David Miller Cc: Linux Kernel Network Developers , Vlad Buslov Content-Type: text/plain; charset="UTF-8" Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On Fri, Feb 15, 2019 at 12:41 PM David Miller wrote: > > > I've merged net into net-next. > > The worst conflict was cls_tcindex.c as Cong's fixes collided heavily > with Vlad's work. > > The interim solution I used for this merge was to revert back to RCU. > > Please take a look at what I did and send me followups because I am > absolutely certain that some are necessary :-))) Well, there is nothing fundamentally changed w.r.t. the race I have fixed. In tcindex_delete(), after all Vlad's patches, it still calls tcf_queue_work() therefore still races with call_rcu(). This has nothing to do with whether it is RTNL or another mutex. For the first memory leak, it is same, nothing changes, tcindex_delete() still skips r->res.class==0 therefore we still need to fix it. For the rest two memory leaks, it looks like you already merged the fix (patch 3/3) correctly. I will cherry-pick the first two patches for net-next and send them to you. Thanks.