summaryrefslogtreecommitdiffstats
path: root/include/hw
diff options
context:
space:
mode:
authorXiao Feng Ren2017-05-17 02:48:10 +0200
committerCornelia Huck2017-05-19 12:29:01 +0200
commit8ca2b376b47fff58f7ab6f16d86a66d4af3a2be2 (patch)
treee8cfa27be91fd4fc8b4af613163635d8c400d72a /include/hw
parentvfio/ccw: get irqs info and set the eventfd fd (diff)
downloadqemu-8ca2b376b47fff58f7ab6f16d86a66d4af3a2be2.tar.gz
qemu-8ca2b376b47fff58f7ab6f16d86a66d4af3a2be2.tar.xz
qemu-8ca2b376b47fff58f7ab6f16d86a66d4af3a2be2.zip
s390x/css: introduce and realize ccw-request callback
Introduce a new callback on subchannel to handle ccw-request. Realize the callback in vfio-ccw device. Besides, resort to the event notifier handler to handling the ccw-request results. 1. Pread the I/O results via MMIO region. 2. Update the scsw info to guest. 3. Inject an I/O interrupt to notify guest the I/O result. Acked-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Xiao Feng Ren <renxiaof@linux.vnet.ibm.com> Signed-off-by: Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com> Message-Id: <20170517004813.58227-11-bjsdjshi@linux.vnet.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'include/hw')
-rw-r--r--include/hw/s390x/css.h2
-rw-r--r--include/hw/s390x/s390-ccw.h1
2 files changed, 3 insertions, 0 deletions
diff --git a/include/hw/s390x/css.h b/include/hw/s390x/css.h
index 60ff83e9c1..a932f91edb 100644
--- a/include/hw/s390x/css.h
+++ b/include/hw/s390x/css.h
@@ -137,6 +137,8 @@ void css_sch_build_virtual_schib(SubchDev *sch, uint8_t chpid, uint8_t type);
int css_sch_build_schib(SubchDev *sch, CssDevId *dev_id);
unsigned int css_find_free_chpid(uint8_t cssid);
uint16_t css_build_subchannel_id(SubchDev *sch);
+void copy_scsw_to_guest(SCSW *dest, const SCSW *src);
+void css_inject_io_interrupt(SubchDev *sch);
void css_reset(void);
void css_reset_sch(SubchDev *sch);
void css_queue_crw(uint8_t rsc, uint8_t erc, int chain, uint16_t rsid);
diff --git a/include/hw/s390x/s390-ccw.h b/include/hw/s390x/s390-ccw.h
index b58d8e9ca3..9f45cf1347 100644
--- a/include/hw/s390x/s390-ccw.h
+++ b/include/hw/s390x/s390-ccw.h
@@ -33,6 +33,7 @@ typedef struct S390CCWDeviceClass {
CCWDeviceClass parent_class;
void (*realize)(S390CCWDevice *dev, char *sysfsdev, Error **errp);
void (*unrealize)(S390CCWDevice *dev, Error **errp);
+ int (*handle_request) (ORB *, SCSW *, void *);
} S390CCWDeviceClass;
#endif