lkml.org 
[lkml]   [2005]   [Mar]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: serial CardBus card does not wake up after sleep
On Sun, Mar 06, 2005 at 02:09:46PM -0600, Hendrik Hoeth wrote:
> I'm using a serial CardBus card (Sony Ericsson GC79 -- combined GPRS and
> WiFi, I'm talking about the GPRS modem part of it) in a Samsung P35
> laptop, kernel version 2.6.11. If I put the laptop in S3 leaving the
> card in the laptop, the card does not wake up on resume. I need to
> remove and reinsert the card.

Looks like the card wasn't resumed properly. Please try this patch:

diff -up -x BitKeeper -x ChangeSet -x SCCS -x _xlk -x *.orig -x *.rej orig/drivers/serial/8250_pci.c linux/drivers/serial/8250_pci.c
--- orig/drivers/serial/8250_pci.c Wed Mar 2 14:40:16 2005
+++ linux/drivers/serial/8250_pci.c Sun Mar 6 22:38:46 2005
@@ -1759,7 +1759,7 @@ static void __devexit pciserial_remove_o
}
}

-static int pciserial_suspend_one(struct pci_dev *dev, u32 state)
+static int pciserial_suspend_one(struct pci_dev *dev, pm_message_t state)
{
struct serial_private *priv = pci_get_drvdata(dev);

@@ -1769,6 +1769,8 @@ static int pciserial_suspend_one(struct
for (i = 0; i < priv->nr; i++)
serial8250_suspend_port(priv->line[i]);
}
+ pci_save_state(dev);
+ pci_set_power_state(dev, pci_choose_state(dev, state));
return 0;
}

@@ -1776,10 +1778,18 @@ static int pciserial_resume_one(struct p
{
struct serial_private *priv = pci_get_drvdata(dev);

+ pci_set_power_state(dev, PCI_D0);
+ pci_restore_state(dev);
+
if (priv) {
int i;

/*
+ * The device may have been disabled. Re-enable it.
+ */
+ pci_enable_device(dev);
+
+ /*
* Ensure that the board is correctly configured.
*/
if (priv->quirk->init)

--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of: 2.6 Serial core
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:10    [W:0.335 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site