Received: by 2002:a05:7412:e794:b0:fa:551:50a7 with SMTP id o20csp235937rdd; Tue, 9 Jan 2024 02:27:27 -0800 (PST) X-Google-Smtp-Source: AGHT+IHd8V5SrDxJe/KXmHJ9ghsCydeQTxKMWWLYKabFVet5d391NGhZSV1xE4gUERqZLUO1az79 X-Received: by 2002:a05:6a20:1488:b0:199:f27a:86e6 with SMTP id o8-20020a056a20148800b00199f27a86e6mr626469pzi.115.1704796046638; Tue, 09 Jan 2024 02:27:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704796046; cv=none; d=google.com; s=arc-20160816; b=w7YuJBasyyFSBkDeoITo1R4H9YaJpUwKBXFt+mMMVKZPKZXw+7SbD522LZQK8jjPBt 5jsRIXPkLFguriTlDSVwtW/EZE/YnZ1fJgd/OoTHP4+XQ5veXQA4GZ03mlEfNs6maxMu JugvB/1IbgTW6gGMWHdv4ykC4FCn0NXg3bD4vD7HP9z4NjqPMz4F0q3fTZ3PkUs8AWFM eOyTI3zKVQcmWQ+8mWbYiQ07J1I4H/dMSMmiJIz5xgRFOtdRka4BQJBFpYJNz3c3iDn5 NI3cqYBy5FNVCRPoRfBFnN2jG8rfZhS6JsVAEfhyfzyDEUWTeyc5eHY2AB14Ps+cEZIF woMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=KqCs7xVcoH/Y335TS6+AvlQypI4PD3ESEDIAEMa+9Hk=; fh=UtmyC9Kbe1mFFrxOgSSWpa9kMKXMwYGrt4csT9Jm9jM=; b=RxsVbnu5PsdCI7GSbLIrCsYRaVZA5MUb4PsF1kjLpUbeDZk4vP75WzH/P4w69ggfdb BVHJB2z7OZK7HhBB8gyDATqQQgQB5IEk8SR9mS2M88YWx3C7Os3+jt2OXqUnbZnsEbDk hx0J5DtFxjsu25Sm/LMgeQ5i/nkANoazliXxP2ztgn35YG4xUZypgzuNjYipAmVUxrUz 4ZmVctwkjXlDnMPks76z0bcrfZ/d7HE1m/4Ad0MAfQ/Hn+2UM0WJZukCxAJQQea/HmfS HTXlpXiwncM5fzPwpY03kod6MPVf6U3PaUXIXiqBWVxlGIn9C8vd9f42yvzTU65I0MqO wsyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=VhkYgAMh; spf=pass (google.com: domain of linux-kernel+bounces-20716-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-20716-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id q20-20020a656254000000b005ce07e2dc79si1256318pgv.256.2024.01.09.02.27.26 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jan 2024 02:27:26 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-20716-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=VhkYgAMh; spf=pass (google.com: domain of linux-kernel+bounces-20716-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-20716-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 48437283A3A for ; Tue, 9 Jan 2024 10:27:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D1585360B1; Tue, 9 Jan 2024 10:27:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="VhkYgAMh" Received: from mail-lj1-f178.google.com (mail-lj1-f178.google.com [209.85.208.178]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6557C364C0 for ; Tue, 9 Jan 2024 10:27:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Received: by mail-lj1-f178.google.com with SMTP id 38308e7fff4ca-2cd33336b32so36156861fa.0 for ; Tue, 09 Jan 2024 02:27:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1704796019; x=1705400819; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=KqCs7xVcoH/Y335TS6+AvlQypI4PD3ESEDIAEMa+9Hk=; b=VhkYgAMhO7m5TnvRWFXeaN2j+exrFFMz8//NhnccrsQpqArRU14OviQGQvA1MwKXnr gqFoaFUaj9/R/5kFHRT9SnSjTWEHKis1grFmiExoXzBomhK7+m3JA9oqUkfR37s+MekT ECIdVndwnRfI3TwD8B17VCb07O2FKUDlDBf2U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704796019; x=1705400819; 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=KqCs7xVcoH/Y335TS6+AvlQypI4PD3ESEDIAEMa+9Hk=; b=LmHUD3m2RrwSIhGRj0CoLQc0N6zPJU8r1gYTbTKG0MDsyqWH4ByGbsr9vkBO3+5l/5 QA10yuq6HeYcBQZnOMIfJ36BsZl4g6rMuNLrZuEpjbDkoqYvxo1RxL9gicoBb0f43d/E i7i71gYK7wI22A1GV2kUYkHvSKiWhJU5QHHsa0xeXpxi66ysyxKk2YEE2ohKVDM/3VVd hYRoiYUptmSF9esXJhTxnF5ECzf5VqaD31X2fOPaLLrE8nUM0Gpa/d4cLuYEU170oQib nFbrOgK/YwsAag2hsaj8/JJLaeIPHAJSeeXNyIDPsCF+w36EBRZgVe9y3Wcw2IFhtK8O EvZQ== X-Gm-Message-State: AOJu0YyrTdC8yYseXXr6IvBJMKXvVJ1x2dqGIY3c9wcZ6b0FTmg/HVtl xzwkFYry+94cuVFjoSLvzGk2IN7LvWBjgY8x5Kzsvz7OdTQw X-Received: by 2002:a2e:c42:0:b0:2cc:9882:4cb5 with SMTP id o2-20020a2e0c42000000b002cc98824cb5mr2242827ljd.45.1704796019352; Tue, 09 Jan 2024 02:26:59 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240104130123.37115-1-brgl@bgdev.pl> <20240104130123.37115-9-brgl@bgdev.pl> <15443d5d-6544-45d0-afeb-b23e6a041ecf@quicinc.com> <87jzoizwz7.fsf@kernel.org> <87bk9uzum9.fsf@kernel.org> <5904461c-ca3c-4eb1-a44a-876872234545@app.fastmail.com> In-Reply-To: <5904461c-ca3c-4eb1-a44a-876872234545@app.fastmail.com> From: Chen-Yu Tsai Date: Tue, 9 Jan 2024 18:26:48 +0800 Message-ID: Subject: Re: [RFC 8/9] PCI/pwrseq: add a pwrseq driver for QCA6390 To: Arnd Bergmann Cc: Kalle Valo , Jeff Johnson , Bartosz Golaszewski , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Bjorn Andersson , Konrad Dybcio , Catalin Marinas , Will Deacon , Bjorn Helgaas , =?UTF-8?Q?Heiko_St=C3=BCbner?= , Jernej Skrabec , Chris Morgan , Linus Walleij , Geert Uytterhoeven , Neil Armstrong , =?UTF-8?B?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= , Marek Szyprowski , Peng Fan , Robert Richter , Dan Williams , Jonathan Cameron , Terry Bowman , Kuppuswamy Sathyanarayanan , =?UTF-8?Q?Ilpo_J=C3=A4rvinen?= , Huacai Chen , Alex Elder , Srinivas Kandagatla , Greg Kroah-Hartman , linux-wireless@vger.kernel.org, Netdev , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-pci@vger.kernel.org, Bartosz Golaszewski Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Jan 9, 2024 at 6:15=E2=80=AFPM Arnd Bergmann wrote: > > On Tue, Jan 9, 2024, at 11:09, Kalle Valo wrote: > > Chen-Yu Tsai writes: > >> On Tue, Jan 9, 2024 at 5:18=E2=80=AFPM Kalle Valo w= rote: > >>> Jeff Johnson writes: > >>> > >>> > On 1/4/2024 5:01 AM, Bartosz Golaszewski wrote: > >>> >> diff --git a/drivers/pci/pcie/pwrseq/Kconfig b/drivers/pci/pcie/pw= rseq/Kconfig > >>> >> index 010e31f432c9..f9fe555b8506 100644 > >>> >> --- a/drivers/pci/pcie/pwrseq/Kconfig > >>> >> +++ b/drivers/pci/pcie/pwrseq/Kconfig > >>> >> @@ -6,3 +6,14 @@ menuconfig PCIE_PWRSEQ > >>> >> help > >>> >> Say yes here to enable support for PCIe power sequencing > >>> >> drivers. > >>> >> + > >>> >> +if PCIE_PWRSEQ > >>> >> + > >>> >> +config PCIE_PWRSEQ_QCA6390 > >>> >> + tristate "PCIe Power Sequencing driver for QCA6390" > >>> >> + depends on ARCH_QCOM || COMPILE_TEST > >>> >> + help > >>> >> + Enable support for the PCIe power sequencing driver for the > >>> >> + ath11k module of the QCA6390 WLAN/BT chip. > >>> >> + > >>> >> +endif > >>> > > >>> > As I mentioned in the 5/9 patch I'm concerned that the current > >>> > definition of PCIE_PWRSEQ and PCIE_PWRSEQ_QCA6390 will effectively = hide > >>> > the fact that QCA6390 may need additional configuration since the m= enu > >>> > item will only show up if you have already enabled PCIE_PWRSEQ. > >>> > Yes I see that these are set in the defconfig in 9/9 but I'm concer= ned > >>> > about the more generic case. > >>> > > >>> > I'm wondering if there should be a separate config QCA6390 within a= th11k > >>> > which would then select PCIE_PWRSEQ and PCIE_PWRSEQ_QCA6390 > >>> > >>> Or is it possible to provide an optional dependency in Kconfig (I gue= ss > >> > >> imply PCIE_PWRSEQ > >> imply PCIE_PWRSEQ_QCA6390 > >> ? > > > > Nice, I had forgotten imply altogether. Would 'imply > > PCIE_PWRSEQ_QCA6390' in ath11k Kconfig be enough to address Jeff's > > concern? > > Please don't use imply (ever), it doesn't normally do > what you want. In this case, the only effect the > 'imply' has is to change the default of the PCIE_PWRSEQ_QCA6390 > option when a defconfig contains QCA6390. > > If this is indeed what you want, it's still better to do the > equivalent expression in PCIE_PWRSEQ_QCA6390 rather than ATH11K: > > config PCIE_PWRSEQ_QCA6390 > tristate "PCIe Power Sequencing driver for QCA6390" > default ATH11K && ARCH_QCOM PCIE_PWRSEQ_QCA6390 is also guarded by PCIE_PWRSEQ though. That would require the default statement to be duplicated to the PCIE_PWRSEQ option as well. Presumably we'd get a few more power sequencing drivers, and the list of default statements for PCIE_PWRSEQ would grow. If that's acceptable then Arnd's proposal plus duplicating it to PCIE_PWRSEQ should work as described. ChenYu