mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
image-fuzzer: Trivial readability and formatting improvements
Signed-off-by: Maria Kustova <maria.k@catit.be> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
parent
5b0ed2be88
commit
407ba0844d
2 changed files with 28 additions and 31 deletions
|
@ -332,9 +332,8 @@ def l1_entry(current):
|
|||
constraints = UINT64_V
|
||||
# Reserved bits are ignored
|
||||
# Added a possibility when only flags are fuzzed
|
||||
offset = 0x7fffffffffffffff & random.choice([selector(current,
|
||||
constraints),
|
||||
current])
|
||||
offset = 0x7fffffffffffffff & \
|
||||
random.choice([selector(current, constraints), current])
|
||||
is_cow = random.randint(0, 1)
|
||||
return offset + (is_cow << UINT64_M)
|
||||
|
||||
|
@ -344,9 +343,8 @@ def l2_entry(current):
|
|||
constraints = UINT64_V
|
||||
# Reserved bits are ignored
|
||||
# Add a possibility when only flags are fuzzed
|
||||
offset = 0x3ffffffffffffffe & random.choice([selector(current,
|
||||
constraints),
|
||||
current])
|
||||
offset = 0x3ffffffffffffffe & \
|
||||
random.choice([selector(current, constraints), current])
|
||||
is_compressed = random.randint(0, 1)
|
||||
is_cow = random.randint(0, 1)
|
||||
is_zero = random.randint(0, 1)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue