Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 259332
b: refs/heads/master
c: aef7fe5
h: refs/heads/master
v: v3
  • Loading branch information
MyungJoo Ham authored and Greg Kroah-Hartman committed Jul 1, 2011
1 parent 2b70f86 commit 9ca9bd5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f2eb3cdf14457fccb14ae8c4d7d7cee088cd3957
refs/heads/master: aef7fe5274af3e608e0f3eaf0fea6d3c78ffb92e
27 changes: 14 additions & 13 deletions trunk/drivers/tty/serial/samsung.c
Original file line number Diff line number Diff line change
Expand Up @@ -1194,22 +1194,20 @@ int __devexit s3c24xx_serial_remove(struct platform_device *dev)
EXPORT_SYMBOL_GPL(s3c24xx_serial_remove);

/* UART power management code */

#ifdef CONFIG_PM

static int s3c24xx_serial_suspend(struct platform_device *dev, pm_message_t state)
#ifdef CONFIG_PM_SLEEP
static int s3c24xx_serial_suspend(struct device *dev)
{
struct uart_port *port = s3c24xx_dev_to_port(&dev->dev);
struct uart_port *port = s3c24xx_dev_to_port(dev);

if (port)
uart_suspend_port(&s3c24xx_uart_drv, port);

return 0;
}

static int s3c24xx_serial_resume(struct platform_device *dev)
static int s3c24xx_serial_resume(struct device *dev)
{
struct uart_port *port = s3c24xx_dev_to_port(&dev->dev);
struct uart_port *port = s3c24xx_dev_to_port(dev);
struct s3c24xx_uart_port *ourport = to_ourport(port);

if (port) {
Expand All @@ -1222,17 +1220,20 @@ static int s3c24xx_serial_resume(struct platform_device *dev)

return 0;
}
#endif

static const struct dev_pm_ops s3c24xx_serial_pm_ops = {
.suspend = s3c24xx_serial_suspend,
.resume = s3c24xx_serial_resume,
};
#else /* !CONFIG_PM_SLEEP */
#define s3c24xx_serial_pm_ops NULL
#endif /* CONFIG_PM_SLEEP */

int s3c24xx_serial_init(struct platform_driver *drv,
struct s3c24xx_uart_info *info)
{
dbg("s3c24xx_serial_init(%p,%p)\n", drv, info);

#ifdef CONFIG_PM
drv->suspend = s3c24xx_serial_suspend;
drv->resume = s3c24xx_serial_resume;
#endif
drv->driver.pm = &s3c24xx_serial_pm_ops;

return platform_driver_register(drv);
}
Expand Down

0 comments on commit 9ca9bd5

Please sign in to comment.