acpi_piix4: Do not use old_portio-style callbacks
[qemu/ar7.git] / hw / stream.h
blobf6137d6e258d89a2821c622ac314e9b3b6cf86b9
1 #ifndef STREAM_H
2 #define STREAM_H 1
4 #include "qemu-common.h"
5 #include "qom/object.h"
7 /* stream slave. Used until qdev provides a generic way. */
8 #define TYPE_STREAM_SLAVE "stream-slave"
10 #define STREAM_SLAVE_CLASS(klass) \
11 OBJECT_CLASS_CHECK(StreamSlaveClass, (klass), TYPE_STREAM_SLAVE)
12 #define STREAM_SLAVE_GET_CLASS(obj) \
13 OBJECT_GET_CLASS(StreamSlaveClass, (obj), TYPE_STREAM_SLAVE)
14 #define STREAM_SLAVE(obj) \
15 INTERFACE_CHECK(StreamSlave, (obj), TYPE_STREAM_SLAVE)
17 typedef struct StreamSlave {
18 Object Parent;
19 } StreamSlave;
21 typedef struct StreamSlaveClass {
22 InterfaceClass parent;
24 void (*push)(StreamSlave *obj, unsigned char *buf, size_t len,
25 uint32_t *app);
26 } StreamSlaveClass;
28 void
29 stream_push(StreamSlave *sink, uint8_t *buf, size_t len, uint32_t *app);
31 #endif /* STREAM_H */