Re: [PATCH] of: overlay: Remove redundant assignment to ret

From: Rob Herring
Date: Mon May 03 2021 - 14:58:05 EST


On Sun, 25 Apr 2021 18:40:58 +0800, Jiapeng Chong wrote:
> Variable ret is set to zero but this value is never read as it is
> overwritten with a new value later on, hence it is a redundant
> assignment and can be removed.
>
> Cleans up the following clang-analyzer warning:
>
> drivers/of/overlay.c:1197:2: warning: Value stored to 'ret' is never
> read [clang-analyzer-deadcode.DeadStores].
>
> drivers/of/overlay.c:1026:2: warning: Value stored to 'ret' is never
> read [clang-analyzer-deadcode.DeadStores].
>
> Reported-by: Abaci Robot <abaci@xxxxxxxxxxxxxxxxx>
> Signed-off-by: Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx>
> ---
> drivers/of/overlay.c | 3 ---
> 1 file changed, 3 deletions(-)
>

Applied, thanks!