Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp2410180pxb; Fri, 25 Mar 2022 17:33:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwMW2fPeGdc3fHQn4hdicGaan/q4clytbJRNR8HEWr5IRMXsJRHe8t4CXakv5YJT9gLXlwB X-Received: by 2002:a50:a6c2:0:b0:410:a328:3c86 with SMTP id f2-20020a50a6c2000000b00410a3283c86mr1628025edc.55.1648254784511; Fri, 25 Mar 2022 17:33:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648254784; cv=none; d=google.com; s=arc-20160816; b=wmczwUOXhfYw2eT55H/TQjVWH4EUmqezNFCojHgK0MhVljJILP9vsotxQhOmqwoyiN Z8iKa9pdBNpU7yIrCj9b2JUmcWKQuBryjlKVHwlp3fNNgshJ2Yv4FqXea06Grl1WRge/ 1sUPCnIHeMLSZStVk6doZOfC84sFJmR3N6ObiM3pVF7eE/fsih8Y/YFil8u5HbZLkTp7 pcdlw2pKGEwEmUG0dEHfTa7p0TJHlCGlYQpQrXABJJQymOHTzb3I8NsPZRl92+J+plyB cXmoUlJ9EhsFwaLpcVj9ebB66HgRqDI5mh9LVAMdSD3qYUmaOlMODDxqFHvt9nKlth5d tlzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Iovdo5gFW3lzHAF30oHCSlnhp9HGhN02yXG4gTQEzBo=; b=rvamAUc5c7NfKhZkFbXux666WKxvGlqjy6b4hViqccVs4VA/ETfITo5Vfk/EXt68/g tYX5VDLAnNdz+iXm1/3MGR7fZQiufYzg31ASS4PUXZvrVpjxlwib+1kG1jw1HkhSKStg JiQ2Oa5Pt0MUtRi7Tx+YjrYE5gm/xl2MFxmNIXqQh8XwWogpdFuJTw6obrfea0FhOHMT 98QVDi52CClSZHrM6wnEnVZghkVg2sK5uM7m7eoL8zZBPP0ArQA2z2Fp7SsrsuaInKHN NAU1CII1QDdzn/NVXZhpQqwUeXLCM8tRkYN+U7E6wDst/KliUEmjfR7QovuxdGF/2hbQ M7cw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=IFxbrtw6; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j23-20020a50ed17000000b00418c2b5bdf1si4355032eds.211.2022.03.25.17.32.39; Fri, 25 Mar 2022 17:33:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=IFxbrtw6; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230194AbiCZAOI (ORCPT + 70 others); Fri, 25 Mar 2022 20:14:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49990 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230171AbiCZAOH (ORCPT ); Fri, 25 Mar 2022 20:14:07 -0400 Received: from mail-pg1-x52d.google.com (mail-pg1-x52d.google.com [IPv6:2607:f8b0:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 13501175859 for ; Fri, 25 Mar 2022 17:12:33 -0700 (PDT) Received: by mail-pg1-x52d.google.com with SMTP id c2so7681844pga.10 for ; Fri, 25 Mar 2022 17:12:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=Iovdo5gFW3lzHAF30oHCSlnhp9HGhN02yXG4gTQEzBo=; b=IFxbrtw6MX2TzbzPUVW0OZVJ60JT3UsTUf7o84Lwn974qsIPRA2qCnz2AIm3i7ESQ8 AnkP997VGJGbxPrru5B+NrOjHm1pxfwjmGmXLN58bOL6b07IqcO91WmgoMoAmPFWddaH TY5AbGT/zqRrPa9VdHwPq3ebX7UVVx4eZpkEP4nVSMq3bagk1iqieC1TBgJc9hEFdT0e bf1/9DM3ZpDF5+mr1ImJYtt+e1Qo5CJvIJAf6SSEJ5eI2YgahFOcmIveR2IhUtrjiv7y T8MsRFfG/uVLki2FNxm0zZV6afAvOzMYFgt2DVHL0ttdcqAWcKhR80mOobAOwid26BtA U2yg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=Iovdo5gFW3lzHAF30oHCSlnhp9HGhN02yXG4gTQEzBo=; b=SOn5+y2/4cshOUS3bR6mu0KaJNtDxusuuOlDpo1pexNa4U1n2JxWzgdUAQn7mlx0Nm SmzOJhwEKmOc9Rx+eLrsWo+M8TQh51+XjeWdUQu51xxzPVJmVvB4UxmnwWUy1zTETiQw Gt4QCHg8JPv9XrpkYkIZgS/0oPW9BaRxfwB3XxwGuoSdjs0/SnUW/iSqhZCHKKTjVpXG PWm3uNrpfrTGTTt29drfUEqAsLvvtvdMFyNNrsl27RPJdcpl580A4GH2qeNmhnSnLa4o FpglOJvNqG6LjBPJmddZYK7GCk9Bhs+WNDWgFj8zn7MdIOANzhROGQLe8SU9eKbNtfdo 0bDw== X-Gm-Message-State: AOAM531qtzOvGr+C4EOd50OZQ5RltLCcsoEj3H02fHUvHMg3Yb1Lhvmq SElgsxR5A9lCWpgu+AnrGyLOtA== X-Received: by 2002:a05:6a00:4198:b0:4fa:8591:5456 with SMTP id ca24-20020a056a00419800b004fa85915456mr12630644pfb.81.1648253552353; Fri, 25 Mar 2022 17:12:32 -0700 (PDT) Received: from google.com (249.189.233.35.bc.googleusercontent.com. [35.233.189.249]) by smtp.gmail.com with ESMTPSA id o3-20020a056a0015c300b004fb24adc4b8sm1269851pfu.159.2022.03.25.17.12.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Mar 2022 17:12:31 -0700 (PDT) Date: Sat, 26 Mar 2022 00:12:28 +0000 From: William McVicker To: Jakub Kicinski Cc: Johannes Berg , linux-wireless@vger.kernel.org, Marek Szyprowski , Kalle Valo , "David S. Miller" , netdev@vger.kernel.org, Amitkumar Karwar , Ganapathi Bhat , Xinming Hu , kernel-team@android.com, Paolo Abeni Subject: Re: [BUG] deadlock in nl80211_vendor_cmd Message-ID: References: <19e12e6b5f04ba9e5b192001fbe31a3fc47d380a.camel@sipsolutions.net> <20220325094952.10c46350@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> <976e8cf697c7e5bc3a752e758a484b69a058710a.camel@sipsolutions.net> <20220325170712.69c2c8d3@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220325170712.69c2c8d3@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> X-Spam-Status: No, score=-15.6 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, ENV_AND_HDR_SPF_MATCH,HK_RANDOM_ENVFROM,HK_RANDOM_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, USER_IN_DEF_DKIM_WL,USER_IN_DEF_SPF_WL autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On 03/25/2022, Jakub Kicinski wrote: > On Fri, 25 Mar 2022 23:57:33 +0000 William McVicker wrote: > > Instead of open coding it, we could just pass the internal_flags via struct > > genl_info to nl80211_vendor_cmds() and then handle the rtnl_unlock() there if > > the vendor command doesn't request it. I included the patch below in case > > there's any chance you would consider this for upstream. This would at least > > add backwards compatibility to the vendor ops API so that existing drivers that > > depend on the RTNL being held don't need to be fully refactored. > > Sorry to step in, Johannes may be AFK already. There's no asterisk next > to the "we don't cater to out of tree code" rule, AFAIK. We change > locking often, making a precedent like this would be ill-advised. Yeah I understand. I'll talk to Broadcom about this to see why they didn't use the existing upstream NAN interface. This sounds like it's going to be a problem for all the Android out-of-tree drivers. Thanks for the help! --Will