|
|
|
|
|
|
|
|
|
|
xen-devel
RE: [Xen-devel] [memory sharing] bug on get_page_and_type
To: |
xen devel <xen-devel@xxxxxxxxxxxxxxxxxxx> |
Subject: |
RE: [Xen-devel] [memory sharing] bug on get_page_and_type |
From: |
MaoXiaoyun <tinnycloud@xxxxxxxxxxx> |
Date: |
Wed, 9 Feb 2011 10:46:02 +0800 |
Cc: |
george.dunlap@xxxxxxxxxxxxx, tim.deegan@xxxxxxxxxx, juihaochiang@xxxxxxxxx |
Delivery-date: |
Tue, 08 Feb 2011 18:46:54 -0800 |
Envelope-to: |
www-data@xxxxxxxxxxxxxxxxxxx |
Importance: |
Normal |
In-reply-to: |
<20110202161837.GQ8286@xxxxxxxxxxxxxxxxxxxxxxx> |
List-help: |
<mailto:xen-devel-request@lists.xensource.com?subject=help> |
List-id: |
Xen developer discussion <xen-devel.lists.xensource.com> |
List-post: |
<mailto:xen-devel@lists.xensource.com> |
List-subscribe: |
<http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe> |
List-unsubscribe: |
<http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe> |
References: |
<BLU157-ds63E3E55F8D444780B613ADAE20@xxxxxxx>, <AANLkTika2afgs8hhdMD024PHGzDFsoWcOK7nJ7ePzG=z@xxxxxxxxxxxxxx>, <BLU157-w29AAD53D1BF4AF2892205EDAE20@xxxxxxx>, <AANLkTim4O6QXdAJedB1KhECpDhrq2w8FTDXn7irQtk2Y@xxxxxxxxxxxxxx>, <20110201142816.GE20638@xxxxxxxxxxxxxxxxxxxxxxx>, <BLU157-w243AEA6AA94C1835B206F4DAE40@xxxxxxx>, <20110202161837.GQ8286@xxxxxxxxxxxxxxxxxxxxxxx> |
Sender: |
xen-devel-bounces@xxxxxxxxxxxxxxxxxxx |
Hi Tim:
I've been looking into the TOCTOU issue quite a while, but
1) There are quite a lot judgements like "p2m_is_shared(p2mt)" or "p2mt == p2m_ram_shared",
which, for me, is hard to tell whom are need to be protect by p2m_lock and whom are not
So is there a rule to distinguish these?
2) Could we improve p2m_lock to sparse lock, which maybe better, right?
thanks.
> Date: Wed, 2 Feb 2011 16:18:37 +0000 > From: Tim.Deegan@xxxxxxxxxx > To: tinnycloud@xxxxxxxxxxx > CC: xen-devel@xxxxxxxxxxxxxxxxxxx; George.Dunlap@xxxxxxxxxxxxx; juihaochiang@xxxxxxxxx > Subject: Re: [Xen-devel] [memory sharing] bug on get_page_and_type > > At 15:43 +0000 on 02 Feb (1296661396), MaoXiaoyun wrote: > > Hi Tim: > > > > Thanks for both your advice and quick reply. I will follow. > > > > So at last we should replace shr_lock with p2m_lock. > > But more complicate, it seems both the > > *check action* code and *nominate page* code need to be locked ,right? > > If so, quite a lot of *check action* codes need to be locked. > > Yes, I think you're right about that. Unfortunately there are some very > long TOCTOU windows in those kind of p2m lookups, which will get more > important as the p2m gets more dynamic. I don't want to hav
e the > callers of p2m code touching the p2m lock directly so we may need a new > p2m interface to address it. > > Tim. >
|
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|