From owner-freebsd-mobile Fri Jan 10 10:57: 4 2003 Delivered-To: freebsd-mobile@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AD69537B401 for ; Fri, 10 Jan 2003 10:57:02 -0800 (PST) Received: from ambrisko.com (adsl-64-174-51-42.dsl.snfc21.pacbell.net [64.174.51.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 138B543F18 for ; Fri, 10 Jan 2003 10:57:02 -0800 (PST) (envelope-from ambrisko@www.ambrisko.com) Received: from www.ambrisko.com (localhost [127.0.0.1]) by ambrisko.com (8.12.6/8.12.6) with ESMTP id h0AIv1F0063700 for ; Fri, 10 Jan 2003 10:57:01 -0800 (PST) (envelope-from ambrisko@www.ambrisko.com) Received: (from ambrisko@localhost) by www.ambrisko.com (8.12.6/8.12.6/Submit) id h0AIv1co063699 for freebsd-mobile@FreeBSD.ORG; Fri, 10 Jan 2003 10:57:01 -0800 (PST) (envelope-from ambrisko) From: Doug Ambrisko Message-Id: <200301101857.h0AIv1co063699@www.ambrisko.com> Subject: Re: Thinkpad X30, wireless card In-Reply-To: <20030108211532.GF18309@pir.net> To: freebsd-mobile@FreeBSD.ORG Date: Fri, 10 Jan 2003 10:57:01 -0800 (PST) X-Mailer: ELM [version 2.4ME+ PL94b (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-mobile@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Peter Radcliffe writes: | "M. Warner Losh" probably said: | > At a minimum, you'll need to save the BARs in suspend (maybe setting | > the power state to D3 afterwards) and then restore them afterwards | > (after setting the power state to D0).... | | I was talking to a couple of people about the general FreeBSD | compatability of the X30 and mentioned this problem. One of the people | was winter and he came up with a couple of test patches, this one | seems to have fixed the problem for me. Guess I need to add this to the an(4) driver for the MPI-350 version. Doug A. | -------------------------------------------------------------------- | *** sys/dev/wi/if_wi_pci.c.orig Wed Jan 8 15:45:12 2003 | --- sys/dev/wi/if_wi_pci.c Wed Jan 8 16:09:04 2003 | *************** | *** 69,74 **** | --- 69,76 ---- | | static int wi_pci_probe(device_t); | static int wi_pci_attach(device_t); | + static int wi_pci_suspend(device_t); | + static int wi_pci_resume(device_t); | | static device_method_t wi_pci_methods[] = { | /* Device interface */ | *************** | *** 76,81 **** | --- 78,85 ---- | DEVMETHOD(device_attach, wi_pci_attach), | DEVMETHOD(device_detach, wi_generic_detach), | DEVMETHOD(device_shutdown, wi_shutdown), | + DEVMETHOD(device_suspend, wi_pci_suspend), | + DEVMETHOD(device_resume, wi_pci_resume), | | { 0, 0 } | }; | *************** | *** 231,235 **** | --- 235,261 ---- | if (error != 0) | return (error); | | + return (0); | + } | + | + static int | + wi_pci_suspend (device_t dev) | + { | + return (0); | + } | + | + static int | + wi_pci_resume (device_t dev) | + { | + struct wi_softc *sc; | + struct ifnet *ifp; | + sc = device_get_softc(dev); | + | + if (sc->wi_bus_type != WI_BUS_PCI_NATIVE) | + return (0); | + | + ifp = &sc->arpcom.ac_if; | + ifp->if_init(ifp->if_softc); | + | return (0); | } | -------------------------------------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-mobile" in the body of the message