Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
pm.h File Reference
#include <linux/irq.h>

Go to the source code of this file.

Data Structures

struct  sleep_save
 
struct  pm_uart_save
 

Macros

#define SAVE_ITEM(x)   { .reg = (x) }
 
#define s3c_irqext_wake   NULL
 
#define s3c24xx_irq_suspend   NULL
 
#define s3c24xx_irq_resume   NULL
 
#define S3C_PMDBG(fmt...)   printk(KERN_DEBUG fmt)
 
#define s3c_pm_check_prepare()   do { } while(0)
 
#define s3c_pm_check_restore()   do { } while(0)
 
#define s3c_pm_check_cleanup()   do { } while(0)
 
#define s3c_pm_check_store()   do { } while(0)
 

Functions

void s3c_cpu_resume (void)
 
int s3c2410_cpu_suspend (unsigned long)
 
void s3c_pm_do_save (struct sleep_save *ptr, int count)
 
void s3c_pm_do_restore (struct sleep_save *ptr, int count)
 
void s3c_pm_do_restore_core (struct sleep_save *ptr, int count)
 
void s3c_pm_configure_extint (void)
 
void samsung_pm_restore_gpios (void)
 
void samsung_pm_save_gpios (void)
 
void s3c_pm_save_core (void)
 
void s3c_pm_restore_core (void)
 

Variables

unsigned long s3c_irqwake_intmask
 
unsigned long s3c_irqwake_eintmask
 
unsigned long s3c_irqwake_intallow
 
unsigned long s3c_irqwake_eintallow
 
void(* pm_cpu_prep )(void)
 
int(* pm_cpu_sleep )(unsigned long)
 
unsigned long s3c_pm_flags
 
unsigned char pm_uart_udivslot
 
struct syscore_ops s3c24xx_irq_syscore_ops
 

Macro Definition Documentation

#define s3c24xx_irq_resume   NULL

Definition at line 116 of file pm.h.

#define s3c24xx_irq_suspend   NULL

Definition at line 115 of file pm.h.

#define s3c_irqext_wake   NULL

Definition at line 114 of file pm.h.

#define s3c_pm_check_cleanup (   void)    do { } while(0)

Definition at line 161 of file pm.h.

#define s3c_pm_check_prepare (   void)    do { } while(0)

Definition at line 159 of file pm.h.

#define s3c_pm_check_restore (   void)    do { } while(0)

Definition at line 160 of file pm.h.

#define s3c_pm_check_store (   void)    do { } while(0)

Definition at line 162 of file pm.h.

#define S3C_PMDBG (   fmt...)    printk(KERN_DEBUG fmt)

Definition at line 136 of file pm.h.

#define SAVE_ITEM (   x)    { .reg = (x) }

Definition at line 80 of file pm.h.

Function Documentation

int s3c2410_cpu_suspend ( unsigned  long)
void s3c_cpu_resume ( void  )
void s3c_pm_configure_extint ( void  )

s3c_pm_configure_extint() - ensure pins are correctly set for IRQ

Setup all the necessary GPIO pins for waking the system on external interrupt.

Definition at line 119 of file pm.c.

void s3c_pm_do_restore ( struct sleep_save ptr,
int  count 
)

s3c_pm_do_restore() - restore register values from the save list. : Pointer to an array of registers. : Size of the ptr array.

Restore the register values saved from s3c_pm_do_save().

Note, we do not use S3C_PMDBG() in here, as the system may not have restore the UARTs state yet

Definition at line 187 of file pm.c.

void s3c_pm_do_restore_core ( struct sleep_save ptr,
int  count 
)

s3c_pm_do_restore_core() - early restore register values from save list.

This is similar to s3c_pm_do_restore() except we try and minimise the side effects of the function in case registers that hardware might need to work has been restored.

WARNING: Do not put any debug in here that may effect memory or use peripherals, as things may be changing!

Definition at line 208 of file pm.c.

void s3c_pm_do_save ( struct sleep_save ptr,
int  count 
)

s3c_pm_do_save() - save a set of registers for restoration on resume. : Pointer to an array of registers. : Size of the ptr array.

Run through the list of registers given, saving their contents in the array for later restoration when we wakeup.

Definition at line 168 of file pm.c.

void s3c_pm_restore_core ( void  )

Definition at line 138 of file pm.c.

void s3c_pm_save_core ( void  )

Definition at line 144 of file pm.c.

void samsung_pm_restore_gpios ( void  )

samsung_pm_restore_gpios() - restore the state of the gpios after sleep.

Restore the state of the GPIO pins after sleep, which may involve ensuring that we do not glitch the state of the pins from that the bootloader's resume code has done.

Definition at line 367 of file pm-gpio.c.

void samsung_pm_save_gpios ( void  )

samsung_pm_save_gpios() - save the state of the GPIOs for restoring after sleep.

Save the GPIO states for resotration on resume. See samsung_pm_restore_gpios().

samsung_pm_save_gpios() - Save the state of the GPIO banks.

For all the GPIO banks, save the state of each one ready for going into a suspend mode.

Definition at line 327 of file pm-gpio.c.

Variable Documentation

void(* pm_cpu_prep)(void)

Definition at line 234 of file pm.c.

int(* pm_cpu_sleep)(unsigned long)

Definition at line 235 of file pm.c.

unsigned char pm_uart_udivslot

Definition at line 73 of file pm.c.

struct syscore_ops s3c24xx_irq_syscore_ops

Definition at line 673 of file irq.c.

unsigned long s3c_irqwake_eintallow

Definition at line 33 of file irq-pm.c.

unsigned long s3c_irqwake_eintmask

Definition at line 138 of file pm.c.

unsigned long s3c_irqwake_intallow

Definition at line 32 of file irq-pm.c.

unsigned long s3c_irqwake_intmask

Definition at line 137 of file pm.c.

unsigned long s3c_pm_flags

Definition at line 37 of file pm.c.