qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] smbios: stop ignoring command line options for


From: Leif Lindholm
Subject: Re: [Qemu-devel] [PATCH] smbios: stop ignoring command line options for TARGET_ARM
Date: Thu, 22 Dec 2016 15:18:31 +0000
User-agent: Mutt/1.5.23 (2014-03-12)

On Wed, Dec 21, 2016 at 06:58:44PM +0100, Paolo Bonzini wrote:
> On 21/12/2016 14:59, Igor Mammedov wrote:
> >> Apparently a misunderstanding of the underlying command line handling
> >> mechanics.
> >>
> >>> Also this patch would break build for targets that don't link smbios.c
> >>> (i.e. which don't have CONFIG_SMBIOS=y)  
> >> 
> >> Ah, I hadn't spotted that - apologies.
> > 
> > Just do 1 build for all targets before posting patches to avoid
> > such kind of errors.
> > 
> >> So a simpler, and more correct fix would rather be to change the
> >> #ifdef TARGET_I386
> >> in arch_init.c to
> >> #ifdef CONFIG_SMBIOS
> > 
> > it looks better to me than enumerating targets explicitly,
> > CCing Paolo for another opinion
> 
> I don't think CONFIG_SMBIOS is visible from C, is it?

No.
(A bit of context that was drop asked:
"... if there had been a conveniently available CONFIG_SMBIOS.
Would it be acceptable to add one to config-target.h or is that
reserved for host-specific options?"
But that doesn't matter now.)

> However, the solution is to:
> 
> 1) add a smbios-stub.c file to hw/smbios, containing a dummy
> implementation of smbios_entry_add.  For the Makefile magic see
> hw/pci/Makefile.objs.
> 
> 2) add an Error * argument to smbios_entry_add, and make the stub
> version fail
> 
> 3) remove do_smbios_option altogether, and make vl.c call
> smbios_entry_add directly.

Many thanks for the pointers, I've done just that and am sending it
out (as a new patch rather than a v2 because ... it bears no
resemblance to the first one).

Regards,

Leif



reply via email to

[Prev in Thread] Current Thread [Next in Thread]