]> git.baikalelectronics.ru Git - kernel.git/commit
net: ipa: track allocated transactions with an ID
authorAlex Elder <elder@linaro.org>
Wed, 31 Aug 2022 22:40:13 +0000 (17:40 -0500)
committerDavid S. Miller <davem@davemloft.net>
Fri, 2 Sep 2022 11:08:44 +0000 (12:08 +0100)
commit3441b7df517832f89e3bcb978d9e137b67b8c6a7
treec1ccc0fdf6f5d77d46e89ea2f75684b97cfa2c60
parentf89dd88aa939a7ff7fe12549c34eae5c55da7977
net: ipa: track allocated transactions with an ID

Transactions for a channel are now managed in an array, with a free
transaction ID indicating which is the next one free.

Add another transaction ID field to track the first element in the
array that has been allocated.  Advance it when a transaction is
committed (because that is when that transaction leaves allocated
state).

Temporarily add warnings that verify that the first allocated
transaction tracked by the ID matches the first element on the
allocated list, both when allocating and committing a transaction.

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