}
/* E.g., create volume size */
if (argc == 4) {
- size = simple_strtoull(argv[3], NULL, 16);
+ if (argv[3][0] != '-')
+ size = simple_strtoull(argv[3], NULL, 16);
argc--;
}
/* Use maximum available size */
" - Display volume and ubi layout information\n"
"ubi check volumename"
" - check if volumename exists\n"
- "ubi create[vol] volume [size] [type] [id]"
- " - create volume name with size\n"
+ "ubi create[vol] volume [size] [type] [id]\n"
+ " - create volume name with size ('-' for maximum"
+ " available size)\n"
"ubi write[vol] address volume size"
" - Write volume from address with size\n"
"ubi write.part address volume size [fullsize]\n"