|
@@ -474,10 +474,16 @@ struct zone {
|
|
|
* frequently read in proximity to zone->lock. It's good to
|
|
|
* give them a chance of being in the same cacheline.
|
|
|
*
|
|
|
- * Write access to present_pages and managed_pages at runtime should
|
|
|
- * be protected by lock_memory_hotplug()/unlock_memory_hotplug().
|
|
|
- * Any reader who can't tolerant drift of present_pages and
|
|
|
- * managed_pages should hold memory hotplug lock to get a stable value.
|
|
|
+ * Write access to present_pages at runtime should be protected by
|
|
|
+ * lock_memory_hotplug()/unlock_memory_hotplug(). Any reader who can't
|
|
|
+ * tolerant drift of present_pages should hold memory hotplug lock to
|
|
|
+ * get a stable value.
|
|
|
+ *
|
|
|
+ * Read access to managed_pages should be safe because it's unsigned
|
|
|
+ * long. Write access to zone->managed_pages and totalram_pages are
|
|
|
+ * protected by managed_page_count_lock at runtime. Idealy only
|
|
|
+ * adjust_managed_page_count() should be used instead of directly
|
|
|
+ * touching zone->managed_pages and totalram_pages.
|
|
|
*/
|
|
|
unsigned long spanned_pages;
|
|
|
unsigned long present_pages;
|