net: systemport: Remove need for DMA descriptor
All we do is write the length/status and address bits to a DMA descriptor only to write its contents into on-chip registers right after, eliminate this unnecessary step. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
697cd36cda
commit
7e6e185c74
@@ -516,12 +516,6 @@ struct bcm_rsb {
|
||||
|
||||
#define TDMA_DEBUG 0x64c
|
||||
|
||||
/* Transmit/Receive descriptor */
|
||||
struct dma_desc {
|
||||
u32 addr_status_len;
|
||||
u32 addr_lo;
|
||||
};
|
||||
|
||||
/* Number of Receive hardware descriptor words */
|
||||
#define SP_NUM_HW_RX_DESC_WORDS 1024
|
||||
#define SP_LT_NUM_HW_RX_DESC_WORDS 256
|
||||
@@ -530,7 +524,7 @@ struct dma_desc {
|
||||
#define SP_NUM_TX_DESC 1536
|
||||
#define SP_LT_NUM_TX_DESC 256
|
||||
|
||||
#define WORDS_PER_DESC (sizeof(struct dma_desc) / sizeof(u32))
|
||||
#define WORDS_PER_DESC 2
|
||||
|
||||
/* Rx/Tx common counter group.*/
|
||||
struct bcm_sysport_pkt_counters {
|
||||
@@ -718,7 +712,6 @@ struct bcm_sysport_net_dim {
|
||||
struct bcm_sysport_tx_ring {
|
||||
spinlock_t lock; /* Ring lock for tx reclaim/xmit */
|
||||
struct napi_struct napi; /* NAPI per tx queue */
|
||||
dma_addr_t desc_dma; /* DMA cookie */
|
||||
unsigned int index; /* Ring index */
|
||||
unsigned int size; /* Ring current size */
|
||||
unsigned int alloc_size; /* Ring one-time allocated size */
|
||||
@@ -727,7 +720,6 @@ struct bcm_sysport_tx_ring {
|
||||
unsigned int c_index; /* Last consumer index */
|
||||
unsigned int clean_index; /* Current clean index */
|
||||
struct bcm_sysport_cb *cbs; /* Transmit control blocks */
|
||||
struct dma_desc *desc_cpu; /* CPU view of the descriptor */
|
||||
struct bcm_sysport_priv *priv; /* private context backpointer */
|
||||
unsigned long packets; /* packets statistics */
|
||||
unsigned long bytes; /* bytes statistics */
|
||||
|
||||
Reference in New Issue
Block a user