diff --git a/stepmania/src/MemoryCardManager.cpp b/stepmania/src/MemoryCardManager.cpp index dcdc9610c3..d63d096c5f 100644 --- a/stepmania/src/MemoryCardManager.cpp +++ b/stepmania/src/MemoryCardManager.cpp @@ -82,7 +82,6 @@ public: /* These functions may time out. */ bool Mount( const UsbStorageDevice *pDevice ); bool Unmount( const UsbStorageDevice *pDevice ); - bool Flush( const UsbStorageDevice *pDevice ); /* This function will not time out. */ bool StorageDevicesChanged( vector &aOut ); @@ -113,7 +112,6 @@ private: { REQ_MOUNT, REQ_UNMOUNT, - REQ_FLUSH, }; }; @@ -184,10 +182,6 @@ void ThreadedMemoryCardWorker::HandleRequest( int iRequest ) m_aMountedDevices.erase( it ); break; } - - case REQ_FLUSH: - m_pDriver->Flush( &m_RequestDevice ); - break; } } @@ -251,21 +245,6 @@ bool ThreadedMemoryCardWorker::Unmount( const UsbStorageDevice *pDevice ) return true; } -bool ThreadedMemoryCardWorker::Flush( const UsbStorageDevice *pDevice ) -{ - ASSERT( TimeoutEnabled() ); - - /* If we're currently in a timed-out state, fail. */ - if( IsTimedOut() ) - return false; - - m_RequestDevice = *pDevice; - if( !DoRequest(REQ_FLUSH) ) - return false; - - return true; -} - static ThreadedMemoryCardWorker *g_pWorker = NULL; MemoryCardManager::MemoryCardManager() @@ -642,25 +621,6 @@ void MemoryCardManager::UnmountCard( PlayerNumber pn ) this->UnPauseMountingThread(); } -void MemoryCardManager::FlushAndReset() -{ - /* - * Disabled for now. Currently, this is a no-op in Linux. It's a little - * tricky: we set the timeout period in Mount, and finish in Unmount, and - * this is called outside that; currently, flushing is done by Unmount. - * I think that's OK and this will probably go away, but I'm not sure yet. - FOREACH_PlayerNumber( p ) - { - UsbStorageDevice &d = m_Device[p]; - if( d.IsBlank() ) // no card assigned - continue; // skip - if( d.m_State == UsbStorageDevice::STATE_WRITE_ERROR ) - continue; // skip - g_pWorker->Flush( &m_Device[p] ); - } - */ -} - bool MemoryCardManager::PathIsMemCard( CString sDir ) const { FOREACH_PlayerNumber( p ) diff --git a/stepmania/src/MemoryCardManager.h b/stepmania/src/MemoryCardManager.h index fe4ff3b90c..96f760f5b4 100644 --- a/stepmania/src/MemoryCardManager.h +++ b/stepmania/src/MemoryCardManager.h @@ -33,8 +33,6 @@ public: void PauseMountingThread( int iTimeout = 20 ); void UnPauseMountingThread(); - void FlushAndReset(); // force all files to be flushed to mounted memory cards - bool GetCardsLocked() const { return m_bCardsLocked; } bool PathIsMemCard( CString sDir ) const;