From: Ram Pai <linuxram@us.ibm.com>
To: Florian Weimer <fweimer@redhat.com>
Cc: linux-api@vger.kernel.org, dave.hansen@intel.com,
linuxppc-dev@lists.ozlabs.org, linux-mm@kvack.org
Subject: Re: pkeys: Reserve PKEY_DISABLE_READ
Date: Thu, 8 Nov 2018 11:22:26 -0800 [thread overview]
Message-ID: <20181108192226.GC5481@ram.oc3035372033.ibm.com> (raw)
In-Reply-To: <877ehnbwqy.fsf@oldenburg.str.redhat.com>
On Thu, Nov 08, 2018 at 01:05:09PM +0100, Florian Weimer wrote:
> Would it be possible to reserve a bit for PKEY_DISABLE_READ?
>
> I think the POWER implementation can disable read access at the hardware
> level, but not write access, and that cannot be expressed with the
> current PKEY_DISABLE_ACCESS and PKEY_DISABLE_WRITE bits.
POWER hardware can disable-read and can **also disable-write**
at the hardware level. It can disable-execute aswell at the
hardware level. For example if the key bits for a given key in the AMR
register is
0b01 it is read-disable
0b10 it is write-disable
To support access-disable, we make the key value 0b11.
So in case if you want to know if the key is read-disable 'bitwise-and' it
against 0x1. i.e (x & 0x1)
RP
next parent reply other threads:[~2018-11-08 19:28 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <877ehnbwqy.fsf@oldenburg.str.redhat.com>
2018-11-08 19:22 ` Ram Pai [this message]
2018-11-12 10:29 ` pkeys: Reserve PKEY_DISABLE_READ Florian Weimer
[not found] ` <2d62c9e2-375b-2791-32ce-fdaa7e7664fd@intel.com>
[not found] ` <87bm6zaa04.fsf@oldenburg.str.redhat.com>
[not found] ` <6f9c65fb-ea7e-8217-a4cc-f93e766ed9bb@intel.com>
[not found] ` <87k1ln8o7u.fsf@oldenburg.str.redhat.com>
2018-11-08 20:12 ` Ram Pai
2018-11-08 20:23 ` Florian Weimer
2018-11-09 18:09 ` Ram Pai
2018-11-12 12:00 ` Florian Weimer
2018-11-27 10:23 ` Ram Pai
2018-11-27 11:57 ` Florian Weimer
2018-11-27 15:31 ` Dave Hansen
2018-11-29 11:37 ` Florian Weimer
2018-12-03 4:02 ` Ram Pai
2018-12-03 15:52 ` Florian Weimer
2018-12-04 6:23 ` Ram Pai
2018-12-05 13:00 ` Florian Weimer
2018-12-05 20:23 ` Ram Pai
2018-12-05 16:21 ` Andy Lutomirski
2018-12-05 20:36 ` Ram Pai
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=20181108192226.GC5481@ram.oc3035372033.ibm.com \
--to=linuxram@us.ibm.com \
--cc=dave.hansen@intel.com \
--cc=fweimer@redhat.com \
--cc=linux-api@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linuxppc-dev@lists.ozlabs.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).