[PATCH V2 0/3] Fix some kernel panics due to the host sending invalid PDUs

Maurizio Lombardi
2023-12-22T15:18:05Z

I used the reproducer that was published here:
https://lore.kernel.org/linux-nvme/89a927a6-2baf-434a-b1d5-50fb99beca73@grimberg.me/T/#m57f25abc944dc706125fed02cb99d86b56c5d36e

I didn't get the same call trace, however.

V2: Be sure the DATAL field is consistent with the packet size.
Add a third patch that cleans up the error code path.

Maurizio Lombardi (3):
nvmet-tcp: Fix a kernel panic when host sends an invalid H2C PDU
length
nvmet-tcp: fix a crash in nvmet_req_complete()
nvmet-tcp: remove boilerplate code

drivers/nvme/target/tcp.c | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)

--
2.39.3