Received: by 2002:ab2:6d45:0:b0:1fb:d597:ff75 with SMTP id d5csp473317lqr; Wed, 5 Jun 2024 11:10:30 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVdg4Tuka5AnYskKAoMq/aakq6GSp8r4TkisGDJn3RgI+fQnas8DGwQWCrnbSpusDiXb59N5LvpUMqGgsI/083TqGeK5B+ZAUEhSXSoOQ== X-Google-Smtp-Source: AGHT+IHmATVtaZNWjhC+armhN3A7IBgtEl5mAYkbPpJVJtby+OKpwI4R3fdQsAyHGX38Ho6KDQ0m X-Received: by 2002:a05:6214:5906:b0:6a0:c962:a2be with SMTP id 6a1803df08f44-6b02bf8380fmr41581376d6.39.1717611030522; Wed, 05 Jun 2024 11:10:30 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717611030; cv=pass; d=google.com; s=arc-20160816; b=TZzk/q5SL6yZ9yVCpVd9BHJhe+JfT+/RFHfKRBUl9NsBwBfYST/jbr1aJbwT/q3YFk PzzUAW+3uBeJemPPMaD/0t2UpsiMZgqdzLbfqMvhvWb2hHqON6ZQEwf1SexY1+BBVTVo PidoxkuZ8IrHMGTB+bXor5hZK3CtXwOMfcE4xpnY1+sc8meXSgApPJiWta/QnfxHnklo TZquL676LkZ4MLBdpty70tqiMNvF3VzA3Z+Qx2yZubTS8YZPjRoVx7kldGMgp/xnzmGZ L5wCNy/vFo+MCkF1tRl0I+ux+wfno051yC4swbJdm4qR4J532DaTLo5M5Hy9KL+FH2c0 kUKw== ARC-Message-Signature: i=2; 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=ox0cTDoj9EAdvqJSQWodBv8pPoGx05u+NIZ/qY+c1Hw=; fh=u6KoVfmcTqiDg6OBb1TfyeRl1bI44Q/9d4BgpezKai4=; b=VqkwkrPymLZU0B/XCKBjLcxxMG46mUm8jVEBJmVBf1UAWqm8C47RcJNnqntVja1Svb iBXTgt5pXDYT3L9xsJd7csN/SSG2aeTyass1XbCHlpG1DUVaSP756qyI/W6sUb3dv7PH 0BpBpa3yCObF81sg57ycEfiFSQg7HbfuMpz37/2UNN9oH2A6ZNcYkII1H71MeNei+5w3 eXUcvXrfS0V+sTo//iJ2Vc+rTwthwgPYYRkoidxDsmijDxCfHdqNlcMtOmc6tHEMskqe wPkqImsFu9mMkX9j9KFpMGx7diJVJe3CUNR4ANb0imAOn84DSQ2K/y3utavockELBfWF 2czA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@bgdev-pl.20230601.gappssmtp.com header.s=20230601 header.b=MlehV81c; arc=pass (i=1 dkim=pass dkdomain=bgdev-pl.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-wireless+bounces-8572-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-8572-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id 6a1803df08f44-6ae4b43ebf2si27215166d6.614.2024.06.05.11.10.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 Jun 2024 11:10:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless+bounces-8572-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20230601.gappssmtp.com header.s=20230601 header.b=MlehV81c; arc=pass (i=1 dkim=pass dkdomain=bgdev-pl.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-wireless+bounces-8572-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-wireless+bounces-8572-linux.lists.archive=gmail.com@vger.kernel.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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 336A11C22FAA for ; Wed, 5 Jun 2024 18:10:30 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C084ADDD2; Wed, 5 Jun 2024 18:04:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b="MlehV81c" X-Original-To: linux-wireless@vger.kernel.org Received: from mail-lj1-f175.google.com (mail-lj1-f175.google.com [209.85.208.175]) (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 A27C617555 for ; Wed, 5 Jun 2024 18:04:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.175 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717610670; cv=none; b=LAPLD6T+/JGZLA8e2m8+Ia6LuEgGv8Z7pg86YiSUoc0lbgOls+hQ3jaihqf3O02NhP1nioq/1qAkc4CQXZqJu4ywHDDX8pbrETxOFeIxX07F3nB3iU1N7lLaIJm5S+KCbT3xARvllWvLB8TN+wirm9aXlxJnxH4BsKbdUMXOF1A= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717610670; c=relaxed/simple; bh=s8KVP578g4tIAvF7jUKxEjt/8ys8vUdXttVcAIBlKWM=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=Mq1q+h5vx2HtboYksCY6Lwa/iq1tTVMdgUsBeOuIkvbd9Eo9hYuv0Mib1Mr0H/HUfopNWuecYkhAyzd7XBSnKflCWs83ejrpqzKGjzqD7jQNnkfm3jQ17dX0KXzVluB3s3oxdfRyD0fhgezJUH5OvxBzJ1hvb5R/lqZoh8FZAUg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl; spf=none smtp.mailfrom=bgdev.pl; dkim=pass (2048-bit key) header.d=bgdev-pl.20230601.gappssmtp.com header.i=@bgdev-pl.20230601.gappssmtp.com header.b=MlehV81c; arc=none smtp.client-ip=209.85.208.175 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=bgdev.pl Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=bgdev.pl Received: by mail-lj1-f175.google.com with SMTP id 38308e7fff4ca-2eaafda3b90so1539781fa.0 for ; Wed, 05 Jun 2024 11:04:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20230601.gappssmtp.com; s=20230601; t=1717610667; x=1718215467; 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=ox0cTDoj9EAdvqJSQWodBv8pPoGx05u+NIZ/qY+c1Hw=; b=MlehV81c+11vhzUjBsl7/PQu+rxcZy6u+ypfU2se7cXJWojH1uKKOsllA5AFp6Gt4Y sMlf0tNoqFB374baOdRT6/Q8mb1nH8A9QDIsd9f4LPfMTttMR2MviXjLQhF+llWPtB1D L4SmR4X+KRLqAWuBfrRnEnFhDn/QH6uH4ZZ+5Iipi5RObbqsWrPkZoagZysf50bQh29s NJD1k4FMNIRVKMSSThaLRyWhIEwEZU8rTjTj05xtSN9H/LjOAEQn5OrIZnsxhTWZl1Ic +U1R2dO5EV0KnDqDLrH7FgVOI8wP8VgwFhmGkXLFEBj+VE5AFDlTPhqev7Z0bnSMox0J NAqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717610667; x=1718215467; 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=ox0cTDoj9EAdvqJSQWodBv8pPoGx05u+NIZ/qY+c1Hw=; b=jzJYRr4fmR/hSoY53hnEZDyKfjrNqbc7HUMTiwuQNaTjpGLt5E5S27lYCFA6/t0/zL 3EhqZVjvODok1lqFTpVTNe4zoXPYBkpIJ7u7IKP6Vs0GN5Pg2EW4vvBwXmnJB0uFTXxU rUozoItJc55d5zgoDOZPtdu3XY7YougYxsNuumReHkJGSccAftPKNFad/LFjJef/QoPT U5QTdQ1g5QEvvZVaBhg23Ssdmelr4wakOPwKlb/kaEVkKda4PPxiKlbTiWBRDl14cSBG yvghcanmjy5B4JPeCoyybcz5BW5D+2zPpS+r753Yibc5nECdFSMBcnI84o0kdksih2mj A9uQ== X-Forwarded-Encrypted: i=1; AJvYcCX099ml2lLohtWO3sXPJ4j17su0/jL+XZtrhnO8qH/XZvzbL942CeX2muwSJM7+OOShP8c+WDZdqEW9dR1kt2wcthMLXah8+U/0xMJrvkg= X-Gm-Message-State: AOJu0Yy0w4Zrmq1ws5fFzGf0KfC64VScQg8zXuE10dDBD9mzJ/LT/89u DFHYIoNmpzLq9THL7zkPMw4g9kgaOgS858F90etSqYRS0P6QtrQ//PZewVrOx5GrWIDZ7WQuico Est61rntGmx9gnkzIz6SpYvgIEAXMu79GGtW7OA== X-Received: by 2002:a2e:b00a:0:b0:2ea:7726:4a77 with SMTP id 38308e7fff4ca-2eac7a72b8emr19843541fa.35.1717610666844; Wed, 05 Jun 2024 11:04:26 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240605174713.GA767261@bhelgaas> In-Reply-To: <20240605174713.GA767261@bhelgaas> From: Bartosz Golaszewski Date: Wed, 5 Jun 2024 20:04:15 +0200 Message-ID: Subject: Re: [PATCH v8 16/17] PCI/pwrctl: add a PCI power control driver for power sequenced devices To: Bjorn Helgaas Cc: Dmitry Baryshkov , Liam Girdwood , Mark Brown , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Marcel Holtmann , Luiz Augusto von Dentz , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Balakrishna Godavarthi , Rocky Liao , Kalle Valo , Jeff Johnson , Bjorn Andersson , Konrad Dybcio , Bjorn Helgaas , Srini Kandagatla , Elliot Berman , Caleb Connolly , Neil Armstrong , Alex Elder , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org, linux-wireless@vger.kernel.org, ath11k@lists.infradead.org, Jeff Johnson , ath12k@lists.infradead.org, linux-pm@vger.kernel.org, linux-pci@vger.kernel.org, Bartosz Golaszewski , kernel@quicinc.com, Amit Pundir Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Jun 5, 2024 at 7:47=E2=80=AFPM Bjorn Helgaas w= rote: > > > > > > > wifi@0 { > > > compatible =3D "pci17cb,1101", "wlan-pwrseq"; > > > > What even is "pwrseq" in the context of the hardware description? DT > > maintainers would like to have a word with you. :) > > There are "compatible" strings like "simple-bus", "simple-mfd", and > "syscon" that allow drivers to bind and provide generic functionality > when they don't need to know the exact hardware. > There's a difference however: a "simple bus" is a thing. A "simple multifunction device" is also an actual thing. A "pwrseq" or "power-sequencer" is not a thing, it's a functionality. And we don't describe it in device-tree. Rob has said before that he regrets having merged the mmc pwrseq bindings back in the day and that he wouldn't do it again now because it describes what HW does and not what it is. In this case the PMU is simply a PMIC and the bindings I'm proposing describe it as such. But what you're proposing is even worse: this is the ath1x module of the larger chipset (power sequencee rather than sequencer) so naming it "wlan-pwrseq" makes absolutely no sense at all. It's a PCI device whose ID is 0x17cb1101 and the device tree describes it as such. > > > and pci_pwrctl_pwrseq_of_match[] had this: > > > > > > { .compatible =3D "wlan-pwrseq", .data =3D "wlan", } > > > > > > Wouldn't this pci-pwrctl-pwrseq driver work the same? I'm not a DT > > > whiz, so likely I'm missing something, but it would be nice if we > > > didn't have to update this very generic-looking driver to add every > > > device that needs it. > > Do you have any other ideas to reduce the churn in this file? It just > seems weird to have to add an ID to this file without adding any > actual code or data related to it. > Is it really that much churn though? You'd save 4 lines of code? I think this is premature optimization, we'll see about unifying it when we have several models supported, right now with two, I'd just leave it as is and not seek perfection. > We should probably also add a pattern to MAINTAINERS so > get_maintainers.pl on this file will show you as a maintainer. > Makes sense. Bartosz > Bjorn