WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] deadlock in the credit2

To: george.dunlap@xxxxxxxxxxxxx
Subject: [Xen-devel] deadlock in the credit2
From: Eunbyung Park <silverbottlep@xxxxxxxxx>
Date: Fri, 14 Oct 2011 18:08:58 +0900
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Fri, 14 Oct 2011 02:12:51 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :content-type:content-transfer-encoding; bh=anx72C4CT0FW7k45ai48ZBvDSGU251b5ZysKPgC84yg=; b=FM9NBZr3becQGhkMCE9ULDAle11EGomQfgbbn83fkwuELuWCjC70i8ARYDmbfNHuZZ zjsvxCPCVtzh5nEKR3ylOwoF4VbsFAvYX1mp9NzNF4cvUdOSX8jHB1INO0Lbvd0tMvLX cegJmb2ydoDY6T5hN0Zk2H8UjDb0hhBeCHOts=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (Windows NT 6.1; rv:7.0.1) Gecko/20110929 Thunderbird/7.0.1
IMHO, it seems to be deadlock when changing dom0's weight in credit2
scheduler.

when the sched_adjust() in schedule.c is called, it grabs the
schedule_lock after pausing all of the vcpus

and then, csched_dom_cntl in sched_credit2.c, it also grab the
schedule_lock by using vcpu_schedule_lock_irq().

In the credit2, all of the percpu schedule_lock points out same runqueue
lock if they belong to same runqueue.

Eventually, all of vcpu are paused except for itself running the code,
and it try to grab schedule_lock that was grabbed by itself.

Am I right? If I was wrong, please tell me my misunderstanding.

And, I have a question about the code, where are in sched_adjust() in
schedule.c

if ( d == current->domain )
vcpu_schedule_lock_irq(current);

It was very hard to understan for me..:) What does it exactly mean?

I would be very grateful for any comments

-- 
Best Regards,
Eunbyung Park


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>