From 5bbb6a856e367a1f265128cf397d09f7dd2c39c1 Mon Sep 17 00:00:00 2001 From: oster Date: Thu, 8 Nov 2007 04:10:09 +0000 Subject: We need to initialize dk_driver as well. Thanks to Ronald Roskens for reporting the problem and testing the fix. --- sys/dev/raidframe/rf_netbsdkintf.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'sys/dev/raidframe') diff --git a/sys/dev/raidframe/rf_netbsdkintf.c b/sys/dev/raidframe/rf_netbsdkintf.c index 7eeb025f971..06057d748a3 100644 --- a/sys/dev/raidframe/rf_netbsdkintf.c +++ b/sys/dev/raidframe/rf_netbsdkintf.c @@ -1,4 +1,4 @@ -/* $NetBSD: rf_netbsdkintf.c,v 1.234 2007/11/01 04:11:22 oster Exp $ */ +/* $NetBSD: rf_netbsdkintf.c,v 1.235 2007/11/08 04:10:09 oster Exp $ */ /*- * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc. * All rights reserved. @@ -146,7 +146,7 @@ ***********************************************************/ #include -__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.234 2007/11/01 04:11:22 oster Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rf_netbsdkintf.c,v 1.235 2007/11/08 04:10:09 oster Exp $"); #include #include @@ -239,6 +239,8 @@ const struct cdevsw raid_cdevsw = { nostop, notty, nopoll, nommap, nokqfilter, D_DISK }; +static struct dkdriver rf_dkdriver = { raidstrategy, minphys }; + /* XXX Not sure if the following should be replacing the raidPtrs above, or if it should be used in conjunction with that... */ @@ -1868,7 +1870,7 @@ raidinit(RF_Raid_t *raidPtr) * other things, so it's critical to call this *BEFORE* we try putzing * with disklabels. */ - disk_init(&rs->sc_dkdev, rs->sc_xname, NULL); + disk_init(&rs->sc_dkdev, rs->sc_xname, &rf_dkdriver); disk_attach(&rs->sc_dkdev); /* XXX There may be a weird interaction here between this, and -- cgit