]> git.baikalelectronics.ru Git - kernel.git/commit
tsnep: Fix tsnep_tx_unmap() error path usage
authorGerhard Engleder <gerhard@engleder-embedded.com>
Thu, 4 Aug 2022 18:39:35 +0000 (20:39 +0200)
committerJakub Kicinski <kuba@kernel.org>
Tue, 9 Aug 2022 03:44:33 +0000 (20:44 -0700)
commitb3ace288b23a62839cd1909f287b001dd76ae651
tree01277f80afcf77a5b337c9c8b89fc85377c51a1c
parentd39ce4d86ddfd8fdcbef5985e91fbccb418ad5c4
tsnep: Fix tsnep_tx_unmap() error path usage

If tsnep_tx_map() fails, then tsnep_tx_unmap() shall start at the write
index like tsnep_tx_map(). This is different to the normal operation.
Thus, add an additional parameter to tsnep_tx_unmap() to enable start at
different positions for successful TX and failed TX.

Fixes: ed2d3a71e548 ("tsnep: Add TSN endpoint Ethernet MAC driver")
Signed-off-by: Gerhard Engleder <gerhard@engleder-embedded.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/engleder/tsnep_main.c