| 368 | } |
| 369 | |
| 370 | static int bf_read_async(BlockDevice *bs, |
| 371 | uint64_t sector_num, uint8_t *buf, int n, |
| 372 | BlockDeviceCompletionFunc *cb, void *opaque) |
| 373 | { |
| 374 | BlockDeviceHTTP *bf = bs->opaque; |
| 375 | // printf("bf_read_async: sector_num=%" PRId64 " n=%d\n", sector_num, n); |
| 376 | bf->is_write = FALSE; |
| 377 | bf->sector_num = sector_num; |
| 378 | bf->io_buf = buf; |
| 379 | bf->sector_count = n; |
| 380 | bf->sector_index = 0; |
| 381 | bf->cb = cb; |
| 382 | bf->opaque = opaque; |
| 383 | bf->n_read_sectors += n; |
| 384 | return bf_rw_async1(bs, TRUE); |
| 385 | } |
| 386 | |
| 387 | static int bf_write_async(BlockDevice *bs, |
| 388 | uint64_t sector_num, const uint8_t *buf, int n, |
nothing calls this directly
no test coverage detected