devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: David Woodhouse <dwmw2@infradead.org>
Cc: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>,
	Sudan Landge <sudanl@amazon.com>,
	tytso@mit.edu, Jason@zx2c4.com,
	krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org,
	sathyanarayanan.kuppuswamy@linux.intel.com,
	thomas.lendacky@amd.com, dan.j.williams@intel.com,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	graf@amazon.de, bchalios@amazon.es, xmarcalx@amazon.co.uk,
	ardb@kernel.org, benh <benh@kernel.crashing.org>
Subject: Re: [PATCH v1 0/4] virt: vmgenid: Add devicetree bindings support
Date: Wed, 20 Mar 2024 11:15:31 -0500	[thread overview]
Message-ID: <20240320161531.GA1810860-robh@kernel.org> (raw)
In-Reply-To: <38aad6c0e698c8e804694276d1762d61f2068ce8.camel@infradead.org>

On Wed, Mar 20, 2024 at 01:50:43PM +0000, David Woodhouse wrote:
> On Tue, 2024-03-19 at 16:24 +0100, Krzysztof Kozlowski wrote:
> > On 19/03/2024 15:32, Sudan Landge wrote:
> > > This small series of patches aims to add devicetree bindings support for
> > > the Virtual Machine Generation ID (vmgenid) driver.
> > > 
> > > Virtual Machine Generation ID driver was introduced in commit af6b54e2b5ba
> > > ("virt: vmgenid: notify RNG of VM fork and supply generation ID") as an
> > > ACPI only device.
> > > We would like to extend vmgenid to support devicetree bindings because:
> > > 1. A device should not be defined as an ACPI or DT only device.

This (and the binding patch) tells me nothing about what "Virtual 
Machine Generation ID driver" is and isn't really justification for 
"why".

> > 
> > Virtual stuff is not a device, so your first assumption or rationale is
> > not correct.
> > 
> > Virtual stuff can be ACPI only, because DT is not for Virtual stuff.
> 
> I strongly disagree with this.
> 
> Discovering things is what the device-tree is *for*.

DT/ACPI is for discovering what hardware folks failed to make 
discoverable. But here, both sides are software. Can't the software 
folks do better?

This is just the latest in $hypervisor bindings[1][2][3]. The value add 
must be hypervisors because every SoC vendor seems to be creating their 
own with their own interfaces.


> We don't want to add extra complexity and overhead on both host and
> guest side to make things discoverable in a *less* efficient way.
> 
> The device-tree isn't just a last-resort for when we can't possibly do
> things differently in a discoverable way. The device-tree is a first-
> class citizen and perfectly valid choice as a way to discover things.
> 
> We shouldn't be forcing people to turn things into PCI devices just to
> avoid adding DT bindings for them.
> 
> And we *certainly* shouldn't be directing people towards all the
> awfulness of ACPI, and in-kernel bytecode interpreters, and all that
> horridness, just because we don't want to use DT to... describe things.

I assume you have other calls into the hypervisor and notifications from 
the hypervisor? Are you going to add DT nodes for each one? I'd be more 
comfortable with DT describing THE communication channel with the 
hypervisor than what sounds like a singular function. Otherwise, what's 
the next binding?

Rob

[1] https://lore.kernel.org/all/20240222-gunyah-v17-2-1e9da6763d38@quicinc.com/
[2] https://lore.kernel.org/all/20240129083302.26044-4-yi-de.wu@mediatek.com/
[3] https://lore.kernel.org/all/20240127004321.1902477-2-davidai@google.com/

  reply	other threads:[~2024-03-20 16:15 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-19 14:32 [PATCH v1 0/4] virt: vmgenid: Add devicetree bindings support Sudan Landge
2024-03-19 14:32 ` [PATCH v1 1/4] virt: vmgenid: rearrange code to make review easier Sudan Landge
2024-03-19 14:32 ` [PATCH v1 2/4] virt: vmgenid: change implementation to use a platform driver Sudan Landge
2024-03-19 14:32 ` [PATCH v1 3/4] dt-bindings: Add bindings for vmgenid Sudan Landge
2024-03-19 15:28   ` Krzysztof Kozlowski
     [not found]     ` <f221da06-2a7c-4db3-a0de-870156865631@amazon.co.uk>
2024-03-20 10:24       ` Krzysztof Kozlowski
2024-03-20 12:16         ` Landge, Sudan
2024-03-19 14:32 ` [PATCH v1 4/4] virt: vmgenid: add support for devicetree bindings Sudan Landge
2024-03-19 15:30   ` Krzysztof Kozlowski
2024-03-20  8:14   ` kernel test robot
2024-03-20 13:35   ` kernel test robot
2024-03-20 16:54   ` kernel test robot
2024-03-21  1:10   ` kernel test robot
2024-03-19 15:24 ` [PATCH v1 0/4] virt: vmgenid: Add devicetree bindings support Krzysztof Kozlowski
2024-03-20 13:50   ` David Woodhouse
2024-03-20 16:15     ` Rob Herring [this message]
2024-03-20 16:55       ` David Woodhouse
2024-03-21 13:32         ` Rob Herring
2024-03-21 17:39           ` Landge, Sudan
2024-03-22  5:40             ` Krzysztof Kozlowski
2024-03-22  8:21               ` David Woodhouse
2024-03-22 13:22                 ` Rob Herring
2024-03-22 14:27                   ` David Woodhouse
2024-03-22 16:39                     ` Landge, Sudan
2024-03-19 15:32 ` Krzysztof Kozlowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240320161531.GA1810860-robh@kernel.org \
    --to=robh@kernel.org \
    --cc=Jason@zx2c4.com \
    --cc=ardb@kernel.org \
    --cc=bchalios@amazon.es \
    --cc=benh@kernel.crashing.org \
    --cc=conor+dt@kernel.org \
    --cc=dan.j.williams@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dwmw2@infradead.org \
    --cc=graf@amazon.de \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sathyanarayanan.kuppuswamy@linux.intel.com \
    --cc=sudanl@amazon.com \
    --cc=thomas.lendacky@amd.com \
    --cc=tytso@mit.edu \
    --cc=xmarcalx@amazon.co.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).