tests/acpi: allow expected files change
[qemu/ar7.git] / hw / core / stream.c
bloba65ad1208d8f252cd13de069239cdb57ea4e3f65
1 #include "qemu/osdep.h"
2 #include "hw/stream.h"
3 #include "qemu/module.h"
5 size_t
6 stream_push(StreamSlave *sink, uint8_t *buf, size_t len, bool eop)
8 StreamSlaveClass *k = STREAM_SLAVE_GET_CLASS(sink);
10 return k->push(sink, buf, len, eop);
13 bool
14 stream_can_push(StreamSlave *sink, StreamCanPushNotifyFn notify,
15 void *notify_opaque)
17 StreamSlaveClass *k = STREAM_SLAVE_GET_CLASS(sink);
19 return k->can_push ? k->can_push(sink, notify, notify_opaque) : true;
22 static const TypeInfo stream_slave_info = {
23 .name = TYPE_STREAM_SLAVE,
24 .parent = TYPE_INTERFACE,
25 .class_size = sizeof(StreamSlaveClass),
29 static void stream_slave_register_types(void)
31 type_register_static(&stream_slave_info);
34 type_init(stream_slave_register_types)