Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp12721219rwd; Fri, 23 Jun 2023 09:43:18 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6GrVgoK/lCzhw6FH8NkF02uCKhIHkYCs7f8VjOTWKCpwtrWejxA2pg3cMk6JUN0/YhJt+T X-Received: by 2002:a17:90a:ff09:b0:25c:7f2:2e5d with SMTP id ce9-20020a17090aff0900b0025c07f22e5dmr20678335pjb.13.1687538597955; Fri, 23 Jun 2023 09:43:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687538597; cv=none; d=google.com; s=arc-20160816; b=ps0AsUYTVyWNjynDb298CH7MgR9RkVEkRxASxf52VyXjpKvlca9HFy23bz9Y65me1L YMS8wnw9qbdpSeCX6wxAehts8nyBLopjE5WsknVcdChDGY0Xn2x3CcDtQMreZ9Sh00FW 1MIHEn2mp352/0b+5IZKsQATzcu5SiN2YqLG8PUZb7tiGVxXcNCaYovh5Hca2GpeuJgz oJJgi6YSddTezdQMd1DUxxGlJjbwpi+yQYkYQmoWvoe3bkth4Iv2GMZVDULTICfb+Nru zoL4wY2pM8UVbn9BSrvXeT4uL2bi7g4UUD6/g24nN9AyVon6v1Bv/ySfxPCFk5Ma4Ns+ 90YQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version; bh=+17Z60SJjahDrwMvSTZwEQXhSL7H7f+m5cqUXalyNv0=; b=PSSO9wQPLNFBPx4re3hiHMCR/WroeSgNdBAAZTQrJbyRe25S7cUduUrGHRd8HYTkoU Wy3Yf4FIuDBXFRVkcegZPjPZ8Ewn5LwN31d69Yr0vRVPDKJWxOnp1a74WSrLhpRcDCxI PoZ4ositwhkqdKf/C19JbpB/tFRvLGyYMlyKmg1hBhbz0edI/aufKVTG4hmzH0hJ40I/ rg4wayMdLksKQ40DjWAaFNyS12/DEfppiPnFhtteE6PSF9r98FfIse2M/iRr02HmKJTH 7UqaSjE3ySKbx6NnFcBgb/KCCbQSRtv06IL1LXUcTIB6rtO3ncSJCeAhkH/bGqhuPQRy MW1g== ARC-Authentication-Results: i=1; mx.google.com; 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=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id lp3-20020a17090b4a8300b00256cba1cadesi2485766pjb.50.2023.06.23.09.43.10; Fri, 23 Jun 2023 09:43:17 -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; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232019AbjFWQ2R convert rfc822-to-8bit (ORCPT + 58 others); Fri, 23 Jun 2023 12:28:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42544 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231744AbjFWQ2P (ORCPT ); Fri, 23 Jun 2023 12:28:15 -0400 Received: from mail-lj1-f173.google.com (mail-lj1-f173.google.com [209.85.208.173]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D5099270E; Fri, 23 Jun 2023 09:28:14 -0700 (PDT) Received: by mail-lj1-f173.google.com with SMTP id 38308e7fff4ca-2b5910c231bso2895911fa.0; Fri, 23 Jun 2023 09:28:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687537693; x=1690129693; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kvgeaWwow5dQzFM6Uw8ojK5T7WjFQWYGvDt1Izr/8jk=; b=j1eDX+rfTascQewMT2R8wt077pwLqnl3/fHykK9weg+VTC5KosdoIuB3zkzwR8IbOS zvycxikFdqCQrAFXyinBgS6VtwRUPIYDJmHT3WEAyY3h+eTR5DrO6qeNEeLc2zsAJUIA l1fySydLjAUM2cOffkZKTzJsk/jQSx/uXVuAI8IgFvbLFnpnq79LCiLs197N43BePVbo KFSmfEUTU+5hSX/d9lIiStR9EMAjb5sgc0pg/YOYZ3Drxp2oKRcVSQdzjooW29X63mKa /m45mGkJ+ZlzoQS1f6eFUSxI8JOabddWQWis+NJBzR4q6I+6JVTgQACj6eaXib+tWd74 DeVA== X-Gm-Message-State: AC+VfDx9wxskLyjZy3Z7uFCMal1z4aDHi7gSVzqOpz1QXtLcqKdjfDUs IQcBHcu+GfVOcvpOukI3xmSgJm3EFqwnup38i0w= X-Received: by 2002:a2e:a492:0:b0:2b4:6d9a:2222 with SMTP id h18-20020a2ea492000000b002b46d9a2222mr9575407lji.0.1687537692753; Fri, 23 Jun 2023 09:28:12 -0700 (PDT) MIME-Version: 1.0 References: <20230621054603.1262299-1-evan.quan@amd.com> <20230621054603.1262299-2-evan.quan@amd.com> In-Reply-To: From: "Rafael J. Wysocki" Date: Fri, 23 Jun 2023 18:28:01 +0200 Message-ID: Subject: Re: [PATCH V4 1/8] drivers/acpi: Add support for Wifi band RF mitigations To: "Limonciello, Mario" Cc: "Rafael J. Wysocki" , Evan Quan , lenb@kernel.org, alexander.deucher@amd.com, christian.koenig@amd.com, Xinhui.Pan@amd.com, 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, lijo.lazar@amd.com, 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 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, 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 Fri, Jun 23, 2023 at 5:57 PM Limonciello, Mario wrote: > > > On 6/23/2023 9:52 AM, Rafael J. Wysocki wrote: > > On Wed, Jun 21, 2023 at 7:47 AM Evan Quan wrote: > >> From: Mario Limonciello > >> > >> Due to electrical and mechanical constraints in certain platform designs > >> there may be likely interference of relatively high-powered harmonics of > >> the (G-)DDR memory clocks with local radio module frequency bands used > >> by Wifi 6/6e/7. > >> > >> To mitigate this, AMD has introduced an ACPI based mechanism that > >> devices can use to notify active use of particular frequencies so > >> that devices can make relative internal adjustments as necessary > >> to avoid this resonance. > >> > >> In order for a device to support this, the expected flow for device > >> driver or subsystems: > >> > >> Drivers/subsystems contributing frequencies: > >> > >> 1) During probe, check `wbrf_supported_producer` to see if WBRF supported > > The prefix should be acpi_wbrf_ or acpi_amd_wbrf_ even, so it is clear > > that this uses ACPI and is AMD-specific. > > I guess if we end up with an intermediary library approach > wbrf_supported_producer makes sense and that could call acpi_wbrf_*. > > But with no intermediate library your suggestion makes sense. > > I would prefer not to make it acpi_amd as there is no reason that > this exact same problem couldn't happen on an > Wifi 6e + Intel SOC + AMD dGPU design too and OEMs could use the > same mitigation mechanism as Wifi6e + AMD SOC + AMD dGPU too. The mitigation mechanism might be the same, but the AML interface very well may be different. My point is that this particular interface is AMD-specific ATM and I'm not aware of any plans to make it "standard" in some way. Also if the given interface is specified somewhere, it would be good to have a pointer to that place. > > > > Whether or not there needs to be an intermediate library wrapped > > around this is a different matter. IMO individual drivers should not be expected to use this interface directly, as that would add to boilerplate code and overall bloat. Also whoever uses it, would first need to check if the device in question has an ACPI companion.