[PATCH] swsusp cleanups
This cleans spaces between * and pointer up, and adds "int" in "unsigned int". Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
36fabc248e
commit
dc19d507b1
2 changed files with 27 additions and 28 deletions
|
@ -168,9 +168,8 @@ static unsigned count_data_pages(void)
|
|||
{
|
||||
struct zone *zone;
|
||||
unsigned long zone_pfn;
|
||||
unsigned n;
|
||||
unsigned int n = 0;
|
||||
|
||||
n = 0;
|
||||
for_each_zone (zone) {
|
||||
if (is_highmem(zone))
|
||||
continue;
|
||||
|
@ -250,10 +249,10 @@ static inline void fill_pb_page(struct pbe *pbpage)
|
|||
* of memory pages allocated with alloc_pagedir()
|
||||
*/
|
||||
|
||||
void create_pbe_list(struct pbe *pblist, unsigned nr_pages)
|
||||
void create_pbe_list(struct pbe *pblist, unsigned int nr_pages)
|
||||
{
|
||||
struct pbe *pbpage, *p;
|
||||
unsigned num = PBES_PER_PAGE;
|
||||
unsigned int num = PBES_PER_PAGE;
|
||||
|
||||
for_each_pb_page (pbpage, pblist) {
|
||||
if (num >= nr_pages)
|
||||
|
@ -293,9 +292,9 @@ static void *alloc_image_page(void)
|
|||
* On each page we set up a list of struct_pbe elements.
|
||||
*/
|
||||
|
||||
struct pbe *alloc_pagedir(unsigned nr_pages)
|
||||
struct pbe *alloc_pagedir(unsigned int nr_pages)
|
||||
{
|
||||
unsigned num;
|
||||
unsigned int num;
|
||||
struct pbe *pblist, *pbe;
|
||||
|
||||
if (!nr_pages)
|
||||
|
@ -348,7 +347,7 @@ void swsusp_free(void)
|
|||
* free pages.
|
||||
*/
|
||||
|
||||
static int enough_free_mem(unsigned nr_pages)
|
||||
static int enough_free_mem(unsigned int nr_pages)
|
||||
{
|
||||
pr_debug("swsusp: available memory: %u pages\n", nr_free_pages());
|
||||
return nr_free_pages() > (nr_pages + PAGES_FOR_IO +
|
||||
|
@ -356,7 +355,7 @@ static int enough_free_mem(unsigned nr_pages)
|
|||
}
|
||||
|
||||
|
||||
static struct pbe *swsusp_alloc(unsigned nr_pages)
|
||||
static struct pbe *swsusp_alloc(unsigned int nr_pages)
|
||||
{
|
||||
struct pbe *pblist, *p;
|
||||
|
||||
|
@ -380,7 +379,7 @@ static struct pbe *swsusp_alloc(unsigned nr_pages)
|
|||
|
||||
asmlinkage int swsusp_save(void)
|
||||
{
|
||||
unsigned nr_pages;
|
||||
unsigned int nr_pages;
|
||||
|
||||
pr_debug("swsusp: critical section: \n");
|
||||
if (save_highmem()) {
|
||||
|
|
|
@ -492,7 +492,7 @@ static void free_pagedir_entries(void)
|
|||
static int write_pagedir(void)
|
||||
{
|
||||
int error = 0;
|
||||
unsigned n = 0;
|
||||
unsigned int n = 0;
|
||||
struct pbe *pbe;
|
||||
|
||||
printk( "Writing pagedir...");
|
||||
|
@ -543,7 +543,7 @@ static int write_suspend_image(void)
|
|||
* We should only consider resume_device.
|
||||
*/
|
||||
|
||||
int enough_swap(unsigned nr_pages)
|
||||
int enough_swap(unsigned int nr_pages)
|
||||
{
|
||||
struct sysinfo i;
|
||||
|
||||
|
@ -950,7 +950,7 @@ static int data_read(struct pbe *pblist)
|
|||
static int read_pagedir(struct pbe *pblist)
|
||||
{
|
||||
struct pbe *pbpage, *p;
|
||||
unsigned i = 0;
|
||||
unsigned int i = 0;
|
||||
int error;
|
||||
|
||||
if (!pblist)
|
||||
|
|
Loading…
Reference in a new issue