OSDN Git Service

sd: Switch to byte-based block access
authorEric Blake <eblake@redhat.com>
Fri, 6 May 2016 16:26:39 +0000 (10:26 -0600)
committerKevin Wolf <kwolf@redhat.com>
Thu, 12 May 2016 13:22:09 +0000 (15:22 +0200)
commit12c125cba9c548929ccf4da2515e5b795c94afd9
treea16035e904e71cac0de092b939fd60c10e6d2a1c
parent098e732dbeb9d1f191da6fd6d0ddb66909690302
sd: Switch to byte-based block access

Sector-based blk_write() should die; switch to byte-based
blk_pwrite() instead.  Likewise for blk_read().

Greatly simplifies the code, now that we let the block layer
take care of alignment and read-modify-write on our behalf :)
In fact, we no longer need to include 'buf' in the migration
stream (although we do have to ensure that the stream remains
compatible).

Signed-off-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
hw/sd/sd.c