Merge commit 'refs/top-bases/linux-kernel-module' into linux-kernel-module

This commit is contained in:
Brian Behlendorf 2009-02-18 16:37:54 -08:00
commit 87245deaab
1 changed files with 3 additions and 2 deletions

View File

@ -357,6 +357,7 @@ void
zio_add_child(zio_t *pio, zio_t *cio)
{
zio_link_t *zl = kmem_cache_alloc(zio_link_cache, KM_SLEEP);
int w;
/*
* Logical I/Os can have logical, gang, or vdev children.
@ -374,7 +375,7 @@ zio_add_child(zio_t *pio, zio_t *cio)
ASSERT(pio->io_state[ZIO_WAIT_DONE] == 0);
for (int w = 0; w < ZIO_WAIT_TYPES; w++)
for (w = 0; w < ZIO_WAIT_TYPES; w++)
pio->io_children[cio->io_child_type][w] += !cio->io_state[w];
list_insert_head(&pio->io_child_list, zl);
@ -1157,7 +1158,7 @@ zio_reexecute(zio_t *pio)
for (cio = zio_walk_children(pio); cio != NULL; cio = cio_next) {
cio_next = zio_walk_children(pio);
mutex_enter(&pio->io_lock);
for (int w = 0; w < ZIO_WAIT_TYPES; w++)
for (w = 0; w < ZIO_WAIT_TYPES; w++)
pio->io_children[cio->io_child_type][w]++;
mutex_exit(&pio->io_lock);
zio_reexecute(cio);