Skip to contentSkip to conversation

mm: highmem remove 3 errors

PATCH In review Paul McQuade 2 participants 3 messages Oct 2, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mm: highmem remove 3 errors

pointers should be foo *bar or (foo *)

---
 mm/highmem.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
mm/highmem.c +3 -3
index 123bcd3..f6dae74 100644
@@ -130,7 +130,7 @@ unsigned int nr_free_highpages (void)
 static int pkmap_count[LAST_PKMAP];
 static  __cacheline_aligned_in_smp DEFINE_SPINLOCK(kmap_lock);
 
-pte_t * pkmap_page_table;
+pte_t *pkmap_page_table;
 
 /*
  * Most architectures have no use for kmap_high_get(), so let's abstract
@@ -291,7 +291,7 @@ void *kmap_high(struct page *page)
 	pkmap_count[PKMAP_NR(vaddr)]++;
 	BUG_ON(pkmap_count[PKMAP_NR(vaddr)] < 2);
 	unlock_kmap();
-	return (void*) vaddr;
+	return (void *) vaddr;
 }
 
 EXPORT_SYMBOL(kmap_high);
@@ -318,7 +318,7 @@ void *kmap_high_get(struct page *page)
 		pkmap_count[PKMAP_NR(vaddr)]++;
 	}
 	unlock_kmap_any(flags);
-	return (void*) vaddr;
+	return (void *) vaddr;
 }
 #endif
 
Signature · 7 lines
1.9.1

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
#1 lore raw
Quoted 21 lines · Paul McQuade

pointers should be foo *bar or (foo *)

---
 mm/highmem.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
mm/highmem.c +1 -1
index 123bcd3..f6dae74 100644
@@ -130,7 +130,7 @@ unsigned int nr_free_highpages (void)
 static int pkmap_count[LAST_PKMAP];
 static  __cacheline_aligned_in_smp DEFINE_SPINLOCK(kmap_lock);
 
-pte_t * pkmap_page_table;
+pte_t *pkmap_page_table;
 
 /*
  * Most architectures have no use for kmap_high_get(), so let's abstract

mm/highmem.c void *kmap_high(struct page *page) · line 294

Quoted 5 lines
mm/highmem.c +1 -1
@@ -291,7 +291,7 @@ void *kmap_high(struct page *page)
        pkmap_count[PKMAP_NR(vaddr)]++;
        BUG_ON(pkmap_count[PKMAP_NR(vaddr)] < 2);
        unlock_kmap();
-       return (void*) vaddr;
+       return (void *) vaddr;

checkpatch suggests that
CHECK: No space is necessary after a cast

mm/highmem.c void *kmap_high_get(struct page *page) · line 321

Quoted 9 lines
mm/highmem.c +1 -1
 }
 
 EXPORT_SYMBOL(kmap_high);
@@ -318,7 +318,7 @@ void *kmap_high_get(struct page *page)
                pkmap_count[PKMAP_NR(vaddr)]++;
        }
        unlock_kmap_any(flags);
-       return (void*) vaddr;
+       return (void *) vaddr;

Here as well.

Signature · 8 lines
Thanks.
-- Max

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>
#2 lore raw
Quoted 6 lines · Max Filippov

Review

Quoted 2 lines · Paul McQuade
(quoted diff) +1 -1
-       return (void*) vaddr;
+       return (void *) vaddr;

checkpatch suggests that
CHECK: No space is necessary after a cast

Sorry, wasn't clear enough. 'After a cast' means between ')' and 'vaddr' in the above case. Space insertion between 'void' and '*' is correct.

Signature · 8 lines
Thanks.
-- Max

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>