Changes in uspace/srv/fs/cdfs/cdfs_ops.c [4f30222:0cebbac] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/fs/cdfs/cdfs_ops.c
r4f30222 r0cebbac 52 52 #include <byteorder.h> 53 53 #include <macros.h> 54 #include <unaligned.h> 55 54 56 #include "cdfs.h" 55 57 #include "cdfs_endian.h" … … 115 117 } cdfs_dir_flag_t; 116 118 119 /** Directory record */ 117 120 typedef struct { 118 121 uint8_t length; … … 132 135 } __attribute__((packed)) cdfs_dir_t; 133 136 137 /** Directory record for the root directory */ 138 typedef struct { 139 uint8_t length; 140 uint8_t ea_length; 141 142 uint32_t_lb lba; 143 uint32_t_lb size; 144 145 cdfs_timestamp_t timestamp; 146 uint8_t flags; 147 uint8_t unit_size; 148 uint8_t gap_size; 149 uint16_t_lb sequence_nr; 150 151 uint8_t name_length; 152 uint8_t name[1]; 153 } __attribute__((packed)) cdfs_root_dir_t; 154 134 155 typedef struct { 135 156 uint8_t flags; /* reserved in primary */ … … 153 174 uint32_t opt_path_table_msb; 154 175 155 cdfs_ dir_t root_dir;176 cdfs_root_dir_t root_dir; 156 177 uint8_t pad0; 157 178 … … 458 479 size_t i; 459 480 for (i = 0; i < dsize / sizeof(uint16_t); i++) { 460 buf[i] = uint16_t_be2host(((uint16_t *)data)[i]); 481 buf[i] = uint16_t_be2host( 482 ((unaligned_uint16_t *)data)[i]); 461 483 } 462 484
Note:
See TracChangeset
for help on using the changeset viewer.