Re: [PATCH net-next] devlink: remove some unnecessary code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fri, Jan 13, 2023 at 08:35:43AM CET, error27@xxxxxxxxx wrote:
>This code checks if (attrs[DEVLINK_ATTR_TRAP_POLICER_ID]) twice.  Once
>at the start of the function and then a couple lines later.  Delete the
>second check since that one must be true.
>
>Because the second condition is always true, it means the:
>
>	policer_item = group_item->policer_item;
>
>assignment is immediately over-written.  Delete that as well.
>
>Signed-off-by: Dan Carpenter <error27@xxxxxxxxx>

Reviewed-by: Jiri Pirko <jiri@xxxxxxxxxx>



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux