aboutsummaryrefslogtreecommitdiff
path: root/py/stream.h
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2016-12-02 16:37:29 +1100
committerDamien George <damien.p.george@gmail.com>2016-12-02 16:37:29 +1100
commit304cfda8c466920b1d29903bfca8bca5ed110f3b (patch)
tree1a6e2aec1e3da97d6e50512c4923a404087bd932 /py/stream.h
parent6194336d81e73e74eb7e0f26501966082ce4d411 (diff)
py/stream: Move ad-hoc ioctl constants to stream.h and rename them.
The constants MP_IOCTL_POLL_xxx, which were stmhal-specific, are moved from stmhal/pybioctl.h (now deleted) to py/stream.h. And they are renamed to MP_STREAM_POLL_xxx to be consistent with other such constants. All uses of these constants have been updated.
Diffstat (limited to 'py/stream.h')
-rw-r--r--py/stream.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/py/stream.h b/py/stream.h
index 94002e252..01199ab60 100644
--- a/py/stream.h
+++ b/py/stream.h
@@ -42,6 +42,12 @@
#define MP_STREAM_GET_DATA_OPTS (8) // Get data/message options
#define MP_STREAM_SET_DATA_OPTS (9) // Set data/message options
+// These poll ioctl values are compatible with Linux
+#define MP_STREAM_POLL_RD (0x0001)
+#define MP_STREAM_POLL_WR (0x0004)
+#define MP_STREAM_POLL_ERR (0x0008)
+#define MP_STREAM_POLL_HUP (0x0010)
+
// Argument structure for MP_STREAM_SEEK
struct mp_stream_seek_t {
mp_off_t offset;