]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ntb: Drop packets when qp link is down
authorDave Jiang <dave.jiang@intel.com>
Tue, 22 Aug 2023 16:04:51 +0000 (09:04 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 19 Sep 2023 10:22:51 +0000 (12:22 +0200)
commitbfa051f650a7708183bd86901ca4645dcf88c486
tree035a82186e326f61b12362f8f1263e169e0f7f72
parent8f4edcd655348beb97a21bb91e23c18126fe3855
ntb: Drop packets when qp link is down

commit f195a1a6fe416882984f8bd6c61afc1383171860 upstream.

Currently when the transport receive packets after netdev has closed the
transport returns error and triggers tx errors to be incremented and
carrier to be stopped. There is no reason to return error if the device is
already closed. Drop the packet and return 0.

Fixes: e26a5843f7f5 ("NTB: Split ntb_hw_intel and ntb_transport drivers")
Reported-by: Yuan Y Lu <yuan.y.lu@intel.com>
Tested-by: Yuan Y Lu <yuan.y.lu@intel.com>
Reviewed-by: Logan Gunthorpe <logang@deltatee.com>
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Signed-off-by: Jon Mason <jdmason@kudzu.us>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/ntb/ntb_transport.c