net: ipa: allocate transaction before pages when replenishing
authorAlex Elder <elder@linaro.org>
Thu, 3 Feb 2022 17:09:19 +0000 (11:09 -0600)
committerDavid S. Miller <davem@davemloft.net>
Fri, 4 Feb 2022 10:16:07 +0000 (10:16 +0000)
commitb4061c136b56b9cc2688e83293e0ea7b9605d992
treec717c2cc85445108e19732ca0cb3489ca3525725
parenta9bec7ae70c16f003d6138617c8bd305de3b230e
net: ipa: allocate transaction before pages when replenishing

A transaction failure only occurs if no more transactions are
available for an endpoint.  It's a very cheap test.

When replenishing an RX endpoint buffer, there's no point in
allocating pages if transactions are exhausted.  So don't bother
doing so unless the transaction allocation succeeds.

Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ipa/ipa_endpoint.c