Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/ic set chan_bustype correctly.



details:   https://anonhg.NetBSD.org/src/rev/e7527972892c
branches:  trunk
changeset: 781698:e7527972892c
user:      chs <chs%NetBSD.org@localhost>
date:      Sun Sep 23 01:13:21 2012 +0000

description:
set chan_bustype correctly.

diffstat:

 sys/dev/ic/mpt_netbsd.c |  12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diffs (33 lines):

diff -r d34d2edb639e -r e7527972892c sys/dev/ic/mpt_netbsd.c
--- a/sys/dev/ic/mpt_netbsd.c   Sun Sep 23 01:12:51 2012 +0000
+++ b/sys/dev/ic/mpt_netbsd.c   Sun Sep 23 01:13:21 2012 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: mpt_netbsd.c,v 1.18 2012/03/18 21:05:21 martin Exp $   */
+/*     $NetBSD: mpt_netbsd.c,v 1.19 2012/09/23 01:13:21 chs Exp $      */
 
 /*
  * Copyright (c) 2003 Wasabi Systems, Inc.
@@ -77,7 +77,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mpt_netbsd.c,v 1.18 2012/03/18 21:05:21 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mpt_netbsd.c,v 1.19 2012/09/23 01:13:21 chs Exp $");
 
 #include <dev/ic/mpt.h>                        /* pulls in all headers */
 
@@ -125,7 +125,13 @@
        /* Fill in the scsipi_channel. */
        memset(chan, 0, sizeof(*chan));
        chan->chan_adapter = adapt;
-       chan->chan_bustype = &scsi_bustype;
+       if (mpt->is_sas) {
+               chan->chan_bustype = &scsi_sas_bustype;
+       } else if (mpt->is_fc) {
+               chan->chan_bustype = &scsi_fc_bustype;
+       } else {
+               chan->chan_bustype = &scsi_bustype;
+       }
        chan->chan_channel = 0;
        chan->chan_flags = 0;
        chan->chan_nluns = 8;



Home | Main Index | Thread Index | Old Index