Commit 5be5b776 authored by Eric Blake's avatar Eric Blake Committed by Markus Armbruster
Browse files

blkdebug: Avoid '.' in enum values



Our qapi conventions document that '.' should only be used in
the prefix of downstream names.  BlkdebugEvent was a lone
exception to this.  Changing this is not backwards compatible
to the 'blockdev-add' QMP command; however, that command is
not yet fully stable.  It can also be argued that the testsuite
is the biggest user of blkdebug, and that any other user can
be taught to deal with the change by paying attention to
introspection results.

Done with:

$ for str in \
     l1_grow.{alloc,write,activate}_table \
     l2_alloc.{cow_read,write} \
     refblock_alloc.{hookup,write,write_blocks,write_table,switch_table} \
     pwritev_rmw.{head,after_head,tail,after_tail}; do
   str1=$(echo "$str" | sed 's/\./\\./')
   str2=$(echo "$str" | sed 's/\./_/')
   git grep -l "$str1" | xargs -r sed -i "s/$str1/$str2/g"
 done

followed by a manual touchup to test 77 to keep the test working.

Reported-by: default avatarMarkus Armbruster <armbru@redhat.com>
CC: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: default avatarEric Blake <eblake@redhat.com>
Message-Id: <1447836791-369-21-git-send-email-eblake@redhat.com>
Signed-off-by: default avatarMarkus Armbruster <armbru@redhat.com>
parent a31939e6
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
@@ -1780,19 +1780,19 @@
# Since: 2.0
##
{ 'enum': 'BlkdebugEvent', 'prefix': 'BLKDBG',
  'data': [ 'l1_update', 'l1_grow.alloc_table', 'l1_grow.write_table',
            'l1_grow.activate_table', 'l2_load', 'l2_update',
            'l2_update_compressed', 'l2_alloc.cow_read', 'l2_alloc.write',
  'data': [ 'l1_update', 'l1_grow_alloc_table', 'l1_grow_write_table',
            'l1_grow_activate_table', 'l2_load', 'l2_update',
            'l2_update_compressed', 'l2_alloc_cow_read', 'l2_alloc_write',
            'read_aio', 'read_backing_aio', 'read_compressed', 'write_aio',
            'write_compressed', 'vmstate_load', 'vmstate_save', 'cow_read',
            'cow_write', 'reftable_load', 'reftable_grow', 'reftable_update',
            'refblock_load', 'refblock_update', 'refblock_update_part',
            'refblock_alloc', 'refblock_alloc.hookup', 'refblock_alloc.write',
            'refblock_alloc.write_blocks', 'refblock_alloc.write_table',
            'refblock_alloc.switch_table', 'cluster_alloc',
            'refblock_alloc', 'refblock_alloc_hookup', 'refblock_alloc_write',
            'refblock_alloc_write_blocks', 'refblock_alloc_write_table',
            'refblock_alloc_switch_table', 'cluster_alloc',
            'cluster_alloc_bytes', 'cluster_free', 'flush_to_os',
            'flush_to_disk', 'pwritev_rmw.head', 'pwritev_rmw.after_head',
            'pwritev_rmw.tail', 'pwritev_rmw.after_tail', 'pwritev',
            'flush_to_disk', 'pwritev_rmw_head', 'pwritev_rmw_after_head',
            'pwritev_rmw_tail', 'pwritev_rmw_after_tail', 'pwritev',
            'pwritev_zero', 'pwritev_done', 'empty_image_prepare' ] }

##
+9 −9
Original line number Diff line number Diff line
@@ -66,7 +66,7 @@ for event in \
    \
    l2_load \
    l2_update \
    l2_alloc.write \
    l2_alloc_write \
    \
    write_aio \
    \
@@ -126,11 +126,11 @@ CLUSTER_SIZE=512


for event in \
    refblock_alloc.hookup \
    refblock_alloc.write \
    refblock_alloc.write_blocks \
    refblock_alloc.write_table \
    refblock_alloc.switch_table \
    refblock_alloc_hookup \
    refblock_alloc_write \
    refblock_alloc_write_blocks \
    refblock_alloc_write_table \
    refblock_alloc_switch_table \

do

@@ -170,9 +170,9 @@ CLUSTER_SIZE=1024


for event in \
    l1_grow.alloc_table \
    l1_grow.write_table \
    l1_grow.activate_table \
    l1_grow_alloc_table \
    l1_grow_write_table \
    l1_grow_activate_table \

do

+40 −40
Original line number Diff line number Diff line
@@ -195,24 +195,24 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 5; imm: off; once: on; write
Event: l2_alloc_write; errno: 5; imm: off; once: on; write
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 5; imm: off; once: on; write -b
Event: l2_alloc_write; errno: 5; imm: off; once: on; write -b
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 5; imm: off; once: off; write
Event: l2_alloc_write; errno: 5; imm: off; once: off; write
Failed to flush the L2 table cache: Input/output error
Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 5; imm: off; once: off; write -b
Event: l2_alloc_write; errno: 5; imm: off; once: off; write -b
Failed to flush the L2 table cache: Input/output error
Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
@@ -221,24 +221,24 @@ write failed: Input/output error
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 28; imm: off; once: on; write
Event: l2_alloc_write; errno: 28; imm: off; once: on; write
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 28; imm: off; once: on; write -b
Event: l2_alloc_write; errno: 28; imm: off; once: on; write -b
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 28; imm: off; once: off; write
Event: l2_alloc_write; errno: 28; imm: off; once: off; write
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l2_alloc.write; errno: 28; imm: off; once: off; write -b
Event: l2_alloc_write; errno: 28; imm: off; once: off; write -b
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -490,17 +490,17 @@ No errors were found on the image.

Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.hookup; errno: 28; imm: off; once: on; write
Event: refblock_alloc_hookup; errno: 28; imm: off; once: on; write
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.hookup; errno: 28; imm: off; once: on; write -b
Event: refblock_alloc_hookup; errno: 28; imm: off; once: on; write -b
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.hookup; errno: 28; imm: off; once: off; write
Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -509,7 +509,7 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.hookup; errno: 28; imm: off; once: off; write -b
Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write -b
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -518,41 +518,41 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write; errno: 28; imm: off; once: on; write
Event: refblock_alloc_write; errno: 28; imm: off; once: on; write
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write; errno: 28; imm: off; once: on; write -b
Event: refblock_alloc_write; errno: 28; imm: off; once: on; write -b
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write; errno: 28; imm: off; once: off; write
Event: refblock_alloc_write; errno: 28; imm: off; once: off; write
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write; errno: 28; imm: off; once: off; write -b
Event: refblock_alloc_write; errno: 28; imm: off; once: off; write -b
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_blocks; errno: 28; imm: off; once: on; write
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: on; write
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_blocks; errno: 28; imm: off; once: on; write -b
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: on; write -b
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_blocks; errno: 28; imm: off; once: off; write
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -561,7 +561,7 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_blocks; errno: 28; imm: off; once: off; write -b
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write -b
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -570,17 +570,17 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_table; errno: 28; imm: off; once: on; write
Event: refblock_alloc_write_table; errno: 28; imm: off; once: on; write
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_table; errno: 28; imm: off; once: on; write -b
Event: refblock_alloc_write_table; errno: 28; imm: off; once: on; write -b
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_table; errno: 28; imm: off; once: off; write
Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -589,7 +589,7 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.write_table; errno: 28; imm: off; once: off; write -b
Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write -b
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -598,17 +598,17 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.switch_table; errno: 28; imm: off; once: on; write
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: on; write
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.switch_table; errno: 28; imm: off; once: on; write -b
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: on; write -b
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.switch_table; errno: 28; imm: off; once: off; write
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -617,7 +617,7 @@ write failed: No space left on device
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: refblock_alloc.switch_table; errno: 28; imm: off; once: off; write -b
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write -b
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
@@ -629,60 +629,60 @@ This means waste of disk space, but no harm to data.

Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.alloc_table; errno: 5; imm: off; once: on
Event: l1_grow_alloc_table; errno: 5; imm: off; once: on
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.alloc_table; errno: 5; imm: off; once: off
Event: l1_grow_alloc_table; errno: 5; imm: off; once: off
Failed to flush the L2 table cache: Input/output error
Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.alloc_table; errno: 28; imm: off; once: on
Event: l1_grow_alloc_table; errno: 28; imm: off; once: on
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.alloc_table; errno: 28; imm: off; once: off
Event: l1_grow_alloc_table; errno: 28; imm: off; once: off
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.write_table; errno: 5; imm: off; once: on
Event: l1_grow_write_table; errno: 5; imm: off; once: on
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.write_table; errno: 5; imm: off; once: off
Event: l1_grow_write_table; errno: 5; imm: off; once: off
Failed to flush the L2 table cache: Input/output error
Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.write_table; errno: 28; imm: off; once: on
Event: l1_grow_write_table; errno: 28; imm: off; once: on
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.write_table; errno: 28; imm: off; once: off
Event: l1_grow_write_table; errno: 28; imm: off; once: off
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.activate_table; errno: 5; imm: off; once: on
Event: l1_grow_activate_table; errno: 5; imm: off; once: on
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.activate_table; errno: 5; imm: off; once: off
Event: l1_grow_activate_table; errno: 5; imm: off; once: off
Failed to flush the L2 table cache: Input/output error
Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
@@ -691,12 +691,12 @@ write failed: Input/output error
This means waste of disk space, but no harm to data.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.activate_table; errno: 28; imm: off; once: on
Event: l1_grow_activate_table; errno: 28; imm: off; once: on
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824

Event: l1_grow.activate_table; errno: 28; imm: off; once: off
Event: l1_grow_activate_table; errno: 28; imm: off; once: off
Failed to flush the L2 table cache: No space left on device
Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
+40 −40

File changed.

Preview size limit exceeded, changes collapsed.

+12 −12
Original line number Diff line number Diff line
@@ -63,7 +63,7 @@ EOF
off=0x1000
for ev in "head" "after_head" "tail" "after_tail"; do
cat  <<EOF
break pwritev_rmw.$ev A
break pwritev_rmw_$ev A
aio_write -P 10 $((off + 0x200)) 0x200
wait_break A
aio_write -P 11 $((off + 0x400)) 0x200
@@ -76,7 +76,7 @@ done

# Chained dependencies
cat  <<EOF
break pwritev_rmw.after_tail A
break pwritev_rmw_after_tail A
aio_write -P 10 0x5000 0x200
wait_break A
aio_write -P 11 0x5200 0x200
@@ -93,10 +93,10 @@ EOF

# Overlapping multiple requests
cat  <<EOF
break pwritev_rmw.after_tail A
break pwritev_rmw_after_tail A
aio_write -P 10 0x6000 0x200
wait_break A
break pwritev_rmw.after_head B
break pwritev_rmw_after_head B
aio_write -P 10 0x7e00 0x200
wait_break B
aio_write -P 11 0x6800 0x1000
@@ -107,10 +107,10 @@ aio_flush
EOF

cat  <<EOF
break pwritev_rmw.after_tail A
break pwritev_rmw_after_tail A
aio_write -P 10 0x8000 0x200
wait_break A
break pwritev_rmw.after_head B
break pwritev_rmw_after_head B
aio_write -P 10 0x9e00 0x200
wait_break B
aio_write -P 11 0x8800 0x1000
@@ -121,11 +121,11 @@ aio_flush
EOF

cat  <<EOF
break pwritev_rmw.after_tail A
break pwritev_rmw_after_tail A
aio_write -P 10 0xa000 0x200
wait_break A
aio_write -P 11 0xa800 0x1000
break pwritev_rmw.after_head B
break pwritev_rmw_after_head B
aio_write -P 10 0xbe00 0x200
wait_break B
resume A
@@ -135,11 +135,11 @@ aio_flush
EOF

cat  <<EOF
break pwritev_rmw.after_tail A
break pwritev_rmw_after_tail A
aio_write -P 10 0xc000 0x200
wait_break A
aio_write -P 11 0xc800 0x1000
break pwritev_rmw.after_head B
break pwritev_rmw_after_head B
aio_write -P 10 0xde00 0x200
wait_break B
resume B
@@ -150,7 +150,7 @@ EOF

# Only RMW for the tail part
cat  <<EOF
break pwritev_rmw.after_tail A
break pwritev_rmw_after_tail A
aio_write -P 10 0xe000 0x1800
wait_break A
aio_write -P 11 0xf000 0xc00
@@ -163,7 +163,7 @@ cat <<EOF
break pwritev A
aio_write -P 10 0x10000 0x800
wait_break A
break pwritev_rmw.after_tail B
break pwritev_rmw_after_tail B
aio_write -P 11 0x10000 0x400
break pwritev_done C
resume A