net/bnxt: check resource reservation in TRUFLOW
authorJay Ding <jay.ding@broadcom.com>
Sun, 30 May 2021 08:58:35 +0000 (14:28 +0530)
committerAjit Khaparde <ajit.khaparde@broadcom.com>
Wed, 9 Jun 2021 18:48:08 +0000 (20:48 +0200)
commitfe00aacb6dc5f416fb28e237b4cea64b8b53d091
tree4e8bdfa17e50baa95e2124e8d1ff972dffb3c862
parent3d3ab7df754bbc6047b97850911b6768a0405f0a
net/bnxt: check resource reservation in TRUFLOW

- Allow tf_open to continue if no resource is allocated
  for some table type.
- Close the session if binding fails for any table.
- Close the session if no resource is allocated for all tables.

Signed-off-by: Jay Ding <jay.ding@broadcom.com>
Signed-off-by: Randy Schacher <stuart.schacher@broadcom.com>
Signed-off-by: Venkat Duvvuru <venkatkumar.duvvuru@broadcom.com>
Reviewed-by: Peter Spreadborough <peter.spreadborough@broadcom.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
drivers/net/bnxt/tf_core/tf_device.c
drivers/net/bnxt/tf_core/tf_session.c