mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 15:23:53 -06:00
adb: introduce new ADBDeviceHasData method to ADBDeviceClass
This is required later to allow devices to assert a service request (SRQ) signal to indicate that it has data to send, without having to consume it. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Tested-by: Finn Thain <fthain@telegraphics.com.au> Acked-by: Laurent Vivier <laurent@vivier.eu> Message-Id: <20200623204936.24064-12-mark.cave-ayland@ilande.co.uk>
This commit is contained in:
parent
f3d61457e8
commit
969ca2f7a1
3 changed files with 20 additions and 0 deletions
|
@ -39,6 +39,8 @@ typedef struct ADBDevice ADBDevice;
|
|||
typedef int ADBDeviceRequest(ADBDevice *d, uint8_t *buf_out,
|
||||
const uint8_t *buf, int len);
|
||||
|
||||
typedef bool ADBDeviceHasData(ADBDevice *d);
|
||||
|
||||
#define TYPE_ADB_DEVICE "adb-device"
|
||||
#define ADB_DEVICE(obj) OBJECT_CHECK(ADBDevice, (obj), TYPE_ADB_DEVICE)
|
||||
|
||||
|
@ -62,6 +64,7 @@ typedef struct ADBDeviceClass {
|
|||
/*< public >*/
|
||||
|
||||
ADBDeviceRequest *devreq;
|
||||
ADBDeviceHasData *devhasdata;
|
||||
} ADBDeviceClass;
|
||||
|
||||
#define TYPE_ADB_BUS "apple-desktop-bus"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue