diff --git a/features/filesystem/fat/FATFileSystem.cpp b/features/filesystem/fat/FATFileSystem.cpp index caf04a7da4f..707799eefd6 100644 --- a/features/filesystem/fat/FATFileSystem.cpp +++ b/features/filesystem/fat/FATFileSystem.cpp @@ -247,10 +247,10 @@ FATFileSystem::~FATFileSystem() int FATFileSystem::mount(BlockDevice *bd) { // requires duplicate definition to allow virtual overload to work - return mount(bd, false); + return mount(bd, true); } -int FATFileSystem::mount(BlockDevice *bd, bool force) { +int FATFileSystem::mount(BlockDevice *bd, bool mount) { lock(); if (_id != -1) { unlock(); @@ -265,7 +265,7 @@ int FATFileSystem::mount(BlockDevice *bd, bool force) { _fsid[1] = ':'; _fsid[2] = '\0'; debug_if(FFS_DBG, "Mounting [%s] on ffs drive [%s]\n", getName(), _fsid); - FRESULT res = f_mount(&_fs, _fsid, force); + FRESULT res = f_mount(&_fs, _fsid, mount); unlock(); return fat_error_remap(res); } diff --git a/features/filesystem/fat/FATFileSystem.h b/features/filesystem/fat/FATFileSystem.h index ddef2f805b3..d46535b9c49 100644 --- a/features/filesystem/fat/FATFileSystem.h +++ b/features/filesystem/fat/FATFileSystem.h @@ -69,14 +69,6 @@ class FATFileSystem : public FileSystem { */ virtual int mount(BlockDevice *bd); - /** Mounts a filesystem to a block device - * - * @param bd BlockDevice to mount to - * @param force Flag to force the underlying filesystem to force mounting the filesystem - * @return 0 on success, negative error code on failure - */ - virtual int mount(BlockDevice *bd, bool force); - /** Unmounts a filesystem from the underlying block device * * @return 0 on success, negative error code on failure @@ -235,6 +227,7 @@ class FATFileSystem : public FileSystem { protected: virtual void lock(); virtual void unlock(); + virtual int mount(BlockDevice *bd, bool mount); }; #endif