Merge tag 'pull-loongarch-20241016' of https://gitlab.com/gaosong/qemu into staging
[qemu/armbru.git] / include / hw / s390x / s390-ccw.h
blob2e0a70998132070996d6b0d083b8ddba5b9b87dc
1 /*
2 * s390 CCW Assignment Support
4 * Copyright 2017 IBM Corp.
5 * Author(s): Dong Jia Shi <bjsdjshi@linux.vnet.ibm.com>
6 * Xiao Feng Ren <renxiaof@linux.vnet.ibm.com>
8 * This work is licensed under the terms of the GNU GPL, version 2 or (at
9 * your option) any later version. See the COPYING file in the top-level
10 * directory.
13 #ifndef HW_S390_CCW_H
14 #define HW_S390_CCW_H
16 #include "hw/s390x/ccw-device.h"
17 #include "qom/object.h"
19 #define TYPE_S390_CCW "s390-ccw"
20 typedef struct S390CCWDevice S390CCWDevice;
21 typedef struct S390CCWDeviceClass S390CCWDeviceClass;
22 DECLARE_OBJ_CHECKERS(S390CCWDevice, S390CCWDeviceClass,
23 S390_CCW_DEVICE, TYPE_S390_CCW)
25 struct S390CCWDevice {
26 CcwDevice parent_obj;
27 CssDevId hostid;
28 char *mdevid;
29 int32_t bootindex;
32 struct S390CCWDeviceClass {
33 CCWDeviceClass parent_class;
34 bool (*realize)(S390CCWDevice *dev, char *sysfsdev, Error **errp);
35 void (*unrealize)(S390CCWDevice *dev);
36 IOInstEnding (*handle_request) (SubchDev *sch);
37 int (*handle_halt) (SubchDev *sch);
38 int (*handle_clear) (SubchDev *sch);
39 IOInstEnding (*handle_store) (SubchDev *sch);
42 #endif