master - cleanup: uint64_t casts
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=bd67a3151aa3a3202d52fcc9ffac781b96dca04a Commit: bd67a3151aa3a3202d52fcc9ffac781b96dca04a Parent: ff86c6ed00859a93b984ffd5944c6ba3e450c747 Author: Zdenek Kabelac <[email protected]> AuthorDate: Thu Aug 16 20:07:30 2012 +0200 Committer: Zdenek Kabelac <[email protected]> CommitterDate: Thu Aug 23 14:37:21 2012 +0200
cleanup: uint64_t casts
--- lib/format1/disk-rep.c | 2 +- lib/format1/layout.c | 2 +- lib/format1/lvm1-label.c | 2 +- lib/format_pool/disk_rep.c | 2 +- lib/metadata/lv_manip.c | 2 +- tools/pvdisplay.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-)
lib/format1/disk-rep.c +1 -1
@@ -335,7 +335,7 @@ static void __update_lvmcache(const struct format_type *fmt,return ; } -lvmcache_set_device_size (info,xlate32 (dl->pvd.pv_size) <<SECTOR_SHIFT ); +lvmcache_set_device_size (info, ((uint64_t )xlate32 (dl->pvd.pv_size)) <<SECTOR_SHIFT );lvmcache_del_mdas (info);lvmcache_make_valid (info); }
lib/format1/layout.c +1 -1
@@ -153,7 +153,7 @@ int calculate_extent_count(struct physical_volume *pv, uint32_t extent_size, pvd->pe_start =_round_up (end,LVM1_PE_ALIGN ); - }while ((pvd->pe_start + (pvd->pe_total * extent_size)) + }while ((pvd->pe_start + ((uint64_t )pvd->pe_total * extent_size)) > pv->size);if (pvd->pe_total >MAX_PE_TOTAL ) {
lib/format1/lvm1-label.c +1 -1
@@ -79,7 +79,7 @@ static int _lvm1_read(struct labeller *l, struct device *dev, void *buf, return_0; *label =lvmcache_get_label (info); -lvmcache_set_device_size (info,xlate32 (pvd->pv_size) <<SECTOR_SHIFT ); +lvmcache_set_device_size (info, ((uint64_t )xlate32 (pvd->pv_size)) <<SECTOR_SHIFT );lvmcache_del_mdas (info);lvmcache_make_valid (info);
lib/format_pool/disk_rep.c +1 -1
@@ -103,7 +103,7 @@ int read_pool_label(struct pool_list *pl, struct labeller *l,if (label) *label =lvmcache_get_label (info); -lvmcache_set_device_size (info,xlate32_be (pd->pl_blocks) <<SECTOR_SHIFT ); +lvmcache_set_device_size (info, ((uint64_t )xlate32_be (pd->pl_blocks)) <<SECTOR_SHIFT );lvmcache_del_mdas (info);lvmcache_make_valid (info);
lib/metadata/lv_manip.c +1 -1
@@ -726,7 +726,7 @@ static uint32_t mirror_log_extents(uint32_t region_size, uint32_t pe_size, uint3 {size_t area_size, bitset_size, log_size, region_count; - area_size = area_len * pe_size; + area_size = (size_t )area_len * pe_size; region_count =dm_div_up (area_size, region_size);/* Work out how many "unsigned long"s we need to hold the bitset. */
tools/pvdisplay.c +1 -1
@@ -54,7 +54,7 @@ static int _pvdisplay_single(struct cmd_context *cmd,if (is_orphan (pv)) size =pv_size (pv);else - size = (pv_pe_count (pv) -pv_pe_alloc_count (pv)) * + size = (uint64_t )(pv_pe_count (pv) -pv_pe_alloc_count (pv)) *pv_pe_size (pv);if (arg_count (cmd, short_ARG)) {