staging: vt6655: replaced typedef struct tagTDES1
Create struct vnt_tdes1 that replaces members wReqCount -> req_count byTCR -> tcr byReserved -> reserved Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
5235ff6a1d
commit
9cc8eac99c
@ -234,12 +234,11 @@ struct vnt_tdes0 {
|
|||||||
#endif
|
#endif
|
||||||
} __packed;
|
} __packed;
|
||||||
|
|
||||||
typedef struct tagTDES1 {
|
struct vnt_tdes1 {
|
||||||
volatile __le16 wReqCount;
|
volatile __le16 req_count;
|
||||||
volatile unsigned char byTCR;
|
volatile u8 tcr;
|
||||||
volatile unsigned char byReserved;
|
volatile u8 reserved;
|
||||||
} __attribute__ ((__packed__))
|
} __packed;
|
||||||
STDES1;
|
|
||||||
|
|
||||||
typedef struct tagDEVICE_TD_INFO {
|
typedef struct tagDEVICE_TD_INFO {
|
||||||
void *mic_hdr;
|
void *mic_hdr;
|
||||||
@ -254,7 +253,7 @@ typedef struct tagDEVICE_TD_INFO {
|
|||||||
/* transmit descriptor */
|
/* transmit descriptor */
|
||||||
typedef struct tagSTxDesc {
|
typedef struct tagSTxDesc {
|
||||||
volatile struct vnt_tdes0 td0;
|
volatile struct vnt_tdes0 td0;
|
||||||
volatile STDES1 m_td1TD1;
|
volatile struct vnt_tdes1 td1;
|
||||||
volatile __le32 buff_addr;
|
volatile __le32 buff_addr;
|
||||||
volatile __le32 next_desc;
|
volatile __le32 next_desc;
|
||||||
struct tagSTxDesc *next __aligned(8);
|
struct tagSTxDesc *next __aligned(8);
|
||||||
|
@ -915,7 +915,7 @@ static int device_tx_srv(struct vnt_private *pDevice, unsigned int uIdx)
|
|||||||
byTsr1 = pTD->td0.tsr1;
|
byTsr1 = pTD->td0.tsr1;
|
||||||
|
|
||||||
/* Only the status of first TD in the chain is correct */
|
/* Only the status of first TD in the chain is correct */
|
||||||
if (pTD->m_td1TD1.byTCR & TCR_STP) {
|
if (pTD->td1.tcr & TCR_STP) {
|
||||||
if ((pTD->pTDInfo->byFlags & TD_FLAGS_NETIF_SKB) != 0) {
|
if ((pTD->pTDInfo->byFlags & TD_FLAGS_NETIF_SKB) != 0) {
|
||||||
if (!(byTsr1 & TSR1_TERR)) {
|
if (!(byTsr1 & TSR1_TERR)) {
|
||||||
if (byTsr0 != 0) {
|
if (byTsr0 != 0) {
|
||||||
@ -1174,7 +1174,7 @@ static int vnt_tx_packet(struct vnt_private *priv, struct sk_buff *skb)
|
|||||||
|
|
||||||
head_td = priv->apCurrTD[dma_idx];
|
head_td = priv->apCurrTD[dma_idx];
|
||||||
|
|
||||||
head_td->m_td1TD1.byTCR = 0;
|
head_td->td1.tcr = 0;
|
||||||
|
|
||||||
head_td->pTDInfo->skb = skb;
|
head_td->pTDInfo->skb = skb;
|
||||||
|
|
||||||
@ -1192,9 +1192,8 @@ static int vnt_tx_packet(struct vnt_private *priv, struct sk_buff *skb)
|
|||||||
priv->bPWBitOn = false;
|
priv->bPWBitOn = false;
|
||||||
|
|
||||||
/* Set TSR1 & ReqCount in TxDescHead */
|
/* Set TSR1 & ReqCount in TxDescHead */
|
||||||
head_td->m_td1TD1.byTCR |= (TCR_STP | TCR_EDP | EDMSDU);
|
head_td->td1.tcr |= (TCR_STP | TCR_EDP | EDMSDU);
|
||||||
head_td->m_td1TD1.wReqCount =
|
head_td->td1.req_count = cpu_to_le16((u16)head_td->pTDInfo->dwReqCount);
|
||||||
cpu_to_le16((u16)head_td->pTDInfo->dwReqCount);
|
|
||||||
|
|
||||||
head_td->buff_addr = cpu_to_le32(head_td->pTDInfo->buf_dma);
|
head_td->buff_addr = cpu_to_le32(head_td->pTDInfo->buf_dma);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user