qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] qdev: obey no_user


From: Anthony Liguori
Subject: Re: [Qemu-devel] [PATCH] qdev: obey no_user
Date: Mon, 07 Jan 2013 14:12:09 -0600
User-agent: Notmuch/0.13.2+93~ged93d79 (http://notmuchmail.org) Emacs/23.3.1 (x86_64-pc-linux-gnu)

Peter Maydell <address@hidden> writes:

> On 7 January 2013 19:32, Anthony Liguori <address@hidden> wrote:
>> Christian Borntraeger <address@hidden> writes:
>>
>>> since
>>>
>>> commit 18b6dade8c0799c48f5c5e124b8c407cd5e22e96
>>> qdev: refactor device creation to allow bus_info to be set only in class
>>>
>>> A user can specify a device that is no_user.
>>> For example on my i386 box, I can add a 2nd kvmvapic device.
>>>
>>> This patch checks for no-user and rejects the device_add.
>>>
>>> Signed-off-by: Christian Borntraeger <address@hidden>
>>
>> I specifically broke this when QOM was introduced because no_user
>> precludes a management tool from constructing a machine directlt.
>
> You can't do that anyway...
>
>> The real problem you're trying to solve is that it's an error to have
>> two kvmvapic devices, not that users shouldn't be allowed to create them
>> via -device.
>
> That's not the only thing no-user gets used for. A bunch of the
> ARM sysbus devices have it set presumably because it's just
> flat impossible for a user to correctly create and wire in a sysbus
> device at all, so you might as well not confuse matters by listing
> them in '-device help' output. (We're not consistent about that,
> though.)
>
> It seems to me like arbitrarily allowing the monitor to construct
> no-user devices isn't really the right way to attack the problem
> of "allow complete machine construction by management tools"...

There is no such thing as a 'no-user' device.  It's a silly distinction
that has never had a consistent meaning.

There's really no good reason why kvmvapic isn't supported by -device
other than it was an implementation short cut.

Regards,

Anthony Liguori

>
> -- PMM




reply via email to

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