Subject: Re: PC card adapter PCI board not work
To: None <okazaki@hitachi-to.co.jp>
From: Masanori Kanaoka <kanaoka@ann.hi-ho.ne.jp>
List: tech-kern
Date: 09/10/2002 22:57:33
----Next_Part(Tue_Sep_10_22:57:33_2002_270)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi,

       From: Tsukasa Okazaki <okazaki@hitachi-to.co.jp>
    Subject: Re: PC card adapter PCI board not work
      Date : Tue, 10 Sep 2002 11:02:16 +0900 (JST)
 Message-ID: <20020910.110216.68560663.okazaki@hitachi-to.co.jp>

$ I investigate about my PC card adapter. 
$ If there are any suggestions, it will help me.

How about enabling CBB_DEBUG ?
You can find this option in sys/dev/pci/pcccbb.c.

And I attach a patch against sys/dev/acpi/acpi.c
It is disabling debug print.

Regards
---
 Masanori Kanaoka	kanaoka@ann.hi-ho.ne.jp



----Next_Part(Tue_Sep_10_22:57:33_2002_270)--
Content-Type: Text/Plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="acpi.diff3"

Index: acpi.c
===================================================================
RCS file: /ftp/cvs/syssrc/sys/dev/acpi/acpi.c,v
retrieving revision 1.15
diff -u -r1.15 acpi.c
--- acpi.c	2002/07/29 03:26:20	1.15
+++ acpi.c	2002/09/10 10:41:09
@@ -1014,7 +1014,7 @@
 		if (link == NULL)
 			continue;
 		line = acpi_get_intr(link);
-		if (line == -1) {
+		if (line == -1 || line == 0) {
 #ifdef ACPI_DEBUG
 			printf("%s: fixing up link %s\n", sc->sc_dev.dv_xname,
 			    PrtElement->Source);
@@ -1026,7 +1026,7 @@
 				continue;
 			}
 			line = acpi_get_intr(link);
-			if (line == -1) {
+			if (line == -1 || line == 0) {
 				printf("%s: get intr failed %s\n",
 				    sc->sc_dev.dv_xname, PrtElement->Source);
 				continue;
@@ -1082,7 +1082,7 @@
 			irq = (ACPI_RESOURCE_IRQ *)&resn->Data;
 			irq->Interrupts[0] =
 			    ((ACPI_RESOURCE_IRQ *)&resp->Data)->
-			        Interrupts[irq->NumberOfInterrupts-1];
+			        Interrupts[(irq->NumberOfInterrupts >> 1)];
 			irq->NumberOfInterrupts = 1;
 			resn->Length = ACPI_SIZEOF_RESOURCE(ACPI_RESOURCE_IRQ);
 			break;

----Next_Part(Tue_Sep_10_22:57:33_2002_270)----