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/
Home Products Support Community News


RE: [Xen-devel] [PATCH] Dom0 Kernel - Fixes forsaving/restoringMSI/MSI-X

To: Jan Beulich <jbeulich@xxxxxxxxxx>, "Tian, Kevin" <kevin.tian@xxxxxxxxx>
Subject: RE: [Xen-devel] [PATCH] Dom0 Kernel - Fixes forsaving/restoringMSI/MSI-X across Dom0 S3
From: "Shan, Haitao" <haitao.shan@xxxxxxxxx>
Date: Tue, 25 Nov 2008 09:21:38 +0800
Accept-language: en-US
Acceptlanguage: en-US
Cc: "'xen-devel@xxxxxxxxxxxxxxxxxxx'" <xen-devel@xxxxxxxxxxxxxxxxxxx>, 'Keir Fraser' <keir.fraser@xxxxxxxxxxxxx>
Delivery-date: Mon, 24 Nov 2008 17:23:12 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <492AD723.76E4.0078.0@xxxxxxxxxx>
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: <492AA0F0.76E4.0078.0@xxxxxxxxxx> <C5504899.2950B%keir.fraser@xxxxxxxxxxxxx> <0A882F4D99BBF6449D58E61AAFD7EDD601E23B69@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <492ABBAA.76E4.0078.0@xxxxxxxxxx> <0A882F4D99BBF6449D58E61AAFD7EDD601E23B6B@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <61563CE63B4F854986A895DA7AD3C17701FC5837@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> <492AD723.76E4.0078.0@xxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AclOScYT719ywQ34SQOIJYHdukRmXwAUTPgg
Thread-topic: [Xen-devel] [PATCH] Dom0 Kernel - Fixes forsaving/restoringMSI/MSI-X across Dom0 S3
I have checked the code again. I still can not find where AHCI driver finalize 
and reinitialize the MSI. The driver simply writes its internal registers so 
that the device does not *generate* interrupts and invoke pci_save_state (which 
will invoke our MSI code). Similar is the resume process.
For cannot-rebind-because-already-bound error, I do not mean it is the error 
cause by device rebinding MSI. It is us not the device driver that force 
unbinds MSI. After resume, no one does the rebinding work now.

Best Regards
Shan Haitao 

-----Original Message-----
From: Jan Beulich [mailto:jbeulich@xxxxxxxxxx] 
Sent: 2008年11月24日 23:33
To: Shan, Haitao; Tian, Kevin
Cc: 'Keir Fraser'; 'xen-devel@xxxxxxxxxxxxxxxxxxx'
Subject: RE: [Xen-devel] [PATCH] Dom0 Kernel - Fixes 
forsaving/restoringMSI/MSI-X across Dom0 S3

>>> "Shan, Haitao" <haitao.shan@xxxxxxxxx> 24.11.08 14:55 >>>
>Yes, clear enough as Kevin said. That is what I saw why S3 failed when AHCI is 
>enabled (AHCI uses MSI). I do not know whether it
>is also the reason that Jan sees the need to add force unbind support of MSI.
>I have another question for saving/restoring in Xen if we do not use a new 
>hypercall. Devices are controller by dom0. At the point
>Xen wants to save MSI during S3, dom0 may already places that device in D3hot 
>state, or it may also cease the device's function
>via pci_disable_device. I doubt whether Xen can read device MMIO at that time.

But - as asked before - shouldn't the device undergo full re-initialization 
after coming out of D3? Iirc, the AHCI/S3 bug results in a 
cannot-rebind-because-already-bound error, which would indicate to me that the 
driver tries to create a new binding, and hence doesn't really need the 
device's state saved (admitted, I didn't look closely at the driver's code so 
far). It instead may just need Xen to clean up its internal state properly. But 
really, I'm in no way a suspend/resume expert...


Xen-devel mailing list