Re: [PATCH] coccinelle: api: add sprintf() support to device_attr_show

2020-08-14 Thread Denis Efremov
On 8/14/20 3:30 PM, Markus Elfring wrote: >>> You propose to use a nested SmPL disjunction for desired adjustments. >>> I suggest to start a corresponding case distinction behind >>> the key word “return” instead of repeating it three times. >> >> It doesn't work. > > How do you think about to

Re: [PATCH] coccinelle: api: add sprintf() support to device_attr_show

2020-08-14 Thread Denis Efremov
Hi, Markus, I think that CCing new people and spam them with mails they are obviously not interested in doesn't bring an additional value to the discussion. linux-kernel and cocci mailing lists are enough in my opinion. This also will allow us to keep "threaded" mail order. On 8/14/20 11:30 AM, M

[PATCH] coccinelle: api: add sprintf() support to device_attr_show

2020-08-13 Thread Denis Efremov
It's safe to use sprintf() for simple cases in device_attr_show type of functions. Add support for sprintf() in patch mode to the device_attr_show.cocci script to print numbers and pointers. Signed-off-by: Denis Efremov --- Interesting enough that with this patch coccinelle starts to skip patch g