f3probe: add block size to the drive model

Using the correct block size of the block device can improve
communication speed with the device.
This commit is contained in:
Michel Machado
2014-08-23 08:30:02 -04:00
parent 71370b7d89
commit 294fd81798
3 changed files with 187 additions and 114 deletions

View File

@@ -25,21 +25,22 @@ enum fake_type {
const char *fake_type_to_name(enum fake_type fake_type);
int dev_param_valid(uint64_t real_size_byte,
uint64_t announced_size_byte, int wrap);
uint64_t announced_size_byte, int wrap, int block_order);
enum fake_type dev_param_to_type(uint64_t real_size_byte,
uint64_t announced_size_byte, int wrap);
uint64_t announced_size_byte, int wrap, int block_order);
struct device;
struct device *create_file_device(const char *filename,
uint64_t real_size_byte, uint64_t fake_size_byte, int wrap);
uint64_t real_size_byte, uint64_t fake_size_byte, int wrap,
int block_order);
struct device *create_block_device(const char *filename);
void free_device(struct device *dev);
void probe_device(struct device *dev, uint64_t *preal_size_byte,
uint64_t *pannounced_size_byte, int *pwrap);
uint64_t *pannounced_size_byte, int *pwrap, int *block_order);
#endif /* HEADER_LIBPROBE_H */