pc-bios/s390: Update firmware images
[qemu/ar7.git] / slirp / src / stream.h
blob08bb5b6610df02042b33137df72fe9f13a68ec95
1 /* SPDX-License-Identifier: BSD-3-Clause */
2 #ifndef STREAM_H_
3 #define STREAM_H_
5 #include "libslirp.h"
7 typedef struct SlirpIStream {
8 SlirpReadCb read_cb;
9 void *opaque;
10 } SlirpIStream;
12 typedef struct SlirpOStream {
13 SlirpWriteCb write_cb;
14 void *opaque;
15 } SlirpOStream;
17 bool slirp_istream_read(SlirpIStream *f, void *buf, size_t size);
18 bool slirp_ostream_write(SlirpOStream *f, const void *buf, size_t size);
20 uint8_t slirp_istream_read_u8(SlirpIStream *f);
21 bool slirp_ostream_write_u8(SlirpOStream *f, uint8_t b);
23 uint16_t slirp_istream_read_u16(SlirpIStream *f);
24 bool slirp_ostream_write_u16(SlirpOStream *f, uint16_t b);
26 uint32_t slirp_istream_read_u32(SlirpIStream *f);
27 bool slirp_ostream_write_u32(SlirpOStream *f, uint32_t b);
29 int16_t slirp_istream_read_i16(SlirpIStream *f);
30 bool slirp_ostream_write_i16(SlirpOStream *f, int16_t b);
32 int32_t slirp_istream_read_i32(SlirpIStream *f);
33 bool slirp_ostream_write_i32(SlirpOStream *f, int32_t b);
35 #endif /* STREAM_H_ */