Skip to content

Commit

Permalink
bsd-user: Use the IEC binary prefix definitions
Browse files Browse the repository at this point in the history
It eases code review, unit is explicit.

Patch generated using:

  $ git grep -n '[<>][<>]= ?[1-5]0'

and modified manually.

Suggested-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20180625124238.25339-47-f4bug@amsat.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
  • Loading branch information
philmd authored and bonzini committed Jul 2, 2018
1 parent b52713c commit 66d26dd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions bsd-user/main.c
Expand Up @@ -17,6 +17,7 @@
* along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#include "qemu/osdep.h"
#include "qemu/units.h"
#include "qemu-version.h"
#include <machine/trap.h>

Expand Down Expand Up @@ -795,9 +796,9 @@ int main(int argc, char **argv)
if (x86_stack_size <= 0)
usage();
if (*r == 'M')
x86_stack_size *= 1024 * 1024;
x86_stack_size *= MiB;
else if (*r == 'k' || *r == 'K')
x86_stack_size *= 1024;
x86_stack_size *= KiB;
} else if (!strcmp(r, "L")) {
interp_prefix = argv[optind++];
} else if (!strcmp(r, "p")) {
Expand Down

0 comments on commit 66d26dd

Please sign in to comment.