Message ID | 20230828143646.8835-1-adiupina@astralinux.ru (mailing list archive) |
---|---|
State | Rejected |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | idt77252: remove check of idt77252_init_ubr() return value | expand |
On Mon, 28 Aug 2023 17:36:46 +0300 Alexandra Diupina wrote: > idt77252_init_ubr() always returns 0, so it is possible > to remove check of its return value > > Found by Linux Verification Center (linuxtesting.org) with SVACE. > > Fixes: 2dde18cd1d8f ("Linux 6.5") How is this a fix and if it was how could the release tag possibly have caused the issue? I think this is pointless churn, unless the error handling is buggy in itself you should leave this code be.
diff --git a/drivers/atm/idt77252.c b/drivers/atm/idt77252.c index e327a0229dc1..2c8e0e6cf4b9 100644 --- a/drivers/atm/idt77252.c +++ b/drivers/atm/idt77252.c @@ -2296,13 +2296,7 @@ idt77252_init_tx(struct idt77252_dev *card, struct vc_map *vc, break; case SCHED_UBR: - error = idt77252_init_ubr(card, vc, vcc, qos); - if (error) { - card->scd2vc[vc->scd_index] = NULL; - free_scq(card, vc->scq); - return error; - } - + idt77252_init_ubr(card, vc, vcc, qos); set_bit(VCF_IDLE, &vc->flags); break; } @@ -2586,9 +2580,7 @@ idt77252_change_qos(struct atm_vcc *vcc, struct atm_qos *qos, int flags) break; case ATM_UBR: - error = idt77252_init_ubr(card, vc, vcc, qos); - if (error) - goto out; + idt77252_init_ubr(card, vc, vcc, qos); if (!test_bit(VCF_IDLE, &vc->flags)) { writel(TCMDQ_LACR | (vc->lacr << 16) |
idt77252_init_ubr() always returns 0, so it is possible to remove check of its return value Found by Linux Verification Center (linuxtesting.org) with SVACE. Fixes: 2dde18cd1d8f ("Linux 6.5") Signed-off-by: Alexandra Diupina <adiupina@astralinux.ru> --- drivers/atm/idt77252.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-)