summaryrefslogtreecommitdiffstatshomepage
path: root/stmhal/pybioctl.h
diff options
context:
space:
mode:
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2015-11-09 22:10:01 +0200
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2015-11-09 22:10:31 +0200
commit746b752b8efd089c8dd37e615949315973a8d370 (patch)
treed1a08a928fd5ba64c08fa26391364e7dc2073adc /stmhal/pybioctl.h
parent1f92ffb5b7e3404e9a290f3e5ab95dc98a28753e (diff)
downloadmicropython-746b752b8efd089c8dd37e615949315973a8d370.tar.gz
micropython-746b752b8efd089c8dd37e615949315973a8d370.zip
stmhal/moduselect: Expose POLLIN/OUT/ERR/HUP constants.
This makes select.poll() interface fully compatible with CpYthon. Also, make their numeric values of these options compatible with Linux (and by extension, with iBCS2 standard, which jopefully means compatibility with other Unices too).
Diffstat (limited to 'stmhal/pybioctl.h')
-rw-r--r--stmhal/pybioctl.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/stmhal/pybioctl.h b/stmhal/pybioctl.h
index 79f994b8b6..b71e04ed5d 100644
--- a/stmhal/pybioctl.h
+++ b/stmhal/pybioctl.h
@@ -1,6 +1,8 @@
#define MP_IOCTL_POLL (0x100 | 1)
+// These values are compatible with Linux, which are in turn
+// compatible with iBCS2 spec.
#define MP_IOCTL_POLL_RD (0x0001)
-#define MP_IOCTL_POLL_WR (0x0002)
-#define MP_IOCTL_POLL_HUP (0x0004)
+#define MP_IOCTL_POLL_WR (0x0004)
#define MP_IOCTL_POLL_ERR (0x0008)
+#define MP_IOCTL_POLL_HUP (0x0010)