diff --git a/src/LibHac/Fat/FatAttribute.cs b/src/LibHac/Fat/FatAttribute.cs new file mode 100644 index 00000000..4019b8f2 --- /dev/null +++ b/src/LibHac/Fat/FatAttribute.cs @@ -0,0 +1,9 @@ +namespace LibHac.Fat +{ + public struct FatAttribute + { + public bool IsFatSafeEnabled; + public bool IsFatFormatNormalized; + public bool IsTimeStampUpdated; + } +} diff --git a/src/LibHac/Fat/FatFormatParam.cs b/src/LibHac/Fat/FatFormatParam.cs new file mode 100644 index 00000000..e6106fde --- /dev/null +++ b/src/LibHac/Fat/FatFormatParam.cs @@ -0,0 +1,12 @@ +using System; + +namespace LibHac.Fat +{ + public struct FatFormatParam + { + public bool IsSdCard; + public uint ProtectedAreaSectors; + public Result WriteVerifyErrorResult; + public Memory WorkBuffer; + } +} diff --git a/src/LibHac/FsSrv/Creators/IFatFileSystemCreator.cs b/src/LibHac/FsSrv/Creators/IFatFileSystemCreator.cs index 82d19238..6ecf6d38 100644 --- a/src/LibHac/FsSrv/Creators/IFatFileSystemCreator.cs +++ b/src/LibHac/FsSrv/Creators/IFatFileSystemCreator.cs @@ -1,10 +1,16 @@ -using LibHac.Fs; +using LibHac.Fat; +using LibHac.Fs; using LibHac.Fs.Fsa; namespace LibHac.FsSrv.Creators { public interface IFatFileSystemCreator { - Result Create(out IFileSystem fileSystem, IStorage baseStorage); + Result Create(out ReferenceCountedDisposable fileSystem, + ReferenceCountedDisposable baseStorage, FatAttribute attribute, int driveId, + Result invalidFatFormatResult, Result usableSpaceNotEnoughResult); + + Result Format(ReferenceCountedDisposable partitionStorage, FatAttribute attribute, + FatFormatParam formatParam, int driveId, Result invalidFatFormatResult, Result usableSpaceNotEnoughResult); } } \ No newline at end of file