Re: [PATCH 0/8] drop if around WARN_ON

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

 



On Sun, 4 Nov 2012, Sasha Levin wrote:

Hi Julia,

On Sat, Nov 3, 2012 at 4:30 PM, Julia Lawall <Julia.Lawall@xxxxxxx> wrote:
These patches convert a conditional with a simple test expression and a
then branch that only calls WARN_ON(1) to just a call to WARN_ON, which
will test the condition.

// <smpl>
@@
expression e;
@@

(
if(<+...e(...)...+>) WARN_ON(1);
|
- if (e) WARN_ON(1);
+ WARN_ON(e);
)// </smpl>

So this deals with WARN_ON(), are you considering doing the same for
the rest of it's friends?

I tried WARN_ON_ONCE, but the pattern never occurred. Are there others that are worth trying?

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


[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux