summaryrefslogtreecommitdiff
path: root/py/stream.h
diff options
context:
space:
mode:
authorAndrew Leech <andrew.leech@planetinnovation.com.au>2023-10-31 15:14:05 +1100
committerDamien George <damien@micropython.org>2023-11-09 11:20:31 +1100
commit4cf741062b20fa34062d236d56b2168515e990b4 (patch)
treef5362f11623a29ded6d47398e5fe9f480e2f3e50 /py/stream.h
parentdff293840e381444bcd843a325ab3dd7da685733 (diff)
extmod/vfs_reader: Add file ioctl to set read buffer size.
Can be used to speed up importing a file from a vfs based filesystem. Signed-off-by: Andrew Leech <andrew.leech@planetinnovation.com.au>
Diffstat (limited to 'py/stream.h')
-rw-r--r--py/stream.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/py/stream.h b/py/stream.h
index 6b5c85ab1..e6e6f283d 100644
--- a/py/stream.h
+++ b/py/stream.h
@@ -43,6 +43,7 @@
#define MP_STREAM_GET_DATA_OPTS (8) // Get data/message options
#define MP_STREAM_SET_DATA_OPTS (9) // Set data/message options
#define MP_STREAM_GET_FILENO (10) // Get fileno of underlying file
+#define MP_STREAM_GET_BUFFER_SIZE (11) // Get preferred buffer size for file
// These poll ioctl values are compatible with Linux
#define MP_STREAM_POLL_RD (0x0001)