From 0c1d175b72e347cfb44d9ca5171e0e0423306729 Mon Sep 17 00:00:00 2001 From: Shannon Nelson Date: Tue, 1 Sep 2020 11:20:20 -0700 Subject: ionic: struct reorder for faster access Move a few active struct fields to the front of the struct for a little better cache use and performance. Signed-off-by: Shannon Nelson Signed-off-by: David S. Miller --- drivers/net/ethernet/pensando/ionic/ionic_dev.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'drivers/net/ethernet/pensando/ionic/ionic_dev.h') diff --git a/drivers/net/ethernet/pensando/ionic/ionic_dev.h b/drivers/net/ethernet/pensando/ionic/ionic_dev.h index 9e2ac2b8a082..0641ca2e1780 100644 --- a/drivers/net/ethernet/pensando/ionic/ionic_dev.h +++ b/drivers/net/ethernet/pensando/ionic/ionic_dev.h @@ -199,16 +199,17 @@ struct ionic_desc_info { struct ionic_queue { struct device *dev; - u64 dbell_count; - u64 drop; - u64 stop; - u64 wake; struct ionic_lif *lif; struct ionic_desc_info *info; - struct ionic_dev *idev; u16 head_idx; u16 tail_idx; unsigned int index; + unsigned int num_descs; + u64 dbell_count; + u64 stop; + u64 wake; + u64 drop; + struct ionic_dev *idev; unsigned int type; unsigned int hw_index; unsigned int hw_type; @@ -226,7 +227,6 @@ struct ionic_queue { }; dma_addr_t base_pa; dma_addr_t sg_base_pa; - unsigned int num_descs; unsigned int desc_size; unsigned int sg_desc_size; unsigned int pid; @@ -246,8 +246,6 @@ struct ionic_intr_info { }; struct ionic_cq { - void *base; - dma_addr_t base_pa; struct ionic_lif *lif; struct ionic_cq_info *info; struct ionic_queue *bound_q; @@ -255,8 +253,10 @@ struct ionic_cq { u16 tail_idx; bool done_color; unsigned int num_descs; - u64 compl_count; unsigned int desc_size; + u64 compl_count; + void *base; + dma_addr_t base_pa; }; struct ionic; -- cgit v1.2.3-59-g8ed1b