提交 5cadafb2 编写于 作者: B Bart Van Assche 提交者: Nicholas Bellinger

target/cxgbit: Fix endianness annotations

This patch does not change any functionality but avoids that sparse
complains about endianness.
Signed-off-by: NBart Van Assche <bart.vanassche@sandisk.com>
Acked-by: NVarun Prakash <varun@chelsio.com>
Signed-off-by: NNicholas Bellinger <nab@linux-iscsi.org>
上级 2fdbc65e
......@@ -59,7 +59,7 @@ struct cxgbi_pagepod_hdr {
#define PPOD_PAGES_MAX 4
struct cxgbi_pagepod {
struct cxgbi_pagepod_hdr hdr;
u64 addr[PPOD_PAGES_MAX + 1];
__be64 addr[PPOD_PAGES_MAX + 1];
};
/* ddp tag format
......
......@@ -1726,7 +1726,7 @@ static bool cxgbit_credit_err(const struct cxgbit_sock *csk)
}
while (skb) {
credit += skb->csum;
credit += (__force u32)skb->csum;
skb = cxgbit_skcb_tx_wr_next(skb);
}
......@@ -1753,6 +1753,7 @@ static void cxgbit_fw4_ack(struct cxgbit_sock *csk, struct sk_buff *skb)
while (credits) {
struct sk_buff *p = cxgbit_sock_peek_wr(csk);
const u32 csum = (__force u32)p->csum;
if (unlikely(!p)) {
pr_err("csk 0x%p,%u, cr %u,%u+%u, empty.\n",
......@@ -1761,17 +1762,17 @@ static void cxgbit_fw4_ack(struct cxgbit_sock *csk, struct sk_buff *skb)
break;
}
if (unlikely(credits < p->csum)) {
if (unlikely(credits < csum)) {
pr_warn("csk 0x%p,%u, cr %u,%u+%u, < %u.\n",
csk, csk->tid,
credits, csk->wr_cred, csk->wr_una_cred,
p->csum);
p->csum -= credits;
csum);
p->csum = (__force __wsum)(csum - credits);
break;
}
cxgbit_sock_dequeue_wr(csk);
credits -= p->csum;
credits -= csum;
kfree_skb(p);
}
......
......@@ -454,7 +454,7 @@ cxgbit_uld_lro_rx_handler(void *hndl, const __be64 *rsp,
if (unlikely(op != *(u8 *)gl->va)) {
pr_info("? FL 0x%p,RSS%#llx,FL %#llx,len %u.\n",
gl->va, be64_to_cpu(*rsp),
be64_to_cpu(*(u64 *)gl->va),
get_unaligned_be64(gl->va),
gl->tot_len);
return 0;
}
......
......@@ -243,7 +243,7 @@ void cxgbit_push_tx_frames(struct cxgbit_sock *csk)
}
__skb_unlink(skb, &csk->txq);
set_wr_txq(skb, CPL_PRIORITY_DATA, csk->txq_idx);
skb->csum = credits_needed + flowclen16;
skb->csum = (__force __wsum)(credits_needed + flowclen16);
csk->wr_cred -= credits_needed;
csk->wr_una_cred += credits_needed;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册