lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220624141655.zcyebflytmftojsd@revolver>
Date:   Fri, 24 Jun 2022 14:31:22 +0000
From:   Liam Howlett <liam.howlett@...cle.com>
To:     Matthew Wilcox <willy@...radead.org>
CC:     David Hildenbrand <david@...hat.com>,
        "maple-tree@...ts.infradead.org" <maple-tree@...ts.infradead.org>,
        "linux-mm@...ck.org" <linux-mm@...ck.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        "damon @ lists . linux . dev" <damon@...ts.linux.dev>,
        SeongJae Park <sj@...nel.org>
Subject: Re: [PATCH v10 09/69] mm: add VMA iterator

* Matthew Wilcox <willy@...radead.org> [220623 13:03]:
> On Tue, Jun 21, 2022 at 11:10:09PM +0200, David Hildenbrand wrote:
> > > +#define VMA_ITERATOR(name, mm, addr) 					\
> > > +	struct vma_iterator name = {					\
> > > +		.mas = {						\
> > > +			.tree = &mm->mm_mt,				\
> > > +			.index = addr,					\
> > > +			.node = MAS_START,				\
> > > +		},							\
> > > +	}
> > > +
> > 
> > No __* and () macro magic?
> > 
> > I'd have expected at least
> > 
> > tree = &(__mm)->mm_mt,
> > .index = (__addr),
> > 
> > ;)
> 
> Fair, fair.  Just testing that change now.  I always forget to do those
> things until they bite me.
> 
> > Reviewed-by: David Hildenbrand <david@...hat.com>
> 
> Appreciate the review!


I'll also do the same underscores for the maple tree defines where
necessary.

Thanks David.

> 
> diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h
> index acbd8d03e01e..8bcbffefdc02 100644
> --- a/include/linux/mm_types.h
> +++ b/include/linux/mm_types.h
> @@ -686,11 +686,11 @@ struct vma_iterator {
>  	struct ma_state mas;
>  };
>  
> -#define VMA_ITERATOR(name, mm, addr) 					\
> +#define VMA_ITERATOR(name, _mm, _addr)	 				\
>  	struct vma_iterator name = {					\
>  		.mas = {						\
> -			.tree = &mm->mm_mt,				\
> -			.index = addr,					\
> +			.tree = &(_mm)->mm_mt,				\
> +			.index = (_addr),				\
>  			.node = MAS_START,				\
>  		},							\
>  	}

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