Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752705AbdCNPeZ (ORCPT ); Tue, 14 Mar 2017 11:34:25 -0400 Received: from mx1.redhat.com ([209.132.183.28]:49258 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750815AbdCNPeX (ORCPT ); Tue, 14 Mar 2017 11:34:23 -0400 Message-ID: <1489505658.2413.12.camel@redhat.com> Subject: Re: net: deadlock between ip_expire/sch_direct_xmit From: Paolo Abeni To: Eric Dumazet Cc: Eric Dumazet , Dmitry Vyukov , David Miller , Cong Wang , Alexey Kuznetsov , James Morris , Hideaki YOSHIFUJI , Patrick McHardy , netdev , LKML , Jamal Hadi Salim , syzkaller Date: Tue, 14 Mar 2017 16:34:18 +0100 In-Reply-To: References: <1489502504.28631.115.camel@edumazet-glaptop3.roam.corp.google.com> <1489503785.2413.10.camel@redhat.com> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Tue, 14 Mar 2017 15:34:22 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 758 Lines: 24 On Tue, 2017-03-14 at 08:09 -0700, Eric Dumazet wrote: > On Tue, Mar 14, 2017 at 8:03 AM, Paolo Abeni wrote: > > > I'm wondering if we really need to keep the fragment queue lock held > > while sending the icmp packet ? we hold a reference to the struct, so > > it can't be deleted, and AFAICS after ipq_kill() nobody else could > > access/modify that queue. > > > > That lock is there pretty much forever, but perhaps is only a leftover > > and we can release it just after ipq_kill() ? > > Maybe, but for peace of mind I would make sure this code path owns the > skb (head) before releasing the lock. > > Seems something to try for net-next ? Agreed. I asked because I was in doubt I missed something obvious. Thank you, Paolo