diff options
author | Aurelien Chartier <aurelien.chartier@citrix.com> | 2013-05-28 19:09:56 +0200 |
---|---|---|
committer | Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> | 2013-05-29 15:04:19 +0200 |
commit | 2abb274629614bef4044a0b98ada42e977feadfd (patch) | |
tree | 0c4ef9f17333b7e6ec558a10cf7d218a52d85276 /include/xen/xenbus.h | |
parent | xmem/tmem: fix 'undefined variable' build error. (diff) | |
download | linux-2abb274629614bef4044a0b98ada42e977feadfd.tar.xz linux-2abb274629614bef4044a0b98ada42e977feadfd.zip |
xenbus: delay xenbus frontend resume if xenstored is not running
If the xenbus frontend is located in a domain running xenstored, the device
resume is hanging because it is happening before the process resume. This
patch adds extra logic to the resume code to check if we are the domain
running xenstored and delay the resume if needed.
Signed-off-by: Aurelien Chartier <aurelien.chartier@citrix.com>
[Changes in v2:
- Instead of bypassing the resume, process it in a workqueue]
[Changes in v3:
- Add a struct work in xenbus_device to avoid dynamic allocation
- Several small code fixes]
[Changes in v4:
- Use a dedicated workqueue]
[Changes in v5:
- Move create_workqueue error handling to xenbus_frontend_dev_resume]
Acked-by: Jan Beulich <jbeulich@suse.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'include/xen/xenbus.h')
-rw-r--r-- | include/xen/xenbus.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/xen/xenbus.h b/include/xen/xenbus.h index 0a7515c1e3a4..569c07f2e344 100644 --- a/include/xen/xenbus.h +++ b/include/xen/xenbus.h @@ -70,6 +70,7 @@ struct xenbus_device { struct device dev; enum xenbus_state state; struct completion down; + struct work_struct work; }; static inline struct xenbus_device *to_xenbus_device(struct device *dev) |