qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Halil Pasic <pasic@linux.vnet.ibm.com>
To: Thomas Huth <thuth@redhat.com>,
	qemu-devel@nongnu.org, Cornelia Huck <cohuck@redhat.com>,
	Christian Borntraeger <borntraeger@de.ibm.com>
Cc: Eric Farman <farman@linux.vnet.ibm.com>,
	Janosch Frank <frankja@linux.vnet.ibm.com>,
	Yi Min Zhao <zyimin@linux.vnet.ibm.com>,
	Jason J Herne <jjherne@linux.vnet.ibm.com>,
	Pierre Morel <pmorel@linux.vnet.ibm.com>,
	Farhan Ali <alifm@linux.vnet.ibm.com>,
	Jing Liu <liujbjl@linux.vnet.ibm.com>,
	Claudio Imbrenda <imbrenda@linux.vnet.ibm.com>,
	QingFeng Hao <haoqf@linux.vnet.ibm.com>,
	Xiao Feng Ren <renxiaof@linux.vnet.ibm.com>,
	Fei Li <sherrylf@linux.vnet.ibm.com>,
	Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com>,
	Yang Chen <bjcyang@linux.vnet.ibm.com>
Subject: Re: [Qemu-devel] [PATCH] hw/s390x/sclp: Mark the sclp device with user_creatable = false
Date: Wed, 4 Oct 2017 16:56:46 +0200	[thread overview]
Message-ID: <65835b70-98da-f8aa-15f6-e893947b5eb0@linux.vnet.ibm.com> (raw)
In-Reply-To: <1507125199-22562-1-git-send-email-thuth@redhat.com>



On 10/04/2017 03:53 PM, Thomas Huth wrote:
> The "sclp" device is just an internal device that can not be instantiated
> by the users. If they try to use it, they only get a simple error message:
> 
> $ qemu-system-s390x -nographic -device sclp
> qemu-system-s390x: Option '-device s390-sclp-event-facility' cannot be
> handled by this machine
> 
> Since sclp_init() tries to create a TYPE_SCLP_EVENT_FACILITY which is
> a non-pluggable sysbus device, there is really no way that the "sclp"
> device can be used by the user, so let's set the user_creatable = false
> accordingly.
> 
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> 

While I'm not really familiar with the sclp code, I do understand the
measure (user_creatable = false), but I'm not sure I understand the
explanation. So it's:

Acked-by: Halil Pasic <pasic@linux.vnet.ibm.com>

---
>  hw/s390x/sclp.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/hw/s390x/sclp.c b/hw/s390x/sclp.c
> index 30aefbf..9be0cb8 100644
> --- a/hw/s390x/sclp.c
> +++ b/hw/s390x/sclp.c
> @@ -606,6 +606,11 @@ static void sclp_class_init(ObjectClass *oc, void *data)
>      dc->realize = sclp_realize;
>      dc->hotpluggable = false;
>      set_bit(DEVICE_CATEGORY_MISC, dc->categories);
> +    /*
> +     * Reason: Creates TYPE_SCLP_EVENT_FACILITY in sclp_init
> +     * which is a non-pluggable sysbus device
> +     */
> +    dc->user_creatable = false;
> 
>      sc->read_SCP_info = read_SCP_info;
>      sc->read_storage_element0_info = read_storage_element0_info;
> 

  parent reply	other threads:[~2017-10-04 14:57 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-04 13:53 [Qemu-devel] [PATCH] hw/s390x/sclp: Mark the sclp device with user_creatable = false Thomas Huth
2017-10-04 14:00 ` Claudio Imbrenda
2017-10-04 14:22 ` Farhan Ali
2017-10-04 14:56 ` Halil Pasic [this message]
2017-10-04 15:18 ` Pierre Morel
2017-10-04 15:42   ` Cornelia Huck
2017-10-04 17:06   ` Thomas Huth
2017-10-05  8:14     ` Cornelia Huck
2017-10-05  8:04 ` Cornelia Huck

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=65835b70-98da-f8aa-15f6-e893947b5eb0@linux.vnet.ibm.com \
    --to=pasic@linux.vnet.ibm.com \
    --cc=alifm@linux.vnet.ibm.com \
    --cc=bjcyang@linux.vnet.ibm.com \
    --cc=bjsdjshi@linux.vnet.ibm.com \
    --cc=borntraeger@de.ibm.com \
    --cc=cohuck@redhat.com \
    --cc=farman@linux.vnet.ibm.com \
    --cc=frankja@linux.vnet.ibm.com \
    --cc=haoqf@linux.vnet.ibm.com \
    --cc=imbrenda@linux.vnet.ibm.com \
    --cc=jjherne@linux.vnet.ibm.com \
    --cc=liujbjl@linux.vnet.ibm.com \
    --cc=pmorel@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=renxiaof@linux.vnet.ibm.com \
    --cc=sherrylf@linux.vnet.ibm.com \
    --cc=thuth@redhat.com \
    --cc=zyimin@linux.vnet.ibm.com \
    /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).