ionic: remove the cq_info to save more memory
authorShannon Nelson <shannon.nelson@amd.com>
Wed, 6 Mar 2024 23:29:50 +0000 (15:29 -0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 8 Mar 2024 11:54:34 +0000 (11:54 +0000)
commit65e548f6b0ffc4222a99feda8a033a2a9fb9f3e7
tree64d64b48e377494e254c8cddcc5b0664c8e96dc9
parentae24a8f88b3fc8ef463e8dffd41ebba48c81cfd4
ionic: remove the cq_info to save more memory

With a little simple math we don't need another struct array to
find the completion structs, so we can remove the ionic_cq_info
altogether.  This doesn't really save anything in the ionic_cq
since it gets padded out to the cacheline, but it does remove
the parallel array allocation of 8 * num_descriptors, or about
8 Kbytes per queue in a default configuration.

Suggested-by: Neel Patel <npatel2@amd.com>
Reviewed-by: Brett Creeley <brett.creeley@amd.com>
Signed-off-by: Shannon Nelson <shannon.nelson@amd.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/pensando/ionic/ionic.h
drivers/net/ethernet/pensando/ionic/ionic_dev.c
drivers/net/ethernet/pensando/ionic/ionic_dev.h
drivers/net/ethernet/pensando/ionic/ionic_lif.c
drivers/net/ethernet/pensando/ionic/ionic_main.c
drivers/net/ethernet/pensando/ionic/ionic_txrx.c
drivers/net/ethernet/pensando/ionic/ionic_txrx.h