public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Helgaas <bjorn.helgaas@hp.com>
To: emisca <emisca.ml@gmail.com>
Cc: Len Brown <len.brown@intel.com>,
	linux-acpi@vger.kernel.org, Adam Belay <ambx1@neo.rr.com>,
	Matthieu Castet <castet.matthieu@free.fr>,
	Li Shaohua <shaohua.li@intel.com>
Subject: Re: [0/5] remove ACPI motherboard driver, use PNP system driver instead (take 2)
Date: Mon, 22 Jan 2007 09:25:49 -0700	[thread overview]
Message-ID: <200701220925.49821.bjorn.helgaas@hp.com> (raw)
In-Reply-To: <414cba4e0701201000n698f0bbbh10016c984c84b364@mail.gmail.com>

On Saturday 20 January 2007 11:00, emisca wrote:
> Could you tell me which informations I must collect and in which
> conditions I must collect them so I could post them?
> They replied me on the other post that I must manually debug the
> pnpacpi code.......

Sure.  I'm here to help with the manual debug of pnpacpi :-)

If I understand correctly, you're seeing this:

  1a) Original boot (serial port works fine)
  1b) Suspend to disk
  1c) Resume (serial port doesn't work)

  2a) Original boot with pnpacpi=off (serial port works fine)
  2b) Suspend to disk
  2c) Resume (serial port works fine)

Can you please apply the patch below and collect this info:

  - Your .config file
  - dmesg logs (use "dmesg -s64000") from 1a, 1c, 2a, and 2c
  - Contents of /proc/interrupts from 1c and 2c

I'm pretty ignorant of suspend/resume, so I don't know what the
dmesg log of a resume looks like.  My dim understanding is that
resume starts with a normal boot, and then loads a suspended memory
image from disk.  I suppose the suspended memory image contains
a dmesg buffer from the original boot.  So I'm not sure what sort
of log you'll get from the 2c case.

Bjorn



Index: mm-work3/drivers/serial/8250.c
===================================================================
--- mm-work3.orig/drivers/serial/8250.c	2007-01-22 09:10:16.000000000 -0700
+++ mm-work3/drivers/serial/8250.c	2007-01-22 09:23:32.000000000 -0700
@@ -2511,6 +2511,7 @@
  */
 void serial8250_suspend_port(int line)
 {
+	printk("%s: line %d\n", __FUNCTION__, line);
 	uart_suspend_port(&serial8250_reg, &serial8250_ports[line].port);
 }
 
@@ -2522,6 +2523,7 @@
  */
 void serial8250_resume_port(int line)
 {
+	printk("%s: line %d\n", __FUNCTION__, line);
 	uart_resume_port(&serial8250_reg, &serial8250_ports[line].port);
 }
 
@@ -2584,8 +2586,10 @@
 	for (i = 0; i < UART_NR; i++) {
 		struct uart_8250_port *up = &serial8250_ports[i];
 
-		if (up->port.type != PORT_UNKNOWN && up->port.dev == &dev->dev)
+		if (up->port.type != PORT_UNKNOWN && up->port.dev == &dev->dev) {
+			printk("%s: line %d\n", __FUNCTION__, i);
 			uart_suspend_port(&serial8250_reg, &up->port);
+		}
 	}
 
 	return 0;
@@ -2598,8 +2602,10 @@
 	for (i = 0; i < UART_NR; i++) {
 		struct uart_8250_port *up = &serial8250_ports[i];
 
-		if (up->port.type != PORT_UNKNOWN && up->port.dev == &dev->dev)
+		if (up->port.type != PORT_UNKNOWN && up->port.dev == &dev->dev) {
+			printk("%s: line %d\n", __FUNCTION__, i);
 			uart_resume_port(&serial8250_reg, &up->port);
+		}
 	}
 
 	return 0;
