MIPS: rtlx: Fix two error paths in rtlx_open()
Get series with b4
b4 am [email protected] change-id 20261121-rtlx-c20afd932646Versions newest first
- v1 Latest2 patches 0 repliesNew
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | MIPS: rtlx: Drop in_open count when rtlx_init() failsarch/ | +1 | 0 replies | |
| 2/2 | MIPS: rtlx: Call finish_wait() when rtlx_open() is interruptedarch/ | +2 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/2] MIPS: rtlx: Fix two error paths in rtlx_open()
Two error paths in rtlx_open() leave state behind: a failed rtlx_init() skips the in_open decrement, so the channel stays busy for good, and a signal while waiting for the SP program leaves the stack wait entry on the queue.
Found with a static analysis tool and checked by hand. Compile tested on mips (maltaaprp_defconfig, W=1); I don't have the hardware.
---
Suyuan Wang (2):
MIPS: rtlx: Drop in_open count when rtlx_init() fails
MIPS: rtlx: Call finish_wait() when rtlx_open() is interrupted
arch/mips/kernel/rtlx.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)