diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-12-12 12:43:05 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-12-12 12:43:05 +0100 |
commit | 81444a799550214f549caf579cf65a0ca55e70b7 (patch) | |
tree | 3288dac0740be2e1e7d1af4ee51d792a6e91edf3 /mm | |
parent | a64d31baed104be25305e9c71585d3ea4ee9a418 (diff) | |
parent | da485e0cb16726797e99a595a399b9fc721b91bc (diff) |
Merge branch 'tracing/fastboot' into cpus4096
Diffstat (limited to 'mm')
-rw-r--r-- | mm/backing-dev.c | 3 | ||||
-rw-r--r-- | mm/bounce.c | 5 | ||||
-rw-r--r-- | mm/swap.c | 7 |
3 files changed, 13 insertions, 2 deletions
diff --git a/mm/backing-dev.c b/mm/backing-dev.c index f2e574dbc300..2a56124dbc28 100644 --- a/mm/backing-dev.c +++ b/mm/backing-dev.c @@ -176,6 +176,9 @@ int bdi_register(struct backing_dev_info *bdi, struct device *parent, int ret = 0; struct device *dev; + if (WARN_ON(bdi->dev)) + goto exit; + va_start(args, fmt); dev = device_create_vargs(bdi_class, parent, MKDEV(0, 0), bdi, fmt, args); va_end(args); diff --git a/mm/bounce.c b/mm/bounce.c index 06722c403058..bf0cf7c8387b 100644 --- a/mm/bounce.c +++ b/mm/bounce.c @@ -14,6 +14,7 @@ #include <linux/hash.h> #include <linux/highmem.h> #include <linux/blktrace_api.h> +#include <trace/block.h> #include <asm/tlbflush.h> #define POOL_SIZE 64 @@ -21,6 +22,8 @@ static mempool_t *page_pool, *isa_page_pool; +DEFINE_TRACE(block_bio_bounce); + #ifdef CONFIG_HIGHMEM static __init int init_emergency_pool(void) { @@ -222,7 +225,7 @@ static void __blk_queue_bounce(struct request_queue *q, struct bio **bio_orig, if (!bio) return; - blk_add_trace_bio(q, *bio_orig, BLK_TA_BOUNCE); + trace_block_bio_bounce(q, *bio_orig); /* * at least one page was bounced, fill in possible non-highmem diff --git a/mm/swap.c b/mm/swap.c index 2152e48a7b8f..2881987603eb 100644 --- a/mm/swap.c +++ b/mm/swap.c @@ -445,6 +445,7 @@ void ____pagevec_lru_add(struct pagevec *pvec, enum lru_list lru) for (i = 0; i < pagevec_count(pvec); i++) { struct page *page = pvec->pages[i]; struct zone *pagezone = page_zone(page); + int file; if (pagezone != zone) { if (zone) @@ -456,8 +457,12 @@ void ____pagevec_lru_add(struct pagevec *pvec, enum lru_list lru) VM_BUG_ON(PageUnevictable(page)); VM_BUG_ON(PageLRU(page)); SetPageLRU(page); - if (is_active_lru(lru)) + file = is_file_lru(lru); + zone->recent_scanned[file]++; + if (is_active_lru(lru)) { SetPageActive(page); + zone->recent_rotated[file]++; + } add_page_to_lru_list(zone, page, lru); } if (zone) |