* Re: [patch 2/2] xen/arm: Use p2m entry with lock protection
@ 2019-04-30 16:21 ` Stefano Stabellini
0 siblings, 0 replies; 5+ messages in thread
From: Stefano Stabellini @ 2019-04-30 16:21 UTC (permalink / raw)
To: Hillf Danton; +Cc: xen-devel, Stefano Stabellini <sstabellini@kernel.org>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1247 bytes --]
On Tue, 30 Apr 2019, Hillf Danton wrote:
> A new local variable is introduced for accessing p2m entry with lock protection.
>
Same comment about html and space damage. But the change looks correct.
>
> Cc: Stefano Stabellini <sstabellini@kernel.org>
>
> Signed-off-by: Hillf Danton <hdanton@sina.com>
>
> ---
>
>
>
> --- a/arch/arm/xen/p2m.c 2019-04-30 12:32:05.363768200 +0800
>
> +++ b/arch/arm/xen/p2m.c 2019-04-30 12:58:19.854334100 +0800
>
> @@ -70,8 +70,9 @@ unsigned long __pfn_to_mfn(unsigned long
>
> entry = rb_entry(n, struct xen_p2m_entry, rbnode_phys);
>
> if (entry->pfn <= pfn &&
>
> entry->pfn + entry->nr_pages > pfn) {
>
> + unsigned long mfn = entry->mfn + (pfn - entry->pfn);
>
> read_unlock_irqrestore(&p2m_lock, irqflags);
>
> - return entry->mfn + (pfn - entry->pfn);
>
> + return mfn;
>
> }
>
> if (pfn < entry->pfn)
>
> n = n->rb_left;
>
> --
>
>
>
>
>
[-- Attachment #2: Type: text/plain, Size: 157 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Xen-devel] [patch 2/2] xen/arm: Use p2m entry with lock protection
@ 2019-04-30 16:21 ` Stefano Stabellini
0 siblings, 0 replies; 5+ messages in thread
From: Stefano Stabellini @ 2019-04-30 16:21 UTC (permalink / raw)
To: Hillf Danton; +Cc: xen-devel, Stefano Stabellini <sstabellini@kernel.org>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1247 bytes --]
On Tue, 30 Apr 2019, Hillf Danton wrote:
> A new local variable is introduced for accessing p2m entry with lock protection.
>
Same comment about html and space damage. But the change looks correct.
>
> Cc: Stefano Stabellini <sstabellini@kernel.org>
>
> Signed-off-by: Hillf Danton <hdanton@sina.com>
>
> ---
>
>
>
> --- a/arch/arm/xen/p2m.c 2019-04-30 12:32:05.363768200 +0800
>
> +++ b/arch/arm/xen/p2m.c 2019-04-30 12:58:19.854334100 +0800
>
> @@ -70,8 +70,9 @@ unsigned long __pfn_to_mfn(unsigned long
>
> entry = rb_entry(n, struct xen_p2m_entry, rbnode_phys);
>
> if (entry->pfn <= pfn &&
>
> entry->pfn + entry->nr_pages > pfn) {
>
> + unsigned long mfn = entry->mfn + (pfn - entry->pfn);
>
> read_unlock_irqrestore(&p2m_lock, irqflags);
>
> - return entry->mfn + (pfn - entry->pfn);
>
> + return mfn;
>
> }
>
> if (pfn < entry->pfn)
>
> n = n->rb_left;
>
> --
>
>
>
>
>
[-- Attachment #2: Type: text/plain, Size: 157 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [patch 2/2] xen/arm: Use p2m entry with lock protection
@ 2019-04-30 19:56 ` Stefano Stabellini
0 siblings, 0 replies; 5+ messages in thread
From: Stefano Stabellini @ 2019-04-30 19:56 UTC (permalink / raw)
To: Stefano Stabellini; +Cc: xen-devel, Hillf Danton
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1458 bytes --]
On Tue, 30 Apr 2019, Stefano Stabellini wrote:
> On Tue, 30 Apr 2019, Hillf Danton wrote:
> > A new local variable is introduced for accessing p2m entry with lock protection.
> >
>
> Same comment about html and space damage. But the change looks correct.
I fixed up the patches and committed both of them to the xentip tree.
> >
> > Cc: Stefano Stabellini <sstabellini@kernel.org>
> >
> > Signed-off-by: Hillf Danton <hdanton@sina.com>
> >
> > ---
> >
> >
> >
> > --- a/arch/arm/xen/p2m.c 2019-04-30 12:32:05.363768200 +0800
> >
> > +++ b/arch/arm/xen/p2m.c 2019-04-30 12:58:19.854334100 +0800
> >
> > @@ -70,8 +70,9 @@ unsigned long __pfn_to_mfn(unsigned long
> >
> > entry = rb_entry(n, struct xen_p2m_entry, rbnode_phys);
> >
> > if (entry->pfn <= pfn &&
> >
> > entry->pfn + entry->nr_pages > pfn) {
> >
> > + unsigned long mfn = entry->mfn + (pfn - entry->pfn);
> >
> > read_unlock_irqrestore(&p2m_lock, irqflags);
> >
> > - return entry->mfn + (pfn - entry->pfn);
> >
> > + return mfn;
> >
> > }
> >
> > if (pfn < entry->pfn)
> >
> > n = n->rb_left;
> >
> > --
> >
> >
> >
> >
> >
[-- Attachment #2: Type: text/plain, Size: 157 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Xen-devel] [patch 2/2] xen/arm: Use p2m entry with lock protection
@ 2019-04-30 19:56 ` Stefano Stabellini
0 siblings, 0 replies; 5+ messages in thread
From: Stefano Stabellini @ 2019-04-30 19:56 UTC (permalink / raw)
To: Stefano Stabellini; +Cc: xen-devel, Hillf Danton
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1458 bytes --]
On Tue, 30 Apr 2019, Stefano Stabellini wrote:
> On Tue, 30 Apr 2019, Hillf Danton wrote:
> > A new local variable is introduced for accessing p2m entry with lock protection.
> >
>
> Same comment about html and space damage. But the change looks correct.
I fixed up the patches and committed both of them to the xentip tree.
> >
> > Cc: Stefano Stabellini <sstabellini@kernel.org>
> >
> > Signed-off-by: Hillf Danton <hdanton@sina.com>
> >
> > ---
> >
> >
> >
> > --- a/arch/arm/xen/p2m.c 2019-04-30 12:32:05.363768200 +0800
> >
> > +++ b/arch/arm/xen/p2m.c 2019-04-30 12:58:19.854334100 +0800
> >
> > @@ -70,8 +70,9 @@ unsigned long __pfn_to_mfn(unsigned long
> >
> > entry = rb_entry(n, struct xen_p2m_entry, rbnode_phys);
> >
> > if (entry->pfn <= pfn &&
> >
> > entry->pfn + entry->nr_pages > pfn) {
> >
> > + unsigned long mfn = entry->mfn + (pfn - entry->pfn);
> >
> > read_unlock_irqrestore(&p2m_lock, irqflags);
> >
> > - return entry->mfn + (pfn - entry->pfn);
> >
> > + return mfn;
> >
> > }
> >
> > if (pfn < entry->pfn)
> >
> > n = n->rb_left;
> >
> > --
> >
> >
> >
> >
> >
[-- Attachment #2: Type: text/plain, Size: 157 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* [patch 2/2] xen/arm: Use p2m entry with lock protection
@ 2019-04-30 5:37 Hillf Danton
0 siblings, 0 replies; 5+ messages in thread
From: Hillf Danton @ 2019-04-30 5:37 UTC (permalink / raw)
To: xen-devel; +Cc: Stefano Stabellini <sstabellini@kernel.org>
[-- Attachment #1.1: Type: text/plain, Size: 727 bytes --]
A new local variable is introduced for accessing p2m entry with lock protection.
Cc: Stefano Stabellini <sstabellini@kernel.org>
Signed-off-by: Hillf Danton <hdanton@sina.com>
---
--- a/arch/arm/xen/p2m.c 2019-04-30 12:32:05.363768200 +0800
+++ b/arch/arm/xen/p2m.c 2019-04-30 12:58:19.854334100 +0800
@@ -70,8 +70,9 @@ unsigned long __pfn_to_mfn(unsigned long
entry = rb_entry(n, struct xen_p2m_entry, rbnode_phys);
if (entry->pfn <= pfn &&
entry->pfn + entry->nr_pages > pfn) {
+ unsigned long mfn = entry->mfn + (pfn - entry->pfn);
read_unlock_irqrestore(&p2m_lock, irqflags);
- return entry->mfn + (pfn - entry->pfn);
+ return mfn;
}
if (pfn < entry->pfn)
n = n->rb_left;
--
[-- Attachment #1.2: Type: text/html, Size: 3233 bytes --]
[-- Attachment #2: Type: text/plain, Size: 157 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2019-04-30 19:57 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20190430053741.F1C0C2080C@mail.kernel.org>
2019-04-30 16:21 ` [patch 2/2] xen/arm: Use p2m entry with lock protection Stefano Stabellini
2019-04-30 16:21 ` [Xen-devel] " Stefano Stabellini
2019-04-30 19:56 ` Stefano Stabellini
2019-04-30 19:56 ` [Xen-devel] " Stefano Stabellini
2019-04-30 5:37 Hillf Danton
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.