From owner-freebsd-current@FreeBSD.ORG Tue Jan 29 06:16:15 2013 Return-Path: Delivered-To: freebsd-current@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 7B3D8F53; Tue, 29 Jan 2013 06:16:15 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-pa0-f45.google.com (mail-pa0-f45.google.com [209.85.220.45]) by mx1.freebsd.org (Postfix) with ESMTP id 50F5E927; Tue, 29 Jan 2013 06:16:15 +0000 (UTC) Received: by mail-pa0-f45.google.com with SMTP id bg2so186835pad.32 for ; Mon, 28 Jan 2013 22:16:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=vSJykJrYeP5MGgIU9BWPv++MSQlPx7slQR8TMF26DzQ=; b=s2ph7vhs4vS03kZHlYZVFvzgdns7l6kzSs5r/bT3C+SFAZXgOVO/vY617inzT911K1 vjHthB4XwWpmYhZAJM1PlMns/+llvLNPzlOGNe3vACLSzkHLFk5wxY/+vOiwty04rg2I 0jngOWcj3xjk9gwVAT6zYAd0GZGq0JMsoVgiDodhWyyT1G+CxjxleudErAbATkT1sq3J /jr4v5dnWyeMpj5FSdSqphMAGYOAKVCmy+BFPsoIxlj/mg1sZqMFowvSfkoZ1ac9C3D6 wdxNp+XzT81Bkg3+KR/SfS7z1wFiNpYokqRnv3yyZ++WpiUgNUfIMzl99CtXFcQiEufI h74A== MIME-Version: 1.0 X-Received: by 10.68.131.35 with SMTP id oj3mr1314183pbb.17.1359440169233; Mon, 28 Jan 2013 22:16:09 -0800 (PST) Received: by 10.67.2.65 with HTTP; Mon, 28 Jan 2013 22:16:09 -0800 (PST) In-Reply-To: <201301281355.31601.jhb@freebsd.org> References: <510245B5.8070704@FreeBSD.org> <5102ADF6.4060202@FreeBSD.org> <5103E5D1.3070808@FreeBSD.org> <201301281355.31601.jhb@freebsd.org> Date: Mon, 28 Jan 2013 22:16:09 -0800 Message-ID: Subject: Re: acpi resume related patch From: Kevin Oberman To: John Baldwin Content-Type: text/plain; charset=UTF-8 Cc: freebsd-current@freebsd.org, Andriy Gapon X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Jan 2013 06:16:15 -0000 On Mon, Jan 28, 2013 at 10:55 AM, John Baldwin wrote: > On Saturday, January 26, 2013 9:18:57 am Andriy Gapon wrote: >> on 25/01/2013 18:08 Andriy Gapon said the following: >> > on 25/01/2013 15:51 John Baldwin said the following: >> >> On Friday, January 25, 2013 3:43:33 am Andriy Gapon wrote: >> >>> >> >>> If you have ACPI suspend/resume working, if it used to work but stopped working >> >>> at some time, if it never worked, but you are still hoping, could you please >> >>> test the following patch and report back? >> >>> >> >>> http://svn.freebsd.by/files/acpi-apic-wakeup-final.patch >> >> >> >> This will break systems not using the local APIC since you unconditionally >> >> call lapic_setup() on resume.This was part of the feature of the previous >> >> code that by using a dummy pic it could register it only when the local APIC >> >> was used. >> > >> > Thank you for drawing my attention to this. I will try to fix this issue. >> > The reason I want to remove lapic from 'pics' (and I already described it in a >> > private email) is that Local APIC is a special kind of PIC. It's already >> > explicitly initialized by APs. Putting it into 'pics' tailq just obfuscates the code. >> > >> >> It should also be registered before any of the I/O APICs are by >> >> the design of the local_apic.c code. >> > >> > In fact, as I see in the code, Local APIC is always registered _after_ I/O APICs. >> > And thus lapic_resume was called after ioapic_resume. >> > Additionally, currently there is no synchronization between initialization of >> > Local APICs on APs and initialization of I/O APICs at the wakeup/resume time. >> > >> >> Here is an updated version of the patch: >> http://people.freebsd.org/~avg/acpi-apic-wakeup.2.patch >> >> John, >> could you please review the PIC-related part? I decided to go back to the >> current approach while fixing the suspend/resume ordering and also order of >> registration for Local APIC. Must say that XEN special casing makes >> apic_setup_io a little bit untidy. >> >> Additionally this patch fixes AP Local APIC initialization ordering on i386. >> In the original patch I changed only amd64 code. > > This looks good to me. No joy here. System graphics turns off as I'd expect, but it never comes back. No wireless. No access. :-( Maybe someday, but not today. -- R. Kevin Oberman, Network Engineer E-mail: kob6558@gmail.com