Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 88575
b: refs/heads/master
c: ee7ae7a
h: refs/heads/master
i:
  88573: 7f85cd3
  88571: 367887d
  88567: 84d04bc
  88559: 2e70660
  88543: 0294ea8
  88511: 8d5ba7b
  88447: f355d6b
  88319: 58c8bd0
  88063: 6c3bac0
v: v3
  • Loading branch information
Thomas Gleixner authored and Ingo Molnar committed Apr 17, 2008
1 parent 6438dc8 commit 31b55bb
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5de253cc5b1f565f7aeb5bacd67bac37e943ceef
refs/heads/master: ee7ae7a1981caaa4a5b14d8c75692a9dccd52105
41 changes: 41 additions & 0 deletions trunk/arch/x86/mm/pageattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
#include <linux/slab.h>
#include <linux/mm.h>
#include <linux/interrupt.h>
#include <linux/seq_file.h>
#include <linux/debugfs.h>

#include <asm/e820.h>
#include <asm/processor.h>
Expand Down Expand Up @@ -918,6 +920,45 @@ void kernel_map_pages(struct page *page, int numpages, int enable)
cpa_fill_pool(NULL);
}

#ifdef CONFIG_DEBUG_FS
static int dpa_show(struct seq_file *m, void *v)
{
seq_puts(m, "DEBUG_PAGEALLOC\n");
seq_printf(m, "pool_size : %lu\n", pool_size);
seq_printf(m, "pool_pages : %lu\n", pool_pages);
seq_printf(m, "pool_low : %lu\n", pool_low);
seq_printf(m, "pool_used : %lu\n", pool_used);
seq_printf(m, "pool_failed : %lu\n", pool_failed);

return 0;
}

static int dpa_open(struct inode *inode, struct file *filp)
{
return single_open(filp, dpa_show, NULL);
}

static const struct file_operations dpa_fops = {
.open = dpa_open,
.read = seq_read,
.llseek = seq_lseek,
.release = single_release,
};

int __init debug_pagealloc_proc_init(void)
{
struct dentry *de;

de = debugfs_create_file("debug_pagealloc", 0600, NULL, NULL,
&dpa_fops);
if (!de)
return -ENOMEM;

return 0;
}
__initcall(debug_pagealloc_proc_init);
#endif

#ifdef CONFIG_HIBERNATION

bool kernel_page_present(struct page *page)
Expand Down

0 comments on commit 31b55bb

Please sign in to comment.