linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/3] cciss: add support for blktrace
@ 2007-11-19 22:07 Mike Miller
  2007-11-20  7:55 ` Andrew Morton
  2007-11-20  8:32 ` Jens Axboe
  0 siblings, 2 replies; 3+ messages in thread
From: Mike Miller @ 2007-11-19 22:07 UTC (permalink / raw)
  To: Andrew Morton, Jens Axboe; +Cc: linux-kernel, linux-scsi

Patch 2 of 3
This patch adds support for the blktrace utility. Please consider this for
inclusion. Seems there was already a call to blk_add_trace. This patch adds
ifdef's and includes the header file.

Signed-off-by: Mike Miller <mike.miller@hp.com>


diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
index 2ba5a89..61bc0f3 100644
--- a/drivers/block/cciss.c
+++ b/drivers/block/cciss.c
@@ -41,6 +41,10 @@
 #include <asm/uaccess.h>
 #include <asm/io.h>
 
+#ifdef CONFIG_BLK_DEV_IO_TRACE
+#include <linux/blktrace_api.h>
+#endif /* CONFIG_BLK_DEV_IO_TRACE */
+
 #include <linux/dma-mapping.h>
 #include <linux/blkdev.h>
 #include <linux/genhd.h>
@@ -3013,7 +3017,9 @@ after_error_processing:
 	}
 	cmd->rq->data_len = 0;
 	cmd->rq->completion_data = cmd;
+#ifdef CONFIG_BLK_DEV_IO_TRACE
 	blk_add_trace_rq(cmd->rq->q, cmd->rq, BLK_TA_COMPLETE);
+#endif /* CONFIG_BLK_DEV_IO_TRACE */
 	blk_complete_request(cmd->rq);
 }
 

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 2/3] cciss: add support for blktrace
  2007-11-19 22:07 [PATCH 2/3] cciss: add support for blktrace Mike Miller
@ 2007-11-20  7:55 ` Andrew Morton
  2007-11-20  8:32 ` Jens Axboe
  1 sibling, 0 replies; 3+ messages in thread
From: Andrew Morton @ 2007-11-20  7:55 UTC (permalink / raw)
  To: Mike Miller; +Cc: Jens Axboe, linux-kernel, linux-scsi

On Mon, 19 Nov 2007 16:07:17 -0600 Mike Miller <mike.miller@hp.com> wrote:

> Patch 2 of 3
> This patch adds support for the blktrace utility. Please consider this for
> inclusion. Seems there was already a call to blk_add_trace. This patch adds
> ifdef's and includes the header file.
> 
> Signed-off-by: Mike Miller <mike.miller@hp.com>
> 
> 
> diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
> index 2ba5a89..61bc0f3 100644
> --- a/drivers/block/cciss.c
> +++ b/drivers/block/cciss.c
> @@ -41,6 +41,10 @@
>  #include <asm/uaccess.h>
>  #include <asm/io.h>
>  
> +#ifdef CONFIG_BLK_DEV_IO_TRACE
> +#include <linux/blktrace_api.h>
> +#endif /* CONFIG_BLK_DEV_IO_TRACE */

The ifdefs shouldn't be needed here.  If they are needed, blktrace_api.h needs
fixing.

>  #include <linux/dma-mapping.h>
>  #include <linux/blkdev.h>
>  #include <linux/genhd.h>
> @@ -3013,7 +3017,9 @@ after_error_processing:
>  	}
>  	cmd->rq->data_len = 0;
>  	cmd->rq->completion_data = cmd;
> +#ifdef CONFIG_BLK_DEV_IO_TRACE
>  	blk_add_trace_rq(cmd->rq->q, cmd->rq, BLK_TA_COMPLETE);
> +#endif /* CONFIG_BLK_DEV_IO_TRACE */
>  	blk_complete_request(cmd->rq);
>  }

Add if you remove the first set of ifdefs, these ifdefs can also be
removed.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 2/3] cciss: add support for blktrace
  2007-11-19 22:07 [PATCH 2/3] cciss: add support for blktrace Mike Miller
  2007-11-20  7:55 ` Andrew Morton
@ 2007-11-20  8:32 ` Jens Axboe
  1 sibling, 0 replies; 3+ messages in thread
From: Jens Axboe @ 2007-11-20  8:32 UTC (permalink / raw)
  To: Mike Miller; +Cc: Andrew Morton, linux-kernel, linux-scsi

On Mon, Nov 19 2007, Mike Miller wrote:
> Patch 2 of 3
> This patch adds support for the blktrace utility. Please consider this for
> inclusion. Seems there was already a call to blk_add_trace. This patch adds
> ifdef's and includes the header file.
> 
> Signed-off-by: Mike Miller <mike.miller@hp.com>
> 
> 
> diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
> index 2ba5a89..61bc0f3 100644
> --- a/drivers/block/cciss.c
> +++ b/drivers/block/cciss.c
> @@ -41,6 +41,10 @@
>  #include <asm/uaccess.h>
>  #include <asm/io.h>
>  
> +#ifdef CONFIG_BLK_DEV_IO_TRACE
> +#include <linux/blktrace_api.h>
> +#endif /* CONFIG_BLK_DEV_IO_TRACE */
> +
>  #include <linux/dma-mapping.h>
>  #include <linux/blkdev.h>
>  #include <linux/genhd.h>
> @@ -3013,7 +3017,9 @@ after_error_processing:
>  	}
>  	cmd->rq->data_len = 0;
>  	cmd->rq->completion_data = cmd;
> +#ifdef CONFIG_BLK_DEV_IO_TRACE
>  	blk_add_trace_rq(cmd->rq->q, cmd->rq, BLK_TA_COMPLETE);
> +#endif /* CONFIG_BLK_DEV_IO_TRACE */
>  	blk_complete_request(cmd->rq);
>  }

Puzzled by this patch... What is it trying to achieve?

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-11-20  8:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-19 22:07 [PATCH 2/3] cciss: add support for blktrace Mike Miller
2007-11-20  7:55 ` Andrew Morton
2007-11-20  8:32 ` Jens Axboe

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).