Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Feb 2009 00:23:56 +0000 (UTC)
From:      Pyun YongHyeon <yongari@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r188474 - in head/sys: dev/re pci
Message-ID:  <200902110023.n1B0NuFV008983@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: yongari
Date: Wed Feb 11 00:23:56 2009
New Revision: 188474
URL: http://svn.freebsd.org/changeset/base/188474

Log:
  Allocating 2 MSI messages do not seem to work on certain controllers
  so use just 1 MSI message. This fixes regression introduced in
  r188381.
  
  Tested by:	many

Modified:
  head/sys/dev/re/if_re.c
  head/sys/pci/if_rlreg.h

Modified: head/sys/dev/re/if_re.c
==============================================================================
--- head/sys/dev/re/if_re.c	Wed Feb 11 00:08:48 2009	(r188473)
+++ head/sys/dev/re/if_re.c	Wed Feb 11 00:23:56 2009	(r188474)
@@ -1149,7 +1149,8 @@ re_attach(device_t dev)
 		if (bootverbose)
 			device_printf(dev, "MSI count : %d\n", msic);
 	}
-	if (msic == RL_MSI_MESSAGES  && msi_disable == 0) {
+	if (msic > 0 && msi_disable == 0) {
+		msic = 1;
 		if (pci_alloc_msi(dev, &msic) == 0) {
 			if (msic == RL_MSI_MESSAGES) {
 				device_printf(dev, "Using %d MSI messages\n",

Modified: head/sys/pci/if_rlreg.h
==============================================================================
--- head/sys/pci/if_rlreg.h	Wed Feb 11 00:08:48 2009	(r188473)
+++ head/sys/pci/if_rlreg.h	Wed Feb 11 00:23:56 2009	(r188474)
@@ -779,7 +779,7 @@ struct rl_stats {
 #define RE_RX_DESC_BUFLEN	MCLBYTES
 #endif
 
-#define	RL_MSI_MESSAGES	2
+#define	RL_MSI_MESSAGES	1
 
 #define RL_ADDR_LO(y)		((uint64_t) (y) & 0xFFFFFFFF)
 #define RL_ADDR_HI(y)		((uint64_t) (y) >> 32)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200902110023.n1B0NuFV008983>