Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-1-4]: src/sys/dev/raidframe pull up rev 1.4 from trunk (requested...



details:   https://anonhg.NetBSD.org/src/rev/ba73fcca1876
branches:  netbsd-1-4
changeset: 469505:ba73fcca1876
user:      cgd <cgd%NetBSD.org@localhost>
date:      Mon Sep 27 05:02:51 1999 +0000

description:
pull up rev 1.4 from trunk (requested by oster):
  Do not continue the configuration process if sectorsPerStripeUnit is
  not larger than 0.

diffstat:

 sys/dev/raidframe/rf_layout.c |  9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diffs (23 lines):

diff -r fe00a436cb5c -r ba73fcca1876 sys/dev/raidframe/rf_layout.c
--- a/sys/dev/raidframe/rf_layout.c     Mon Sep 27 03:16:12 1999 +0000
+++ b/sys/dev/raidframe/rf_layout.c     Mon Sep 27 05:02:51 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rf_layout.c,v 1.3 1999/02/05 00:06:12 oster Exp $      */
+/*     $NetBSD: rf_layout.c,v 1.3.2.1 1999/09/27 05:02:51 cgd Exp $    */
 /*
  * Copyright (c) 1995 Carnegie-Mellon University.
  * All rights reserved.
@@ -436,6 +436,13 @@
        layoutPtr->SUsPerRU = cfgPtr->SUsPerRU;
        parityConfig = cfgPtr->parityConfig;
 
+       if (layoutPtr->sectorsPerStripeUnit <= 0) {
+               RF_ERRORMSG2("raid%d: Invalid sectorsPerStripeUnit: %d\n",
+                            raidPtr->raidid, 
+                            (int)layoutPtr->sectorsPerStripeUnit );
+               return (EINVAL); 
+       }
+
        layoutPtr->stripeUnitsPerDisk = raidPtr->sectorsPerDisk / layoutPtr->sectorsPerStripeUnit;
 
        p = rf_GetLayout(parityConfig);



Home | Main Index | Thread Index | Old Index