socsvn commit: r257383 - soc2013/zcore/head/usr.sbin/bhyve

zcore at FreeBSD.org zcore at FreeBSD.org
Sun Sep 15 15:54:34 UTC 2013


Author: zcore
Date: Sun Sep 15 15:54:34 2013
New Revision: 257383
URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=257383

Log:
  make slots equeal the blockif queue size

Modified:
  soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c

Modified: soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c
==============================================================================
--- soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c	Sun Sep 15 15:33:44 2013	(r257382)
+++ soc2013/zcore/head/usr.sbin/bhyve/pci_ahci.c	Sun Sep 15 15:54:34 2013	(r257383)
@@ -1240,7 +1240,7 @@
 static int
 pci_ahci_init(struct vmctx *ctx, struct pci_devinst *pi, char *opts)
 {
-	int i, ret = 0;
+	int i, slots, ret = 0;
 	struct pci_ahci_softc *sc;
 	char *str, *cpy, *fstr;
 
@@ -1302,11 +1302,12 @@
 	pthread_mutex_init(&sc->mtx, NULL);
 
 	/* Intel Cougar Point AHCI */
+	slots = sc->port[0].ioqsz - 1;
 	sc->cap = AHCI_CAP_64BIT | AHCI_CAP_SNCQ | AHCI_CAP_SSNTF |
 		AHCI_CAP_SMPS | AHCI_CAP_SSS | AHCI_CAP_SALP |
 		AHCI_CAP_SAL | AHCI_CAP_SCLO | (0x3 << AHCI_CAP_ISS_SHIFT)|
 		AHCI_CAP_PMD | AHCI_CAP_SSC | AHCI_CAP_PSC |
-		(0x1f << AHCI_CAP_NCS_SHIFT) | AHCI_CAP_SXS | (sc->ports - 1);
+		(slots << AHCI_CAP_NCS_SHIFT) | AHCI_CAP_SXS | (sc->ports - 1);
 	sc->pi = (1 << sc->ports) - 1;
 	sc->vs = 0x10300;
 	sc->cap2 = AHCI_CAP2_APST;


More information about the svn-soc-all mailing list