Index: mm-work3/drivers/serial/8250_pnp.c
===================================================================
--- mm-work3.orig/drivers/serial/8250_pnp.c	2007-01-22 09:08:19.000000000 -0700
+++ mm-work3/drivers/serial/8250_pnp.c	2007-01-22 09:23:53.000000000 -0700
@@ -469,6 +469,7 @@
 {
 	long line = (long)pnp_get_drvdata(dev);
 
+	printk("%s: dev %s line %ld\n", __FUNCTION__, dev->name, line);
 	if (!line)
 		return -ENODEV;
 	serial8250_suspend_port(line - 1);
@@ -479,6 +480,7 @@
 {
 	long line = (long)pnp_get_drvdata(dev);
 
+	printk("%s: dev %s line %ld\n", __FUNCTION__, dev->name, line);
 	if (!line)
 		return -ENODEV;
 	serial8250_resume_port(line - 1);
Index: mm-work3/drivers/pnp/driver.c
===================================================================
--- mm-work3.orig/drivers/pnp/driver.c	2007-01-22 09:11:02.000000000 -0700
+++ mm-work3/drivers/pnp/driver.c	2007-01-22 09:17:47.000000000 -0700
@@ -155,6 +155,7 @@
 		return 0;
 
 	if (pnp_drv->suspend) {
+		printk("%s: %s\n", __FUNCTION__, pnp_dev->name);
 		error = pnp_drv->suspend(pnp_dev, state);
 		if (error)
 			return error;
@@ -185,8 +186,10 @@
 			return error;
 	}
 
-	if (pnp_drv->resume)
+	if (pnp_drv->resume) {
+		printk("%s: %s\n", __FUNCTION__, pnp_dev->name);
 		return pnp_drv->resume(pnp_dev);
+	}
 
 	return 0;
 }

  reply	other threads:[~2007-01-22 16:25 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-18 23:36 [0/5] remove ACPI motherboard driver, use PNP system driver instead (take 2) Bjorn Helgaas
2007-01-18 23:42 ` [patch 1/5] ACPI: move FADT resource reservations from motherboard driver to osl Bjorn Helgaas
2007-01-19  1:12   ` Shaohua Li
2007-01-19 19:46     ` Bjorn Helgaas
2007-01-22  1:27       ` Shaohua Li
2007-01-22 15:57         ` Bjorn Helgaas
2007-01-18 23:43 ` [patch 2/5] PNP: reserve system board iomem resources as well as ioport resources Bjorn Helgaas
2007-01-18 23:43 ` [patch 3/5] PNP: system.c whitespace cleanup Bjorn Helgaas
2007-01-18 23:44 ` [patch 4/5] i386: turn on CONFIG_PNP in defconfig Bjorn Helgaas
2007-01-18 23:44 ` [patch 5/5] ACPI: remove motherboard driver (redundant with PNP system driver) Bjorn Helgaas
2007-01-19 15:37 ` [0/5] remove ACPI motherboard driver, use PNP system driver instead (take 2) emisca
2007-01-19 21:33   ` Bjorn Helgaas
2007-01-20 18:00     ` emisca
2007-01-22 16:25       ` Bjorn Helgaas [this message]
2007-01-23  9:07         ` emisca
2007-01-23 15:44           ` Bjorn Helgaas
2007-01-23 19:24             ` emisca
2007-01-29 22:53               ` Bjorn Helgaas
2007-01-29 23:00 ` Bjorn Helgaas
2007-01-29 23:19   ` Len Brown
2007-01-29 23:24     ` Bjorn Helgaas
2007-01-30 20:18       ` emisca
2007-02-03 22:16         ` emisca
2007-02-09 19:15           ` emisca
2007-02-16  3:57             ` Bjorn Helgaas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200701220925.49821.bjorn.helgaas@hp.com \
    --to=bjorn.helgaas@hp.com \
    --cc=ambx1@neo.rr.com \
    --cc=castet.matthieu@free.fr \
    --cc=emisca.ml@gmail.com \
    --cc=len.brown@intel.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=shaohua.li@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox