add hdd dump support, cleanup dump code into a single generic file.

This commit is contained in:
ITotalJustice
2025-05-22 15:50:50 +01:00
parent 2e6d757852
commit 8070268d2a
12 changed files with 634 additions and 719 deletions

View File

@@ -21,4 +21,21 @@ using Entries = std::vector<Entry>;
auto Load() -> Entries;
void Add(const Entry& e);
// helper for hdd devices.
// this doesn't really belong in this header, however
// locations likely will be renamed to something more generic soon.
struct StdioEntry {
// mount point (ums0:)
std::string mount{};
// ums0: (USB Flash Disk)
std::string name{};
// set if read-only.
bool write_protect;
};
using StdioEntries = std::vector<StdioEntry>;
// set write=true to filter out write protected devices.
auto GetStdio(bool write) -> StdioEntries;
} // namespace sphaira::location