lkml.org 
[lkml]   [2019]   [Jul]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v4 3/3] coccinelle: Add script to check for platform_get_irq() excessive prints
From
Date
I would prefer to concentrate the usage of SmPL disjunctions on changing
implementation details so that the specification of duplicate code
can be avoided.


> +(
> +platform_get_irq(E, ...)
> +|
> +platform_get_irq_byname(E, ...)
> +);

Function names:

+(platform_get_irq
+|platform_get_irq_byname
+)(E, ...);


> +if ( \( ret < 0 \| ret <= 0 \) )

Comparison operators:

+if (ret \( < \| <= \) 0)


> +if (ret != -EPROBE_DEFER)

Is it appropriate to treat this error code check as optional
by the shown transformation approach?
Can this case distinction be omitted?

Regards,
Markus

\
 
 \ /
  Last update: 2019-07-24 11:32    [W:0.138 / U:3.072 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site