aboutsummaryrefslogtreecommitdiff
path: root/lib/common.c
AgeCommit message (Collapse)Author
2018-01-30mtd-utils: common.c: convert to integer arithmeticAndrea Adami
We use floating point just to print out KiB, MiB, GiB. Avoid that to be klibc friendly. Fixes compilation for aarch64 against klibc: error: '-mgeneral-regs-only' is incompatible with floating-point argument | printf("%s%.1f GiB", p, (double)bytes / (1024 * 1024 * 1024)); etc. Signed-off-by: Andrea Adami <andrea.adami@gmail.com> Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
2016-11-17Merge rest of ubiutils-common into libmtd commonDavid Oberhollenzer
This patch moves the remaining 3 functions from ubiutils-common.{c,h} into libmtd common.{c,h}. The functions are only generic utility functions that other mtd-utils programs may also find usefull and every program that uses libubi links against libmtd anyway so there is no real reason for keeping around a seperate ubiutils-common with only generic helper functions. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>