From owner-freebsd-acpi@FreeBSD.ORG Sun Aug 24 07:00:51 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 645A4286 for ; Sun, 24 Aug 2014 07:00:51 +0000 (UTC) Received: from o2.email.wpengine.com (o2.email.wpengine.com [198.37.147.232]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D1F8A3E57 for ; Sun, 24 Aug 2014 07:00:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=email.wpengine.com; h=to:subject:from:reply-to:mime-version:content-transfer-encoding:content-type; s=smtpapi; bh=YaQWtQMGYxgVoZekapcc1/vKCOU=; b=tqYEyTUMePkLU27gjC WvuVziPKmODc6khb7zKY/61zhR/iHzyCjWpM24yK+eHN68Hd5D3x2fBOrfjyss5r CCebBJZRibI3Jx/lr5bkEdRUg4/ora+clPb+W9qehh5ICHkW5QqDU6mjsJtQ9OQ+ dl6D6q//R3WDLMjwCWtUN2GvA= Received: by mf190.sendgrid.net with SMTP id mf190.3104.53F98D9A39 2014-08-24 07:00:42.976048108 +0000 UTC Received: from pod-2745 (li170-216.members.linode.com [173.230.130.216]) by ismtpd-026.iad1.sendgrid.net (SG) with ESMTP id 14806d124cf.5e98.3f5865 for ; Sun, 24 Aug 2014 07:00:42 +0000 (GMT) X-SendGrid-User: wpengine-pod-2745 Received: by pod-2745 (Postfix, from userid 33) id A703955038; Sun, 24 Aug 2014 07:00:42 +0000 (UTC) To: freebsd-acpi@freebsd.org Subject: =?UTF-8?Q?Account_Blocked?= X-PHP-Originating-Script: 33:index.php Date: Sun, 24 Aug 2014 07:00:42 +0000 From: =?UTF-8?Q?Support?= Message-ID: <7133fa1a26a138d8324ca59805c4b695@souhail.wpengine.com> X-Priority: 1 X-Mailer: PHPMailer (phpmailer.sourceforge.net) [version ] X-SG-EID: t2fXfoZHCw6vGsGKHqKxJ9qWwHSlQfPdDS+3+p6rOCvrFt41kZu8yHrF4cCrgnnHkujQUblIeMgX4E6TnwaTKu8LjE4Oypn+IZyPSqSA9Cf6D4fF7+qUNWV6QVkMdsECCTzo+cn0y0eumK++8nW8vx57grfr4A64YlaDnF61rBc= MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 24 Aug 2014 07:00:51 -0000 Dear costumer, You have received this email because our system has noticed some suspicious activities with Ale ID. All what you need to keep enjoying all the benefits of your id is to confirm your identity , follow the link below to start this process . [1]Confirm Now > Wondering why you got this email? Some massive failed login attempts were been made from unknown location that didnt match with your usual one , as a result we decided to suspend your account temporarily in order to protect it . This is an automated message. Please do not reply to this email. Thanks, Customer. TM and copyright © 2014 Inc. 1 Infinite Loop, MS 96-DM, Cupertino, CA 95014. All Rights Reserved / Keep Informed / Privacy Policy / My ID References 1. http://goo.gl/IsbNDo From owner-freebsd-acpi@FreeBSD.ORG Mon Aug 25 16:13:56 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id E33169FB for ; Mon, 25 Aug 2014 16:13:55 +0000 (UTC) Received: from nm19-vm6.access.bullet.mail.gq1.yahoo.com (nm19-vm6.access.bullet.mail.gq1.yahoo.com [216.39.63.167]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A21C33C3D for ; Mon, 25 Aug 2014 16:13:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1408983059; bh=yVjh5QXK1zCdgnJf2U2xpSiY23ktjMrFNpCoq+px69w=; h=Received:Received:Received:DKIM-Signature:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type; b=C1p5jOgyqW4RmyTDSVscZ8IpcKU0pI+guiewAUanI4NbY40gZWJaF3g8PT7ir07IoQupvt64VXbc2druj6tE3YVgUd6FXP+Aq9e0GFBRO0ItlV2hIJG8mjkwnFKs9U0DGRhFxExqYsq4Sq6e30PwZELqPI9cc46+n2Ogm3mT+2s= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=att.net; b=pmJtXAIrNV+Za8IMDQ/tZq0Vy/L6TXZCJh2Z2brsRQdydKux5/D72qTSy/voj3yFI0HP5BJJlEKcWh+bVdJgYk84HrWcdqsB3bWoBR+OdvbeEkAZZRZ6uN29/4ww8DD22R9qn/haJPD0RDpV/Bo5phu7MGLHRXtvwVKwp7504WA=; Received: from [216.39.60.173] by nm19.access.bullet.mail.gq1.yahoo.com with NNFMP; 25 Aug 2014 16:10:59 -0000 Received: from [98.138.104.98] by tm9.access.bullet.mail.gq1.yahoo.com with NNFMP; 25 Aug 2014 16:10:59 -0000 Received: from [127.0.0.1] by smtp118.sbc.mail.ne1.yahoo.com with NNFMP; 25 Aug 2014 16:10:58 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1408983058; bh=yVjh5QXK1zCdgnJf2U2xpSiY23ktjMrFNpCoq+px69w=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type; b=QU2qAPyl9gtjAoi2Hw9OgETjRJ5RGS6RXehOEMcxqGh6Aqff99S8Dq5o7UlkAP94EARYeT+J8qSLooBzboMJq558jyD7XHGh7m/t4O1Dn3+yXEbxf2JuYXZSadbkumKrrN6rj3+iKHVAr906djl2RyraMyA/MHVuoBw+Xxjppf4= X-Yahoo-Newman-Id: 918509.42040.bm@smtp118.sbc.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: Ym0whroVM1mi0vG8KTw._NPL5OjZ13dB9sZB7bTzkvhj9UG JhLDYsoJRZ94dE_n4ZMVW5VhR4E8ZtuIacNZzd0QPxJJpHPAi.vg.NEvSp.I 08KgAiDyQFtZocYX72w5ZEMAiYoYOwhPoQESNhbZ9P9ucuTl51a6y6_s4Vvp ZzhORrJuqD4dzwEwXuvUA2XP2djS_84ZDZUomPUuvySYIcUVGp841B0Kqibq Bl7HTwGjxi60_icCIT6QU8k5IrooKrodvKCx2AkZXQsdy1PuZTPfiC7yvLr_ G5HfXDMSVo5LwNwNHFqkVBdTap0pZ0Wd6eTlaNlUH_VFsD9HWz4kb_g5e1Jt pPVMtBYjKjwr8bFO_n4bZjOwAhe0Drf.YmxcLnMdO1sDBOtbZ093YAchzXIb FSJTi1jiP4hVgmbUZb0oN.deMo3tFBMpMW4e4ZcIR.PTRIw0qfdfMzJTToe9 6lcUAPmFdvqMWQvPBp2bSdmnWJjxIH5Eau0lqBQCGjeLdV4n35F2ATHxKjdd sO6BOeT0MQM6.9VxnAQ0yZ7j.8wYwYNihGWKs5EIDSFSamBJ28YvyCoCRFdo pIwg_ubv2546qhugRr871OJe9Lnq.PzXTpQngim9MN5QlMJDVM3piuhNoRV_ Ahg-- X-Yahoo-SMTP: OKD1keCswBBTAmAF1s00hLyKW3wE3YfSK0Eazl6b4VZG4LTqJxg- Message-ID: <53FB6011.3080509@att.net> Date: Mon, 25 Aug 2014 12:10:57 -0400 From: Anthony Jenkins User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: =?UTF-8?B?5byg5pmT6Z2W?= Subject: Re: =?UTF-8?B?562U5aSNOiDnrZTlpI06IE15IGxhcHRvcCBjYW4ndCByZXN1bWU=?= =?UTF-8?B?IGZyb20gc3VzcGVuZC4=?= References: <53EE78ED.2030208@att.net> In-Reply-To: Content-Type: multipart/mixed; boundary="------------010903030303070503090707" Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Aug 2014 16:13:56 -0000 This is a multi-part message in MIME format. --------------010903030303070503090707 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit No problem... attached. And amd64 doesn't matter - works for x86-based computers with the basic CMOS RTC chip (PNP0B00). Hopefully your suspend/resume problems are due to your ACPI BIOS needing to read/write info from/to CMOS and not finding a CMOS handler. Anthony On 08/25/2014 11:50, 张晓靖 wrote: > I google less than complete information. Do you have the relevant code can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa directory, but my system is amd64 of ...... > > root@skycn:~ # uname -a > FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 > > > -----邮件原件----- > 发件人: Anthony Jenkins [mailto:Anthony.B.Jenkins@att.net] > 发送时间: 2014年8月16日 5:18 > 收件人: 张晓靖; 'Kevin Oberman' > 抄送: freebsd-acpi@freebsd.org > 主题: Re: 答复: My laptop can't resume from suspend. > > On 08/15/2014 16:20, 张晓靖 wrote: >> Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I >> received an e-mail, >> >> immediately compile the kernel (make a note #options VESA).But the >> problem persists, dmesg >> >> Information Reference url http://url.cn/SQ0vXD. >> >> >> >> Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a >> notebook can not boot >> >> until yesterday afternoon for a good notebook motherboard, now do not >> dare to use “acpiconf >> >> -s 3” testing. >> >> >> >> Do you have suggestions for me? > You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region support atrtc.c.patch") to play with, it works to enable suspend/resume on some laptops and should be safe to try. I still need to clean it up (style, other suggestions) for submission to FreeBSD, haven't gotten around to it yet. > > Anthony Jenkins > >> Thanks you~ >> >> >> >> >> >> >> >> -----邮件原件----- >> 发件人: Bykov Vladislav [mailto:envolyse@gmail.com] >> 发送时间: 2014年8月13日 0:13 >> 收件人: 张晓靖 >> 主题: Re: My laptop can't resume from suspend. >> >> >> >> On Tue, Aug 12, 2014 at 12:20:28PM +0800, 张晓靖 wrote: >> >>> The laptop can't resume, the screen no display, no beep sound. >> Can you please try to install video driver for your card and remove VESA device from kernel configuration? >> >> >> >> >> >> 发件人: kob6558@gmail.com [mailto:kob6558@gmail.com] 代表 Kevin Oberman >> 发送时间: 2014年8月13日 1:15 >> 收件人: 张晓靖 >> 抄送: freebsd-acpi@freebsd.org >> 主题: Re: My laptop can't resume from suspend. >> >> >> >> On Mon, Aug 11, 2014 at 9:20 PM, 张晓靖 > wrote: >> >> Hello, >> >> I am having a problem. >> >> My laptop is lenovo's zhaoyang K47A series HM65. >> >> I used ati graphics CARDS, Use the url ( >> https://wiki.freebsd.org/Graphics) >> the method of normal driving the graphics card. >> >> >> >> After set " >> >> sysctl debug. Bootverbose = 1 >> >> sysctl debug. Acpi. Suspend_bounce = 1 >> >> sysctl debug. Acpi. Resume_beep = 1 >> >> acpiconf -s 3 >> >> " >> >> The laptop can't resume, the screen no display, no beep sound. >> >> >> >> Disabling ACPI not helps to fix the problem. All files downloaded from >> http://url.cn/WVISGF. >> >> >> >> Output from sysctl hw.acpi >> >> hw.acpi.supported_sleep_state: S1 S3 S4 S5 >> >> hw.acpi.power_button_state: S5 >> >> hw.acpi.sleep_button_state: S1 >> >> hw.acpi.lid_switch_state: NONE >> >> hw.acpi.standby_state: S1 >> >> hw.acpi.suspend_state: S3 >> >> hw.acpi.sleep_delay: 1 >> >> hw.acpi.s4bios: 0 >> >> hw.acpi.verbose: 1 >> >> hw.acpi.disable_on_reboot: 0 >> >> hw.acpi.handle_reboot: 0 >> >> hw.acpi.reset_video: 0 >> >> hw.acpi.cpu.cx_lowest: C1 >> >> hw.acpi.acline: 1 >> >> hw.acpi.battery.life: 100 >> >> hw.acpi.battery.time: -1 >> >> hw.acpi.battery.state: 0 >> >> hw.acpi.battery.units: 2 >> >> hw.acpi.battery.info_expire: 5 >> >> hw.acpi.thermal.min_runtime: 0 >> >> hw.acpi.thermal.polling_rate: 10 >> >> hw.acpi.thermal.user_override: 0 >> >> hw.acpi.thermal.tz0.temperature: 62.0C >> >> hw.acpi.thermal.tz0.active: -1 >> >> hw.acpi.thermal.tz0.passive_cooling: 1 >> >> hw.acpi.thermal.tz0.thermal_flags: 0 >> >> hw.acpi.thermal.tz0._PSV: 95.0C >> >> hw.acpi.thermal.tz0._HOT: -1 >> >> hw.acpi.thermal.tz0._CRT: 100.0C >> >> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 >> >> hw.acpi.thermal.tz0._TC1: 2 >> >> hw.acpi.thermal.tz0._TC2: 3 >> >> hw.acpi.thermal.tz0._TSP: 100 >> >> >> >> Sincerely, >> ZhangXiaoJing. >> >> >> >> Have you tried building the kernel without VESA? Many laptops won't resume if you leave VESA in the kernel build. >> >> -- >> >> >> R. Kevin Oberman, Network Engineer, Retired >> E-mail: rkoberman@gmail.com >> >> _______________________________________________ >> freebsd-acpi@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-acpi >> To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" > > --------------010903030303070503090707 Content-Type: text/x-patch; name="atrtc.c.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="atrtc.c.patch" Index: sys/x86/isa/atrtc.c =================================================================== --- sys/x86/isa/atrtc.c (revision 268728) +++ sys/x86/isa/atrtc.c (working copy) @@ -31,6 +31,7 @@ __FBSDID("$FreeBSD$"); #include "opt_isa.h" +#include "opt_acpi.h" #include #include @@ -53,12 +54,19 @@ #include #include "clock_if.h" +#include +#include +#include + #define RTC_LOCK do { if (!kdb_active) mtx_lock_spin(&clock_lock); } while (0) #define RTC_UNLOCK do { if (!kdb_active) mtx_unlock_spin(&clock_lock); } while (0) +#define IO_DELAY() (void)inb(0x84) +#define IO_RTC_ADDR (IO_RTC + 0) +#define IO_RTC_DATA (IO_RTC + 1) + int atrtcclock_disable = 0; -static int rtc_reg = -1; static u_char rtc_statusa = RTCSA_DIVIDER | RTCSA_NOPROF; static u_char rtc_statusb = RTCSB_24HR; @@ -66,39 +74,50 @@ * RTC support routines */ -int -rtcin(int reg) +static void acpi_cmos_read(ACPI_PHYSICAL_ADDRESS address, UINT8 *buf, UINT32 buflen) { - u_char val; + UINT32 offset; RTC_LOCK; - if (rtc_reg != reg) { - inb(0x84); - outb(IO_RTC, reg); - rtc_reg = reg; - inb(0x84); + for (offset = 0U; offset < buflen; ++offset) { + IO_DELAY(); + outb(IO_RTC_ADDR, ((address + offset) | 0x80) & 0xFF); + IO_DELAY(); + buf[offset] = inb(IO_RTC_DATA); } - val = inb(IO_RTC + 1); RTC_UNLOCK; - return (val); } -void -writertc(int reg, u_char val) +static void acpi_cmos_write(ACPI_PHYSICAL_ADDRESS address, const UINT8 *buf, UINT32 buflen) { + UINT32 offset; RTC_LOCK; - if (rtc_reg != reg) { - inb(0x84); - outb(IO_RTC, reg); - rtc_reg = reg; - inb(0x84); + for (offset = 0U; offset < buflen; ++offset) { + IO_DELAY(); + outb(IO_RTC_ADDR, ((address + offset) | 0x80) & 0xFF); + IO_DELAY(); + outb(IO_RTC_DATA, buf[offset]); } - outb(IO_RTC + 1, val); - inb(0x84); + IO_DELAY(); RTC_UNLOCK; } +int +rtcin(int reg) +{ + u_char val; + + acpi_cmos_read(reg & 0xFF, &val, 1); + return (val); +} + +void +writertc(int reg, u_char val) +{ + acpi_cmos_write(reg & 0xFF, &val, 1); +} + static __inline int readrtc(int port) { @@ -144,7 +163,6 @@ { /* Restore all of the RTC's "status" (actually, control) registers. */ - rtcin(RTC_STATUSA); /* dummy to get rtc_reg set */ writertc(RTC_STATUSB, RTCSB_24HR); writertc(RTC_STATUSA, rtc_statusa); writertc(RTC_STATUSB, rtc_statusb); @@ -161,9 +179,52 @@ struct resource *intr_res; void *intr_handler; struct eventtimer et; + ACPI_HANDLE acpi_handle; /* Handle of the PNP0B00 node */ }; static int +is_datetime_reg(ACPI_PHYSICAL_ADDRESS address) +{ + return address == 0x00 || + address == 0x02 || + address == 0x04 || + address == 0x04 || + (address >= 0x06 && address <= 0x09); +} + +static ACPI_STATUS +acpi_rtc_cmos_handler(UINT32 function, ACPI_PHYSICAL_ADDRESS address, UINT32 width, + UINT64 *value, void *context, void *region_context) +{ + struct atrtc_softc *sc; + + sc = (struct atrtc_softc *)context; + if (!value || !sc) + return AE_BAD_PARAMETER; + if (width > 32 || (width & 0x07) || address >= 64U) + return AE_BAD_PARAMETER; + if (function == ACPI_WRITE && + (is_datetime_reg(address) || + (width > 8 && address <= 0x09))) + return AE_BAD_PARAMETER; + + switch (function) { + case ACPI_READ: + acpi_cmos_read(address, (UINT8 *)value, width >> 3); + break; + case ACPI_WRITE: + acpi_cmos_write(address, (const UINT8 *)value, width >> 3); + break; + default: + return AE_BAD_PARAMETER; + } + printf("%s: %-5s%02u address=%04lx value=%08x\n", + __FUNCTION__, function == ACPI_READ ? "READ" : "WRITE", + width >> 3, address, *((UINT32 *)value)); + return AE_OK; +} + +static int rtc_start(struct eventtimer *et, sbintime_t first, sbintime_t period) { @@ -245,10 +306,17 @@ int i; sc = device_get_softc(dev); + sc->acpi_handle = acpi_get_handle(dev); sc->port_res = bus_alloc_resource(dev, SYS_RES_IOPORT, &sc->port_rid, IO_RTC, IO_RTC + 1, 2, RF_ACTIVE); if (sc->port_res == NULL) device_printf(dev, "Warning: Couldn't map I/O.\n"); + if (ACPI_FAILURE(AcpiInstallAddressSpaceHandler(sc->acpi_handle, + ACPI_ADR_SPACE_CMOS, acpi_rtc_cmos_handler, NULL, sc))) + { + device_printf(dev, "Error registering ACPI CMOS address space handler.\n"); + return 0; + } atrtc_start(); clock_register(dev, 1000000); bzero(&sc->et, sizeof(struct eventtimer)); @@ -286,6 +354,15 @@ return(0); } +static int atrtc_detach(device_t dev) +{ + struct atrtc_softc *sc; + + sc = device_get_softc(dev); + AcpiRemoveAddressSpaceHandler(sc->acpi_handle, ACPI_ADR_SPACE_CMOS, acpi_rtc_cmos_handler); + return bus_generic_detach(dev); +} + static int atrtc_resume(device_t dev) { @@ -366,7 +443,7 @@ /* Device interface */ DEVMETHOD(device_probe, atrtc_probe), DEVMETHOD(device_attach, atrtc_attach), - DEVMETHOD(device_detach, bus_generic_detach), + DEVMETHOD(device_detach, atrtc_detach), DEVMETHOD(device_shutdown, bus_generic_shutdown), DEVMETHOD(device_suspend, bus_generic_suspend), /* XXX stop statclock? */ --------------010903030303070503090707-- From owner-freebsd-acpi@FreeBSD.ORG Mon Aug 25 16:16:10 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id D4187B2D for ; Mon, 25 Aug 2014 16:16:10 +0000 (UTC) Received: from mail-qg0-x22c.google.com (mail-qg0-x22c.google.com [IPv6:2607:f8b0:400d:c04::22c]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 910603C68 for ; Mon, 25 Aug 2014 16:16:10 +0000 (UTC) Received: by mail-qg0-f44.google.com with SMTP id e89so13468466qgf.31 for ; Mon, 25 Aug 2014 09:16:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=qMTqZoZTy16wKkJqZR8DpTSNY5Wz6oMEuklQAMzesP0=; b=P9oDHfxzvbAvAEURCBa/5yq4C5dSck154RrI50kjKVuITDMRFH60LKTALWO9SY5pTr 8sdUB88SaMHf7T/N0E5SSaF8AF8T/qkW0yUEsHI24o2pRVAdWlJX/9grTdgNG3FBzJ4N dE2P1MuRAscDO4WjdaZs6YSfE/x3vj2a4gglX0ADilIcrtrzIFAN/Djvymgkk4nSss+r SeupQHZlJqCe7wKW0Ya7N9t3o/EX/iyH6JQPGsR+v93HO6CzqB0H2sGG0G81hIXz2LDu pQF/nthI2cwUeYQq+BlBvmJEbNNR3cB3ksT8uvgGObBF1KgqjXDr6TsL/nfLwcxJDGKp hL6g== MIME-Version: 1.0 X-Received: by 10.224.151.69 with SMTP id b5mr37396065qaw.37.1408983369593; Mon, 25 Aug 2014 09:16:09 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.224.39.139 with HTTP; Mon, 25 Aug 2014 09:16:09 -0700 (PDT) In-Reply-To: <53EE78ED.2030208@att.net> References: <53EE78ED.2030208@att.net> Date: Mon, 25 Aug 2014 09:16:09 -0700 X-Google-Sender-Auth: ewd8VsZa8f372FS5m3OXDm6ZgOw Message-ID: Subject: =?UTF-8?B?UmU6IOetlOWkjTogTXkgbGFwdG9wIGNhbid0IHJlc3VtZSBmcm9tIHN1c3BlbmQu?= From: Adrian Chadd To: Anthony Jenkins Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: =?UTF-8?B?5byg5pmT6Z2W?= , "freebsd-acpi@freebsd.org" , Kevin Oberman X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Aug 2014 16:16:10 -0000 Please do tidy it up and submit it for review! -a On 15 August 2014 14:17, Anthony Jenkins wrote: > On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: >> Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I recei= ved an e-mail, >> >> immediately compile the kernel (make a note #options VESA).But the probl= em persists, dmesg >> >> Information Reference url http://url.cn/SQ0vXD. >> >> >> >> Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a no= tebook can not boot >> >> until yesterday afternoon for a good notebook motherboard, now do not da= re to use =E2=80=9Cacpiconf >> >> -s 3=E2=80=9D testing. >> >> >> >> Do you have suggestions for me? > > You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region suppor= t atrtc.c.patch") to play with, it works to enable suspend/resume on some l= aptops and should be safe to try. I still need to clean it up (style, othe= r suggestions) for submission to FreeBSD, haven't gotten around to it yet. > > Anthony Jenkins > >> Thanks you~ >> >> >> >> >> >> >> >> -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- >> =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav [mailto:envolyse@gmail.com] >> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97=A5= 0:13 >> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 >> =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. >> >> >> >> On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 wr= ote: >> >>> The laptop can't resume, the screen no display, no beep sound. >> Can you please try to install video driver for your card and remove VESA= device from kernel configuration? >> >> >> >> >> >> =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com [mailto:kob6558@gmail.com= ] =E4=BB=A3=E8=A1=A8 Kevin Oberman >> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97=A5= 1:15 >> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 >> =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org >> =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. >> >> >> >> On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 > wrote: >> >> Hello, >> >> I am having a problem. >> >> My laptop is lenovo's zhaoyang K47A series HM65. >> >> I used ati graphics CARDS, Use the url ( >> https://wiki.freebsd.org/Graphics) t= he >> method of normal driving the graphics card. >> >> >> >> After set " >> >> sysctl debug. Bootverbose =3D 1 >> >> sysctl debug. Acpi. Suspend_bounce =3D 1 >> >> sysctl debug. Acpi. Resume_beep =3D 1 >> >> acpiconf -s 3 >> >> " >> >> The laptop can't resume, the screen no display, no beep sound. >> >> >> >> Disabling ACPI not helps to fix the problem. All files downloaded from >> http://url.cn/WVISGF. >> >> >> >> Output from sysctl hw.acpi >> >> hw.acpi.supported_sleep_state: S1 S3 S4 S5 >> >> hw.acpi.power_button_state: S5 >> >> hw.acpi.sleep_button_state: S1 >> >> hw.acpi.lid_switch_state: NONE >> >> hw.acpi.standby_state: S1 >> >> hw.acpi.suspend_state: S3 >> >> hw.acpi.sleep_delay: 1 >> >> hw.acpi.s4bios: 0 >> >> hw.acpi.verbose: 1 >> >> hw.acpi.disable_on_reboot: 0 >> >> hw.acpi.handle_reboot: 0 >> >> hw.acpi.reset_video: 0 >> >> hw.acpi.cpu.cx_lowest: C1 >> >> hw.acpi.acline: 1 >> >> hw.acpi.battery.life: 100 >> >> hw.acpi.battery.time: -1 >> >> hw.acpi.battery.state: 0 >> >> hw.acpi.battery.units: 2 >> >> hw.acpi.battery.info_expire: 5 >> >> hw.acpi.thermal.min_runtime: 0 >> >> hw.acpi.thermal.polling_rate: 10 >> >> hw.acpi.thermal.user_override: 0 >> >> hw.acpi.thermal.tz0.temperature: 62.0C >> >> hw.acpi.thermal.tz0.active: -1 >> >> hw.acpi.thermal.tz0.passive_cooling: 1 >> >> hw.acpi.thermal.tz0.thermal_flags: 0 >> >> hw.acpi.thermal.tz0._PSV: 95.0C >> >> hw.acpi.thermal.tz0._HOT: -1 >> >> hw.acpi.thermal.tz0._CRT: 100.0C >> >> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 >> >> hw.acpi.thermal.tz0._TC1: 2 >> >> hw.acpi.thermal.tz0._TC2: 3 >> >> hw.acpi.thermal.tz0._TSP: 100 >> >> >> >> Sincerely, >> ZhangXiaoJing. >> >> >> >> Have you tried building the kernel without VESA? Many laptops won't resu= me if you leave VESA in the kernel build. >> >> -- >> >> >> R. Kevin Oberman, Network Engineer, Retired >> E-mail: rkoberman@gmail.com >> >> _______________________________________________ >> freebsd-acpi@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-acpi >> To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" > > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" From owner-freebsd-acpi@FreeBSD.ORG Mon Aug 25 15:51:37 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7EDC2F19 for ; Mon, 25 Aug 2014 15:51:37 +0000 (UTC) Received: from BLU004-OMC2S1.hotmail.com (blu004-omc2s1.hotmail.com [65.55.111.76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (Client CN "*.outlook.com", Issuer "MSIT Machine Auth CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 410573A46 for ; Mon, 25 Aug 2014 15:51:36 +0000 (UTC) Received: from BLU436-SMTP67 ([65.55.111.73]) by BLU004-OMC2S1.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.22712); Mon, 25 Aug 2014 08:50:29 -0700 X-TMN: [JXbm6qdDz2FDkLhbLQ+XS6x3fBZFtNE9] X-Originating-Email: [zhangxiaojing@hotmail.com] Message-ID: Received: from skyPC ([122.239.235.82]) by BLU436-SMTP67.smtp.hotmail.com over TLS secured channel with Microsoft SMTPSVC(8.0.9200.16384); Mon, 25 Aug 2014 08:50:24 -0700 From: =?utf-8?B?5byg5pmT6Z2W?= To: "'Anthony Jenkins'" References: <53EE78ED.2030208@att.net> In-Reply-To: <53EE78ED.2030208@att.net> Subject: =?utf-8?Q?=E7=AD=94=E5=A4=8D:_=E7=AD=94=E5=A4=8D:_My_laptop_can't_resume_f?= =?utf-8?Q?rom_suspend.?= Date: Mon, 25 Aug 2014 23:50:17 +0800 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 15.0 Thread-Index: AQKorSl5wDquPSj2B+rkJbH2YizX6QG+CdzvAmKsNT0DVCrZ2Jnz9AaA Content-Language: zh-cn X-OriginalArrivalTime: 25 Aug 2014 15:50:29.0003 (UTC) FILETIME=[4B5F05B0:01CFC07C] X-Mailman-Approved-At: Mon, 25 Aug 2014 16:28:34 +0000 Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Aug 2014 15:51:37 -0000 I google less than complete information. Do you have the relevant code = can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa = directory, but my system is amd64 of ......=20 root@skycn:~ # uname -a FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 = 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8816=E6=97=A5 = 5:18 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96; 'Kevin = Oberman' =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: My laptop can't resume from = suspend. On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I=20 > received an e-mail, > > immediately compile the kernel (make a note #options VESA).But the=20 > problem persists, dmesg > > Information Reference url http://url.cn/SQ0vXD.=20 > > =20 > > Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a=20 > notebook can not boot > > until yesterday afternoon for a good notebook motherboard, now do not=20 > dare to use =E2=80=9Cacpiconf > > -s 3=E2=80=9D testing.=20 > > =20 > > Do you have suggestions for me? You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region = support atrtc.c.patch") to play with, it works to enable suspend/resume = on some laptops and should be safe to try. I still need to clean it up = (style, other suggestions) for submission to FreeBSD, haven't gotten = around to it yet. Anthony Jenkins > Thanks you~ > > =20 > > =20 > > =20 > > -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- > =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav = [mailto:envolyse@gmail.com] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 0:13 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. > > =20 > > On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 = wrote: > >> The laptop can't resume, the screen no display, no beep sound.=20 > Can you please try to install video driver for your card and remove = VESA device from kernel configuration? > > =20 > > =20 > > =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com = [mailto:kob6558@gmail.com] =E4=BB=A3=E8=A1=A8 Kevin Oberman > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 1:15 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org > =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. > > =20 > > On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 = > wrote: > > Hello, > > I am having a problem. > > My laptop is lenovo's zhaoyang K47A series HM65. > > I used ati graphics CARDS, Use the url (=20 > https://wiki.freebsd.org/Graphics) = > the method of normal driving the graphics card. > > > > After set " > > sysctl debug. Bootverbose =3D 1 > > sysctl debug. Acpi. Suspend_bounce =3D 1 > > sysctl debug. Acpi. Resume_beep =3D 1 > > acpiconf -s 3 > > " > > The laptop can't resume, the screen no display, no beep sound. > > > > Disabling ACPI not helps to fix the problem. All files downloaded from = > http://url.cn/WVISGF. > > > > Output from sysctl hw.acpi > > hw.acpi.supported_sleep_state: S1 S3 S4 S5 > > hw.acpi.power_button_state: S5 > > hw.acpi.sleep_button_state: S1 > > hw.acpi.lid_switch_state: NONE > > hw.acpi.standby_state: S1 > > hw.acpi.suspend_state: S3 > > hw.acpi.sleep_delay: 1 > > hw.acpi.s4bios: 0 > > hw.acpi.verbose: 1 > > hw.acpi.disable_on_reboot: 0 > > hw.acpi.handle_reboot: 0 > > hw.acpi.reset_video: 0 > > hw.acpi.cpu.cx_lowest: C1 > > hw.acpi.acline: 1 > > hw.acpi.battery.life: 100 > > hw.acpi.battery.time: -1 > > hw.acpi.battery.state: 0 > > hw.acpi.battery.units: 2 > > hw.acpi.battery.info_expire: 5 > > hw.acpi.thermal.min_runtime: 0 > > hw.acpi.thermal.polling_rate: 10 > > hw.acpi.thermal.user_override: 0 > > hw.acpi.thermal.tz0.temperature: 62.0C > > hw.acpi.thermal.tz0.active: -1 > > hw.acpi.thermal.tz0.passive_cooling: 1 > > hw.acpi.thermal.tz0.thermal_flags: 0 > > hw.acpi.thermal.tz0._PSV: 95.0C > > hw.acpi.thermal.tz0._HOT: -1 > > hw.acpi.thermal.tz0._CRT: 100.0C > > hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 > > hw.acpi.thermal.tz0._TC1: 2 > > hw.acpi.thermal.tz0._TC2: 3 > > hw.acpi.thermal.tz0._TSP: 100 > > > > Sincerely, > ZhangXiaoJing. > > =20 > > Have you tried building the kernel without VESA? Many laptops won't = resume if you leave VESA in the kernel build.=20 > > -- > > > R. Kevin Oberman, Network Engineer, Retired > E-mail: rkoberman@gmail.com > > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to = "freebsd-acpi-unsubscribe@freebsd.org" From owner-freebsd-acpi@FreeBSD.ORG Mon Aug 25 16:33:22 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 81F39BD9 for ; Mon, 25 Aug 2014 16:33:22 +0000 (UTC) Received: from mail-qa0-x22e.google.com (mail-qa0-x22e.google.com [IPv6:2607:f8b0:400d:c00::22e]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 3D1F83E6C for ; Mon, 25 Aug 2014 16:33:22 +0000 (UTC) Received: by mail-qa0-f46.google.com with SMTP id v10so12393014qac.33 for ; Mon, 25 Aug 2014 09:33:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=2z7V6Grv+gNdr1BxIZPLBfmZAfookilqtfknZalumig=; b=wrCHIJScAFcQEVXrpiWrK5UE1KPmOaiQFAh6HihFe6e27CNl+N6OtTvbCbbGs/PEEZ qWIU0YpUVqtxgDolV+ni82kFf6IBsNkuPQtNvIhzn9wllWOahAib8G6wawqfa8+zNAeW CcvEpPmIYWkQ4lErPkz4WG6abdqeQRlRQmBxQGMMuMIeDL9b9/xbClYaCXJWVUpGcmPB FcocplYCzcT9LstfRgMWh+cwe/2J58uwAlIEgjXn/xLLgkO+IyfKlY0vlplMWN8YiSvY ToIN/Pa1S1gcYlvkIPOi7Cff23kvNNUZwtkmrQPWlKVu10/yudJZ6CEIrMm2if49wKJl g/TA== MIME-Version: 1.0 X-Received: by 10.229.140.70 with SMTP id h6mr36475213qcu.3.1408984401166; Mon, 25 Aug 2014 09:33:21 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.224.39.139 with HTTP; Mon, 25 Aug 2014 09:33:21 -0700 (PDT) In-Reply-To: <53FB6011.3080509@att.net> References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> Date: Mon, 25 Aug 2014 09:33:21 -0700 X-Google-Sender-Auth: 3O-esIlIUI_n9ykre7eAOfClnZs Message-ID: Subject: =?UTF-8?B?UmU6IOetlOWkjTog562U5aSNOiBNeSBsYXB0b3AgY2FuJ3QgcmVzdW1lIGZyb20gc3VzcA==?= =?UTF-8?B?ZW5kLg==?= From: Adrian Chadd To: Anthony Jenkins Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Cc: =?UTF-8?B?5byg5pmT6Z2W?= , "freebsd-acpi@freebsd.org" X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Aug 2014 16:33:22 -0000 Hm! Cool, so you've reimplemented the RTC accesses to go via ACPI. Shouldn't this be another device though? One that gets attached if it finds it on the ACPI bus? -a On 25 August 2014 09:10, Anthony Jenkins wrote: > No problem... attached. And amd64 doesn't matter - works for x86-based c= omputers with the basic CMOS RTC chip (PNP0B00). Hopefully your suspend/re= sume problems are due to your ACPI BIOS needing to read/write info from/to = CMOS and not finding a CMOS handler. > > Anthony > > On 08/25/2014 11:50, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: >> I google less than complete information. Do you have the relevant code c= an be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa directo= ry, but my system is amd64 of ...... >> >> root@skycn:~ # uname -a >> FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 00:= 06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 >> >> >> -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- >> =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins [mailto:Anthony.B.Jenkins@a= tt.net] >> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8816=E6=97=A5= 5:18 >> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96; 'Kevin Oberman= ' >> =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org >> =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: My laptop can't resume from = suspend. >> >> On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: >>> Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I >>> received an e-mail, >>> >>> immediately compile the kernel (make a note #options VESA).But the >>> problem persists, dmesg >>> >>> Information Reference url http://url.cn/SQ0vXD. >>> >>> >>> >>> Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a >>> notebook can not boot >>> >>> until yesterday afternoon for a good notebook motherboard, now do not >>> dare to use =E2=80=9Cacpiconf >>> >>> -s 3=E2=80=9D testing. >>> >>> >>> >>> Do you have suggestions for me? >> You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region suppo= rt atrtc.c.patch") to play with, it works to enable suspend/resume on some = laptops and should be safe to try. I still need to clean it up (style, oth= er suggestions) for submission to FreeBSD, haven't gotten around to it yet. >> >> Anthony Jenkins >> >>> Thanks you~ >>> >>> >>> >>> >>> >>> >>> >>> -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- >>> =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav [mailto:envolyse@gmail.com= ] >>> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97= =A5 0:13 >>> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 >>> =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. >>> >>> >>> >>> On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 w= rote: >>> >>>> The laptop can't resume, the screen no display, no beep sound. >>> Can you please try to install video driver for your card and remove VES= A device from kernel configuration? >>> >>> >>> >>> >>> >>> =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com [mailto:kob6558@gmail.co= m] =E4=BB=A3=E8=A1=A8 Kevin Oberman >>> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97= =A5 1:15 >>> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 >>> =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org >>> =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. >>> >>> >>> >>> On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 > wrote: >>> >>> Hello, >>> >>> I am having a problem. >>> >>> My laptop is lenovo's zhaoyang K47A series HM65. >>> >>> I used ati graphics CARDS, Use the url ( >>> https://wiki.freebsd.org/Graphics) >>> the method of normal driving the graphics card. >>> >>> >>> >>> After set " >>> >>> sysctl debug. Bootverbose =3D 1 >>> >>> sysctl debug. Acpi. Suspend_bounce =3D 1 >>> >>> sysctl debug. Acpi. Resume_beep =3D 1 >>> >>> acpiconf -s 3 >>> >>> " >>> >>> The laptop can't resume, the screen no display, no beep sound. >>> >>> >>> >>> Disabling ACPI not helps to fix the problem. All files downloaded from >>> http://url.cn/WVISGF. >>> >>> >>> >>> Output from sysctl hw.acpi >>> >>> hw.acpi.supported_sleep_state: S1 S3 S4 S5 >>> >>> hw.acpi.power_button_state: S5 >>> >>> hw.acpi.sleep_button_state: S1 >>> >>> hw.acpi.lid_switch_state: NONE >>> >>> hw.acpi.standby_state: S1 >>> >>> hw.acpi.suspend_state: S3 >>> >>> hw.acpi.sleep_delay: 1 >>> >>> hw.acpi.s4bios: 0 >>> >>> hw.acpi.verbose: 1 >>> >>> hw.acpi.disable_on_reboot: 0 >>> >>> hw.acpi.handle_reboot: 0 >>> >>> hw.acpi.reset_video: 0 >>> >>> hw.acpi.cpu.cx_lowest: C1 >>> >>> hw.acpi.acline: 1 >>> >>> hw.acpi.battery.life: 100 >>> >>> hw.acpi.battery.time: -1 >>> >>> hw.acpi.battery.state: 0 >>> >>> hw.acpi.battery.units: 2 >>> >>> hw.acpi.battery.info_expire: 5 >>> >>> hw.acpi.thermal.min_runtime: 0 >>> >>> hw.acpi.thermal.polling_rate: 10 >>> >>> hw.acpi.thermal.user_override: 0 >>> >>> hw.acpi.thermal.tz0.temperature: 62.0C >>> >>> hw.acpi.thermal.tz0.active: -1 >>> >>> hw.acpi.thermal.tz0.passive_cooling: 1 >>> >>> hw.acpi.thermal.tz0.thermal_flags: 0 >>> >>> hw.acpi.thermal.tz0._PSV: 95.0C >>> >>> hw.acpi.thermal.tz0._HOT: -1 >>> >>> hw.acpi.thermal.tz0._CRT: 100.0C >>> >>> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 >>> >>> hw.acpi.thermal.tz0._TC1: 2 >>> >>> hw.acpi.thermal.tz0._TC2: 3 >>> >>> hw.acpi.thermal.tz0._TSP: 100 >>> >>> >>> >>> Sincerely, >>> ZhangXiaoJing. >>> >>> >>> >>> Have you tried building the kernel without VESA? Many laptops won't res= ume if you leave VESA in the kernel build. >>> >>> -- >>> >>> >>> R. Kevin Oberman, Network Engineer, Retired >>> E-mail: rkoberman@gmail.com >>> >>> _______________________________________________ >>> freebsd-acpi@freebsd.org mailing list >>> http://lists.freebsd.org/mailman/listinfo/freebsd-acpi >>> To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" >> >> > > > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" From owner-freebsd-acpi@FreeBSD.ORG Mon Aug 25 17:08:53 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 750F59AC for ; Mon, 25 Aug 2014 17:08:53 +0000 (UTC) Received: from nm19-vm1.access.bullet.mail.bf1.yahoo.com (nm19-vm1.access.bullet.mail.bf1.yahoo.com [216.109.115.96]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1E6803223 for ; Mon, 25 Aug 2014 17:08:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1408986172; bh=TM9b4rxDdI+W503JDX9rcudvuYS0YjJoJhhWXfE5QDs=; h=Received:Received:Received:DKIM-Signature:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=xPjti24xiTBGzHcKSpHw+fIw8YVyIxpNlF4gbyn5N9bEypgUx49PGkpoiXiSo3JGbxdPEyNOaf07LpMT2Z/knvG1mwe4NW9z0hWlO4sn7EAcvEAJO684NFX4k9NX6mbfIfgERDy8MUqMdR3BeMv+IyleT/V9SYaMNJkxkaqJJPQ= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=att.net; b=RmMYepXr2uGTDhLY9eIi/4Be/2XudU9hzX5L8Vs8ZpnQ1wKZ3heoyVfRcQTkvlib9KQtDLx7jvmb2ZI+Vfnsc9erQSN9fEeLbsxZJQb0mSMiPXlH8xNL3gNLEVilwShzdGQQVq8mNEcgod0uAHPve1Y817L98ygkOo8y/Eln+D0=; Received: from [66.196.81.156] by nm19.access.bullet.mail.bf1.yahoo.com with NNFMP; 25 Aug 2014 17:02:52 -0000 Received: from [98.138.226.244] by tm2.access.bullet.mail.bf1.yahoo.com with NNFMP; 25 Aug 2014 17:02:52 -0000 Received: from [127.0.0.1] by smtp115.sbc.mail.ne1.yahoo.com with NNFMP; 25 Aug 2014 17:02:52 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1408986172; bh=TM9b4rxDdI+W503JDX9rcudvuYS0YjJoJhhWXfE5QDs=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=mLRjLziGKzzAGzXqXa+CwqcUp4UgfLvEu5NOe32OPeo+UAlFSEpbrzf7wIrH6YRN+lyIY56LyxNxAt1QS+uo1jDyO7SudqHxGKHne59H78DJO2JcKQJIf3i6wYz1XL8aJet2fGdqxMNhut0INVcv+YGjGzW9PxEE6qzS8li3kjk= X-Yahoo-Newman-Id: 464855.87585.bm@smtp115.sbc.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: w5kgHyEVM1ny6vPYHg.ipu3Z2fCV27wbknIVHLu6OcTX3Ur 1821FlLGSXgOFK976LGAg_ctOzrm6_pnyl2dU4O3VY.c2he7qMviDDlWTD3R PF7lKnqM4ETEXoxLnp1KOhC3D8HutFOLImFjK4mxj1orWc3RpBEFEXzQMBcr FX_QgXEHmJ3YlySOJsJKq960rbk5gy_ZyuwmMC9iBB4StIv8E2AF_yIaiiLJ PRDPCZN_Xx36bnr82q5jd.YYkEpsa.Bs2vizNM5ey8txHT5U.R7bOGKnyZPN Y4T7X4b6BirHdjEsE8zlMa600sKQYBfDkoPMg0_WLFz.HBE9CFNEYfEWmhhf mSq30vm4a7M9yfC58dnq4Yqww.gqXyTKDGEd9LgqB7_kXApBRQKMk7N4X5OI UNIGXGTJ3rtXIt3mXqAnrP8LDY1qfG4rOiVde6PAyXZABVa6C_hIxCCFs3We P9Yz76PgXa482G6M0nRnufjbc7YJIUoO1TOr6k2Xe2GH7M1MXiyEUwmC_nLy B6tA97mpPZpGuKoVEp27EKd6kT9rJifMyEWJeNObFaL0pHlgsCLd6S6bmn5t r3PkEOREkhFWizScG_KeV0Aey98ra3w7pBDwsTTJTlHkfK6sWLOqr X-Yahoo-SMTP: OKD1keCswBBTAmAF1s00hLyKW3wE3YfSK0Eazl6b4VZG4LTqJxg- Message-ID: <53FB6C3B.2080802@att.net> Date: Mon, 25 Aug 2014 13:02:51 -0400 From: Anthony Jenkins User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Adrian Chadd Subject: Re: =?UTF-8?B?562U5aSNOiDnrZTlpI06IE15IGxhcHRvcCBjYW4ndCByZXN1bWU=?= =?UTF-8?B?IGZyb20gc3VzcGVuZC4=?= References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: =?UTF-8?B?5byg5pmT6Z2W?= , "freebsd-acpi@freebsd.org" X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Aug 2014 17:08:53 -0000 The device probe for the CMOS RTC chip handles that (I assume) - none of my stuff ever gets called if the device isn't found on the ACPI bus. The reimplementation of the CMOS read/write methods is just to allow ACPI multibyte accesses (the existing read/write calls lock single byte accesses). Anthony On 08/25/2014 12:33, Adrian Chadd wrote: > Hm! > > Cool, so you've reimplemented the RTC accesses to go via ACPI. > > Shouldn't this be another device though? One that gets attached if it > finds it on the ACPI bus? > > > -a > > > On 25 August 2014 09:10, Anthony Jenkins wrote: >> No problem... attached. And amd64 doesn't matter - works for x86-based computers with the basic CMOS RTC chip (PNP0B00). Hopefully your suspend/resume problems are due to your ACPI BIOS needing to read/write info from/to CMOS and not finding a CMOS handler. >> >> Anthony >> >> On 08/25/2014 11:50, 张晓靖 wrote: >>> I google less than complete information. Do you have the relevant code can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa directory, but my system is amd64 of ...... >>> >>> root@skycn:~ # uname -a >>> FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 >>> >>> >>> -----邮件原件----- >>> 发件人: Anthony Jenkins [mailto:Anthony.B.Jenkins@att.net] >>> 发送时间: 2014年8月16日 5:18 >>> 收件人: 张晓靖; 'Kevin Oberman' >>> 抄送: freebsd-acpi@freebsd.org >>> 主题: Re: 答复: My laptop can't resume from suspend. >>> >>> On 08/15/2014 16:20, 张晓靖 wrote: >>>> Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I >>>> received an e-mail, >>>> >>>> immediately compile the kernel (make a note #options VESA).But the >>>> problem persists, dmesg >>>> >>>> Information Reference url http://url.cn/SQ0vXD. >>>> >>>> >>>> >>>> Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a >>>> notebook can not boot >>>> >>>> until yesterday afternoon for a good notebook motherboard, now do not >>>> dare to use “acpiconf >>>> >>>> -s 3” testing. >>>> >>>> >>>> >>>> Do you have suggestions for me? >>> You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region support atrtc.c.patch") to play with, it works to enable suspend/resume on some laptops and should be safe to try. I still need to clean it up (style, other suggestions) for submission to FreeBSD, haven't gotten around to it yet. >>> >>> Anthony Jenkins >>> >>>> Thanks you~ >>>> >>>> >>>> >>>> >>>> >>>> >>>> >>>> -----邮件原件----- >>>> 发件人: Bykov Vladislav [mailto:envolyse@gmail.com] >>>> 发送时间: 2014年8月13日 0:13 >>>> 收件人: 张晓靖 >>>> 主题: Re: My laptop can't resume from suspend. >>>> >>>> >>>> >>>> On Tue, Aug 12, 2014 at 12:20:28PM +0800, 张晓靖 wrote: >>>> >>>>> The laptop can't resume, the screen no display, no beep sound. >>>> Can you please try to install video driver for your card and remove VESA device from kernel configuration? >>>> >>>> >>>> >>>> >>>> >>>> 发件人: kob6558@gmail.com [mailto:kob6558@gmail.com] 代表 Kevin Oberman >>>> 发送时间: 2014年8月13日 1:15 >>>> 收件人: 张晓靖 >>>> 抄送: freebsd-acpi@freebsd.org >>>> 主题: Re: My laptop can't resume from suspend. >>>> >>>> >>>> >>>> On Mon, Aug 11, 2014 at 9:20 PM, 张晓靖 > wrote: >>>> >>>> Hello, >>>> >>>> I am having a problem. >>>> >>>> My laptop is lenovo's zhaoyang K47A series HM65. >>>> >>>> I used ati graphics CARDS, Use the url ( >>>> https://wiki.freebsd.org/Graphics) >>>> the method of normal driving the graphics card. >>>> >>>> >>>> >>>> After set " >>>> >>>> sysctl debug. Bootverbose = 1 >>>> >>>> sysctl debug. Acpi. Suspend_bounce = 1 >>>> >>>> sysctl debug. Acpi. Resume_beep = 1 >>>> >>>> acpiconf -s 3 >>>> >>>> " >>>> >>>> The laptop can't resume, the screen no display, no beep sound. >>>> >>>> >>>> >>>> Disabling ACPI not helps to fix the problem. All files downloaded from >>>> http://url.cn/WVISGF. >>>> >>>> >>>> >>>> Output from sysctl hw.acpi >>>> >>>> hw.acpi.supported_sleep_state: S1 S3 S4 S5 >>>> >>>> hw.acpi.power_button_state: S5 >>>> >>>> hw.acpi.sleep_button_state: S1 >>>> >>>> hw.acpi.lid_switch_state: NONE >>>> >>>> hw.acpi.standby_state: S1 >>>> >>>> hw.acpi.suspend_state: S3 >>>> >>>> hw.acpi.sleep_delay: 1 >>>> >>>> hw.acpi.s4bios: 0 >>>> >>>> hw.acpi.verbose: 1 >>>> >>>> hw.acpi.disable_on_reboot: 0 >>>> >>>> hw.acpi.handle_reboot: 0 >>>> >>>> hw.acpi.reset_video: 0 >>>> >>>> hw.acpi.cpu.cx_lowest: C1 >>>> >>>> hw.acpi.acline: 1 >>>> >>>> hw.acpi.battery.life: 100 >>>> >>>> hw.acpi.battery.time: -1 >>>> >>>> hw.acpi.battery.state: 0 >>>> >>>> hw.acpi.battery.units: 2 >>>> >>>> hw.acpi.battery.info_expire: 5 >>>> >>>> hw.acpi.thermal.min_runtime: 0 >>>> >>>> hw.acpi.thermal.polling_rate: 10 >>>> >>>> hw.acpi.thermal.user_override: 0 >>>> >>>> hw.acpi.thermal.tz0.temperature: 62.0C >>>> >>>> hw.acpi.thermal.tz0.active: -1 >>>> >>>> hw.acpi.thermal.tz0.passive_cooling: 1 >>>> >>>> hw.acpi.thermal.tz0.thermal_flags: 0 >>>> >>>> hw.acpi.thermal.tz0._PSV: 95.0C >>>> >>>> hw.acpi.thermal.tz0._HOT: -1 >>>> >>>> hw.acpi.thermal.tz0._CRT: 100.0C >>>> >>>> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 >>>> >>>> hw.acpi.thermal.tz0._TC1: 2 >>>> >>>> hw.acpi.thermal.tz0._TC2: 3 >>>> >>>> hw.acpi.thermal.tz0._TSP: 100 >>>> >>>> >>>> >>>> Sincerely, >>>> ZhangXiaoJing. >>>> >>>> >>>> >>>> Have you tried building the kernel without VESA? Many laptops won't resume if you leave VESA in the kernel build. >>>> >>>> -- >>>> >>>> >>>> R. Kevin Oberman, Network Engineer, Retired >>>> E-mail: rkoberman@gmail.com >>>> >>>> _______________________________________________ >>>> freebsd-acpi@freebsd.org mailing list >>>> http://lists.freebsd.org/mailman/listinfo/freebsd-acpi >>>> To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" >>> >> >> _______________________________________________ >> freebsd-acpi@freebsd.org mailing list >> http://lists.freebsd.org/mailman/listinfo/freebsd-acpi >> To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" From owner-freebsd-acpi@FreeBSD.ORG Tue Aug 26 09:33:28 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8EC5444E for ; Tue, 26 Aug 2014 09:33:28 +0000 (UTC) Received: from BLU004-OMC2S8.hotmail.com (blu004-omc2s8.hotmail.com [65.55.111.83]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (Client CN "*.outlook.com", Issuer "MSIT Machine Auth CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 377F93FDE for ; Tue, 26 Aug 2014 09:33:27 +0000 (UTC) Received: from BLU436-SMTP89 ([65.55.111.72]) by BLU004-OMC2S8.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.22712); Tue, 26 Aug 2014 02:33:21 -0700 X-TMN: [zUjPoJv6jqfH9bUJp0VCSntbq9hWv775] X-Originating-Email: [zhangxiaojing@hotmail.com] Message-ID: Received: from skyPC ([218.75.24.110]) by BLU436-SMTP89.smtp.hotmail.com over TLS secured channel with Microsoft SMTPSVC(8.0.9200.16384); Tue, 26 Aug 2014 02:33:20 -0700 From: =?utf-8?B?5byg5pmT6Z2W?= To: "'Anthony Jenkins'" References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> In-Reply-To: <53FB6011.3080509@att.net> Subject: =?utf-8?Q?=E7=AD=94=E5=A4=8D:_=E7=AD=94=E5=A4=8D:_=E7=AD=94=E5=A4=8D:_My_l?= =?utf-8?Q?aptop_can't_resume_from_suspend.?= Date: Tue, 26 Aug 2014 17:33:16 +0800 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 15.0 Thread-Index: AQKorSl5wDquPSj2B+rkJbH2YizX6QG+CdzvAmKsNT0DVCrZ2AHKNGNxAprQPgWZ0fcCgA== Content-Language: zh-cn X-OriginalArrivalTime: 26 Aug 2014 09:33:21.0081 (UTC) FILETIME=[C67DE290:01CFC110] X-Mailman-Approved-At: Tue, 26 Aug 2014 11:26:18 +0000 Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Aug 2014 09:33:28 -0000 Thanks so quick reply, for the use of patch files I have no experience, = from the freebsd manual and the Internet did not find a reliable upgrade = process, you can tell me how to use this patch file to upgrade atrtc.c = it? For the use of the code, I was a rookie, needs your help.=20 Or tell me which part of the contents of the manual freebsd can guide me = to upgrade atrtc.c code, thank you. -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 = 0:11 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My = laptop can't resume from suspend. No problem... attached. And amd64 doesn't matter - works for x86-based = computers with the basic CMOS RTC chip (PNP0B00). Hopefully your = suspend/resume problems are due to your ACPI BIOS needing to read/write = info from/to CMOS and not finding a CMOS handler. Anthony On 08/25/2014 11:50, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > I google less than complete information. Do you have the relevant code = can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa = directory, but my system is amd64 of ......=20 > > root@skycn:~ # uname -a > FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 = 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 > > > -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- > =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8816=E6=97=A5 5:18 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96; 'Kevin = Oberman' > =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org > =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: My laptop can't resume = from suspend. > > On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: >> Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I=20 >> received an e-mail, >> >> immediately compile the kernel (make a note #options VESA).But the=20 >> problem persists, dmesg >> >> Information Reference url http://url.cn/SQ0vXD.=20 >> >> =20 >> >> Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a = >> notebook can not boot >> >> until yesterday afternoon for a good notebook motherboard, now do not = >> dare to use =E2=80=9Cacpiconf >> >> -s 3=E2=80=9D testing.=20 >> >> =20 >> >> Do you have suggestions for me? > You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region = support atrtc.c.patch") to play with, it works to enable suspend/resume = on some laptops and should be safe to try. I still need to clean it up = (style, other suggestions) for submission to FreeBSD, haven't gotten = around to it yet. > > Anthony Jenkins > >> Thanks you~ >> >> =20 >> >> =20 >> >> =20 >> >> -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- >> =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav = [mailto:envolyse@gmail.com] >> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 0:13 >> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 >> =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. >> >> =20 >> >> On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 = wrote: >> >>> The laptop can't resume, the screen no display, no beep sound.=20 >> Can you please try to install video driver for your card and remove = VESA device from kernel configuration? >> >> =20 >> >> =20 >> >> =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com = [mailto:kob6558@gmail.com] =E4=BB=A3=E8=A1=A8 Kevin Oberman >> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 1:15 >> =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 >> =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org >> =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. >> >> =20 >> >> On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 = > wrote: >> >> Hello, >> >> I am having a problem. >> >> My laptop is lenovo's zhaoyang K47A series HM65. >> >> I used ati graphics CARDS, Use the url (=20 >> =20 >> https://wiki.freebsd.org/Graphics) >> the method of normal driving the graphics card. >> >> >> >> After set " >> >> sysctl debug. Bootverbose =3D 1 >> >> sysctl debug. Acpi. Suspend_bounce =3D 1 >> >> sysctl debug. Acpi. Resume_beep =3D 1 >> >> acpiconf -s 3 >> >> " >> >> The laptop can't resume, the screen no display, no beep sound. >> >> >> >> Disabling ACPI not helps to fix the problem. All files downloaded=20 >> from http://url.cn/WVISGF. >> >> >> >> Output from sysctl hw.acpi >> >> hw.acpi.supported_sleep_state: S1 S3 S4 S5 >> >> hw.acpi.power_button_state: S5 >> >> hw.acpi.sleep_button_state: S1 >> >> hw.acpi.lid_switch_state: NONE >> >> hw.acpi.standby_state: S1 >> >> hw.acpi.suspend_state: S3 >> >> hw.acpi.sleep_delay: 1 >> >> hw.acpi.s4bios: 0 >> >> hw.acpi.verbose: 1 >> >> hw.acpi.disable_on_reboot: 0 >> >> hw.acpi.handle_reboot: 0 >> >> hw.acpi.reset_video: 0 >> >> hw.acpi.cpu.cx_lowest: C1 >> >> hw.acpi.acline: 1 >> >> hw.acpi.battery.life: 100 >> >> hw.acpi.battery.time: -1 >> >> hw.acpi.battery.state: 0 >> >> hw.acpi.battery.units: 2 >> >> hw.acpi.battery.info_expire: 5 >> >> hw.acpi.thermal.min_runtime: 0 >> >> hw.acpi.thermal.polling_rate: 10 >> >> hw.acpi.thermal.user_override: 0 >> >> hw.acpi.thermal.tz0.temperature: 62.0C >> >> hw.acpi.thermal.tz0.active: -1 >> >> hw.acpi.thermal.tz0.passive_cooling: 1 >> >> hw.acpi.thermal.tz0.thermal_flags: 0 >> >> hw.acpi.thermal.tz0._PSV: 95.0C >> >> hw.acpi.thermal.tz0._HOT: -1 >> >> hw.acpi.thermal.tz0._CRT: 100.0C >> >> hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 >> >> hw.acpi.thermal.tz0._TC1: 2 >> >> hw.acpi.thermal.tz0._TC2: 3 >> >> hw.acpi.thermal.tz0._TSP: 100 >> >> >> >> Sincerely, >> ZhangXiaoJing. >> >> =20 >> >> Have you tried building the kernel without VESA? Many laptops won't = resume if you leave VESA in the kernel build.=20 >> >> -- >> >> >> R. Kevin Oberman, Network Engineer, Retired >> E-mail: rkoberman@gmail.com >> >> _______________________________________________ >> freebsd-acpi@freebsd.org mailing list=20 >> http://lists.freebsd.org/mailman/listinfo/freebsd-acpi >> To unsubscribe, send any mail to = "freebsd-acpi-unsubscribe@freebsd.org" > > From owner-freebsd-acpi@FreeBSD.ORG Tue Aug 26 14:54:15 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 826F5FAE for ; Tue, 26 Aug 2014 14:54:15 +0000 (UTC) Received: from BLU004-OMC2S38.hotmail.com (blu004-omc2s38.hotmail.com [65.55.111.113]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (Client CN "*.outlook.com", Issuer "MSIT Machine Auth CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2BE3C3050 for ; Tue, 26 Aug 2014 14:54:15 +0000 (UTC) Received: from BLU436-SMTP102 ([65.55.111.72]) by BLU004-OMC2S38.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.22712); Tue, 26 Aug 2014 07:54:08 -0700 X-TMN: [XldixvQB9CefosBEvyvT7qqs69fy7lMOQ+YkwT9tcvQ=] X-Originating-Email: [zhangxiaojing@hotmail.com] Message-ID: Received: from skyPC ([122.239.214.122]) by BLU436-SMTP102.smtp.hotmail.com over TLS secured channel with Microsoft SMTPSVC(8.0.9200.16384); Tue, 26 Aug 2014 07:54:06 -0700 From: =?utf-8?B?5byg5pmT6Z2W?= To: "'Anthony Jenkins'" References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> In-Reply-To: <53FC7C2D.8030307@att.net> Subject: =?utf-8?Q?=E7=AD=94=E5=A4=8D:_=E7=AD=94=E5=A4=8D:_=E7=AD=94=E5=A4=8D:_?= =?utf-8?Q?=E7=AD=94=E5=A4=8D:_My_laptop_can't_resume_from_?= =?utf-8?Q?suspend.?= Date: Tue, 26 Aug 2014 22:54:01 +0800 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_0007_01CFC180.A401CDB0" X-Mailer: Microsoft Outlook 15.0 Thread-Index: AQKorSl5wDquPSj2B+rkJbH2YizX6QG+CdzvAmKsNT0DVCrZ2AHKNGNxAprQPgUCTgddawJ4i8HRmawbJMA= Content-Language: zh-cn X-OriginalArrivalTime: 26 Aug 2014 14:54:06.0912 (UTC) FILETIME=[95E6A400:01CFC13D] Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Aug 2014 14:54:15 -0000 ------=_NextPart_000_0007_01CFC180.A401CDB0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Also learned, thanks. patch when there are mistakes. Attachment is generated atrtc.c.rej root@skycn:/usr/src # patch -p0 < /root/atrtc.c.patch Hmm... Looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: sys/x86/isa/atrtc.c |=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D |--- sys/x86/isa/atrtc.c (revision 268728) |+++ sys/x86/isa/atrtc.c (working copy) -------------------------- Patching file sys/x86/isa/atrtc.c using Plan A... Hunk #1 failed at 31. Hunk #2 failed at 54. Hunk #3 failed at 74. Hunk #4 failed at 163. Hunk #5 failed at 179. Hunk #6 failed at 306. Hunk #7 failed at 354. Hunk #8 failed at 443. 8 out of 8 hunks failed--saving rejects to sys/x86/isa/atrtc.c.rej Done =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 = 20:23 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: = =E7=AD=94=E5=A4=8D: My laptop can't resume from suspend. 1. Install FreeBSD source tree. 2. Download patch file. 3. 'cd' to /usr/src. 4. Execute 'patch -p0 < path/to/atrtc.c.patch' 5. Rebuild and install kernel ('make kernel = KERNCONF=3DYOUR_KERNEL_CONFIG_FILE_NAME && reboot') 6. Test suspend/resume. Anthony References: =E2=80=A2 = https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-b= uilding.html On 08/26/2014 05:33, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: Thanks so quick reply, for the use of patch files I have no experience, = from the freebsd manual and the Internet did not find a reliable upgrade = process, you can tell me how to use this patch file to upgrade atrtc.c = it? For the use of the code, I was a rookie, needs your help.=20 Or tell me which part of the contents of the manual freebsd can guide me = to upgrade atrtc.c code, thank you. -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 = 0:11 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My = laptop can't resume from suspend. No problem... attached. And amd64 doesn't matter - works for x86-based = computers with the basic CMOS RTC chip (PNP0B00). Hopefully your = suspend/resume problems are due to your ACPI BIOS needing to read/write = info from/to CMOS and not finding a CMOS handler. Anthony On 08/25/2014 11:50, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: I google less than complete information. Do you have the relevant code = can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa = directory, but my system is amd64 of ......=20 root@skycn:~ # uname -a FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 = 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8816=E6=97=A5 = 5:18 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96; 'Kevin = Oberman' =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: My laptop can't resume from = suspend. On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I=20 received an e-mail, immediately compile the kernel (make a note #options VESA).But the=20 problem persists, dmesg Information Reference url http://url.cn/SQ0vXD.=20 =20 Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a=20 notebook can not boot until yesterday afternoon for a good notebook motherboard, now do not=20 dare to use =E2=80=9Cacpiconf -s 3=E2=80=9D testing.=20 =20 Do you have suggestions for me? You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region = support atrtc.c.patch") to play with, it works to enable suspend/resume = on some laptops and should be safe to try. I still need to clean it up = (style, other suggestions) for submission to FreeBSD, haven't gotten = around to it yet. Anthony Jenkins Thanks you~ =20 =20 =20 -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav [mailto:envolyse@gmail.com] =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 = 0:13 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. =20 On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 = wrote: The laptop can't resume, the screen no display, no beep sound.=20 Can you please try to install video driver for your card and remove VESA = device from kernel configuration? =20 =20 =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com = [mailto:kob6558@gmail.com] =E4=BB=A3=E8=A1=A8 Kevin Oberman =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 = 1:15 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. =20 On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 = > wrote: Hello, I am having a problem. My laptop is lenovo's zhaoyang K47A series HM65. I used ati graphics CARDS, Use the url (=20 =20 https://wiki.freebsd.org/Graphics) the method of normal driving the graphics card. After set " sysctl debug. Bootverbose =3D 1 sysctl debug. Acpi. Suspend_bounce =3D 1 sysctl debug. Acpi. Resume_beep =3D 1 acpiconf -s 3 " The laptop can't resume, the screen no display, no beep sound. Disabling ACPI not helps to fix the problem. All files downloaded=20 from http://url.cn/WVISGF. Output from sysctl hw.acpi hw.acpi.supported_sleep_state: S1 S3 S4 S5 hw.acpi.power_button_state: S5 hw.acpi.sleep_button_state: S1 hw.acpi.lid_switch_state: NONE hw.acpi.standby_state: S1 hw.acpi.suspend_state: S3 hw.acpi.sleep_delay: 1 hw.acpi.s4bios: 0 hw.acpi.verbose: 1 hw.acpi.disable_on_reboot: 0 hw.acpi.handle_reboot: 0 hw.acpi.reset_video: 0 hw.acpi.cpu.cx_lowest: C1 hw.acpi.acline: 1 hw.acpi.battery.life: 100 hw.acpi.battery.time: -1 hw.acpi.battery.state: 0 hw.acpi.battery.units: 2 hw.acpi.battery.info_expire: 5 hw.acpi.thermal.min_runtime: 0 hw.acpi.thermal.polling_rate: 10 hw.acpi.thermal.user_override: 0 hw.acpi.thermal.tz0.temperature: 62.0C hw.acpi.thermal.tz0.active: -1 hw.acpi.thermal.tz0.passive_cooling: 1 hw.acpi.thermal.tz0.thermal_flags: 0 hw.acpi.thermal.tz0._PSV: 95.0C hw.acpi.thermal.tz0._HOT: -1 hw.acpi.thermal.tz0._CRT: 100.0C hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 hw.acpi.thermal.tz0._TC1: 2 hw.acpi.thermal.tz0._TC2: 3 hw.acpi.thermal.tz0._TSP: 100 Sincerely, ZhangXiaoJing. =20 Have you tried building the kernel without VESA? Many laptops won't = resume if you leave VESA in the kernel build.=20 -- R. Kevin Oberman, Network Engineer, Retired E-mail: rkoberman@gmail.com _______________________________________________ freebsd-acpi@freebsd.org mailing list=20 http://lists.freebsd.org/mailman/listinfo/freebsd-acpi To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" ------=_NextPart_000_0007_01CFC180.A401CDB0 Content-Type: application/octet-stream; name="atrtc.c.rej.zip" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="atrtc.c.rej.zip" UEsDBBQAAAAIAOi0GkV4mYo3WQcAADgUAAALAAAAYXRydGMuYy5yZWrtWHtz0kAQ/zvO+B1W1JqU 1EJL8YFV00KnjLV0gPoYdTIhOSQjJExyqfXR7+7u3iUB2tr6v0wL3N6+97d7F16/ho3tut2EKr4/ gdev74DrHuwN2t22WXlwkAiB3x9UrNbdO4B/98PIn2aBgEo8l26Yeo8nlbt3qstkz5+HSF+ReJH+ SDfnXuLNHk9eXtrAf6k2yKOdbbu+BdWdhl1/xj6VzDPPn4SR2Awjmbi0CMR8RWHFn8b+Nzcc505U S3E/RrlwtBmIs03y0/c29R4vUdPt2f14NoujVZGSlT/OvERxkIeBGKPvRn+47x719t8YQQy/IByD ee9bMMK8yfBMWDCT5y5HkM7DyFxT0dCb1YIL+D4JpwLMmrWi8PT4BpVZdDul6KvWC92e2+4cOR9N yzDP4jCwwmhk1s6fNqxlJrLvtNt9w1QLqELtCpa2M3QWWOqWSguW0vBkIn3lVICwGqE3u1BTqNtI pSdD3yA+5HIT8RU3N+q0q7cy1594Ce8SJUs95EArA8dtd991250+/Nbr495Jv3fwN9mRlt1ztxqH feJUqGw27e1nUH3SsHdqjEpYJz5Is/k8TiQkcSYx2vQu7Wwq19FnfEfdmHT8Dug7Ra1MA+UUCCWu P4tTDMwLTGf/pOueHH4cdPedI85qZzAALwgSkaY2nHaPh09hfZSN1fftLcDvUxFR6X6hLR0PnHnT FloyNFM8HqdC6jYuENgiAUJLntd7u+yi0mQU5W7xEuMb6fLZxKbJuSyLtpYF2YVxnICpHKCqnrZA L15o31tQrSoSWiYJo0Aea8hNl0izwTR1ThBJuexvQKM1C9bw8+CARS+rQpOflMAX9IY8XYAnDzrj goLABOr9ErFqu2w3jjYRMksiMFGA9y9U6am4+PE9CaXAFOXlt6Es0PVQYKmbsIDTKZU3IuI/BC6p AqWrLLsNC6goMaBsluW3qWgc8nJ4pYFVgJR4qPIoqF4aBRTsSs8SZWUqILMOyYY1ZLMVFqur4Kte KHkFvurfwFcYX0HdVbYK1cXYxGtCGE1puHNcQF7mhmgaMvjU3Kw3Gni1qNab23aT5+YvDcFNnJ8i lXEiwJtOsYQgJ4JG6qMUKmoWV8DEMyzD7R+Md5nEU4siCVMMLH3Mg3bDUFmltA+GzvB0gH1M2oNs NvsBMoaviLQco1hiNZ6NIjul4J69MPqt1jVciJeFo+Zatr1FthGyqXQ06/YzTMeTZ/bOFufDSGWS +VSgNM4SX8A6325wyZqplpo08aJgKhIkF0LiTERShjORgJAMCZ4ah85x+6jDE0VLcUYO+Wue6pPj k9perQZRHAiVkwtSXRZZYTZM3cCTgoxQBv8+lhSsSmTmLbq7i5BCW79/cwsuk7euJjduIBf9/5Lp TVhbK+y9YNKzxabQQZH7ukJI5AxhmbgD8gSbemSOswhvUHFkwy2OZeT/HgZyYrNvBuCLyM0GrGMX ZcIGVUmCsTiX+RIzihZcTc3Tl5fXkwyheCx9WE/9fDykPo5R8yoeSylSUOCLIBvHlMG91LeImpfG 6bh7Tts9cfrO286w0y9EOAx4CdtUl3y5Rvl8YhFlIe3NxuntdOapxBqqZL7vd4cdrJjKlrkKshxO utb4Kv16elWhrRv94MR9D6U/Kd3JTxvfS4Xyq99x2s+ZtjqEi2qb+sy1dF21X5gwfcAYIxT41io1 lxEr1ZeGbqlbner/YgFv2V42laz574W4oLd5gm09NisP0+fwcGMnfVjbyvJs7j6sNabnwFbx+9Pz z1FF4xmfC0+P94fd3rHr2rBQzjJt8Aoq9FmB51DhaHPh0n+7bJp1U/dZHqelgisj6L1Zat9yJuWD NZHm5Tm4LrC50hEyEpgkjMMkXabMRRLGAZ9RxfV+q7Fj12v4IFxr2vUnajDTaRbqkah6Dh/vQl+4 eKCohjORwF7j9sbLhXGLvLQiTk3JWYFZ6ZCkEY98oyx18YSLfVefAMxqw+DjANM6cLu9k15/iIdx KRcGNikCfOW3scVryhYeYweug9V612GT3ILLZnfh+PToyKJNQ0elkKGMV957SRRGX5/DfpxNg+iR hJk3h+5m7zFiwir6mot/4HSPTvsd08GIuwhfjMZRVR7MPV8c6qm6kiLGBr9YidPuu4MTZ7/j7r/t DWy4cjLb7DUW09cNT+17dQCdJImT4q6AoTBQgZQXwyMl90DrLgIrmqiWdw3gE2oJOZVS9bia61dG 6zV+KYbRT5HEJleNERn+FPH4Ml4R9RqBT5v8Swz97rHDANR+mLXiwWKxD/LJHwiJP4SYOgeSMPov x8j1kKZy9sUsPhO3qSbcvoqLfU7wR+MRlmgxlOUrZ9n5OhT0JpuJ5ZjLK+d2s0lXzkZjm3/UUnfN NvOSFpGMMQ59C2x33uGAPOy1zQJE8UjYhqq4Wln2lZyeJG9txalXxLpxiRUDU6zLweYC1esFFkt8 jRvpJJNB/D1a0l5QrxPK0rmIgiWZnKhEKGcfPnzA7MdzLgED/hWn7Q9QSwECPwAUAAAACADotBpF eJmKN1kHAAA4FAAACwAkAAAAAAAAAIAAAAAAAAAAYXRydGMuYy5yZWoKACAAAAAAAAEAGACAq0eC O8HPAYCrR4I7wc8BAPbRuDzBzwFQSwUGAAAAAAEAAQBdAAAAggcAAAAA ------=_NextPart_000_0007_01CFC180.A401CDB0-- From owner-freebsd-acpi@FreeBSD.ORG Wed Aug 27 00:38:22 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 2DD291C7 for ; Wed, 27 Aug 2014 00:38:22 +0000 (UTC) Received: from BLU004-OMC2S8.hotmail.com (blu004-omc2s8.hotmail.com [65.55.111.83]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (Client CN "*.outlook.com", Issuer "MSIT Machine Auth CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CF2F23727 for ; Wed, 27 Aug 2014 00:38:21 +0000 (UTC) Received: from BLU437-SMTP61 ([65.55.111.72]) by BLU004-OMC2S8.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.22712); Tue, 26 Aug 2014 17:38:19 -0700 X-TMN: [JwRtEqx5nFDuDeqA1JllNhfR4aV6vnmC] X-Originating-Email: [zhangxiaojing@hotmail.com] Message-ID: Received: from skyPC ([218.75.24.110]) by BLU437-SMTP61.smtp.hotmail.com over TLS secured channel with Microsoft SMTPSVC(8.0.9200.16384); Tue, 26 Aug 2014 17:38:18 -0700 From: =?utf-8?B?5byg5pmT6Z2W?= To: "'Anthony Jenkins'" References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> <53FCA5B4.7020309@att.net> In-Reply-To: <53FCA5B4.7020309@att.net> Subject: =?UTF-8?B?562U5aSNOiDnrZTlpI06IOetlOWkjTog562U5aSNOiDnrZTlpI06IE15IGxhcHRv?= =?UTF-8?B?cCBjYW4ndCByZXN1bWUgZnJvbSBzdXNwZW5kLg==?= Date: Wed, 27 Aug 2014 08:38:14 +0800 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 15.0 Thread-Index: AQKorSl5wDquPSj2B+rkJbH2YizX6QG+CdzvAmKsNT0DVCrZ2AHKNGNxAprQPgUCTgddawJ4i8HRAeNdt8ICQiJxX5mLjx3w Content-Language: zh-cn X-OriginalArrivalTime: 27 Aug 2014 00:38:18.0555 (UTC) FILETIME=[324EE8B0:01CFC18F] Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2014 00:38:22 -0000 Thank you quickly solve this problem.=20 Last night successfully compiled kernel, but the problem is still not = resolved after recovery sleep, the phenomenon persists, restore the = notebook when there is energized action, but the hard drive lights under = no response, the screen does not display, only the shutdown restart. =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 = 23:20 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: = =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My laptop can't resume from = suspend. Run the patch through 'dos2unix' (/usr/ports/textproc/unix2dos package): [root@ajenkins-hplaptop /usr/src]# file atrtc.c.patch=20 atrtc.c.patch: unified diff output, ASCII text, with CRLF line = terminators [root@ajenkins-hplaptop /usr/src]# dos2unix atrtc.c.patch=20 [root@ajenkins-hplaptop /usr/src]# file atrtc.c.patch=20 atrtc.c.patch: unified diff output, ASCII text (I had to fake a DOS-ified patch file for this example by running it = through unix2dos first), but Hotmail likely converted it to DOS line = endings. Anthony On 08/26/2014 10:54, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: Also learned, thanks. patch when there are mistakes. Attachment is generated atrtc.c.rej root@skycn:/usr/src # patch -p0 < /root/atrtc.c.patch Hmm... Looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: sys/x86/isa/atrtc.c |=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D |--- sys/x86/isa/atrtc.c (revision 268728) |+++ sys/x86/isa/atrtc.c (working copy) -------------------------- Patching file sys/x86/isa/atrtc.c using Plan A... Hunk #1 failed at 31. Hunk #2 failed at 54. Hunk #3 failed at 74. Hunk #4 failed at 163. Hunk #5 failed at 179. Hunk #6 failed at 306. Hunk #7 failed at 354. Hunk #8 failed at 443. 8 out of 8 hunks failed--saving rejects to sys/x86/isa/atrtc.c.rej Done =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 = 20:23 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: = =E7=AD=94=E5=A4=8D: My laptop can't resume from suspend. 1. Install FreeBSD source tree. 2. Download patch file. 3. 'cd' to /usr/src. 4. Execute 'patch -p0 < path/to/atrtc.c.patch' 5. Rebuild and install kernel ('make kernel = KERNCONF=3DYOUR_KERNEL_CONFIG_FILE_NAME && reboot') 6. Test suspend/resume. Anthony References: =E2=80=A2 = https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-b= uilding.html On 08/26/2014 05:33, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: Thanks so quick reply, for the use of patch files I have no experience, = from the freebsd manual and the Internet did not find a reliable upgrade = process, you can tell me how to use this patch file to upgrade atrtc.c = it? For the use of the code, I was a rookie, needs your help.=20 Or tell me which part of the contents of the manual freebsd can guide me = to upgrade atrtc.c code, thank you. -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 = 0:11 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My = laptop can't resume from suspend. No problem... attached. And amd64 doesn't matter - works for x86-based = computers with the basic CMOS RTC chip (PNP0B00). Hopefully your = suspend/resume problems are due to your ACPI BIOS needing to read/write = info from/to CMOS and not finding a CMOS handler. Anthony On 08/25/2014 11:50, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: I google less than complete information. Do you have the relevant code = can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa = directory, but my system is amd64 of ......=20 root@skycn:~ # uname -a FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 = 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8816=E6=97=A5 = 5:18 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96; 'Kevin = Oberman' =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: My laptop can't resume from = suspend. On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I=20 received an e-mail, immediately compile the kernel (make a note #options VESA).But the=20 problem persists, dmesg Information Reference url http://url.cn/SQ0vXD.=20 =20 Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a=20 notebook can not boot until yesterday afternoon for a good notebook motherboard, now do not=20 dare to use =E2=80=9Cacpiconf -s 3=E2=80=9D testing.=20 =20 Do you have suggestions for me? You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region = support atrtc.c.patch") to play with, it works to enable suspend/resume = on some laptops and should be safe to try. I still need to clean it up = (style, other suggestions) for submission to FreeBSD, haven't gotten = around to it yet. Anthony Jenkins Thanks you~ =20 =20 =20 -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav [mailto:envolyse@gmail.com] =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 = 0:13 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. =20 On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 = wrote: The laptop can't resume, the screen no display, no beep sound.=20 Can you please try to install video driver for your card and remove VESA = device from kernel configuration? =20 =20 =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com = [mailto:kob6558@gmail.com] =E4=BB=A3=E8=A1=A8 Kevin Oberman =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 = 1:15 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. =20 On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 = > wrote: Hello, I am having a problem. My laptop is lenovo's zhaoyang K47A series HM65. I used ati graphics CARDS, Use the url (=20 =20 https://wiki.freebsd.org/Graphics) the method of normal driving the graphics card. After set " sysctl debug. Bootverbose =3D 1 sysctl debug. Acpi. Suspend_bounce =3D 1 sysctl debug. Acpi. Resume_beep =3D 1 acpiconf -s 3 " The laptop can't resume, the screen no display, no beep sound. Disabling ACPI not helps to fix the problem. All files downloaded=20 from http://url.cn/WVISGF. Output from sysctl hw.acpi hw.acpi.supported_sleep_state: S1 S3 S4 S5 hw.acpi.power_button_state: S5 hw.acpi.sleep_button_state: S1 hw.acpi.lid_switch_state: NONE hw.acpi.standby_state: S1 hw.acpi.suspend_state: S3 hw.acpi.sleep_delay: 1 hw.acpi.s4bios: 0 hw.acpi.verbose: 1 hw.acpi.disable_on_reboot: 0 hw.acpi.handle_reboot: 0 hw.acpi.reset_video: 0 hw.acpi.cpu.cx_lowest: C1 hw.acpi.acline: 1 hw.acpi.battery.life: 100 hw.acpi.battery.time: -1 hw.acpi.battery.state: 0 hw.acpi.battery.units: 2 hw.acpi.battery.info_expire: 5 hw.acpi.thermal.min_runtime: 0 hw.acpi.thermal.polling_rate: 10 hw.acpi.thermal.user_override: 0 hw.acpi.thermal.tz0.temperature: 62.0C hw.acpi.thermal.tz0.active: -1 hw.acpi.thermal.tz0.passive_cooling: 1 hw.acpi.thermal.tz0.thermal_flags: 0 hw.acpi.thermal.tz0._PSV: 95.0C hw.acpi.thermal.tz0._HOT: -1 hw.acpi.thermal.tz0._CRT: 100.0C hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 hw.acpi.thermal.tz0._TC1: 2 hw.acpi.thermal.tz0._TC2: 3 hw.acpi.thermal.tz0._TSP: 100 Sincerely, ZhangXiaoJing. =20 Have you tried building the kernel without VESA? Many laptops won't = resume if you leave VESA in the kernel build.=20 -- R. Kevin Oberman, Network Engineer, Retired E-mail: rkoberman@gmail.com _______________________________________________ freebsd-acpi@freebsd.org mailing list=20 http://lists.freebsd.org/mailman/listinfo/freebsd-acpi To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" From owner-freebsd-acpi@FreeBSD.ORG Wed Aug 27 01:10:04 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9156ED8B for ; Wed, 27 Aug 2014 01:10:04 +0000 (UTC) Received: from nm11-vm9.access.bullet.mail.bf1.yahoo.com (nm11-vm9.access.bullet.mail.bf1.yahoo.com [216.109.114.232]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3ABE43986 for ; Wed, 27 Aug 2014 01:10:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409101659; bh=c+9Cjyl8pCHLJG42TfGVGly1SWeZwbGqUmOmU5DpyV4=; h=Received:Received:Received:DKIM-Signature:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=ClGp8CpKxvQ3iYJHPe11bK2jKNbiY8VqsFAeDfpMXfe+6WqvOgSX5CMpQPYkUlocPX1y7xj9xnqzIl4LdaVcHo1CX2McVIyAfdHzN6Tj7PxLG7mVq/lvCeBi8E7KRnKtwLuJGHVUuA3fIyAZu6J2VZdJzCsrx6y9yNYFTYFbUYE= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=att.net; b=RqAEgnm/LnOQVkBT39L3e7Dg9190W4VqmRfJqE1mVFTfbDw+Mko3NrCv5ZuSp3qJnrluAeO1QA5XRdqAVc0zVGdCZalre+G6eToO+Avcu0awL5xphHgqoz4D2r6xbz428KVCiSMp02nMj6XPRwcA4ZoGv1wS3AD77dtw11SEgrA=; Received: from [66.196.81.156] by nm11.access.bullet.mail.bf1.yahoo.com with NNFMP; 27 Aug 2014 01:07:39 -0000 Received: from [98.138.226.240] by tm2.access.bullet.mail.bf1.yahoo.com with NNFMP; 27 Aug 2014 01:07:39 -0000 Received: from [127.0.0.1] by smtp111.sbc.mail.ne1.yahoo.com with NNFMP; 27 Aug 2014 01:07:39 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409101659; bh=c+9Cjyl8pCHLJG42TfGVGly1SWeZwbGqUmOmU5DpyV4=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=YNX83FcMIY9/yhSgneStC+xGfe/vT4eeOh8YeyCRGcL88gZ79YOu7bw+iUzKAu1YAwexPP8+vQfBIZAibQNHLloKaH17ZnJPjIucv/rXWq9cSoZN+JBlRBzjguvNqqgiIZXkbDboJi6QH4E6neoo+UApOoUB1Z6WRl37VfgbrVk= X-Yahoo-Newman-Id: 173852.16343.bm@smtp111.sbc.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: QuNH9yoVM1n3BmENfWp.uPduCl1Xo5YfrrhNZLTohcweMw6 JNmQUMbcyKlFMuSjIgYLNC3qQx5Zv3cuXk2.YDiDKSIjlGR6oGuKZqx1Bdew F9uYGWymJkSMxnCmB6Vz945PVGT_KmkVNFh12awPh9evXeWzA0Biw1f03b6w xpc1.JEMnq5uht3CkIqfg8USOJTyXRyIAC5F_goUuyBzCq5ABEHi5Gt1GHWF jbQKNU8CPje4VccUKsKlpv5G2waZAonlIvXUmvjQlJLOEjM3rIb5nK48zF8U c1j7VZGYRDzvn4tTnksBI.7bJfnY7CU5iJBkXWS_ygLWQvL7y53Ujl278MSV MRBO0S0ScaiuLuvowFvz_E8dpvr01wlOpxH5mzXETJepb8X97tP0P22LhA41 302_WXls1v6N5.e2fa7H6DWrw246FWBP1f6uGGhMeUwrzrABnQwKG87zAHgN Wkxdaa.ViehvsYHWs0KSMl0RdKkRLmgq5XYTzoeeW.KM1i93vefeQE45pfma Ly.R0Z3xd5nEkJV1wz6XmtO_z_c.d1wCh_ls8on7i8CRJ.vSpEpjf6QZ4SY7 2fg4zuhJp2Y0XXiHMNVKA_rA0UvANpwKR70zGW85L X-Yahoo-SMTP: OKD1keCswBBTAmAF1s00hLyKW3wE3YfSK0Eazl6b4VZG4LTqJxg- Message-ID: <53FD2F59.4040600@att.net> Date: Tue, 26 Aug 2014 21:07:37 -0400 From: Anthony Jenkins User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: =?UTF-8?B?5byg5pmT6Z2W?= Subject: Re: =?UTF-8?B?562U5aSNOiDnrZTlpI06IOetlOWkjTog562U5aSNOiDnrZTlpI0=?= =?UTF-8?B?OiBNeSBsYXB0b3AgY2FuJ3QgcmVzdW1lIGZyb20gc3VzcGVuZC4=?= References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> <53FCA5B4.7020309@att.net> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2014 01:10:04 -0000 Well it was just something to try. What make/model laptop is it? Mine is an HP Envy 14. With the patch it suspends/resumes, but the LCD backlight does not recover, so I have a black screen. I can ssh(1) into the laptop and everything. Can you jot down the laptop's IP address and, using another computer on the same network that has an ssh client, try to ssh into the computer (or even just try pinging it)? If you can ssh into the laptop, run 'dmesg', capture the output and post to the mailing list. Other things you can try: * hooking up an external monitor to the laptop and try suspend/resume again; my external monitor (HDMI) output works /somewhat/ after suspend/resume. * Ensure the VESA driver is not compiled into the kernel or loaded as a module. * Load the acpi_[hp|sony|asus|toshiba|ibm|fujitsu] driver for your laptop. The fix for my laptop's backlight problem seems pretty involved, looks like it's solved in Linux and would take some effort to port to FreeBSD. Anthony On 08/26/2014 20:38, 张晓靖 wrote: > Thank you quickly solve this problem. > Last night successfully compiled kernel, but the problem is still not resolved after recovery sleep, the phenomenon persists, restore the notebook when there is energized action, but the hard drive lights under no response, the screen does not display, only the shutdown restart. > > > 发件人: Anthony Jenkins [mailto:Anthony.B.Jenkins@att.net] > 发送时间: 2014年8月26日 23:20 > 收件人: 张晓靖 > 主题: Re: 答复: 答复: 答复: 答复: My laptop can't resume from suspend. > > Run the patch through 'dos2unix' (/usr/ports/textproc/unix2dos package): > [root@ajenkins-hplaptop /usr/src]# file atrtc.c.patch > atrtc.c.patch: unified diff output, ASCII text, with CRLF line terminators > [root@ajenkins-hplaptop /usr/src]# dos2unix atrtc.c.patch > [root@ajenkins-hplaptop /usr/src]# file atrtc.c.patch > atrtc.c.patch: unified diff output, ASCII text > (I had to fake a DOS-ified patch file for this example by running it through unix2dos first), but Hotmail likely converted it to DOS line endings. > > Anthony > > On 08/26/2014 10:54, 张晓靖 wrote: > Also learned, thanks. > patch when there are mistakes. Attachment is generated atrtc.c.rej > > root@skycn:/usr/src # patch -p0 < /root/atrtc.c.patch > Hmm... Looks like a unified diff to me... > The text leading up to this was: > -------------------------- > |Index: sys/x86/isa/atrtc.c > |=================================================================== > |--- sys/x86/isa/atrtc.c (revision 268728) > |+++ sys/x86/isa/atrtc.c (working copy) > -------------------------- > Patching file sys/x86/isa/atrtc.c using Plan A... > Hunk #1 failed at 31. > Hunk #2 failed at 54. > Hunk #3 failed at 74. > Hunk #4 failed at 163. > Hunk #5 failed at 179. > Hunk #6 failed at 306. > Hunk #7 failed at 354. > Hunk #8 failed at 443. > 8 out of 8 hunks failed--saving rejects to sys/x86/isa/atrtc.c.rej > Done > > > 发件人: Anthony Jenkins [mailto:Anthony.B.Jenkins@att.net] > 发送时间: 2014年8月26日 20:23 > 收件人: 张晓靖 > 主题: Re: 答复: 答复: 答复: My laptop can't resume from suspend. > > 1. Install FreeBSD source tree. > 2. Download patch file. > 3. 'cd' to /usr/src. > 4. Execute 'patch -p0 < path/to/atrtc.c.patch' > 5. Rebuild and install kernel ('make kernel KERNCONF=YOUR_KERNEL_CONFIG_FILE_NAME && reboot') > 6. Test suspend/resume. > Anthony > References: > • https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-building.html > > On 08/26/2014 05:33, 张晓靖 wrote: > Thanks so quick reply, for the use of patch files I have no experience, from the freebsd manual and the Internet did not find a reliable upgrade process, you can tell me how to use this patch file to upgrade atrtc.c it? For the use of the code, I was a rookie, needs your help. > > Or tell me which part of the contents of the manual freebsd can guide me to upgrade atrtc.c code, thank you. > > -----邮件原件----- > 发件人: Anthony Jenkins [mailto:Anthony.B.Jenkins@att.net] > 发送时间: 2014年8月26日 0:11 > 收件人: 张晓靖 > 抄送: freebsd-acpi@freebsd.org > 主题: Re: 答复: 答复: My laptop can't resume from suspend. > > No problem... attached. And amd64 doesn't matter - works for x86-based computers with the basic CMOS RTC chip (PNP0B00). Hopefully your suspend/resume problems are due to your ACPI BIOS needing to read/write info from/to CMOS and not finding a CMOS handler. > > Anthony > > On 08/25/2014 11:50, 张晓靖 wrote: > I google less than complete information. Do you have the relevant code can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa directory, but my system is amd64 of ...... > > root@skycn:~ # uname -a > FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 > > > -----邮件原件----- > 发件人: Anthony Jenkins [mailto:Anthony.B.Jenkins@att.net] > 发送时间: 2014年8月16日 5:18 > 收件人: 张晓靖; 'Kevin Oberman' > 抄送: freebsd-acpi@freebsd.org > 主题: Re: 答复: My laptop can't resume from suspend. > > On 08/15/2014 16:20, 张晓靖 wrote: > Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I > received an e-mail, > > immediately compile the kernel (make a note #options VESA).But the > problem persists, dmesg > > Information Reference url http://url.cn/SQ0vXD. > > > > Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a > notebook can not boot > > until yesterday afternoon for a good notebook motherboard, now do not > dare to use “acpiconf > > -s 3” testing. > > > > Do you have suggestions for me? > You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region support atrtc.c.patch") to play with, it works to enable suspend/resume on some laptops and should be safe to try. I still need to clean it up (style, other suggestions) for submission to FreeBSD, haven't gotten around to it yet. > > Anthony Jenkins > > Thanks you~ > > > > > > > > -----邮件原件----- > 发件人: Bykov Vladislav [mailto:envolyse@gmail.com] > 发送时间: 2014年8月13日 0:13 > 收件人: 张晓靖 > 主题: Re: My laptop can't resume from suspend. > > > > On Tue, Aug 12, 2014 at 12:20:28PM +0800, 张晓靖 wrote: > > The laptop can't resume, the screen no display, no beep sound. > Can you please try to install video driver for your card and remove VESA device from kernel configuration? > > > > > > 发件人: kob6558@gmail.com [mailto:kob6558@gmail.com] 代表 Kevin Oberman > 发送时间: 2014年8月13日 1:15 > 收件人: 张晓靖 > 抄送: freebsd-acpi@freebsd.org > 主题: Re: My laptop can't resume from suspend. > > > > On Mon, Aug 11, 2014 at 9:20 PM, 张晓靖 > wrote: > > Hello, > > I am having a problem. > > My laptop is lenovo's zhaoyang K47A series HM65. > > I used ati graphics CARDS, Use the url ( > > https://wiki.freebsd.org/Graphics) > the method of normal driving the graphics card. > > > > After set " > > sysctl debug. Bootverbose = 1 > > sysctl debug. Acpi. Suspend_bounce = 1 > > sysctl debug. Acpi. Resume_beep = 1 > > acpiconf -s 3 > > " > > The laptop can't resume, the screen no display, no beep sound. > > > > Disabling ACPI not helps to fix the problem. All files downloaded > from http://url.cn/WVISGF. > > > > Output from sysctl hw.acpi > > hw.acpi.supported_sleep_state: S1 S3 S4 S5 > > hw.acpi.power_button_state: S5 > > hw.acpi.sleep_button_state: S1 > > hw.acpi.lid_switch_state: NONE > > hw.acpi.standby_state: S1 > > hw.acpi.suspend_state: S3 > > hw.acpi.sleep_delay: 1 > > hw.acpi.s4bios: 0 > > hw.acpi.verbose: 1 > > hw.acpi.disable_on_reboot: 0 > > hw.acpi.handle_reboot: 0 > > hw.acpi.reset_video: 0 > > hw.acpi.cpu.cx_lowest: C1 > > hw.acpi.acline: 1 > > hw.acpi.battery.life: 100 > > hw.acpi.battery.time: -1 > > hw.acpi.battery.state: 0 > > hw.acpi.battery.units: 2 > > hw.acpi.battery.info_expire: 5 > > hw.acpi.thermal.min_runtime: 0 > > hw.acpi.thermal.polling_rate: 10 > > hw.acpi.thermal.user_override: 0 > > hw.acpi.thermal.tz0.temperature: 62.0C > > hw.acpi.thermal.tz0.active: -1 > > hw.acpi.thermal.tz0.passive_cooling: 1 > > hw.acpi.thermal.tz0.thermal_flags: 0 > > hw.acpi.thermal.tz0._PSV: 95.0C > > hw.acpi.thermal.tz0._HOT: -1 > > hw.acpi.thermal.tz0._CRT: 100.0C > > hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 > > hw.acpi.thermal.tz0._TC1: 2 > > hw.acpi.thermal.tz0._TC2: 3 > > hw.acpi.thermal.tz0._TSP: 100 > > > > Sincerely, > ZhangXiaoJing. > > > > Have you tried building the kernel without VESA? Many laptops won't resume if you leave VESA in the kernel build. > > -- > > > R. Kevin Oberman, Network Engineer, Retired > E-mail: rkoberman@gmail.com > > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" > > > > > > > > > From owner-freebsd-acpi@FreeBSD.ORG Wed Aug 27 01:20:52 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C2C5BE29 for ; Wed, 27 Aug 2014 01:20:52 +0000 (UTC) Received: from mail-qa0-x22b.google.com (mail-qa0-x22b.google.com [IPv6:2607:f8b0:400d:c00::22b]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7E75E3A31 for ; Wed, 27 Aug 2014 01:20:52 +0000 (UTC) Received: by mail-qa0-f43.google.com with SMTP id w8so14662580qac.16 for ; Tue, 26 Aug 2014 18:20:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=E4v386Bur0ytYT5nydjmx+rggnpwfNubM36tCwV3WSg=; b=dWF06IngF1gcRc7Hwhu5Pu9dX/X+VTnxBe96CEmSmXkixytj0Gu0nZScB0voRGPD8i /q3eAMM5DuKnaHAamyZbwJQoUTwYRoXRzkJbATzMSEcTRgAfYhdrt4DMZHTXzTQz9s89 rlYbjpJpkec2QG4oLAbmMgi4Mghmxqy1aZ1tsRoXbVk6VzrbpqnF9H/7obipNllV1Psl hoCmLTlR/bmcTB4YYMMzHxg02h6ynBwmcHifbRrNkYCsyvg2ELqJwibceKt4XdYmAUCN D8VhTEBktUHjGQh5PgMQmfVgQxDwJj0g6Iqbwzivbj5TU61YBh7/Z8LKEUiv34Cxpawo Klag== MIME-Version: 1.0 X-Received: by 10.224.86.5 with SMTP id q5mr54608729qal.36.1409102451739; Tue, 26 Aug 2014 18:20:51 -0700 (PDT) Sender: adrian.chadd@gmail.com Received: by 10.224.39.139 with HTTP; Tue, 26 Aug 2014 18:20:51 -0700 (PDT) In-Reply-To: <53FD2F59.4040600@att.net> References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> <53FCA5B4.7020309@att.net> <53FD2F59.4040600@att.net> Date: Tue, 26 Aug 2014 18:20:51 -0700 X-Google-Sender-Auth: LcwGsqmcInommCdFIc3A3osDP6s Message-ID: Subject: =?UTF-8?B?UmU6IOetlOWkjTog562U5aSNOiDnrZTlpI06IOetlOWkjTog562U5aSNOiBNeSBsYXB0bw==?= =?UTF-8?B?cCBjYW4ndCByZXN1bWUgZnJvbSBzdXNwZW5kLg==?= From: Adrian Chadd To: Anthony Jenkins Content-Type: text/plain; charset=UTF-8 Cc: =?UTF-8?B?5byg5pmT6Z2W?= , "freebsd-acpi@freebsd.org" X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2014 01:20:52 -0000 What's the thing that needs porting? -a From owner-freebsd-acpi@FreeBSD.ORG Wed Aug 27 01:53:36 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id AA4967E2 for ; Wed, 27 Aug 2014 01:53:36 +0000 (UTC) Received: from nm13-vm5.access.bullet.mail.gq1.yahoo.com (nm13-vm5.access.bullet.mail.gq1.yahoo.com [216.39.63.131]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5F47F3D35 for ; Wed, 27 Aug 2014 01:53:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409104039; bh=eg2WSnM5xJyyX6lJnscCo29G6DYCFy8gWuClY7i/ouU=; h=Received:Received:Received:DKIM-Signature:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=cIf+ILC2QF8lEqwrz5iEof1ua8f9+C1o9Oz8J8tntoTrZlNU9VQAtqqQqXa4h55xYfycI1dIT+6t7MYaX6EnzUEnx0zAcyqXDIhrvEUFFBiM9DwVkX7QHhMe3m7lI/WcWiFCkHjOfvYBHJU8sbHOiC1pcx9BPVgeFycEje3B6vE= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=att.net; b=ovyENNViKFQx0juLtx5jWtHGsGPizAFonuj2LqNlsw7sPyPur2/Q32LLzAbPj86w5SP9PmKknoU3usFbodbOO6tZHVBvPI59775NCiDGYupc+BXPBET+XqfmrNoqEQM6ZeuUePtSY063iC7bKq10mmX06I2qhH0uJ00mL1jIgcw=; Received: from [216.39.60.172] by nm13.access.bullet.mail.gq1.yahoo.com with NNFMP; 27 Aug 2014 01:47:19 -0000 Received: from [98.138.104.97] by tm8.access.bullet.mail.gq1.yahoo.com with NNFMP; 27 Aug 2014 01:47:19 -0000 Received: from [127.0.0.1] by smtp117.sbc.mail.ne1.yahoo.com with NNFMP; 27 Aug 2014 01:47:19 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409104039; bh=eg2WSnM5xJyyX6lJnscCo29G6DYCFy8gWuClY7i/ouU=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=sO9VwJNV5yTWD4/S+x2U8gXtjB8OYB6T+TBeK7xdBXVZXTv/T0jAc81iz9YZRXQ7eD5sm6qggYyfevJtxP024R1k7LngePJ7WYYeW7U3s0qxlHosaH7Va41OMb41ELumikXsBYeQAa+YJMDIFevZomNbydv+gdabosFpLDT1fcA= X-Yahoo-Newman-Id: 399455.96901.bm@smtp117.sbc.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: g_G_oBUVM1kYR6gJGkT.HnCEykehwcaIFFl1RUghBWgBp8K 5FKlmDNls17ewdP31hDmcyglVGx6VPsOpg7yJKtBp7mwmkFtwEIFSrMM0V0W p39rkpkiSxmi5f6IWNyNJBEUl7lqCuGxkvXqJHyvzeA37ATGMTDX4_4aRsSS DsmINtST1.YQIOdsgTDw1smOdgC6_F4RKTd0uxGqeDS9wIOiCE30MSuylRA0 CQkrS74EQQxpbEzP5kfSVB9rJTzXnlKqOXOFcTh7.2.hx25DR1MhGwWJKzKb NtW_cQh50uAM6.3oHDExweWcsGePNCQ2j.MnXtPza6oHgh1EvmjCeimmlYG6 dNzERvtJnjlkbWMjDAY.AKlW49cTaQm7P3VG9ftF.75DtZHqW0mxe2I7jfb4 pxdH.pmVdUNp9nrnrt2Pv8AaPx8OUurXztpYmG3Cq8HCJq3aH.Qw3Yh1k19f eXCI5m.IVTehz2zUZPNhmo7xov3g_7Yzjgn6Qu5xUvEfE8PsDopnCM45F9oQ e8sSGJY_4QbIkscq7nGi2tiOYA2HtGQCsCjVHRZ_D95cPXPtZ1B1Q0kPpvSs NniaNOJdcosX8aZVvDG5skHYDC.RN.pyM33hhq96uA8KB0dc0C5AEbY80F2W RfFH9kHbYXuiuUzJCT05C.3YACBYoaKw5_XDWNZTcI5z0l.VftcA4dO5ybdL gMNYb3M7VOgnPxm66tD.t.sNg9JDNe2cnnFt7GxstSL1n38ZCNqkWhYlZ5KY UVBMlxGU0Ffav5VcgXaSHNxf.vTHYgTrMHf7nmR5JQ72qzz1V8TtEQhlOZfm yv0vOpRbW4LLWTo6QPzs96XGBrqQN4Wgc.C4U5x._ X-Yahoo-SMTP: OKD1keCswBBTAmAF1s00hLyKW3wE3YfSK0Eazl6b4VZG4LTqJxg- Message-ID: <53FD38A6.3020108@att.net> Date: Tue, 26 Aug 2014 21:47:18 -0400 From: Anthony Jenkins User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Adrian Chadd Subject: Re: =?UTF-8?B?562U5aSNOiDnrZTlpI06IOetlOWkjTog562U5aSNOiDnrZTlpI0=?= =?UTF-8?B?OiBNeSBsYXB0b3AgY2FuJ3QgcmVzdW1lIGZyb20gc3VzcGVuZC4=?= References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> <53FCA5B4.7020309@att.net> <53FD2F59.4040600@att.net> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: =?UTF-8?B?5byg5pmT6Z2W?= , "freebsd-acpi@freebsd.org" X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2014 01:53:36 -0000 On 08/26/2014 21:20, Adrian Chadd wrote: > What's the thing that needs porting? > > > > -a > I've been eyeballing these links: http://h30434.www3.hp.com/t5/Notebook-Display-and-Video/Envy-14-display-backlight-controls-not-working-under-Linux/td-p/289176 https://bugs.launchpad.net/ubuntu/+source/linux/+bug/568611/ The Linux kernel apparently has backlight handlers and the ACPI kernel can either use the ACPI method or some "vendor" method (I think those are the handlers). I get a "Cannot find a backlight controller" error when I boot, and that code is in the radeon drm2 driver (sys/dev/drm2/radeon/radeon_acpi.c). info: [drm] Radeon Display Connectors info: [drm] Connector 0: info: [drm] LVDS-1 info: [drm] HPD1 info: [drm] DDC: 0x6530 0x6530 0x6534 0x6534 0x6538 0x6538 0x653c 0x653c info: [drm] Encoders: info: [drm] LCD1: INTERNAL_UNIPHY2 info: [drm] LCD1: TRAVIS info: [drm] Connector 1: info: [drm] HDMI-A-1 info: [drm] HPD3 info: [drm] DDC: 0x6550 0x6550 0x6554 0x6554 0x6558 0x6558 0x655c 0x655c info: [drm] Encoders: info: [drm] DFP1: INTERNAL_UNIPHY info: [drm] Internal thermal controller without fan control info: [drm] radeon: power management initialized info: [drm] fb mappable at 0xE114C000 info: [drm] vram apper at 0xE0000000 info: [drm] size 4325376 info: [drm] fb depth is 24 info: [drm] pitch is 5632 fbd0 on drmn0 VT: Replacing driver "vga" with new "fb". error: [drm:pid0:radeon_acpi_init] *ERROR* Trying encoder 0xfffff80007465400... error: [drm:pid0:radeon_acpi_init] *ERROR* Found LCD support. error: [drm:pid0:radeon_acpi_init] *ERROR* Trying encoder 0xfffff80007465000... error: [drm:pid0:radeon_acpi_init] *ERROR* Trying encoder 0xfffff80007329e00... error: [drm:pid0:radeon_acpi_init] *ERROR* Cannot find a backlight controller info: [drm] Initialized radeon 2.29.0 20080528 vgapci0: Boot video device (I added the *ERROR* lines to debug). It looks like the Linux changes mentioned in the 2nd link would go in there...but I gave up looking at it until I had more spare time. Anthony From owner-freebsd-acpi@FreeBSD.ORG Wed Aug 27 02:01:34 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 38B718FE for ; Wed, 27 Aug 2014 02:01:34 +0000 (UTC) Received: from BLU004-OMC2S26.hotmail.com (blu004-omc2s26.hotmail.com [65.55.111.101]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (Client CN "*.outlook.com", Issuer "MSIT Machine Auth CA 2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D99C13E35 for ; Wed, 27 Aug 2014 02:01:33 +0000 (UTC) Received: from BLU436-SMTP62 ([65.55.111.73]) by BLU004-OMC2S26.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.22712); Tue, 26 Aug 2014 19:01:32 -0700 X-TMN: [/CCLcj1/ni9fZvmvrmMtI+ynC0vYNHfv] X-Originating-Email: [zhangxiaojing@hotmail.com] Message-ID: Received: from skyPC ([218.75.24.110]) by BLU436-SMTP62.smtp.hotmail.com over TLS secured channel with Microsoft SMTPSVC(8.0.9200.16384); Tue, 26 Aug 2014 19:01:31 -0700 From: =?utf-8?B?5byg5pmT6Z2W?= To: "'Anthony Jenkins'" References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> <53FCA5B4.7020309@att.net> <53FD2F59.4040600@att.net> In-Reply-To: <53FD2F59.4040600@att.net> Subject: =?UTF-8?B?562U5aSNOiDnrZTlpI06IOetlOWkjTog562U5aSNOiDnrZTlpI06IOetlOWkjTo=?= =?UTF-8?B?IE15IGxhcHRvcCBjYW4ndCByZXN1bWUgZnJvbSBzdXM=?= =?UTF-8?B?cGVuZC4=?= Date: Wed, 27 Aug 2014 10:01:27 +0800 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Outlook 15.0 Thread-Index: AQKorSl5wDquPSj2B+rkJbH2YizX6QG+CdzvAmKsNT0DVCrZ2AHKNGNxAprQPgUCTgddawJ4i8HRAeNdt8ICQiJxXwKSt1ScAbKg8xCZaX/94A== Content-Language: zh-cn X-OriginalArrivalTime: 27 Aug 2014 02:01:31.0557 (UTC) FILETIME=[D25E8D50:01CFC19A] Cc: freebsd-acpi@freebsd.org X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2014 02:01:34 -0000 My Lenovo Zhaoyang k47a, ati graphics card (according to = https://wiki.freebsd.org/Graphics install the graphics driver, the = kernel has been removed vesa, dmesg | grep VESA no vesa information).=20 Previously used acpiconf -s 3 test, when a black screen, and sometimes = even use ssh on, sometimes not, when almost Rom estimated laptop = crashed. The worst crash resulting in a notebook can not boot, only to = Lenovo customer service to replace the motherboard.=20 "* Load the acpi_ [hp | sony | asus | toshiba | ibm | fujitsu]. Driver = for your laptop" is a good idea, I am ready to give it a try. -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net]=20 =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: 2014=E5=B9=B48=E6=9C=8827=E6=97=A5 = 9:08 =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: = =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My laptop = can't resume from suspend. Well it was just something to try. What make/model laptop is it? Mine = is an HP Envy 14. With the patch it suspends/resumes, but the LCD = backlight does not recover, so I have a black screen. I can ssh(1) into = the laptop and everything. Can you jot down the laptop's IP address = and, using another computer on the same network that has an ssh client, = try to ssh into the computer (or even just try pinging it)? If you can = ssh into the laptop, run 'dmesg', capture the output and post to the = mailing list. Other things you can try: * hooking up an external monitor to the laptop and try suspend/resume = again; my external monitor (HDMI) output works /somewhat/ after = suspend/resume. * Ensure the VESA driver is not compiled into the kernel or loaded as = a module. * Load the acpi_[hp|sony|asus|toshiba|ibm|fujitsu] driver for your = laptop. The fix for my laptop's backlight problem seems pretty involved, looks = like it's solved in Linux and would take some effort to port to FreeBSD. Anthony On 08/26/2014 20:38, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > Thank you quickly solve this problem.=20 > Last night successfully compiled kernel, but the problem is still not = resolved after recovery sleep, the phenomenon persists, restore the = notebook when there is energized action, but the hard drive lights under = no response, the screen does not display, only the shutdown restart. > > > =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 23:20 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: = =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My laptop can't resume from = suspend. > > Run the patch through 'dos2unix' (/usr/ports/textproc/unix2dos = package): > [root@ajenkins-hplaptop /usr/src]# file atrtc.c.patch > atrtc.c.patch: unified diff output, ASCII text, with CRLF line=20 > terminators [root@ajenkins-hplaptop /usr/src]# dos2unix atrtc.c.patch=20 > [root@ajenkins-hplaptop /usr/src]# file atrtc.c.patch > atrtc.c.patch: unified diff output, ASCII text (I had to fake a=20 > DOS-ified patch file for this example by running it through unix2dos = first), but Hotmail likely converted it to DOS line endings. > > Anthony > > On 08/26/2014 10:54, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > Also learned, thanks. > patch when there are mistakes. Attachment is generated atrtc.c.rej > > root@skycn:/usr/src # patch -p0 < /root/atrtc.c.patch Hmm... Looks=20 > like a unified diff to me... > The text leading up to this was: > -------------------------- > |Index: sys/x86/isa/atrtc.c > = |=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > |--- sys/x86/isa/atrtc.c (revision 268728) > |+++ sys/x86/isa/atrtc.c (working copy) > -------------------------- > Patching file sys/x86/isa/atrtc.c using Plan A... > Hunk #1 failed at 31. > Hunk #2 failed at 54. > Hunk #3 failed at 74. > Hunk #4 failed at 163. > Hunk #5 failed at 179. > Hunk #6 failed at 306. > Hunk #7 failed at 354. > Hunk #8 failed at 443. > 8 out of 8 hunks failed--saving rejects to sys/x86/isa/atrtc.c.rej=20 > Done > > > =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 20:23 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: = =E7=AD=94=E5=A4=8D: My laptop can't resume from suspend. > > 1. Install FreeBSD source tree. > 2. Download patch file. > 3. 'cd' to /usr/src. > 4. Execute 'patch -p0 < path/to/atrtc.c.patch' > 5. Rebuild and install kernel ('make kernel=20 > KERNCONF=3DYOUR_KERNEL_CONFIG_FILE_NAME && reboot') 6. Test = suspend/resume. > Anthony > References: > =E2=80=A2=20 > https://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfi > g-building.html > > On 08/26/2014 05:33, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > Thanks so quick reply, for the use of patch files I have no = experience, from the freebsd manual and the Internet did not find a = reliable upgrade process, you can tell me how to use this patch file to = upgrade atrtc.c it? For the use of the code, I was a rookie, needs your = help.=20 > > Or tell me which part of the contents of the manual freebsd can guide = me to upgrade atrtc.c code, thank you. > > -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- > =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8826=E6=97=A5 0:11 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org > =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: =E7=AD=94=E5=A4=8D: My = laptop can't resume from suspend. > > No problem... attached. And amd64 doesn't matter - works for = x86-based computers with the basic CMOS RTC chip (PNP0B00). Hopefully = your suspend/resume problems are due to your ACPI BIOS needing to = read/write info from/to CMOS and not finding a CMOS handler. > > Anthony > > On 08/25/2014 11:50, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > I google less than complete information. Do you have the relevant code = can be shared under it? I found atrtc.c file in /usr/src/sys/x86/isa = directory, but my system is amd64 of ......=20 > > root@skycn:~ # uname -a > FreeBSD skycn 10.0-RELEASE-p7 FreeBSD 10.0-RELEASE-p7 #2: Sat Aug 16 = 00:06:30 CST 2014 root@skycn:/usr/obj/usr/src/sys/MyKernel amd64 > > > -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- > =E5=8F=91=E4=BB=B6=E4=BA=BA: Anthony Jenkins = [mailto:Anthony.B.Jenkins@att.net] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8816=E6=97=A5 5:18 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96; 'Kevin = Oberman' > =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org > =E4=B8=BB=E9=A2=98: Re: =E7=AD=94=E5=A4=8D: My laptop can't resume = from suspend. > > On 08/15/2014 16:20, =E5=BC=A0=E6=99=93=E9=9D=96 wrote: > Thank Bykov Vladislav and Kevin Oberman's recommendations. Later I=20 > received an e-mail, > > immediately compile the kernel (make a note #options VESA).But the=20 > problem persists, dmesg > > Information Reference url http://url.cn/SQ0vXD.=20 > > =20 > > Even worse thing is, I do use "acpiconf -s 3"debugger, resulting in a=20 > notebook can not boot > > until yesterday afternoon for a good notebook motherboard, now do not=20 > dare to use =E2=80=9Cacpiconf > > -s 3=E2=80=9D testing.=20 > > =20 > > Do you have suggestions for me? > You could dig up my kernel patch (Google "FreeBSD ACPI CMOS region = support atrtc.c.patch") to play with, it works to enable suspend/resume = on some laptops and should be safe to try. I still need to clean it up = (style, other suggestions) for submission to FreeBSD, haven't gotten = around to it yet. > > Anthony Jenkins > > Thanks you~ > > =20 > > =20 > > =20 > > -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- > =E5=8F=91=E4=BB=B6=E4=BA=BA: Bykov Vladislav = [mailto:envolyse@gmail.com] > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 0:13 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. > > =20 > > On Tue, Aug 12, 2014 at 12:20:28PM +0800, =E5=BC=A0=E6=99=93=E9=9D=96 = wrote: > > The laptop can't resume, the screen no display, no beep sound.=20 > Can you please try to install video driver for your card and remove = VESA device from kernel configuration? > > =20 > > =20 > > =E5=8F=91=E4=BB=B6=E4=BA=BA: kob6558@gmail.com = [mailto:kob6558@gmail.com] =E4=BB=A3=E8=A1=A8 Kevin Oberman > =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: = 2014=E5=B9=B48=E6=9C=8813=E6=97=A5 1:15 > =E6=94=B6=E4=BB=B6=E4=BA=BA: =E5=BC=A0=E6=99=93=E9=9D=96 > =E6=8A=84=E9=80=81: freebsd-acpi@freebsd.org > =E4=B8=BB=E9=A2=98: Re: My laptop can't resume from suspend. > > =20 > > On Mon, Aug 11, 2014 at 9:20 PM, =E5=BC=A0=E6=99=93=E9=9D=96 = > wrote: > > Hello, > > I am having a problem. > > My laptop is lenovo's zhaoyang K47A series HM65. > > I used ati graphics CARDS, Use the url (=20 > > https://wiki.freebsd.org/Graphics) > the method of normal driving the graphics card. > > > > After set " > > sysctl debug. Bootverbose =3D 1 > > sysctl debug. Acpi. Suspend_bounce =3D 1 > > sysctl debug. Acpi. Resume_beep =3D 1 > > acpiconf -s 3 > > " > > The laptop can't resume, the screen no display, no beep sound. > > > > Disabling ACPI not helps to fix the problem. All files downloaded from = > http://url.cn/WVISGF. > > > > Output from sysctl hw.acpi > > hw.acpi.supported_sleep_state: S1 S3 S4 S5 > > hw.acpi.power_button_state: S5 > > hw.acpi.sleep_button_state: S1 > > hw.acpi.lid_switch_state: NONE > > hw.acpi.standby_state: S1 > > hw.acpi.suspend_state: S3 > > hw.acpi.sleep_delay: 1 > > hw.acpi.s4bios: 0 > > hw.acpi.verbose: 1 > > hw.acpi.disable_on_reboot: 0 > > hw.acpi.handle_reboot: 0 > > hw.acpi.reset_video: 0 > > hw.acpi.cpu.cx_lowest: C1 > > hw.acpi.acline: 1 > > hw.acpi.battery.life: 100 > > hw.acpi.battery.time: -1 > > hw.acpi.battery.state: 0 > > hw.acpi.battery.units: 2 > > hw.acpi.battery.info_expire: 5 > > hw.acpi.thermal.min_runtime: 0 > > hw.acpi.thermal.polling_rate: 10 > > hw.acpi.thermal.user_override: 0 > > hw.acpi.thermal.tz0.temperature: 62.0C > > hw.acpi.thermal.tz0.active: -1 > > hw.acpi.thermal.tz0.passive_cooling: 1 > > hw.acpi.thermal.tz0.thermal_flags: 0 > > hw.acpi.thermal.tz0._PSV: 95.0C > > hw.acpi.thermal.tz0._HOT: -1 > > hw.acpi.thermal.tz0._CRT: 100.0C > > hw.acpi.thermal.tz0._ACx: -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 > > hw.acpi.thermal.tz0._TC1: 2 > > hw.acpi.thermal.tz0._TC2: 3 > > hw.acpi.thermal.tz0._TSP: 100 > > > > Sincerely, > ZhangXiaoJing. > > =20 > > Have you tried building the kernel without VESA? Many laptops won't = resume if you leave VESA in the kernel build.=20 > > -- > > > R. Kevin Oberman, Network Engineer, Retired > E-mail: rkoberman@gmail.com > > _______________________________________________ > freebsd-acpi@freebsd.org mailing list=20 > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to = "freebsd-acpi-unsubscribe@freebsd.org" > > > > > > > > > From owner-freebsd-acpi@FreeBSD.ORG Wed Aug 27 02:43:11 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9F904F12 for ; Wed, 27 Aug 2014 02:43:11 +0000 (UTC) Received: from nm6-vm6.access.bullet.mail.gq1.yahoo.com (nm6-vm6.access.bullet.mail.gq1.yahoo.com [216.39.63.154]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 55E6131DC for ; Wed, 27 Aug 2014 02:43:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409106985; bh=75EfxvqyOXV/XQX0Sh866v74N4zZ/xKZumZn0j9c4Q0=; h=Received:Received:Received:DKIM-Signature:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=j2Qd6HLwbDaE2y9djflS1YKAPwfJI/5aBU2fI39UBY8EeZtLEq85bIDUSNmqg3BRCHEK1yPYLfZC0uE6OALxvk93qmtFfm9cv1R/jqIb4uPU/TUmnkmbbf8VyAfLooXUt9kBAM+SA77liYzHLwPhkMocXjikgNFapKrlzwXWBLY= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=att.net; b=BgIVdQWb//HvSe/L+vedG80nURNtSi8jqwC1H7QPfyjkXvb76xe8QpDIsr65Th/O4v8G9Lvv59awTnGSxan1pUDrjXO2oaLO+2SPhuv9DvN6ApVeILDrqRce63cI/Qv3mY2mpWpXVnD0QNK4XGjl3wL6819rPg2F4VmOEhI1npo=; Received: from [216.39.60.170] by nm6.access.bullet.mail.gq1.yahoo.com with NNFMP; 27 Aug 2014 02:36:25 -0000 Received: from [98.138.104.98] by tm6.access.bullet.mail.gq1.yahoo.com with NNFMP; 27 Aug 2014 02:36:24 -0000 Received: from [127.0.0.1] by smtp118.sbc.mail.ne1.yahoo.com with NNFMP; 27 Aug 2014 02:36:24 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409106984; bh=75EfxvqyOXV/XQX0Sh866v74N4zZ/xKZumZn0j9c4Q0=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=0w3+NYXBET/Nu56Xnei66NB35ux1jqQY/zIz0sNdSIM1cd3wnW2t4R2XTa+0Dtqoefl7ujjwSDiqr8DVwIoWOPgVNr5v6ZJTbJ4LGdTj2aC8Q6j9NNoRrqyc0w1MNiUJ6EwlsnUbue4zq7AhzuPD2R/bLByRZe1u78kxO3AzUMg= X-Yahoo-Newman-Id: 633139.3006.bm@smtp118.sbc.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: dsYXz7EVM1kKZjF7irfq79IUcKta4tqX1.nXpVnSPIaxqfb U2Rbxsn.38QsLq4lSX8YnyFXrII6H29Rb9wMj7BSEE91SeZLBZzMLtFvP4r9 4a0VY9td3XJuH0.l9OYWYQc6Pp4uBqIUonTAyZ85_mmLIYArV1uRjz_zxnIc .GcFVXjjcOC6jPg7WG8N8PCsL8NuxnUidH459z9W.VJSfkBWTL.Xw_Gp2MnP j50oVr6BDuzMCsRZuKT6FaAbhAM1Za9NAdY4FkBtMPWk.EXFN5b0wjhlO.j1 zcLplZEqKDYMkiN4YC.4sbc3TuPaRgq1ks8hve1lJPG3fCFQTo3tu3w9RMs5 C2OlTJs8Yuz0OhxyARFpu7NaxwuKb5gK_xiJJRm3Tu6djVMN4gQ5SPNWkCTa rM9gyfsjmAKs6cLKtBCKzYldHY9TbhjYqnrkOiXpjDw7D.yDBt35uVNp_7W0 60l5wxrKScjv5iZ0vvACWAL1CZHsahUumL2X6f8.YTrNPO5H4r7q75hhOdIw 9YlLrohqy53tMdrP3gkoRHAfHFyGaEFRkzYDP6C5GQwG6bYZPfkvXwaX1AgV hHtPQoScnJgN0lgPuSU1vbd3lRSjUOzSAzBVW2KRRaXy0M63Cy4xpuv8CzdR WO69mBLzYYWysHbOp1CiUoJl1u_qLERosFL9p3WAyjgih7YAC4ERbJ6J4nEV ospVBq3yBC_0LDYLug1KcnSBo3xDiceDMqeqqHoWrOo9sz5lSbiLxB_viRqW ivAVMkPOWqW4D2ysLhkwWdElgiNneKrFVTjMfrm7FC3Hssl4LetX_.w9sIu9 oldO_.hE7gt4bbix6ODd3nCMviUFjT.2VoAEwdSVG64kx_0_dEUosBCJQaM7 Z4elM7.aoxCMJOVJPecZDOQN6FULvWw8Pgl2R3qbAruuca6KBJ7g.HyDEFPY Xu586YbfFwVLzenvzeA0mpYUDyejDsDkU.gyseUpTlMrTcvnS2WOs0BP90Yv Cq_EIUogSwbJSiNjYeA-- X-Yahoo-SMTP: OKD1keCswBBTAmAF1s00hLyKW3wE3YfSK0Eazl6b4VZG4LTqJxg- Message-ID: <53FD4427.3070308@att.net> Date: Tue, 26 Aug 2014 22:36:23 -0400 From: Anthony Jenkins User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Adrian Chadd Subject: Re: =?UTF-8?B?562U5aSNOiDnrZTlpI06IOetlOWkjTog562U5aSNOiDnrZTlpI0=?= =?UTF-8?B?OiBNeSBsYXB0b3AgY2FuJ3QgcmVzdW1lIGZyb20gc3VzcGVuZC4=?= References: <53EE78ED.2030208@att.net> <53FB6011.3080509@att.net> <53FC7C2D.8030307@att.net> <53FCA5B4.7020309@att.net> <53FD2F59.4040600@att.net> <53FD38A6.3020108@att.net> In-Reply-To: <53FD38A6.3020108@att.net> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: =?UTF-8?B?5byg5pmT6Z2W?= , "freebsd-acpi@freebsd.org" X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2014 02:43:11 -0000 On 08/26/2014 21:47, Anthony Jenkins wrote: > On 08/26/2014 21:20, Adrian Chadd wrote: >> What's the thing that needs porting? >> >> >> >> -a >> > I've been eyeballing these links: > > http://h30434.www3.hp.com/t5/Notebook-Display-and-Video/Envy-14-display-backlight-controls-not-working-under-Linux/td-p/289176 > https://bugs.launchpad.net/ubuntu/+source/linux/+bug/568611/ Here's a link to (what I think is) the commit that needs to be ported for me to enjoy a laptop with the brightness not at 100% 100% of the time: http://kernel.ubuntu.com/git?p=kamal/ubuntu-maverick.git;a=commit;h=b134c5ba49666ab640cbc5ad8a562c9f22539cc3 Anthony > The Linux kernel apparently has backlight handlers and the ACPI kernel can either use the ACPI method or some "vendor" method (I think those are the handlers). I get a "Cannot find a backlight controller" error when I boot, and that code is in the radeon drm2 driver (sys/dev/drm2/radeon/radeon_acpi.c). > > info: [drm] Radeon Display Connectors > info: [drm] Connector 0: > info: [drm] LVDS-1 > info: [drm] HPD1 > info: [drm] DDC: 0x6530 0x6530 0x6534 0x6534 0x6538 0x6538 0x653c 0x653c > info: [drm] Encoders: > info: [drm] LCD1: INTERNAL_UNIPHY2 > info: [drm] LCD1: TRAVIS > info: [drm] Connector 1: > info: [drm] HDMI-A-1 > info: [drm] HPD3 > info: [drm] DDC: 0x6550 0x6550 0x6554 0x6554 0x6558 0x6558 0x655c 0x655c > info: [drm] Encoders: > info: [drm] DFP1: INTERNAL_UNIPHY > info: [drm] Internal thermal controller without fan control > info: [drm] radeon: power management initialized > info: [drm] fb mappable at 0xE114C000 > info: [drm] vram apper at 0xE0000000 > info: [drm] size 4325376 > info: [drm] fb depth is 24 > info: [drm] pitch is 5632 > fbd0 on drmn0 > VT: Replacing driver "vga" with new "fb". > error: [drm:pid0:radeon_acpi_init] *ERROR* Trying encoder 0xfffff80007465400... > error: [drm:pid0:radeon_acpi_init] *ERROR* Found LCD support. > error: [drm:pid0:radeon_acpi_init] *ERROR* Trying encoder 0xfffff80007465000... > error: [drm:pid0:radeon_acpi_init] *ERROR* Trying encoder 0xfffff80007329e00... > error: [drm:pid0:radeon_acpi_init] *ERROR* Cannot find a backlight controller > info: [drm] Initialized radeon 2.29.0 20080528 > vgapci0: Boot video device > > (I added the *ERROR* lines to debug). It looks like the Linux changes mentioned in the 2nd link would go in there...but I gave up looking at it until I had more spare time. > > Anthony > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" > From owner-freebsd-acpi@FreeBSD.ORG Fri Aug 29 15:37:34 2014 Return-Path: Delivered-To: freebsd-acpi@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8C6B4980 for ; Fri, 29 Aug 2014 15:37:34 +0000 (UTC) Received: from nm17-vm7.access.bullet.mail.bf1.yahoo.com (nm17-vm7.access.bullet.mail.bf1.yahoo.com [216.109.115.70]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 397161CD6 for ; Fri, 29 Aug 2014 15:37:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409326251; bh=hFKJVe7DhVdbLyTG/CoCbb3uR5u76YUvqTvTryljBnk=; h=Received:Received:Received:DKIM-Signature:X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=HmOOJ+zmsYX2KG6/D4mECkHxirrCsRK5cEniWKsJ6NAAGUkRKz4zKDdmgN7NYmXLszTZXUw/hfg5+NmP0mf3w8L0P8NA3rWlrSszR67dqyipZkzovqswqnE+eGu8cjSUYeJ8qZJEZh8SP8R5Jthdd4minW8NYiPNHbhrQko0qkg= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=att.net; b=1oInrHCq5GudZSNT9+YEHUvPHYJi0W/zVG0vwohX/UFY0IR5Ngx4ZEZcMhkukTWAimIG8iCRxal0jJQdfTVLOJjgnER9GVsbA01GD8yxsQQ7yMLq3SUu6EjA3HzgqdvBAZOnByC2TWAb4Oa9LLCFF16TAT0Q64kWnoJVvH1apWU=; Received: from [66.196.81.162] by nm17.access.bullet.mail.bf1.yahoo.com with NNFMP; 29 Aug 2014 15:30:51 -0000 Received: from [98.138.226.241] by tm8.access.bullet.mail.bf1.yahoo.com with NNFMP; 29 Aug 2014 15:30:50 -0000 Received: from [127.0.0.1] by smtp112.sbc.mail.ne1.yahoo.com with NNFMP; 29 Aug 2014 15:30:50 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=att.net; s=s1024; t=1409326250; bh=hFKJVe7DhVdbLyTG/CoCbb3uR5u76YUvqTvTryljBnk=; h=X-Yahoo-Newman-Id:X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type:Content-Transfer-Encoding; b=IwZZrPkZ3dttz6Ce7X1rraJ7mHLBcFYiWtANZs1GwRhMLc4n3+WMg78p6NvTTbraBWvjK378lxYSZ10tEotkXHubBlXMERzUHeRilHwDHc8CB0AQaB2a/Lk743vEGSrnoAi8PTNMde8/plae+A95waVEKsrCSNqBGgJCRCOybeA= X-Yahoo-Newman-Id: 808748.81117.bm@smtp112.sbc.mail.ne1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: giH_5tcVM1ntK.4um089klb5UYfvoPqNyH3rA220G91mPim 3B1SqKnd9VKlCFOkKI.CV8eyMM6Lw5JpjqGHZgoWeKv.TRo1zLbcGCBX9PUX 1ioSP8uYl5FmSRbG16VLtt4wLuWwrknAjND5BA6sPcHPYcPGKM1gkN8UEa81 CWLa3_nYbwPh6hBxIVqm6AKyWtjI3WrpRTvvqEuZNEOACYS7WxSb000Xjt_r Ugo.vwGc8aKO.ZVmBc1kbBX3DFAfdYLI7meaniF.jjP.NebIFwEOAe4LwEcV hjFV27E06llrrSuZm0Itk8uN4ZAi2A7roTgrkUjptuMYzUuQAWsapfX4edrX IGmbz0v7JQRZdXlha0fRVcycVjmjNPCkho0Vj_We4R1YGEGER0gvsAVWghMY tg2x_lPZH4wblr3eHe3oJSov4opw1gVDYEopUiPRLOibzzjRFmpZEasmcf0U x0NzMUFy8LyvalJqv7jZifFLO0VYaSP1GmFwRLN5CzkyD3kta8Sa_VaslhoG 2Mx2d2WSnIGT0tZPMPqusy2wJHUtXltiApPz_6f5k7iImnabnYuSSh7MqnmV amrnct.ZQ0GTLTLSmAdR9uxK03KZ6xgqc_fzMBMu1vsH33YvBwsGlMj2Fov7 66ED4oDQCUWge0b7wirIR0HEER.YMsQ4gkUsETsB6w_iNOn6T.4.Z3NxZqSY - X-Yahoo-SMTP: OKD1keCswBBTAmAF1s00hLyKW3wE3YfSK0Eazl6b4VZG4LTqJxg- Message-ID: <54009CA9.50101@att.net> Date: Fri, 29 Aug 2014 11:30:49 -0400 From: Anthony Jenkins User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 To: freebsd-acpi@freebsd.org Subject: [PATCH] ACPI CMOS region support rev. 3 References: <53DD61BD.7050508@att.net> <20140805175541.G62404@sola.nimnet.asn.au> <20140806040804.P849@besplex.bde.org> <53F0C9BF.9060405@att.net> In-Reply-To: <53F0C9BF.9060405@att.net> MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: Ian Smith X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Aug 2014 15:37:34 -0000 Okay here's another revision of the patch, hopefully I made good progress in cleaning up the style and addressing everyone's concerns. Comments/criticisms welcome as always! Patches: * Current: [1]http://www.qtchat.org/docs/atrtc.c-20140829.patch * Previous: [2]http://www.qtchat.org/docs/atrtc.c.patch Changes: * Removed 'U' suffix from integer literals. * Ensured all (my) lines were <= 40 columns * Changed continuation indent to 4 columns. * Replaced is_datetime_reg() with more generic acpi_check_rtc_byteaccess() to encapsulate (deeper) validation of ACPI CMOS accesses. * Replaced some ACPI Windows-like typenames with FreeBSD typenames where possible. Booting my HP Envy 14 laptop and suspend/resuming shows the only ACPI CMOS accesses are byte reads of registers 0x06, 0x04 and 0x02: uhub4: at usbus0, port 1, addr 1 (disconnected) ugen0.2: at usbus0 (disconnected) ums0: at uhub4, port 3, addr 1 (disconnected) uhid0: at uhub4, port 3, addr 1 (disconnected) uhub3: at usbus1, port 1, addr 1 (disconnected) uhub2: at usbus2, port 1, addr 1 (disconnected) ugen2.2: at usbus2 (disconnected) urtwn0: at uhub2, port 1, addr 2 (disconnected) uhub1: at usbus3, port 1, addr 1 (disconnected) ugen3.2: at usbus3 (disconnected) ubt0: at uhub1, port 4, addr 2 (disconnected) uhub0: at usbus4, port 1, addr 1 (disconnected) ugen4.2: at usbus4 (disconnected) acpi_rtc_cmos_handler: READ 01 address=0006 value=00000006 acpi_rtc_cmos_handler: READ 01 address=0004 value=00000015 acpi_rtc_cmos_handler: READ 01 address=0002 value=00000006 vgapci0: child drmn0 requested pci_set_powerstate info: [drm] PCIE GART of 512M enabled (table at 0x0000000000040000). drmn0: info: WB enabled drmn0: info: fence driver on ring 0 use gpu addr 0x0000000020000c00 and cpu addr 0x0xfffff800b686cc00 drmn0: info: fence driver on ring 1 use gpu addr 0x0000000020000c04 and cpu addr 0x0xfffff800b686cc04 drmn0: info: fence driver on ring 2 use gpu addr 0x0000000020000c08 and cpu addr 0x0xfffff800b686cc08 drmn0: info: fence driver on ring 3 use gpu addr 0x0000000020000c0c and cpu addr 0x0xfffff800b686cc0c drmn0: info: fence driver on ring 4 use gpu addr 0x0000000020000c10 and cpu addr 0x0xfffff800b686cc10 info: [drm] ring test on 0 succeeded in 3 usecs info: [drm] ring test on 3 succeeded in 2 usecs info: [drm] ring test on 4 succeeded in 2 usecs info: [drm] ib test on ring 0 succeeded in 0 usecs info: [drm] ib test on ring 3 succeeded in 0 usecs info: [drm] ib test on ring 4 succeeded in 0 usecs re0: link state changed to DOWN psm0: system resume hook called. psm0: current command byte: 0065 (reinitialize). Backlight still doesn't resume, but can still ssh(1) into laptop. Thanks, Anthony Jenkins On 08/17/2014 11:26, Anthony Jenkins wrote: Thanks for the critique guys, comments inline. Sorry it took so long... On 08/05/2014 16:49, Bruce Evans wrote: On Tue, 5 Aug 2014, Ian Smith wrote: On Sat, 2 Aug 2014 18:10:05 -0400, Anthony Jenkins wrote: I made a few minor changes since the last incarnation: - Defined the CMOS address/data register addresses as macros - Defined the (apparent) I/O delay as a macro Looks good, Anthony. I also verified the ACPI CMOS region code only accesses up to register 63 (0x3F - in previous emails I mistakenly said 0x7F). Is 0x3f what the ACPI spec limits ACPI access to? This is mildly surprising, as all modern RTC chips are at least 128 bytes; noone's actually used a MC146818 in over ten years, I gather. BIOSes at least used to use much more. It is good for ACPI to not allow clobbering the BIOS state. If/when this gets in, I'd like to add sysctl controls to e.g. allow ACPI access to the date/time registers (I currently return failure when attempting to write them via ACPI). I don't see anything in the spec (after re-reading it) that disallows ACPI from touching those. I don't know about the spec, but I can't see allowing ACPI write access to time/alarm/date registers as being a sensible idea; this could allow completely out-of-band modification of time/alarm/date regs without the necessary precautions needed for setting these, namely use of the SET bit in status reg B (0x0b) to disable updates while setting time & date, and anyway why allow changing time/date without the OS knowing about it? Reading should be no problem, though without proper observance of UIP bit timing, data may not be consistent. They might need to be read on resume. I can't see how resume can possibly work without reading them or some clock to reset the time. But this should be done by calling the standard time reading functions, not at a low level. I guess there may be a case for messing with the alarm bytes, though we don't currently allow use of the alarm for wake from poweroff (S5) or STR (S3) states, as doth Linux. I looked into this some years ago when there were a few requests for the feature, however it would involve some major reworking to always preserve the alarm interrupt bit through init and suspend/resume, and appropriate clearing of same after use, along with a utility to setup the alarm .. a potential to leave open, perhaps? I use the seconds alarm for pps, but don't use suspend. Which leads to my other concern here: that you are allowing out-of-band access to especially status reg C (0x0c), which when read clears all enabled interrupts, and the other status regs whose settings are also too important to allow screwing with. Yes, reading it would break interrupt handling. We used to use the RTC periodic interrupt as a clock source for a 128Hz interrupt (1024Hz while profiling) but since mav@'s reworking of all the clocks and timers sometime prior to 9.0-REL (IIRC), that's now rarely if ever used as such, but remains an available clock or timer source. Reg A (0x0a) is r/w and sets clock divider and rate selection bits. Do we want ACPI to be able to mess with these? I think not. Readonly, ok. Reg B (0x0b) is r/w and contains the aforementioned SET bit, the three interrupt enable bits (PIE, AIE, UIE), the SQWE, DM, 24/12 and DSE bits, again none of which should be allowed to be written to out-of-band. And reg C (0x0c) is read-only, and as mentioned clears interrupts; again not something that should be permitted without the OS knowing about it. I suppose you have the MC146818 spec to hand? Couple of things from your patch: -static int rtc_reg = -1; Indeed; I never could figure out the advantage in this, as how rarely would you want to read or write the same reg twice in a row anyway? About 99.9999% of accesses are to the status register for handling RTC interrupts. The RTC is almost never used except for the 128Hz interrupt, so the index register is normally constant at the single value used by this interrupt (RTC_INTR). With mav's changes, it is now rarely used. Removing this is a good re-pessimization. rtcin() does 4 i/o's with the pessimization. This takes about 5 usec. At 128 Hz this only wastes 0.064% of a CPU. At 1024 Hz it wastes 0.512%. The non-pessimized version only does 1 i/o so it wastes 1/4 as much. The wastage should be much larger. 1024 Hz is far too slow for profiling a modern system. It is about right for a 4.77 MHz 8086, except the RTC overhead is too high for that (I used the i8254). Scaling this for a 2 GHz modern CPU gives 429 kHz (or more, since instructions per cycle is more). The overhead for that with the pessimization would be 214% of a CPU. Without the pessimization, it would only be 53.7% of a CPU. Still too much. The RTC is just unsuitable for profiling interrupts at a useful rate. The i8254 is better and the lapic timer is much better, but profhz has only been increased to 8192. Other things don't scale so well. There are other i/o's for interrupts that make it difficult to go much higher than 429 KHz though 429 Khz is certainly possible using less than 100% of a CPU. static u_char rtc_statusa = RTCSA_DIVIDER | RTCSA_NOPROF; static u_char rtc_statusb = RTCSB_24HR; +static void acpi_cmos_read(ACPI_PHYSICAL_ADDRESS address, UINT8 *buf, UINT32 bu flen) { + UINT32 offset; Please no Windows typedefs in non-Windows code. Ya need to complain to the folks at acpica.org, who define the types in the regi on access handler functions: sys/contrib/dev/acpica/include/actypes.h: /* Address Spaces (For Operation Regions) */ typedef ACPI_STATUS (*ACPI_ADR_SPACE_HANDLER) ( UINT32 Function, ACPI_PHYSICAL_ADDRESS Address, UINT32 BitWidth, UINT64 *Value, void *HandlerContext, void *RegionContext); It is a minor layering violation to have acpi functions in non-acpi drivers. At least use the driver's spellings and not the Windows ones in drivers. I suppose I could make an atrtc_acpi.c or something and put them there... RTC_LOCK; + for (offset = 0U; offset < buflen; ++offset) { + IO_DELAY(); + outb(IO_RTC_ADDR, ((address + offset) | 0x80) & 0xFF); + IO_DELAY(); + buf[offset] = inb(IO_RTC_DATA); This should just call rtcin() in a loop instead of breaking it. Then there would be no need to put this in the driver. I had to refactor rtcin() and writertc() because the ACPI read/write functions m ay be multibyte and the original functions LOCK(), read/write 1 byte, UNLOCK(). It's ACPI's variable length region handler reads/writes that prompted this chan ge. Sorry, but I don't get '| 0x80' there, and below in acpi_cmos_write ? 0x80 disables NMI on some systems (mostly old ones?). Old books (Van Gilluwe) say to use it. FreeBSD never bothered with it. Locking makes it unecessary, modulo likely bugs in the NMI handler. It is also necessary disable ordinary interrupts and be careful about reenabling NMIs. FreeBSD's locking disables ordinary interrupts as a side effect of using spinlocks, except in my version where spinlocks don't block fast interrupt handlers. The remaining care is just to turn NMIs back on in the RTC at the end of the loop before unlocking (normally) reenables ordinary interrupts. This releases any pending NMIs. Spinlocks don't block NMIs, so the NMI handler must be careful not to block endlessly on a spinlock or call any code that depends on spinlocks for locking, like the code here. Fast interrupt handlers should be similarly careful, but aren't except in my version. NMIs are rare except for pmc and SMP stopping, and the NMI handler never bothered about correctness in FreeBSD. isa_nmi() for x86 normally just prints things (using log()) and returns for the system to panic. Printing is supposed to work when called in the "any" context, but it is quite broken now. It has locks galore. When an NMI occurs while one of these locks is held, then the NMI handler deadlocks on the lock if it is a (non-recursive) spinlock held by the same CPU. If the lock is held by another CPU, then there is some chance that the lock will go away, and the bug is just that the printing is delayed. If the lock is a recursive spinlock held by the same CPU, then the locking just doesn't work. The buggy locking in printf() mostly uses non- recursive spinlocks. The sloppiness in the NMI handler is not much of a problem for the RTC. The NMI handler just doesn't normally go near the RTC code, so it won't deadlock. Unless there is something like a resettodr() call for shutdown and panic() stumbles into this. +int +rtcin(int reg) +{ + u_char val; + + acpi_cmos_read(reg & 0xFF, &val, 1); rtcin() is pessimized too. The pessimization factor must also be increased from 4 to 5 or 6 (1 more i/o to turn off the NMI disable bit at the end, and probably another to delay after this). ... static int +is_datetime_reg(ACPI_PHYSICAL_ADDRESS address) +{ + return address == 0x00 || + address == 0x02 || + address == 0x04 || + address == 0x04 || + (address >= 0x06 && address <= 0x09); +} Lots of style bugs. The KNF style is: return (address == 0x00 || address == 0x02 || address == 0x04 || address == 0x04 || (address >= 0x06 && address <= 0x09)); This includes: - silly parentheses around return values - no splitting of statements after every subexpression to make split statements even more split - continuation indent is 4 spaces. No problem... is there a FreeBSD style guide somewhere, or do I just follow "K&R style"? I guess that second 0x04 should be 0x06? But why are you limiting to even addresses, ie time regs but not the alarm regs? If anything, the alarm regs seem more likely something BIOS/AML may? want to know about? Ehhhh... just trying to encapsulate the request that "CMOS writes should not tou ch certain registers". Stuck that request in a function that would return true if such a register write request was made. It would be helpful to have a concise spec for which registers and what types of accesses should be disallowed by the CMOS region handler... +static ACPI_STATUS +acpi_rtc_cmos_handler(UINT32 function, ACPI_PHYSICAL_ADDRESS address, UINT32 wi dth, + UINT64 *value, void *context, void *region_context) More style bugs. Now the line splitting doesn't even keep the line short enough, and the continuation indentation isn't even 1 tab or gnu style (-lp). +{ + struct atrtc_softc *sc; + + sc = (struct atrtc_softc *)context; + if (!value || !sc) + return AE_BAD_PARAMETER; + if (width > 32 || (width & 0x07) || address >= 64U) + return AE_BAD_PARAMETER; Missing some Windows bad style (U suffix on 64 but not on 32). Yeah I'm not very consistent with those... Ok, address is limited to 0x3f here, though strictly address should be less than (64 - width>>3) for multibyte access? I guess non-ACPI access via rtcin() and writertc() will still be able to access registers, well, from 0 to 0xff .. + if (function == ACPI_WRITE && + (is_datetime_reg(address) || + (width > 8 && address <= 0x09))) + return AE_BAD_PARAMETER; Larger indentation errors than above. The missing silly parentheses on return values seem to be consistent. I'd exclude AT LEAST 0x0a - 0x0d for write, certainly 0x0c from read. + printf("%s: %-5s%02u address=%04lx value=%08x\n", + __FUNCTION__, function == ACPI_READ ? "READ" : "WRITE", + width >> 3, address, *((UINT32 *)value)); + return AE_OK; The printf is good to see. Maybe you'd eventually want to limit this to when verbose booting is on? It would be useful to see with suspend and resume messages, or anywhere else ACPI wanted R/W access to 'CMOS' RAM? It's so ugly it is obviously only for debugging :-). I tried hunting down a list of what CMOS locations various systems use, and find some anecdotal info but nothing like 'manuf X uses bytes Y-Z'. Why do we have to care about acpi doing unsafe accesses? Only the block access seems dangerous. With scattered accesses like rtcin(RTC_FOO) using the system (non-acpi) spelling for 'FOO', it is very easy to see any dangerous ones. rtcin() used to be only used for memory sizing and in the fd driver (for dubious disk equipment byte reads; the equipment bytes just tell you about equipment that systems might have had in 1985, so it is almost useless, while other BIOS bytes are even more useless since they are not standard). It is now used in: - nvram driver. This seems to allow anyone with access to the device to read and/or write the offsets 14-127. So they can manage or corrupt some BIOS bytes but not the ones used by FreeBSD :-). acpia should be even more trustable, but might need read access to the clock bytes. - fb driver. This reads the video equipment byte. This is so hackish that RTC_EQUIPMENT is still not defined in rtc.h but is defined here. EQUIPMENT is the standard name for this byte (see van Gilluwe), but it is not the only equipment-related byte. There is also the diskette equipment byte. Many other equipment-related bytes that worked in 1985 are also not defined in rtc.h. They are also not used in FreeBSD. - acpi_support/icpi_ibm.c uses a large subset of RTC space. It uses rtcin(), but has its own defines for 6 RTC registers between 0x64 and 0x6e (for things like brightness and volume). Obviously very vendor-specific. - i386/xen/clock.c is a copy of the old x86 clock.c. It duplicates almost everything including the badly named readrtc() BCD translation wrapper, but uses the systtem rtcin() and writertc(). Write accesses used to be protected by writerc() being static, but this was broken by exporting it for nvram and xen. Bruce _______________________________________________ [3]freebsd-acpi@freebsd.org mailing list [4]http://lists.freebsd.org/mailman/listinfo/freebsd-acpi To unsubscribe, send any mail to [5]"freebsd-acpi-unsubscribe@freebsd.org" _______________________________________________ [6]freebsd-acpi@freebsd.org mailing list [7]http://lists.freebsd.org/mailman/listinfo/freebsd-acpi To unsubscribe, send any mail to [8]"freebsd-acpi-unsubscribe@freebsd.org" References 1. http://www.qtchat.org/docs/atrtc.c-20140829.patch 2. http://www.qtchat.org/docs/atrtc.c.patch 3. mailto:freebsd-acpi@freebsd.org 4. http://lists.freebsd.org/mailman/listinfo/freebsd-acpi 5. mailto:freebsd-acpi-unsubscribe@freebsd.org 6. mailto:freebsd-acpi@freebsd.org 7. http://lists.freebsd.org/mailman/listinfo/freebsd-acpi 8. mailto:freebsd-acpi-unsubscribe@freebsd.org