qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Huth <thuth@redhat.com>
To: "Philippe Mathieu-Daudé" <philmd@linaro.org>,
	qemu-devel@nongnu.org, "Paolo Bonzini" <pbonzini@redhat.com>
Cc: qemu-trivial@nongnu.org, Jason Wang <jasowang@redhat.com>,
	Gerd Hoffmann <kraxel@redhat.com>
Subject: Re: [PATCH] hw: Include the VMWare devices only in the x86 targets
Date: Tue, 13 Dec 2022 11:13:16 +0100	[thread overview]
Message-ID: <ccaea070-db7f-c25d-96ec-6a2471536a32@redhat.com> (raw)
In-Reply-To: <59a252ed-6cea-1966-97be-85e13a6e582f@linaro.org>

On 13/12/2022 11.01, Philippe Mathieu-Daudé wrote:
> On 13/12/22 10:51, Thomas Huth wrote:
>> It seems a little bit weird that the para-virtualized x86 VMWare
>> devices "vmware-svga" and "vmxnet3" also show up in non-x86 targets.
>> They are likely pretty useless there (since the guest OSes likely
>> do not have any drivers for those enabled), so let's change this and
>> only enable those devices by default for the classical x86 targets.
>>
>> Signed-off-by: Thomas Huth <thuth@redhat.com>
>> ---
>>   ...ate-Pseudo-encoding.txt => vnc-ledstate-pseudo-encoding.rst} | 0
>>   rename docs/interop/{vnc-ledstate-Pseudo-encoding.txt => 
>> vnc-ledstate-pseudo-encoding.rst} (100%)
>>
>> diff --git a/docs/interop/vnc-ledstate-Pseudo-encoding.txt 
>> b/docs/interop/vnc-ledstate-pseudo-encoding.rst
>> similarity index 100%
>> rename from docs/interop/vnc-ledstate-Pseudo-encoding.txt
>> rename to docs/interop/vnc-ledstate-pseudo-encoding.rst
> 
> Unrelated change ;)

Yeah, sorry, just noticed it after sending the patch ... please ignore that 
part.

>> diff --git a/hw/display/Kconfig b/hw/display/Kconfig
>> index a1b159becd..7b3da68d1c 100644
>> --- a/hw/display/Kconfig
>> +++ b/hw/display/Kconfig
>> @@ -55,7 +55,7 @@ config VGA_MMIO
>>   config VMWARE_VGA
>>       bool
>> -    default y if PCI_DEVICES
>> +    default y if PCI_DEVICES && PC_PCI
>>       depends on PCI
>>       select VGA
>> diff --git a/hw/net/Kconfig b/hw/net/Kconfig
>> index 6d795ec752..1cc1c5775e 100644
>> --- a/hw/net/Kconfig
>> +++ b/hw/net/Kconfig
>> @@ -51,7 +51,7 @@ config RTL8139_PCI
>>   config VMXNET3_PCI
>>       bool
>> -    default y if PCI_DEVICES
>> +    default y if PCI_DEVICES && PC_PCI
>>       depends on PCI
> 
> I'm not sure what PC_PCI is for, it seems inherited from the
> first Makefile conversion.
> 
> Are you sure you want to build this by default if the PC
> machine is selected? An user could select it an non-X86 arch.
> 
> Maybe we want:
> 
> -       depends on PCI
> +       depends on PCI && (I386 || X86_64)
> 
> ?

It does not seem to be a hard dependency - apparently the devices compile 
fine for non-x86 and I can also run:

  qemu-system-ppc64 -device vmware-vga -device vmxnet3

and the guest sees these two PCI devices - it just can't use them since it 
has no drivers.

So for the unlikely case that someone still wants to use these devices on 
non-x86 machines, I think it's better to add the test to the "default y" 
line instead of the "depends on" line, so that users still have a chance to 
enable it in their config file before compiling.

  Thomas



  reply	other threads:[~2022-12-13 10:14 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-13  9:51 [PATCH] hw: Include the VMWare devices only in the x86 targets Thomas Huth
2022-12-13 10:01 ` Philippe Mathieu-Daudé
2022-12-13 10:13   ` Thomas Huth [this message]
2022-12-13 10:15     ` Philippe Mathieu-Daudé
2022-12-13 10:02 ` Thomas Huth

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=ccaea070-db7f-c25d-96ec-6a2471536a32@redhat.com \
    --to=thuth@redhat.com \
    --cc=jasowang@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=philmd@linaro.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@nongnu.org \
    /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).