diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2019-12-04 17:49:34 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@gmail.com> | 2019-12-04 17:49:34 -0500 |
commit | f712a866a474d70bfbe3a43aad2b04ceec13ddd3 (patch) | |
tree | 53a63cca6f67ddcf0a6da1afed417fedf8df17b1 /linux | |
parent | ffced87f08a9ff929f78fd941536d4f88507588a (diff) |
Put valgrind support behind CONFIG_VALGRIND
Diffstat (limited to 'linux')
-rw-r--r-- | linux/blkdev.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/blkdev.c b/linux/blkdev.c index 219f888e..709e7703 100644 --- a/linux/blkdev.c +++ b/linux/blkdev.c @@ -10,7 +10,9 @@ #include <libaio.h> +#ifdef CONFIG_VALGRIND #include <valgrind/memcheck.h> +#endif #include <linux/bio.h> #include <linux/blkdev.h> @@ -57,9 +59,11 @@ void generic_make_request(struct bio *bio) .iov_len = len, }; +#ifdef CONFIG_VALGRIND /* To be pedantic it should only be on IO completion. */ if (bio_op(bio) == REQ_OP_READ) VALGRIND_MAKE_MEM_DEFINED(start, len); +#endif } struct iocb iocb = { |