Re: [Patch] fix include statement in stats.h

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Applied both, thanks Martin!


On Mon, Apr 20 2009, Martin Peschke wrote:
> From: Martin Peschke <mpeschke@xxxxxxxxxxxxxxxxxx>
> 
> Some endianess conversion macros have been moved and the corresponding
> header file is gone. Need to adapt an include statement in stats.h. The
> compiler did not complain because blkiomon.c accidently included blktrace.h
> prior to stats.h. Introduced by blktrace rewrite which became version 2.
> 
> Signed-off-by: Martin Peschke <mpeschke@xxxxxxxxxxxxxxxxxx>
> 
> ---
>  stats.h |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- a/stats.h
> +++ b/stats.h
> @@ -23,7 +23,7 @@
>  #define STATS_H
>  
>  #include <linux/types.h>
> -#include "endian.h"
> +#include "blktrace.h"
>  
>  struct minmax {
>  	__u64 min;
> 
> 

On Mon, Apr 20 2009, Martin Peschke wrote:
> From: Martin Peschke <mpeschke@xxxxxxxxxxxxxxxxxx>
> 
> Fix two off-by-one issues. Last bucket of histogram was ommitted by mistake
> when being converted to big-endian or when being merged with another bucket.
> 
> Signed-off-by: Martin Peschke <mpeschke@xxxxxxxxxxxxxxxxxx>
> 
> ---
>  stats.h |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> --- a/stats.h
> +++ b/stats.h
> @@ -124,7 +124,7 @@ static inline void histlog2_merge(struct
>  {
>  	int i;
>  
> -	for (i = 0; i < h->num - 1; i++)
> +	for (i = 0; i < h->num; i++)
>  		dst[i] += src[i];
>  }
>  
> @@ -132,7 +132,7 @@ static inline void histlog2_to_be(__u32 
>  {
>  	int i;
>  
> -	for (i = 0; i < h->num - 1; i++)
> +	for (i = 0; i < h->num; i++)
>  		a[i] = cpu_to_be32(a[i]);
>  }
>  
> 
> 


-- 
Jens Axboe

--
To unsubscribe from this list: send the line "unsubscribe linux-btrace" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux