Test for hwh->type not hwh. --- diff/drivers/md/dm-mpath.c 2004-10-29 16:46:41.000000000 +0100 +++ source/drivers/md/dm-mpath.c 2004-10-29 16:46:22.000000000 +0100 @@ -195,7 +195,7 @@ m->current_pg = path->pg; /* Must we initialise the PG first, and queue I/O till it's ready? */ - if (hwh && hwh->type->pg_init) { + if (hwh->type && hwh->type->pg_init) { m->pg_init_required = 1; m->queue_io = 1; } else { @@ -808,7 +808,7 @@ } spin_unlock(&m->lock); - if (hwh && hwh->type->err) + if (hwh->type && hwh->type->err) err_flags = hwh->type->err(hwh, bio); if (err_flags & MP_FAIL_PATH) @@ -870,7 +870,7 @@ char buffer[32]; char state; - if (hwh && hwh->type->status) + if (hwh->type && hwh->type->status) sz += hwh->type->status(hwh, type, result + sz, maxlen = sz); else if (type == STATUSTYPE_INFO) DMEMIT("0 ");