Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 91279
b: refs/heads/master
c: 6ddc4b0
h: refs/heads/master
i:
  91277: 16a1020
  91275: 3dda98f
  91271: ae6c70b
  91263: 612afd7
v: v3
  • Loading branch information
Ben Dooks authored and Russell King committed Apr 17, 2008
1 parent 1edd842 commit c1a374d
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c63fc13f806b11576e8c41969d4b1598dd261d80
refs/heads/master: 6ddc4b07a2669bdb8b90e3e12fb1ccfb6dc4a99c
34 changes: 34 additions & 0 deletions trunk/arch/arm/mach-s3c2410/mach-bast.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include <linux/list.h>
#include <linux/timer.h>
#include <linux/init.h>
#include <linux/sysdev.h>
#include <linux/serial_core.h>
#include <linux/platform_device.h>
#include <linux/dm9000.h>
Expand Down Expand Up @@ -236,6 +237,36 @@ static struct platform_device bast_device_nor = {

/* NAND Flash on BAST board */

#ifdef CONFIG_PM
static int bast_pm_suspend(struct sys_device *sd, pm_message_t state)
{
/* ensure that an nRESET is not generated on resume. */
s3c2410_gpio_setpin(S3C2410_GPA21, 1);
s3c2410_gpio_cfgpin(S3C2410_GPA21, S3C2410_GPA21_OUT);

return 0;
}

static int bast_pm_resume(struct sys_device *sd)
{
s3c2410_gpio_cfgpin(S3C2410_GPA21, S3C2410_GPA21_nRSTOUT);
return 0;
}

#else
#define bast_pm_suspend NULL
#define bast_pm_resume NULL
#endif

static struct sysdev_class bast_pm_sysclass = {
set_kset_name("mach-bast"),
.suspend = bast_pm_suspend,
.resume = bast_pm_resume,
};

static struct sys_device bast_pm_sysdev = {
.cls = &bast_pm_sysclass,
};

static int smartmedia_map[] = { 0 };
static int chip0_map[] = { 1 };
Expand Down Expand Up @@ -586,6 +617,9 @@ static void __init bast_map_io(void)

static void __init bast_init(void)
{
sysdev_class_register(&bast_pm_sysclass);
sysdev_register(&bast_pm_sysdev);

s3c24xx_fb_set_platdata(&bast_fb_info);
platform_add_devices(bast_devices, ARRAY_SIZE(bast_devices));
}
Expand Down

0 comments on commit c1a374d

Please sign in to comment.