From d2b2ed097050e8934cb11180ca1922c12e371568 Mon Sep 17 00:00:00 2001 From: oster Date: Sat, 27 May 2000 18:23:27 +0000 Subject: Checking parity re-write status makes no sense on RAID 0, but let's return something reasonable anyway. --- 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 5b9375e372f..2d870356ab2 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.79 2000/05/19 18:54:30 thorpej Exp $ */ +/* $NetBSD: rf_netbsdkintf.c,v 1.80 2000/05/27 18:23:27 oster Exp $ */ /*- * Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc. * All rights reserved. @@ -1280,8 +1280,10 @@ raidioctl(dev, cmd, data, flag, p) case RAIDFRAME_CHECK_PARITYREWRITE_STATUS: if (raidPtr->Layout.map->faultsTolerated == 0) { - /* This makes no sense on a RAID 0 */ - return(EINVAL); + /* This makes no sense on a RAID 0, so tell the + user it's done. */ + *(int *) data = 100; + return(0); } if (raidPtr->parity_rewrite_in_progress == 1) { *(int *) data = 100 * raidPtr->parity_rewrite_stripes_done / raidPtr->Layout.numStripe; -- cgit