Added some more endian-aware getter methods for fields actually used.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@4442 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -61,6 +61,11 @@ struct rigid_disk_block {
|
|||||||
char controller_revision[4];
|
char controller_revision[4];
|
||||||
|
|
||||||
uint32 __reserved5[10];
|
uint32 __reserved5[10];
|
||||||
|
|
||||||
|
uint32 ID() { return B_BENDIAN_TO_HOST_INT32(id); }
|
||||||
|
uint32 SummedLongs() { return B_BENDIAN_TO_HOST_INT32(summed_longs); }
|
||||||
|
uint32 BlockSize() { return B_BENDIAN_TO_HOST_INT32(block_size); }
|
||||||
|
uint32 FirstPartition() { return B_BENDIAN_TO_HOST_INT32(partition_list); }
|
||||||
};
|
};
|
||||||
|
|
||||||
#define RDB_DISK_ID 'RDSK'
|
#define RDB_DISK_ID 'RDSK'
|
||||||
@@ -92,19 +97,23 @@ struct bad_block_block {
|
|||||||
/************* partition block *************/
|
/************* partition block *************/
|
||||||
|
|
||||||
struct partition_block {
|
struct partition_block {
|
||||||
uint32 id;
|
uint32 id;
|
||||||
uint32 summed_longs;
|
uint32 summed_longs;
|
||||||
int32 check_sum;
|
int32 check_sum;
|
||||||
uint32 host_id;
|
uint32 host_id;
|
||||||
uint32 next;
|
uint32 next;
|
||||||
uint32 flags;
|
uint32 flags;
|
||||||
uint32 __reserved1[2];
|
uint32 __reserved1[2];
|
||||||
uint32 open_device_flags;
|
uint32 open_device_flags;
|
||||||
uint8 drive_name[32]; // BSTR form (Pascal like string)
|
uint8 drive_name[32]; // BSTR form (Pascal like string)
|
||||||
|
|
||||||
uint32 __reserved2[15];
|
uint32 __reserved2[15];
|
||||||
uint32 environment[17];
|
uint32 environment[17];
|
||||||
uint32 __reserved3[15];
|
uint32 __reserved3[15];
|
||||||
|
|
||||||
|
uint32 ID() { return B_BENDIAN_TO_HOST_INT32(id); }
|
||||||
|
uint32 SummedLongs() { return B_BENDIAN_TO_HOST_INT32(summed_longs); }
|
||||||
|
uint32 Next() { return B_BENDIAN_TO_HOST_INT32(next); }
|
||||||
};
|
};
|
||||||
|
|
||||||
#define RDB_PARTITION_ID 'PART'
|
#define RDB_PARTITION_ID 'PART'
|
||||||
|
|||||||
Reference in New Issue
Block a user