diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-12 16:40:20 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-12 16:40:20 -0400 |
commit | dc690d8ef842b464f1c429a376ca16cb8dbee6ae (patch) | |
tree | 77955849af5a15755f5e55e24ae4b9c520583a72 /arch/arm/mach-sa1100/neponset.c | |
parent | 57399ec9077a4b962b81037aaa279fab52f5e989 (diff) | |
parent | 91a6902958f052358899f58683d44e36228d85c2 (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6: (61 commits)
sysfs: add parameter "struct bin_attribute *" in .read/.write methods for sysfs binary attributes
sysfs: make directory dentries and inodes reclaimable
sysfs: implement sysfs_get_dentry()
sysfs: move sysfs_drop_dentry() to dir.c and make it static
sysfs: restructure add/remove paths and fix inode update
sysfs: use sysfs_mutex to protect the sysfs_dirent tree
sysfs: consolidate sysfs spinlocks
sysfs: make kobj point to sysfs_dirent instead of dentry
sysfs: implement sysfs_find_dirent() and sysfs_get_dirent()
sysfs: implement SYSFS_FLAG_REMOVED flag
sysfs: rename sysfs_dirent->s_type to s_flags and make room for flags
sysfs: make sysfs_drop_dentry() access inodes using ilookup()
sysfs: Fix oops in sysfs_drop_dentry on x86_64
sysfs: use singly-linked list for sysfs_dirent tree
sysfs: slim down sysfs_dirent->s_active
sysfs: move s_active functions to fs/sysfs/dir.c
sysfs: fix root sysfs_dirent -> root dentry association
sysfs: use iget_locked() instead of new_inode()
sysfs: reorganize sysfs_new_indoe() and sysfs_create()
sysfs: fix parent refcounting during rename and move
...
Diffstat (limited to 'arch/arm/mach-sa1100/neponset.c')
-rw-r--r-- | arch/arm/mach-sa1100/neponset.c | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/arch/arm/mach-sa1100/neponset.c b/arch/arm/mach-sa1100/neponset.c index 4cbf9468f654..3a0a1ee2542d 100644 --- a/arch/arm/mach-sa1100/neponset.c +++ b/arch/arm/mach-sa1100/neponset.c | |||
@@ -185,28 +185,21 @@ static int __devinit neponset_probe(struct platform_device *dev) | |||
185 | /* | 185 | /* |
186 | * LDM power management. | 186 | * LDM power management. |
187 | */ | 187 | */ |
188 | static unsigned int neponset_saved_state; | ||
189 | |||
188 | static int neponset_suspend(struct platform_device *dev, pm_message_t state) | 190 | static int neponset_suspend(struct platform_device *dev, pm_message_t state) |
189 | { | 191 | { |
190 | /* | 192 | /* |
191 | * Save state. | 193 | * Save state. |
192 | */ | 194 | */ |
193 | if (!dev->dev.power.saved_state) | 195 | neponset_saved_state = NCR_0; |
194 | dev->dev.power.saved_state = kmalloc(sizeof(unsigned int), GFP_KERNEL); | ||
195 | if (!dev->dev.power.saved_state) | ||
196 | return -ENOMEM; | ||
197 | |||
198 | *(unsigned int *)dev->dev.power.saved_state = NCR_0; | ||
199 | 196 | ||
200 | return 0; | 197 | return 0; |
201 | } | 198 | } |
202 | 199 | ||
203 | static int neponset_resume(struct platform_device *dev) | 200 | static int neponset_resume(struct platform_device *dev) |
204 | { | 201 | { |
205 | if (dev->dev.power.saved_state) { | 202 | NCR_0 = neponset_saved_state; |
206 | NCR_0 = *(unsigned int *)dev->dev.power.saved_state; | ||
207 | kfree(dev->dev.power.saved_state); | ||
208 | dev->dev.power.saved_state = NULL; | ||
209 | } | ||
210 | 203 | ||
211 | return 0; | 204 | return 0; |
212 | } | 205 | } |