Re: [PATCH] can: pch_can: move setting of errc to before use

From: Vincent MAILHOL
Date: Thu Jul 21 2022 - 12:22:04 EST


On Fri. 22 juil. 2022 à 01:18, Tom Rix <trix@xxxxxxxxxx> wrote:
> clang build fails with
> drivers/net/can/pch_can.c:501:17: error: variable 'errc' is uninitialized when used here [-Werror,-Wuninitialized]
> cf->data[6] = errc & PCH_TEC;
>
> The commit in the fixes moved the use without moving the setting. So move
> the setting of errc to before the use.
>
> Fixes: 3a5c7e4611dd ("can: pch_can: do not report txerr and rxerr during bus-off")
> Signed-off-by: Tom Rix <trix@xxxxxxxxxx>

Sorry, you are a couple minutes late. You are actually the third to
submit the same patch:
https://lore.kernel.org/linux-can/20220721155228.3399103-1-mkl@xxxxxxxxxxxxxx/
https://lore.kernel.org/linux-can/20220721160032.9348-1-mailhol.vincent@xxxxxxxxxx/

But thanks for this!


Yours sincerely,
Vincent Mailhol