ntb: Check tx descriptors outstanding instead of head/tail for tx queue
authorDave Jiang <dave.jiang@intel.com>
Tue, 22 Aug 2023 16:05:02 +0000 (09:05 -0700)
committerJon Mason <jdmason@kudzu.us>
Tue, 22 Aug 2023 16:38:19 +0000 (12:38 -0400)
commit643982232860887fed493144957ea5794b6557d1
treecf1d163baad1e20518161ab258d0d6759097eeeb
parent5a7693e6bbf19b22fd6c1d2c4b7beb0a03969e2c
ntb: Check tx descriptors outstanding instead of head/tail for tx queue

Use existing function ntb_transport_tx_free_entry() instead of open coding
the check to see if there are outstanding tx descriptors.

Reviewed-by: Logan Gunthorpe <logang@deltatee.com>
Signed-off-by: Dave Jiang <dave.jiang@intel.com>
Signed-off-by: Jon Mason <jdmason@kudzu.us>
drivers/ntb/ntb_transport.c