diff options
Diffstat (limited to 'include/asm-generic/memory_model.h')
| -rw-r--r-- | include/asm-generic/memory_model.h | 6 | 
1 files changed, 3 insertions, 3 deletions
diff --git a/include/asm-generic/memory_model.h b/include/asm-generic/memory_model.h index fb2d63f13f4..14909b0b9ca 100644 --- a/include/asm-generic/memory_model.h +++ b/include/asm-generic/memory_model.h @@ -39,7 +39,7 @@  })  #define __page_to_pfn(pg)						\ -({	struct page *__pg = (pg);					\ +({	const struct page *__pg = (pg);					\  	struct pglist_data *__pgdat = NODE_DATA(page_to_nid(__pg));	\  	(unsigned long)(__pg - __pgdat->node_mem_map) +			\  	 __pgdat->node_start_pfn;					\ @@ -53,11 +53,11 @@  #elif defined(CONFIG_SPARSEMEM)  /* - * Note: section's mem_map is encorded to reflect its start_pfn. + * Note: section's mem_map is encoded to reflect its start_pfn.   * section[i].section_mem_map == mem_map's address - start_pfn;   */  #define __page_to_pfn(pg)					\ -({	struct page *__pg = (pg);				\ +({	const struct page *__pg = (pg);				\  	int __sec = page_to_section(__pg);			\  	(unsigned long)(__pg - __section_mem_map_addr(__nr_to_section(__sec)));	\  })  | 
