Commit 257bbf45 authored by Michael Chan's avatar Michael Chan Committed by Paolo Abeni

bnxt_en: Refactor ring reservation functions

The current functions to reserve hardware rings pass in 6 different ring
or resource types as parameters.  Add a structure bnxt_hw_rings to
consolidate all these parameters and pass the structure pointer instead
to these functions.  Add 2 related helper functions also.  This makes
the code cleaner and makes it easier to add new resources to be
reserved.
Reviewed-by: default avatarAjit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: default avatarPavan Chebbi <pavan.chebbi@broadcom.com>
Signed-off-by: default avatarMichael Chan <michael.chan@broadcom.com>
Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
parent e7b83f2f
This diff is collapsed.
......@@ -1254,6 +1254,15 @@ struct bnxt_vnic_info {
#define BNXT_VNIC_RFS_NEW_RSS_FLAG 0x10
};
struct bnxt_hw_rings {
int tx;
int rx;
int grp;
int cp;
int stat;
int vnic;
};
struct bnxt_hw_resc {
u16 min_rsscos_ctxs;
u16 max_rsscos_ctxs;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment