From: Zhao Liu <zhao1.liu@linux.intel.com>
To: Dave Hansen <dave.hansen@intel.com>
Cc: Sean Christopherson <seanjc@google.com>,
Paolo Bonzini <pbonzini@redhat.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>,
kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
"Fabio M. De Francesco" <fmdefrancesco@gmail.com>,
Ira Weiny <ira.weiny@intel.com>,
Zhenyu Wang <zhenyu.z.wang@intel.com>,
Zhao Liu <zhao1.liu@intel.com>
Subject: Re: [PATCH] KVM: SVM: Replace kmap_atomic() with kmap_local_page()
Date: Sun, 4 Sep 2022 23:54:15 +0800 [thread overview]
Message-ID: <YxTKJ0O3Gd6at5lH@liuzhao-OptiPlex-7080> (raw)
In-Reply-To: <e08c8c46-2aa8-3cb4-dce6-61d64c6835cb@intel.com>
On Fri, Sep 02, 2022 at 08:09:29AM -0700, Dave Hansen wrote:
> This changelog is a little on the weak side. You could literally take
> any arbitrary call-site and file for kmap_atomic() and slap that
> changelog on it. For instance:
>
> In drivers/target/target_core_sbc.c, the function
> sbc_dif_copy_prot() doesn't need to disable pagefaults and
> preemption in kmap_atomic(). It can simply use kmap_local_page()
> / kunmap_local() that can instead do the mapping / unmapping
> regardless of the context.
>
> With kmap_local_page(), the mapping is per thread, CPU local and
> not globally visible. Therefore, sbc_dif_copy_prot() is a
> function where the use of kmap_local_page() in place of
> kmap_atomic() is correctly suited.
>
> That's all valid English and there's nothing incorrect in it. But, it
> doesn't indicate that any actual analysis was performed. It's utterly
> generic. It could literally have been generated by a pretty trivial script.
>
> It would be great to add at least a small, call-site-specific human
> touch to these changelogs.
>
> In this case, saying something about how global the cache flush is would
> be a great addition.
Thanks Dave! I'll add more detail to the commit message and avoid overly
templated changelogs.
Zhao
next prev parent reply other threads:[~2022-09-04 15:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-02 9:08 Zhao Liu
2022-09-02 15:09 ` Dave Hansen
2022-09-04 15:54 ` Zhao Liu [this message]
2022-09-02 15:15 ` Sean Christopherson
2022-09-02 15:25 ` Dave Hansen
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=YxTKJ0O3Gd6at5lH@liuzhao-OptiPlex-7080 \
--to=zhao1.liu@linux.intel.com \
--cc=bp@alien8.de \
--cc=dave.hansen@intel.com \
--cc=fmdefrancesco@gmail.com \
--cc=hpa@zytor.com \
--cc=ira.weiny@intel.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=pbonzini@redhat.com \
--cc=seanjc@google.com \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--cc=zhao1.liu@intel.com \
--cc=zhenyu.z.wang@intel.com \
/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®