Re: [PATCH v4 04/28] range: Add range_overlaps()

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

 



David Sterba wrote:
> On Mon, Oct 07, 2024 at 06:16:10PM -0500, Ira Weiny wrote:
> > --- a/include/linux/range.h
>> +++ b/include/linux/range.h
> > +/* True if any part of r1 overlaps r2 */
> > +static inline bool range_overlaps(struct range *r1, struct range *r2)
> 
> I've noticed only now, you can constify the arguments, but this applise
> to other range_* functions so that can be done later in one go.

Looks like there will be a v5.  I'll do a separate cleanup patch for
range_contains() and change this one.

Thanks!
Ira

> 
> > +{
> > +	return r1->start <= r2->end && r1->end >= r2->start;
> > +}






[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux