The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: "Tiwei Bie" <tiwei.btw@antgroup.com>
To: Johannes Berg <johannes@sipsolutions.net>,
	richard@nod.at, anton.ivanov@cambridgegreys.com
Cc: linux-um@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] um: Abandon the _PAGE_NEWPROT bit
Date: Fri, 11 Oct 2024 16:51:26 +0800	[thread overview]
Message-ID: <5f129f05-1d50-4076-aae6-99638dce35b9@antgroup.com> (raw)
In-Reply-To: <99d9e95fcb27160da5ff931fcfe16a07b3256574.camel@sipsolutions.net>

Hi Johannes,

On 2024/10/11 15:38, Johannes Berg wrote:
> Hi Tiwei,
> 
> So kind of a nit, but if the resulting code looks like this:
> 
>> @@ -184,17 +172,14 @@ static inline pte_t pte_wrprotect(pte_t pte)
>>  {
>>  	if (likely(pte_get_bits(pte, _PAGE_RW)))
>>  		pte_clear_bits(pte, _PAGE_RW);
>> 	return pte;
>>  }
> 
> then the if really isn't needed?
> 
> Same for all the others, I guess.

Makes sense. It looks a bit odd. Will drop the if. Thanks for the review!

Regards,
Tiwei

> 
> johannes


  reply	other threads:[~2024-10-11  8:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-11  5:38 [PATCH] um: Abandon the _PAGE_NEWPROT bit Tiwei Bie
2024-10-11  7:38 ` Johannes Berg
2024-10-11  8:51   ` Tiwei Bie [this message]
2024-10-11  7:39 ` Benjamin Berg
2024-10-11  8:53   ` Tiwei Bie

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=5f129f05-1d50-4076-aae6-99638dce35b9@antgroup.com \
    --to=tiwei.btw@antgroup.com \
    --cc=anton.ivanov@cambridgegreys.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-um@lists.infradead.org \
    --cc=richard@nod.at \
    /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