From: Thomas Huth <thuth@redhat.com>
To: Cornelia Huck <cornelia.huck@de.ibm.com>
Cc: qemu-devel@nongnu.org, Christian Borntraeger <borntraeger@de.ibm.com>
Subject: Re: [Qemu-devel] [PATCH] target/s390x/kvm: Fix problem when running with SELinux under z/VM
Date: Fri, 24 Mar 2017 10:53:19 +0100 [thread overview]
Message-ID: <45fd0904-be57-a3e3-bc2e-9218fc336e7b@redhat.com> (raw)
In-Reply-To: <20170324103837.60533aaf.cornelia.huck@de.ibm.com>
On 24.03.2017 10:38, Cornelia Huck wrote:
> On Fri, 24 Mar 2017 10:26:55 +0100
> Thomas Huth <thuth@redhat.com> wrote:
[...]
>> diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c
>> index ac47154..5167436 100644
>> --- a/target/s390x/kvm.c
>> +++ b/target/s390x/kvm.c
>> @@ -678,8 +678,7 @@ static void *legacy_s390_alloc(size_t size, uint64_t *align)
>> {
>> void *mem;
>>
>> - mem = mmap((void *) 0x800000000ULL, size,
>> - PROT_EXEC|PROT_READ|PROT_WRITE,
>> + mem = mmap((void *) 0x800000000ULL, size, PROT_READ | PROT_WRITE,
>> MAP_SHARED | MAP_ANONYMOUS | MAP_FIXED, -1, 0);
>> return mem == MAP_FAILED ? NULL : mem;
>> }
>
> Wouldn't it be better to adapt the SELinux rules?
I don't think that we want to change the default behavior of SELinux
here, since this is a security feature. Fortunately, there is already a
SELinux configuration variable available which can be used as a workaround:
setsebool virt_use_execmem 1
But still, it would be nicer, if things worked out of the box instead...
Thomas
next prev parent reply other threads:[~2017-03-24 9:53 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-24 9:26 [Qemu-devel] [PATCH] target/s390x/kvm: Fix problem when running with SELinux under z/VM Thomas Huth
2017-03-24 9:38 ` Cornelia Huck
2017-03-24 9:53 ` Thomas Huth [this message]
2017-03-24 9:39 ` Christian Borntraeger
2017-03-24 10:00 ` Thomas Huth
2017-03-29 14:21 ` Thomas Huth
2017-03-29 14:25 ` Christian Borntraeger
2017-09-15 14:36 ` Thomas Huth
2017-09-18 7:43 ` Christian Borntraeger
2017-09-19 12:38 ` David Hildenbrand
2017-09-19 12:48 ` Thomas Huth
2017-09-19 13:03 ` David Hildenbrand
2017-09-19 13:12 ` Thomas Huth
2017-09-19 13:14 ` David Hildenbrand
2017-09-19 13:15 ` Christian Borntraeger
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=45fd0904-be57-a3e3-bc2e-9218fc336e7b@redhat.com \
--to=thuth@redhat.com \
--cc=borntraeger@de.ibm.com \
--cc=cornelia.huck@de.ibm.com \
--cc=qemu-devel@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).