summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--extmod/vfs_fat_diskio.c (renamed from stmhal/diskio.c)5
-rw-r--r--py/py.mk1
-rw-r--r--stmhal/Makefile1
-rw-r--r--unix/Makefile1
4 files changed, 6 insertions, 2 deletions
diff --git a/stmhal/diskio.c b/extmod/vfs_fat_diskio.c
index 03be24188e..7acdc82972 100644
--- a/stmhal/diskio.c
+++ b/extmod/vfs_fat_diskio.c
@@ -27,6 +27,9 @@
* THE SOFTWARE.
*/
+#include "py/mpconfig.h"
+#if MICROPY_FSUSERMOUNT
+
#include <stdint.h>
#include <stdio.h>
@@ -248,3 +251,5 @@ DRESULT disk_ioctl (
}
}
#endif
+
+#endif // MICROPY_FSUSERMOUNT
diff --git a/py/py.mk b/py/py.mk
index 61faf08920..9391bbdfb8 100644
--- a/py/py.mk
+++ b/py/py.mk
@@ -171,6 +171,7 @@ PY_O_BASENAME = \
../extmod/modurandom.o \
../extmod/fsusermount.o \
../extmod/vfs_fat.o \
+ ../extmod/vfs_fat_diskio.o \
../extmod/moduos_dupterm.o \
# prepend the build destination prefix to the py object files
diff --git a/stmhal/Makefile b/stmhal/Makefile
index 3cad7d1da4..cd565a6f4a 100644
--- a/stmhal/Makefile
+++ b/stmhal/Makefile
@@ -156,7 +156,6 @@ SRC_C = \
file.c \
builtin_open.c \
sdcard.c \
- diskio.c \
fatfs_port.c \
ffconf.c \
lcd.c \
diff --git a/unix/Makefile b/unix/Makefile
index 42f0edf811..342786debe 100644
--- a/unix/Makefile
+++ b/unix/Makefile
@@ -148,7 +148,6 @@ SRC_C = \
$(SRC_MOD)
STMHAL_SRC_C = \
- stmhal/diskio.c \
stmhal/ffconf.c \
stmhal/file.c