From owner-freebsd-wireless@FreeBSD.ORG Sat Jan 12 17:59:26 2013 Return-Path: Delivered-To: freebsd-wireless@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 5E87A201 for ; Sat, 12 Jan 2013 17:59:26 +0000 (UTC) (envelope-from adrian.chadd@gmail.com) Received: from mail-wi0-f180.google.com (mail-wi0-f180.google.com [209.85.212.180]) by mx1.freebsd.org (Postfix) with ESMTP id C8A01222 for ; Sat, 12 Jan 2013 17:59:25 +0000 (UTC) Received: by mail-wi0-f180.google.com with SMTP id hj13so467545wib.7 for ; Sat, 12 Jan 2013 09:59:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=G7LcTMOOfXO6Iv92HC6UrRrt04Q244HqZ15zLpypBnw=; b=QqNOawJDJGAdsCw4HE6QC4F4aZL9WpAS1sBFjoA24RuZUiT/xyW632VjrsrcybGbxX dMCwYlqDIgnorW47ccNXJKJgucAIc6l8ZDqD5LGukBlM6rI0/IKUnvfyd86aPn4XC7Rb 2/A4Pm9FaXY/myqgW0H3nUY6nFG2l6+IImWQ2AxnWvq2fVkV7t+ksMH7NFIUO+Ikzqwd P7T3zOsDQrS6dl5HxmYfxcUFDgciwhrAqqAKboWLSKjD0KzhOWYdQ7q9H/AukJu1SrT2 bKbpfOW0527j5Y5DYfck9ndFXj3ifEqW0K9gvrKDOs2jxNxJMO9JFrKa5APxoVmIXXML 8lgQ== MIME-Version: 1.0 Received: by 10.180.8.130 with SMTP id r2mr4900836wia.28.1358013558965; Sat, 12 Jan 2013 09:59:18 -0800 (PST) Received: by 10.217.57.9 with HTTP; Sat, 12 Jan 2013 09:59:18 -0800 (PST) In-Reply-To: <20130112171337.GM67643@zxy.spb.ru> References: <20130112154404.GH67643@zxy.spb.ru> <20130112162851.GI67643@zxy.spb.ru> <20130112163712.GJ67643@zxy.spb.ru> <20130112165235.GK67643@zxy.spb.ru> <20130112170707.GL67643@zxy.spb.ru> <20130112171337.GM67643@zxy.spb.ru> Date: Sat, 12 Jan 2013 09:59:18 -0800 Message-ID: Subject: Re: Atheros 9220 don't return from S3 state From: Adrian Chadd To: Slawa Olhovchenkov Content-Type: text/plain; charset=ISO-8859-1 Cc: "freebsd-wireless@freebsd.org" X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Discussions of 802.11 stack, tools device driver development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Jan 2013 17:59:26 -0000 On 12 January 2013 09:13, Slawa Olhovchenkov wrote: > On Sat, Jan 12, 2013 at 09:05:37AM -0800, Adrian Chadd wrote: > >> We can't patch pci space if they're all 0xffffffff, that means nothing is there. >> >> That's the point; the card hasn't come back on from suspend. So we >> need to do something _before_ it suspends. We can't do anything to the >> card after it resumes; we can only do stuff to the PCI bus. > > No, patch before suspend. If card don't report support D3 state -- on > sleep card not lost power? Or after resume got full reset? Well, I think there's more to it than that. I could program the card, sure, but what about the PCI bus and the ACPI code that fiddles with the PCI slot. I'm not at all clued up on how PCI sleep/resume works, so I'm scratching in the dark here. I think there's some code in the windows driver to put some older cards into some very specific PCI sleep states (and force them to not enter deep deep sleep?) but I'd have to re-review it. Adrian