Fix unnecessary remounts of cards that weren't changed since last update.\nDon't do OS mounts or unmounts while after cards are locked. It can cause skips.
This commit is contained in:
@@ -29,17 +29,7 @@ struct UsbStorageDevice
|
||||
|
||||
bool IsBlank() { return sOsMountDir.empty(); }
|
||||
|
||||
bool operator==(const UsbStorageDevice& other) const
|
||||
{
|
||||
#define COMPARE(x) if( x != other.x ) return false;
|
||||
COMPARE( iBus );
|
||||
COMPARE( iPort );
|
||||
COMPARE( iLevel );
|
||||
COMPARE( sName );
|
||||
COMPARE( sOsMountDir );
|
||||
return true;
|
||||
#undef COMPARE
|
||||
}
|
||||
bool operator==(const UsbStorageDevice& other) const;
|
||||
bool operator!=(const UsbStorageDevice& other) const
|
||||
{
|
||||
return !operator==(other);
|
||||
@@ -59,6 +49,8 @@ public:
|
||||
virtual void ResetUsbStorage() = 0;
|
||||
virtual void PauseMountingThread() = 0;
|
||||
virtual void UnPauseMountingThread() = 0;
|
||||
virtual void DoOsMount() = 0;
|
||||
virtual void DontDoOsMount() = 0;
|
||||
};
|
||||
|
||||
MemoryCardDriver *MakeMemoryCardDriver();
|
||||
|
||||
Reference in New Issue
Block a user