Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp150429rwb; Tue, 25 Jul 2023 13:27:30 -0700 (PDT) X-Google-Smtp-Source: APBJJlGAAhJUd4bWqwYJoKDapHV0al/H1CvJpDeZKivXpz6gls6Ji9K4AQBBGt2cDxAHU3mVLwm2 X-Received: by 2002:aa7:cf11:0:b0:522:2aba:bc3b with SMTP id a17-20020aa7cf11000000b005222ababc3bmr7727218edy.28.1690316850410; Tue, 25 Jul 2023 13:27:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690316850; cv=none; d=google.com; s=arc-20160816; b=boe7XIiYi2BK/BY1etJXX4dvXEFI8f+xOlrocy5cS0iE1V2DkRg5eQE7TGwwQJH4ju eY0y0/EuB2jqbTAzUR18WiTjlQoDkeV5v1kphHYOJ2WpkDhTkUnYdYDiOSDjKpF0lqqD OSYVyWHuaNo8oTjEx72lSnBAQneczWIm2Lgi8+XZbJrf9SugkOV/jQWpnH8l47RB8yXL riFC3D32ZKfGF1K4aQLLG/yqCR5qK5YBsE509amRL6GM794BTGj1q8bSzmCU98c8x9BF hniIKg+NFbMF/p7ZuEiXSHHnWmx4sR13GSlcSbY12/fqvWiqPm2z4Pymz9FoFcVgFL9l o/OA== 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=hcL2mqqsLeV3tZhZn+BYSnnk2Sx4D0F1irDuol7LTQc=; fh=PfoZMoXsfyWSObGvc4a/YdZp0kaJ6doZIhXaVro1/Bc=; b=TqcsqFqgVdO0/Hox3ot80nhFRfHUtVmx2B8VEi80s/wntPh5Ku0Lh4cbTCY0QVp9hp XVAR3R37R6HFnHSjDUJiIBtGOqlfeeE61uvz1FUCxjyyIzn+aS/QK8Zt8lKe3ckLe/Wy I6AHJZjrcwKQfQXQOT1/STO2qKhyzHJXqtv03ldElrWmaBMjtCOb9ojNpSDeyO0DLG5b ouXIKBvzk50iElX9QXqpy3986e6m0Y4T+UzFl6zrp98XIttiH36OBGojSoXllY+KicBq YPFN2mcgHwSHuIIjHJigFsJYOJERajBKmpi98cWHbzb/w+6osOA5l36kFd/CSy/RPhNb 6tXA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b="i/Icwdgc"; 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=NONE sp=NONE dis=NONE) header.from=lunn.ch Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ba28-20020a0564021adc00b0051e3cbc399dsi8354636edb.287.2023.07.25.13.27.10; Tue, 25 Jul 2023 13:27:30 -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=@lunn.ch header.s=20171124 header.b="i/Icwdgc"; 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=NONE sp=NONE dis=NONE) header.from=lunn.ch Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229590AbjGYUKb (ORCPT + 58 others); Tue, 25 Jul 2023 16:10:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50868 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229445AbjGYUK3 (ORCPT ); Tue, 25 Jul 2023 16:10:29 -0400 Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 82DEB1BCB; Tue, 25 Jul 2023 13:10:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=hcL2mqqsLeV3tZhZn+BYSnnk2Sx4D0F1irDuol7LTQc=; b=i/IcwdgcbJcVBOpP7tnZosGJDw F6rJ2JciP99M4OcSqvkRiuSqtR1CUyga7uLDKceFxgh7kKo8+FQMFcjzcAlr7KXVM/Dkp06RuEvRm XCSyTPcUWcYSQGGsXl2oZmdxkpwWTOrRm1hEJhmeSdIrlcG26NbctxNi4LPWv+AyY5Qg=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1qOOLt-002IlW-Ae; Tue, 25 Jul 2023 22:09:49 +0200 Date: Tue, 25 Jul 2023 22:09:49 +0200 From: Andrew Lunn To: Mario Limonciello Cc: "Quan, Evan" , "rafael@kernel.org" , "lenb@kernel.org" , "Deucher, Alexander" , "Koenig, Christian" , "Pan, Xinhui" , "airlied@gmail.com" , "daniel@ffwll.ch" , "johannes@sipsolutions.net" , "davem@davemloft.net" , "edumazet@google.com" , "kuba@kernel.org" , "pabeni@redhat.com" , "mdaenzer@redhat.com" , "maarten.lankhorst@linux.intel.com" , "tzimmermann@suse.de" , "hdegoede@redhat.com" , "jingyuwang_vip@163.com" , "Lazar, Lijo" , "jim.cromie@gmail.com" , "bellosilicio@gmail.com" , "andrealmeid@igalia.com" , "trix@redhat.com" , "jsg@jsg.id.au" , "arnd@arndb.de" , "linux-kernel@vger.kernel.org" , "linux-acpi@vger.kernel.org" , "amd-gfx@lists.freedesktop.org" , "dri-devel@lists.freedesktop.org" , "linux-wireless@vger.kernel.org" , "netdev@vger.kernel.org" Subject: Re: [PATCH V7 4/9] wifi: mac80211: Add support for ACPI WBRF Message-ID: <5e92b45a-d99b-4a8a-9987-46c75a5fcb3c@lunn.ch> References: <20230719090020.2716892-1-evan.quan@amd.com> <20230719090020.2716892-5-evan.quan@amd.com> <9b1f45f9-02a3-4c03-b9d5-cc3b9ab3a058@lunn.ch> <7d059aed-fac0-cdcd-63d5-58185bb345db@amd.com> <6aa9061b-1702-b8f2-9cb8-982895b9def4@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6aa9061b-1702-b8f2-9cb8-982895b9def4@amd.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham 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 > This comes back to the point that was mentioned by Johannes - you need to > have deep design understanding of the hardware to know whether or not you > will have producers that a consumer need to react to. Yes, this is the policy is keep referring to. I would expect that there is something somewhere in ACPI which says for this machine, the policy is Yes/No. It could well be that AMD based machine has a different ACPI extension to indicate this policy to what Intel machine has. As far as i understand it, you have not submitted this yet for formal approval, this is all vendor specific, so Intel could do it completely differently. Hence i would expect a generic API to tell the core what the policy is, and your glue code can call into ACPI to find out that information, and then tell the core. > If all producers indicate their frequency and all consumers react to it you > may have activated mitigations that are unnecessary. The hardware designer > may have added extra shielding or done the layout such that they're not > needed. And the policy will indicate No, nothing needs to be done. The core can then tell produces and consumes not to bother telling the core anything. > So I don't think we're ever going to be in a situation that the generic > implementation should be turned on by default. It's a "developer knob". Wrong. You should have a generic core, which your AMD CPU DDR device plugs into. The Intel CPU DDR device can plug into, the nvidea GPU can plug into, your Radeon GPU can plug into, the intel ARC can plug into, the generic WiFi core plugs into, etc. > If needed these can then be enabled using the AMD ACPI interface, a DT one > if one is developed or maybe even an allow-list of SMBIOS strings. Notice i've not mentioned DT for a while. I just want a generic core, which AMD, Intel, nvidea, Ampare, Graviton, Qualcomm, Marvell, ..., etc can use. We should be solving this problem once, for everybody, not adding a solution for just one vendor. Andrew