From: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
To: Jens Axboe <jens.axboe@oracle.com>, Ingo Molnar <mingo@elte.hu>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>,
linux-next@vger.kernel.org,
Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: [PATCH] Blktrace : conversion to tracepoint define
Date: Wed, 26 Nov 2008 06:06:31 -0500 [thread overview]
Message-ID: <20081126110631.GD14826@Krystal> (raw)
In-Reply-To: <20081126104700.GI26308@kernel.dk>
Here is the conversion to the new tracepoint API, which applies to -tip
after the patch you just emailed.
Mathieu
Blktrace : conversion to tracepoint define
Adapt declaration/definitions of blktrace tracepoints to the new tracepoint API.
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
CC: Arnaldo Carvalho de Melo <acme@redhat.com>
CC: 'Ingo Molnar' <mingo@elte.hu>
CC: Jens Axboe <jens.axboe@oracle.com>
CC: Arnaldo Carvalho de Melo <acme@redhat.com>
CC: Stephen Rothwell <sfr@canb.auug.org.au>
---
block/blk-core.c | 13 +++++++++++++
block/elevator.c | 3 +++
drivers/md/dm.c | 2 ++
fs/bio.c | 2 ++
include/trace/block.h | 34 +++++++++++++++++-----------------
mm/bounce.c | 2 ++
6 files changed, 39 insertions(+), 17 deletions(-)
Index: linux.trees.git/mm/bounce.c
===================================================================
--- linux.trees.git.orig/mm/bounce.c 2008-11-26 05:49:40.000000000 -0500
+++ linux.trees.git/mm/bounce.c 2008-11-26 05:50:08.000000000 -0500
@@ -22,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)
{
Index: linux.trees.git/fs/bio.c
===================================================================
--- linux.trees.git.orig/fs/bio.c 2008-11-26 05:49:40.000000000 -0500
+++ linux.trees.git/fs/bio.c 2008-11-26 05:50:25.000000000 -0500
@@ -29,6 +29,8 @@
#include <trace/block.h>
#include <scsi/sg.h> /* for struct sg_iovec */
+DEFINE_TRACE(block_split);
+
static struct kmem_cache *bio_slab __read_mostly;
static mempool_t *bio_split_pool __read_mostly;
Index: linux.trees.git/drivers/md/dm.c
===================================================================
--- linux.trees.git.orig/drivers/md/dm.c 2008-11-26 05:49:40.000000000 -0500
+++ linux.trees.git/drivers/md/dm.c 2008-11-26 05:50:08.000000000 -0500
@@ -52,6 +52,8 @@ struct dm_target_io {
union map_info info;
};
+DEFINE_TRACE(block_bio_complete);
+
union map_info *dm_get_mapinfo(struct bio *bio)
{
if (bio && bio->bi_private)
Index: linux.trees.git/block/blk-core.c
===================================================================
--- linux.trees.git.orig/block/blk-core.c 2008-11-26 05:49:40.000000000 -0500
+++ linux.trees.git/block/blk-core.c 2008-11-26 05:50:08.000000000 -0500
@@ -32,6 +32,19 @@
#include "blk.h"
+DEFINE_TRACE(block_plug);
+DEFINE_TRACE(block_unplug_io);
+DEFINE_TRACE(block_unplug_timer);
+DEFINE_TRACE(block_getrq);
+DEFINE_TRACE(block_sleeprq);
+DEFINE_TRACE(block_rq_requeue);
+DEFINE_TRACE(block_bio_backmerge);
+DEFINE_TRACE(block_bio_frontmerge);
+DEFINE_TRACE(block_bio_queue);
+DEFINE_TRACE(block_rq_complete);
+DEFINE_TRACE(block_remap); /* Also used in drivers/md/dm.c */
+EXPORT_TRACEPOINT_SYMBOL_GPL(block_remap);
+
static int __make_request(struct request_queue *q, struct bio *bio);
/*
Index: linux.trees.git/block/elevator.c
===================================================================
--- linux.trees.git.orig/block/elevator.c 2008-11-26 05:49:40.000000000 -0500
+++ linux.trees.git/block/elevator.c 2008-11-26 05:50:08.000000000 -0500
@@ -53,6 +53,9 @@ static const int elv_hash_shift = 6;
#define rq_hash_key(rq) ((rq)->sector + (rq)->nr_sectors)
#define ELV_ON_HASH(rq) (!hlist_unhashed(&(rq)->hash))
+DEFINE_TRACE(block_rq_insert);
+DEFINE_TRACE(block_rq_issue);
+
/*
* Query io scheduler to see if the current process issuing bio may be
* merged with rq.
Index: linux.trees.git/include/trace/block.h
===================================================================
--- linux.trees.git.orig/include/trace/block.h 2008-11-26 05:50:35.000000000 -0500
+++ linux.trees.git/include/trace/block.h 2008-11-26 05:51:09.000000000 -0500
@@ -4,55 +4,55 @@
#include <linux/blkdev.h>
#include <linux/tracepoint.h>
-DEFINE_TRACE(block_rq_abort,
+DECLARE_TRACE(block_rq_abort,
TPPROTO(struct request_queue *q, struct request *rq),
TPARGS(q, rq));
-DEFINE_TRACE(block_rq_insert,
+DECLARE_TRACE(block_rq_insert,
TPPROTO(struct request_queue *q, struct request *rq),
TPARGS(q, rq));
-DEFINE_TRACE(block_rq_issue,
+DECLARE_TRACE(block_rq_issue,
TPPROTO(struct request_queue *q, struct request *rq),
TPARGS(q, rq));
-DEFINE_TRACE(block_rq_requeue,
+DECLARE_TRACE(block_rq_requeue,
TPPROTO(struct request_queue *q, struct request *rq),
TPARGS(q, rq));
-DEFINE_TRACE(block_rq_complete,
+DECLARE_TRACE(block_rq_complete,
TPPROTO(struct request_queue *q, struct request *rq),
TPARGS(q, rq));
-DEFINE_TRACE(block_bio_bounce,
+DECLARE_TRACE(block_bio_bounce,
TPPROTO(struct request_queue *q, struct bio *bio),
TPARGS(q, bio));
-DEFINE_TRACE(block_bio_complete,
+DECLARE_TRACE(block_bio_complete,
TPPROTO(struct request_queue *q, struct bio *bio),
TPARGS(q, bio));
-DEFINE_TRACE(block_bio_backmerge,
+DECLARE_TRACE(block_bio_backmerge,
TPPROTO(struct request_queue *q, struct bio *bio),
TPARGS(q, bio));
-DEFINE_TRACE(block_bio_frontmerge,
+DECLARE_TRACE(block_bio_frontmerge,
TPPROTO(struct request_queue *q, struct bio *bio),
TPARGS(q, bio));
-DEFINE_TRACE(block_bio_queue,
+DECLARE_TRACE(block_bio_queue,
TPPROTO(struct request_queue *q, struct bio *bio),
TPARGS(q, bio));
-DEFINE_TRACE(block_getrq,
+DECLARE_TRACE(block_getrq,
TPPROTO(struct request_queue *q, struct bio *bio, int rw),
TPARGS(q, bio, rw));
-DEFINE_TRACE(block_sleeprq,
+DECLARE_TRACE(block_sleeprq,
TPPROTO(struct request_queue *q, struct bio *bio, int rw),
TPARGS(q, bio, rw));
-DEFINE_TRACE(block_plug,
+DECLARE_TRACE(block_plug,
TPPROTO(struct request_queue *q),
TPARGS(q));
-DEFINE_TRACE(block_unplug_timer,
+DECLARE_TRACE(block_unplug_timer,
TPPROTO(struct request_queue *q),
TPARGS(q));
-DEFINE_TRACE(block_unplug_io,
+DECLARE_TRACE(block_unplug_io,
TPPROTO(struct request_queue *q),
TPARGS(q));
-DEFINE_TRACE(block_split,
+DECLARE_TRACE(block_split,
TPPROTO(struct request_queue *q, struct bio *bio, unsigned int pdu),
TPARGS(q, bio, pdu));
-DEFINE_TRACE(block_remap,
+DECLARE_TRACE(block_remap,
TPPROTO(struct request_queue *q, struct bio *bio, dev_t dev,
sector_t from, sector_t to),
TPARGS(q, bio, dev, from, to));
--
Mathieu Desnoyers
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68
next prev parent reply other threads:[~2008-11-26 12:21 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-26 10:29 linux-next: block tree build failure Stephen Rothwell
2008-11-26 10:42 ` Ingo Molnar
2008-11-26 10:47 ` Jens Axboe
2008-11-26 11:06 ` Mathieu Desnoyers [this message]
2008-11-26 11:22 ` [PATCH] Blktrace : conversion to tracepoint define Ingo Molnar
2008-11-26 11:23 ` Ingo Molnar
2008-11-26 11:27 ` Mathieu Desnoyers
2008-11-26 11:37 ` Ingo Molnar
2008-11-26 11:56 ` Mathieu Desnoyers
2008-11-26 11:16 ` linux-next: block tree build failure Ingo Molnar
2008-11-26 11:20 ` Jens Axboe
2008-11-26 11:28 ` Ingo Molnar
2008-11-26 11:23 ` Mathieu Desnoyers
2008-11-26 11:25 ` Ingo Molnar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20081126110631.GD14826@Krystal \
--to=mathieu.desnoyers@polymtl.ca \
--cc=acme@redhat.com \
--cc=jens.axboe@oracle.com \
--cc=linux-next@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=sfr@canb.auug.org.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).