On Sat, Feb 21, 2015 at 06:53:30PM -0800, Joe Perches wrote:
> The seq_printf return value, because it's frequently misused,
> will eventually be converted to void.
> 
> See: commit 1f33c41c03da ("seq_file: Rename seq_overflow() to
>      seq_has_overflowed() and make public")
> 
> Convert these uses to:
> 
>       seq_printf(seq, ...);
> 
>       return 0;
> 
> Done via cocci script:
> 
> @@
> struct seq_file *seq;
> int i;
> @@
> -     i = seq_printf(seq,
> +     seq_printf(seq,
>                  ...);
>       ...
> -     return i;
> +     return 0;
> 
> @@
> struct seq_file *seq;
> int i;
> @@
> -     i = 0;
> -     i += seq_printf(seq,
> +     seq_printf(seq,
>                  ...);
>       ...
> -     return i;
> +     return 0;
> 
> With some additional reformatting and typing post conversion
> to remove the now unnecessary "int i;" declaration.
> 
> Signed-off-by: Joe Perches <j...@perches.com>
> Cc: Oleg Drokin <oleg.dro...@intel.com>
> Cc: Andreas Dilger <andreas.dil...@intel.com>
> Signed-off-by: Andrew Morton <a...@linux-foundation.org>
> ---
>  drivers/staging/lustre/lustre/fid/lproc_fid.c      | 23 +++---
>  drivers/staging/lustre/lustre/llite/lproc_llite.c  |  5 +-
>  drivers/staging/lustre/lustre/mdc/lproc_mdc.c      |  6 +-
>  drivers/staging/lustre/lustre/osc/lproc_osc.c      | 45 ++++++------
>  .../staging/lustre/lustre/ptlrpc/lproc_ptlrpc.c    |  5 +-
>  drivers/staging/lustre/lustre/ptlrpc/sec_bulk.c    | 82 
> +++++++++++-----------
>  6 files changed, 79 insertions(+), 87 deletions(-)

This patch fails to apply to my tree anymore :(

Can you refresh it against the staging-testing branch of staging.git and
resend?

thanks,

greg k-h
_______________________________________________
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Reply via email to