Commit 77f6078aa8945a18a7780694940e52be0322c2b8

Authored by Randy Dunlap
Committed by Linus Torvalds
1 parent 1b578df022

mm: highmem kernel-doc additions

Add kernel-doc comments to highmem.c.

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 1 changed file with 26 additions and 4 deletions Side-by-side Diff

... ... @@ -104,8 +104,9 @@
104 104 flush_tlb_kernel_range(PKMAP_ADDR(0), PKMAP_ADDR(LAST_PKMAP));
105 105 }
106 106  
107   -/* Flush all unused kmap mappings in order to remove stray
108   - mappings. */
  107 +/**
  108 + * kmap_flush_unused - flush all unused kmap mappings in order to remove stray mappings
  109 + */
109 110 void kmap_flush_unused(void)
110 111 {
111 112 spin_lock(&kmap_lock);
... ... @@ -163,6 +164,14 @@
163 164 return vaddr;
164 165 }
165 166  
  167 +/**
  168 + * kmap_high - map a highmem page into memory
  169 + * @page: &struct page to map
  170 + *
  171 + * Returns the page's virtual memory address.
  172 + *
  173 + * We cannot call this from interrupts, as it may block.
  174 + */
166 175 void *kmap_high(struct page *page)
167 176 {
168 177 unsigned long vaddr;
... ... @@ -170,8 +179,6 @@
170 179 /*
171 180 * For highmem pages, we can't trust "virtual" until
172 181 * after we have the lock.
173   - *
174   - * We cannot call this from interrupts, as it may block
175 182 */
176 183 spin_lock(&kmap_lock);
177 184 vaddr = (unsigned long)page_address(page);
... ... @@ -185,6 +192,10 @@
185 192  
186 193 EXPORT_SYMBOL(kmap_high);
187 194  
  195 +/**
  196 + * kunmap_high - map a highmem page into memory
  197 + * @page: &struct page to unmap
  198 + */
188 199 void kunmap_high(struct page *page)
189 200 {
190 201 unsigned long vaddr;
... ... @@ -259,6 +270,12 @@
259 270 return &page_address_htable[hash_ptr(page, PA_HASH_ORDER)];
260 271 }
261 272  
  273 +/**
  274 + * page_address - get the mapped virtual address of a page
  275 + * @page: &struct page to get the virtual address of
  276 + *
  277 + * Returns the page's virtual address.
  278 + */
262 279 void *page_address(struct page *page)
263 280 {
264 281 unsigned long flags;
... ... @@ -288,6 +305,11 @@
288 305  
289 306 EXPORT_SYMBOL(page_address);
290 307  
  308 +/**
  309 + * set_page_address - set a page's virtual address
  310 + * @page: &struct page to set
  311 + * @virtual: virtual address to use
  312 + */
291 313 void set_page_address(struct page *page, void *virtual)
292 314 {
293 315 unsigned long flags;