From: Juergen Gross <jgross@suse.com>
To: Boris Ostrovsky <boris.ostrovsky@oracle.com>,
linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org
Cc: gregkh@linuxfoundation.org
Subject: Re: [PATCH v3 4/4] xen: add sysfs node for hypervisor build id
Date: Wed, 14 Jun 2017 17:06:21 +0200 [thread overview]
Message-ID: <b3af9873-3100-3c8a-7d7c-3ac0cba92ac1@suse.com> (raw)
In-Reply-To: <7dda9b9a-2335-3484-6170-2bb621c82a0a@oracle.com>
On 14/06/17 17:00, Boris Ostrovsky wrote:
> On 06/12/2017 10:21 AM, Juergen Gross wrote:
>> For support of Xen hypervisor live patching the hypervisor build id is
>> needed. Add a node /sys/hypervisor/properties/buildid containing the
>> information.
>>
>> Signed-off-by: Juergen Gross <jgross@suse.com>
>> ---
>> Documentation/ABI/testing/sysfs-hypervisor-xen | 11 +++++++++-
>> drivers/xen/sys-hypervisor.c | 29 ++++++++++++++++++++++++++
>> 2 files changed, 39 insertions(+), 1 deletion(-)
>>
>> diff --git a/Documentation/ABI/testing/sysfs-hypervisor-xen b/Documentation/ABI/testing/sysfs-hypervisor-xen
>> index c0edb3fdd6eb..53b7b2ea7515 100644
>> --- a/Documentation/ABI/testing/sysfs-hypervisor-xen
>> +++ b/Documentation/ABI/testing/sysfs-hypervisor-xen
>> @@ -1,5 +1,5 @@
>> What: /sys/hypervisor/guest_type
>> -Date: May 2017
>> +Date: June 2017
>> KernelVersion: 4.13
>> Contact: xen-devel@lists.xenproject.org
>> Description: If running under Xen:
>> @@ -32,3 +32,12 @@ Description: If running under Xen:
>> Describes Xen PMU features (as an integer). A set bit indicates
>> that the corresponding feature is enabled. See
>> include/xen/interface/xenpmu.h for available features
>> +
>> +What: /sys/hypervisor/properties/buildid
>> +Date: June 2017
>> +KernelVersion: 4.13
>> +Contact: xen-devel@lists.xenproject.org
>> +Description: If running under Xen:
>> + Build id of the hypervisor, needed for hypervisor live patching.
>> + Might return "<denied>" in case of special security settings
>> + in the hypervisor.
>
> It might? I don't see xen_deny() calls in XENVER_build_id (as I said
> below, assuming that's the command you are using).
>
>> diff --git a/drivers/xen/sys-hypervisor.c b/drivers/xen/sys-hypervisor.c
>> index d641e9970d5d..92307636ed54 100644
>> --- a/drivers/xen/sys-hypervisor.c
>> +++ b/drivers/xen/sys-hypervisor.c
>> @@ -339,12 +339,41 @@ static ssize_t features_show(struct hyp_sysfs_attr *attr, char *buffer)
>>
>> HYPERVISOR_ATTR_RO(features);
>>
>> +static ssize_t buildid_show(struct hyp_sysfs_attr *attr, char *buffer)
>> +{
>> + ssize_t ret;
>> + struct xen_build_id dummy;
>> + struct xen_build_id *buildid;
>> +
>> + dummy.len = 0;
>> + ret = HYPERVISOR_xen_version(XENVER_get_features, &dummy);
>
> Why XENVER_get_features and not XENVER_build_id?
The patch is looking different in my local tree. I might have missed to
do a commit before creating the patch via git format-patch. Will resend.
Juergen
prev parent reply other threads:[~2017-06-14 15:06 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-12 14:21 [PATCH v3 0/4] xen: add xen sysfs nodes Juergen Gross
2017-06-12 14:21 ` [PATCH v3 1/4] doc,xen: document hypervisor sysfs nodes for xen Juergen Gross
2017-06-14 14:38 ` Boris Ostrovsky
2017-06-14 19:06 ` Stefano Stabellini
2017-06-12 14:21 ` [PATCH v3 2/4] xen: add sysfs node for guest type Juergen Gross
2017-06-14 14:48 ` Boris Ostrovsky
2017-06-14 15:00 ` Juergen Gross
2017-06-14 15:01 ` Boris Ostrovsky
2017-06-14 15:09 ` Juergen Gross
2017-06-12 14:21 ` [PATCH v3 3/4] xen: sync include/xen/interface/version.h Juergen Gross
2017-06-14 14:50 ` Boris Ostrovsky
2017-06-12 14:21 ` [PATCH v3 4/4] xen: add sysfs node for hypervisor build id Juergen Gross
2017-06-14 15:00 ` Boris Ostrovsky
2017-06-14 15:06 ` Juergen Gross [this message]
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=b3af9873-3100-3c8a-7d7c-3ac0cba92ac1@suse.com \
--to=jgross@suse.com \
--cc=boris.ostrovsky@oracle.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=xen-devel@lists.xenproject.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
all inboxes | Powered by JetHome®