[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 01/11] xen/manage: keep track of the on-going suspend mode
- To: Anchal Agarwal <anchalag@xxxxxxxxxx>
- From: boris.ostrovsky@xxxxxxxxxx
- Date: Tue, 22 Sep 2020 12:18:05 -0400
- Cc: tglx@xxxxxxxxxxxxx, mingo@xxxxxxxxxx, bp@xxxxxxxxx, hpa@xxxxxxxxx, x86@xxxxxxxxxx, jgross@xxxxxxxx, linux-pm@xxxxxxxxxxxxxxx, linux-mm@xxxxxxxxx, kamatam@xxxxxxxxxx, sstabellini@xxxxxxxxxx, konrad.wilk@xxxxxxxxxx, roger.pau@xxxxxxxxxx, axboe@xxxxxxxxx, davem@xxxxxxxxxxxxx, rjw@xxxxxxxxxxxxx, len.brown@xxxxxxxxx, pavel@xxxxxx, peterz@xxxxxxxxxxxxx, eduval@xxxxxxxxxx, sblbir@xxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, vkuznets@xxxxxxxxxx, netdev@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, dwmw@xxxxxxxxxxxx, benh@xxxxxxxxxxxxxxxxxxx
- Delivery-date: Tue, 22 Sep 2020 16:18:59 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 9/21/20 5:54 PM, Anchal Agarwal wrote:
> Thanks for the above suggestion. You are right I didn't find a way to declare
> a global state either. I just broke the above check in 2 so that once we have
> support for ARM we should be able to remove aarch64 condition easily. Let me
> know if I am missing nay corner cases with this one.
>
> static int xen_pm_notifier(struct notifier_block *notifier,
> unsigned long pm_event, void *unused)
> {
> int ret = NOTIFY_OK;
> if (!xen_hvm_domain() || xen_initial_domain())
> ret = NOTIFY_BAD;
> if(IS_ENABLED(CONFIG_ARM64) && (pm_event == PM_SUSPEND_PREPARE ||
> pm_event == HIBERNATION_PREPARE))
> ret = NOTIFY_BAD;
>
> return ret;
> }
This will allow PM suspend to proceed on x86.
-boris
|