Subject: Re: apm (Re: Anyone running NetBSD on an IBM ThinkPad [A|T]21?)
To: Chuck Cranor <chuck@xxx.research.att.com>
From: Jason R Thorpe <thorpej@zembu.com>
List: port-i386
Date: 01/20/2001 20:23:28
On Fri, Jan 19, 2001 at 11:55:38PM -0500, Chuck Cranor wrote:

 > Jason: can you please fix this?  thanks.

Try the following patch.

-- 
        -- Jason R. Thorpe <thorpej@zembu.com>

Index: npx_isa.c
===================================================================
RCS file: /cvsroot/syssrc/sys/arch/i386/isa/npx_isa.c,v
retrieving revision 1.1
diff -c -r1.1 npx_isa.c
*** npx_isa.c	2000/06/16 03:47:24	1.1
--- npx_isa.c	2001/01/21 04:22:01
***************
*** 77,82 ****
--- 77,88 ----
  
  	bus_space_unmap(ia->ia_iot, ioh, ia->ia_iosize);
  
+ 	/*
+ 	 * Remember our result -- we don't want to have to npxprobe1()
+ 	 * again (especially if we've zapped the IRQ).
+ 	 */
+ 	ia->ia_aux = (void *)(u_long)result;
+ 
  	return (result != NPX_NONE);
  }
  
***************
*** 93,99 ****
  		panic("npxattach: unable to map I/O space");
  	}
  
! 	sc->sc_type = npxprobe1(sc->sc_iot, sc->sc_ioh, ia->ia_irq);
  
  	switch (sc->sc_type) {
  	case NPX_INTERRUPT:
--- 99,105 ----
  		panic("npxattach: unable to map I/O space");
  	}
  
! 	sc->sc_type = (u_long) ia->ia_aux;
  
  	switch (sc->sc_type) {
  	case NPX_INTERRUPT: