rtl8195am - fix lwip_intf.c warnings

Fix the following warning:

[Warning] lwip_intf.c@134,5: this 'if' clause does not guard... [-Wmisleading-indentation]

Signed-off-by: Tony Wu <tonywu@realtek.com>
pull/6697/head
Tony Wu 2018-04-17 16:27:35 +08:00 committed by adbridge
parent 04a2e92d54
commit e87cc1fb34
1 changed files with 11 additions and 10 deletions

View File

@ -126,25 +126,26 @@ exit:
void rltk_wlan_recv(int idx, struct eth_drv_sg *sg_list, int sg_len) void rltk_wlan_recv(int idx, struct eth_drv_sg *sg_list, int sg_len)
{ {
#if (CONFIG_LWIP_LAYER == 1) #if (CONFIG_LWIP_LAYER == 1)
struct eth_drv_sg *last_sg; struct eth_drv_sg *last_sg;
struct sk_buff *skb; struct sk_buff *skb;
DBG_TRACE("%s is called", __FUNCTION__); DBG_TRACE("%s is called", __FUNCTION__);
if (!rltk_wlan_check_isup(idx)) if (!rltk_wlan_check_isup(idx)) {
return; return;
}
if(idx == -1){ if (idx == -1) {
DBG_ERR("skb is NULL"); DBG_ERR("skb is NULL");
return; return;
} }
skb = rltk_wlan_get_recv_skb(idx); skb = rltk_wlan_get_recv_skb(idx);
DBG_ASSERT(skb, "No pending rx skb"); DBG_ASSERT(skb, "No pending rx skb");
for (last_sg = &sg_list[sg_len]; sg_list < last_sg; ++sg_list) { for (last_sg = &sg_list[sg_len]; sg_list < last_sg; ++sg_list) {
if (sg_list->buf != 0) { if (sg_list->buf != 0) {
rtw_memcpy((void *)(sg_list->buf), skb->data, sg_list->len); rtw_memcpy((void *)(sg_list->buf), skb->data, sg_list->len);
skb_pull(skb, sg_list->len); skb_pull(skb, sg_list->len);
} }
} }