Re: [PATCH 1/3] ring_buffer: Change some static functions to void

From: Uros Bizjak
Date: Wed Mar 01 2023 - 03:47:07 EST


On Tue, Feb 28, 2023 at 11:55 PM Masami Hiramatsu <mhiramat@xxxxxxxxxx> wrote:
>
> On Tue, 28 Feb 2023 18:59:27 +0100
> Uros Bizjak <ubizjak@xxxxxxxxx> wrote:
>
> > The results of some static functions are not used. Change the
> > type of these function to void and remove unnecessary returns.
> >
> > No functional change intended.
>
> NAK, instead of dropping the errors, please handle it on the caller side.

I was under the impression that the intention of these two functions
is to warn if there is any corruption in data pages detected. Please
note that the patch has no effect on code size, as the compiler is
smart enough to drop unused return values by itself. So, the change is
mostly cosmetic as I was just bothered by unused returns. I'm not
versed enough in the code to introduce additional error handling, so
considering its minimal impact, the patch can just be dropped.

Uros.