Renamed QueryVolume to QueryVolumeInfo, QueryFileSystemAttributes to QueryAttributeInfo.
This commit is contained in:
parent
3e55b590b1
commit
a4ef6e5837
|
@ -19,8 +19,8 @@ Device::Device(const std::string& path) : path_(path) {}
|
||||||
|
|
||||||
Device::~Device() = default;
|
Device::~Device() = default;
|
||||||
|
|
||||||
// TODO(gibbed): call into HostPathDevice?
|
// TODO(gibbed): make virtual + move implementation into HostPathDevice/etc.
|
||||||
X_STATUS Device::QueryVolume(X_FILE_FS_VOLUME_INFORMATION* out_info, size_t length) {
|
X_STATUS Device::QueryVolumeInfo(X_FILE_FS_VOLUME_INFORMATION* out_info, size_t length) {
|
||||||
assert_not_null(out_info);
|
assert_not_null(out_info);
|
||||||
const char* name = "test"; // TODO(gibbed): actual value
|
const char* name = "test"; // TODO(gibbed): actual value
|
||||||
|
|
||||||
|
@ -38,9 +38,8 @@ X_STATUS Device::QueryVolume(X_FILE_FS_VOLUME_INFORMATION* out_info, size_t leng
|
||||||
return X_STATUS_SUCCESS;
|
return X_STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(gibbed): call into HostPathDevice?
|
// TODO(gibbed): make virtual + move implementation into HostPathDevice/etc.
|
||||||
X_STATUS Device::QueryFileSystemAttributes(X_FILE_FS_ATTRIBUTE_INFORMATION* out_info,
|
X_STATUS Device::QueryAttributeInfo(X_FILE_FS_ATTRIBUTE_INFORMATION* out_info, size_t length) {
|
||||||
size_t length) {
|
|
||||||
assert_not_null(out_info);
|
assert_not_null(out_info);
|
||||||
const char* name = "test"; // TODO(gibbed): actual value
|
const char* name = "test"; // TODO(gibbed): actual value
|
||||||
|
|
||||||
|
|
|
@ -30,9 +30,8 @@ class Device {
|
||||||
|
|
||||||
virtual std::unique_ptr<Entry> ResolvePath(const char* path) = 0;
|
virtual std::unique_ptr<Entry> ResolvePath(const char* path) = 0;
|
||||||
|
|
||||||
virtual X_STATUS QueryVolume(X_FILE_FS_VOLUME_INFORMATION* out_info, size_t length);
|
virtual X_STATUS QueryVolumeInfo(X_FILE_FS_VOLUME_INFORMATION* out_info, size_t length);
|
||||||
virtual X_STATUS QueryFileSystemAttributes(X_FILE_FS_ATTRIBUTE_INFORMATION* out_info,
|
virtual X_STATUS QueryAttributeInfo(X_FILE_FS_ATTRIBUTE_INFORMATION* out_info, size_t length);
|
||||||
size_t length);
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
std::string path_;
|
std::string path_;
|
||||||
|
|
|
@ -617,7 +617,7 @@ SHIM_CALL NtQueryVolumeInformationFile_shim(PPCContext* ppc_state,
|
||||||
switch (fs_info_class) {
|
switch (fs_info_class) {
|
||||||
case 1: { // FileFsVolumeInformation
|
case 1: { // FileFsVolumeInformation
|
||||||
auto volume_info = (X_FILE_FS_VOLUME_INFORMATION*)calloc(length, 1);
|
auto volume_info = (X_FILE_FS_VOLUME_INFORMATION*)calloc(length, 1);
|
||||||
result = file->device()->QueryVolume(volume_info, length);
|
result = file->device()->QueryVolumeInfo(volume_info, length);
|
||||||
if (XSUCCEEDED(result)) {
|
if (XSUCCEEDED(result)) {
|
||||||
volume_info->Write(SHIM_MEM_BASE, fs_info_ptr);
|
volume_info->Write(SHIM_MEM_BASE, fs_info_ptr);
|
||||||
info = length;
|
info = length;
|
||||||
|
@ -627,7 +627,7 @@ SHIM_CALL NtQueryVolumeInformationFile_shim(PPCContext* ppc_state,
|
||||||
}
|
}
|
||||||
case 5: { // FileFsAttributeInformation
|
case 5: { // FileFsAttributeInformation
|
||||||
auto fs_attribute_info = (X_FILE_FS_ATTRIBUTE_INFORMATION*)calloc(length, 1);
|
auto fs_attribute_info = (X_FILE_FS_ATTRIBUTE_INFORMATION*)calloc(length, 1);
|
||||||
result = file->device()->QueryFileSystemAttributes(fs_attribute_info, length);
|
result = file->device()->QueryAttributeInfo(fs_attribute_info, length);
|
||||||
if (XSUCCEEDED(result)) {
|
if (XSUCCEEDED(result)) {
|
||||||
fs_attribute_info->Write(SHIM_MEM_BASE, fs_info_ptr);
|
fs_attribute_info->Write(SHIM_MEM_BASE, fs_info_ptr);
|
||||||
info = length;
|
info = length;
|
||||||
|
|
Loading…
Reference in New Issue