All of lore.kernel.org
 help / color / mirror / Atom feed
From: will.deacon@arm.com (Will Deacon)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv3 2/2] arm64: Add CONFIG_DEBUG_SET_MODULE_RONX support
Date: Fri, 22 Aug 2014 16:45:38 +0100	[thread overview]
Message-ID: <20140822154537.GG17255@arm.com> (raw)
In-Reply-To: <53F38797.1050301@codeaurora.org>

Hi Laura,

On Tue, Aug 19, 2014 at 06:21:27PM +0100, Laura Abbott wrote:
> On 8/19/2014 5:11 AM, Will Deacon wrote:
> > On Wed, Aug 13, 2014 at 12:37:47AM +0100, Laura Abbott wrote:
> >> +static int __change_memory(pte_t *ptep, pgtable_t token, unsigned long addr,
> >> +			pgprot_t prot, bool set)
> >> +{
> >> +	pte_t pte;
> >> +
> >> +	if (set)
> >> +		pte = set_pte_bit(*ptep, prot);
> >> +	else
> >> +		pte = clear_pte_bit(*ptep, prot);
> >> +	set_pte(ptep, pte);
> >> +	return 0;
> >> +}
> > 
> > Why do we need to propagate the token this far?
> > 
> 
> Not quite sure I understand the comment here.

Sorry, I was reviewing patches on a plane and ended up being a bit too
terse. I basically don't understand why we have to pass the `token'
parameter to __change_memory as it appears to be unused.

> > What about UXN? (I don't have the ARM ARM to hand, but we may want to set
> > both)
> > 
> 
> Both PAGE_KERNEL and PAGE_KERNEL_EXEC already set PTE_UXN. It seems
> redundant to add it again given this is currently restricted to module
> addresses. It's cheap to add it though for paranoia's sake.

I missed that, so I think it's fine to leave this part as-is.

Will

      reply	other threads:[~2014-08-22 15:45 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-12 23:37 [PATCHv3 0/2] arm64 CONFIG_DEBUG_SET_MODULE_RONX support Laura Abbott
2014-08-12 23:37 ` [PATCHv3 1/2] arm64: Introduce {set,clear}_pte_bit Laura Abbott
2014-08-19 12:06   ` Will Deacon
2014-08-12 23:37 ` [PATCHv3 2/2] arm64: Add CONFIG_DEBUG_SET_MODULE_RONX support Laura Abbott
2014-08-19 12:11   ` Will Deacon
2014-08-19 17:21     ` Laura Abbott
2014-08-22 15:45       ` Will Deacon [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=20140822154537.GG17255@arm.com \
    --to=will.deacon@arm.com \
    --cc=linux-arm-kernel@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.