From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yosuke Iwamatsu Subject: [PATCH] xend: save the state of PPCIs after hot-plug ([PATCH 4/5] Accept udev events and update physical resource information) Date: Tue, 24 Mar 2009 17:12:58 +0900 Message-ID: <49C8960A.6060306@ab.jp.nec.com> References: <49BA4209.1020702@ab.jp.nec.com> <49BA4C4D.2020703@ab.jp.nec.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Masaki Kanno Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Masaki Kanno wrote: > Hi Yosuke, > > I have a question. > > Need the patch call save_PPCIs at the end of add_PPCI and the end > of remove_PPCI? > It seems you are right. I generated a patch to do that. Thank you. -- Yosuke -------- xend: Save the state of PPCIs after hot-plug events. Signed-off-by: Yosuke Iwamatsu diff -r 0477f9061c8a tools/python/xen/xend/XendNode.py --- a/tools/python/xen/xend/XendNode.py Fri Mar 20 17:42:46 2009 +0000 +++ b/tools/python/xen/xend/XendNode.py Tue Mar 24 15:32:00 2009 +0900 @@ -363,6 +363,8 @@ ppci_uuid = saved_ppci_table.get(pci_dev.name, uuid.createString()) XendPPCI(ppci_uuid, ppci_record) + self.save_PPCIs() + def remove_PPCI(self, pci_name): # Update lspci info @@ -372,6 +374,8 @@ (domain, bus, slot, func) = PciUtil.parse_pci_name(pci_name) ppci_ref = XendPPCI.get_by_sbdf(domain, bus, slot, func) XendAPIStore.get(ppci_ref, "PPCI").destroy() + + self.save_PPCIs() def add_PSCSI(self):