Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp2181628pxb; Fri, 25 Mar 2022 12:32:59 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwQe5r8cNtq2TtpntL6uZohgNNgl+P0AJUVPuZFbqfkOml6RYHsgFKE6kJc8awhk8DpRsSA X-Received: by 2002:a17:90b:1d82:b0:1c7:1d3:f4 with SMTP id pf2-20020a17090b1d8200b001c701d300f4mr26740795pjb.223.1648236779809; Fri, 25 Mar 2022 12:32:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648236779; cv=none; d=google.com; s=arc-20160816; b=qe/WVdvmKN2lbnKx3Q1N+Aw1bXKLCAQuuDHvvgRNr44LcI/QTgua/T2IiqMC7xScjB +8bBd4h6lKD0KkSRVBzpPveB6FsPDUjQ3QuxZbKlE+yPZFxIFY8DFqRTVHVN8PiVg8Cn iXshYW9u0KghkqF/2Y+N9raLOcDQR4Nls907H39O0pIWL23uz20LFXG3vI2Je8ZAOuWR 88mNtDVA9S/eKm9+78zAFQisuRf4XBIpPDQJxDqwx7SnGWRktdgX7qM3OMMY0yDecDkM kDiKj8MO2B0uBzA6QVy5Guayb73SqahDrJ8CywdZ3gidE7qWd2tHysubo0Qk3MwLbn7x S0/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id:dkim-signature; bh=vJsrxyZI5Ey6fLfTdp3jvEKM8Ct/nd/CvW2tCPYF/Mw=; b=RxgIzxEpJt/dnEYq4QNLWAOrh6iXyqP63xSTwwO0yzsyOZbhyYEADiIOnkkhdTr9JT QkjfGxrg3nrk9fRT5G5e0XzhhqEm960GTpQtAJbfxt9mTZczs3DqsPol3aIIYEcYO2rK /k0WiIhjh8zVm7n12uDBHbf2Wh8k9O2C0HW++u11FZ8scEY/947kf6h8oOppst6Z23Os j0+mdHI/Lsf0SlFWbR0qGhh/Zv8O/pA+EZYQp/Nzz3VIbKPJCCpMiZKUXA/+cIuM7Gyx aRieUSDHbOOqI4YHyiDVBWJ7cT7pVYql2I2OyZbatTicHd4sfNOHxRaVnwq5Z8Pfg++v JOGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=QjdoB+09; spf=softfail (google.com: domain of transitioning linux-wireless-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id c7-20020a170902724700b00153b2d165b2si2892781pll.442.2022.03.25.12.32.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Mar 2022 12:32:59 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-wireless-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=QjdoB+09; spf=softfail (google.com: domain of transitioning linux-wireless-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 931FE3472E5; Fri, 25 Mar 2022 11:47:53 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1355644AbiCYMLV (ORCPT + 70 others); Fri, 25 Mar 2022 08:11:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34218 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345960AbiCYMLV (ORCPT ); Fri, 25 Mar 2022 08:11:21 -0400 Received: from sipsolutions.net (s3.sipsolutions.net [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 899422DD71 for ; Fri, 25 Mar 2022 05:09:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sipsolutions.net; s=mail; h=Content-Transfer-Encoding:MIME-Version: Content-Type:References:In-Reply-To:Date:Cc:To:From:Subject:Message-ID:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-To: Resent-Cc:Resent-Message-ID; bh=vJsrxyZI5Ey6fLfTdp3jvEKM8Ct/nd/CvW2tCPYF/Mw=; t=1648210186; x=1649419786; b=QjdoB+09ZmPbyAcs/Ny9AiehY+B5EzEsCBU7EapoMQ713fp yR7JybAB0nazxDdkA2MFWYaDXu/+iIL0mZF+iPih5Zz9alJWH2AvSaJ4YwA3FDEHdxm0iVPzAeoF1 YNoKd3mhkUcUbtwmIv/Vy1SQxMTOxn/L5DlUdXy2Z4EXZVup6NHbM6HJyzswyek3kTEQifhTLlNz7 S2NumLHAUGYWKdoexTgxa4QyRTwqeLhqZNxIFV1w8ROfsp+WcCU7WW8pjRK7ReIGQMcjbekiZFCR5 H+rPRofvFrpwZzVDO3IUcXabtBXuRTGYcAMoPbJy5O7DZvaeU1x/OdNNlPrsULVQ==; Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.95) (envelope-from ) id 1nXilE-000JqX-6v; Fri, 25 Mar 2022 13:09:44 +0100 Message-ID: Subject: Re: [BUG] deadlock in nl80211_vendor_cmd From: Johannes Berg To: William McVicker , Jeff Johnson Cc: linux-wireless@vger.kernel.org, Marek Szyprowski Date: Fri, 25 Mar 2022 13:09:42 +0100 In-Reply-To: References: <0000000000009e9b7105da6d1779@google.com> <99eda6d1dad3ff49435b74e539488091642b10a8.camel@sipsolutions.net> <5d5cf050-7de0-7bad-2407-276970222635@quicinc.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.4 (3.42.4-1.fc35) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-malware-bazaar: not-scanned X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE 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 Tue, 2022-03-22 at 21:58 +0000, William McVicker wrote: > > It would be nice if nl80211_vendor_cmd() could support taking the RTNL lock if > requested via the vendor flags. That would require moving the wiphy lock to > nl80211_vendor_cmds() so that it could take the RTNL and wiphy lock in the > correct order. Is that something you'd be open to Johannes? Not very, to be honest. If we had a good use case for it, maybe, but you're not even saying quite what the use case is :) It's also rather complex, because it'd require effectively open-coding the pre_doit() stuff in the vendor command handler itself, in order to look at the sub-command flags while doing it ... johannes