Commit 78f73d92 authored by Daniil Leshchev's avatar Daniil Leshchev Committed by Greg Kroah-Hartman

staging: rtl8723au: use %pM and %ph formatting

use %pM and %ph specifiers instead of placing each byte on stack.
(staging/rtl8723au/TODO)
Signed-off-by: default avatarDaniil Leshchev <meleodr@gmail.com>
Acked-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 485b099a
......@@ -361,33 +361,19 @@ int recvframe_chkmic(struct rtw_adapter *adapter,
int i;
RT_TRACE(_module_rtl871x_recv_c_, _drv_err_,
"*(pframemic-8)-*(pframemic-1) =0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x\n",
*(pframemic - 8), *(pframemic - 7),
*(pframemic - 6), *(pframemic - 5),
*(pframemic - 4), *(pframemic - 3),
*(pframemic - 2), *(pframemic - 1));
"*(pframemic-8)-*(pframemic-1) =%*phC\n",
8, pframemic - 8);
RT_TRACE(_module_rtl871x_recv_c_, _drv_err_,
"*(pframemic-16)-*(pframemic-9) =0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x\n",
*(pframemic - 16), *(pframemic - 15),
*(pframemic - 14), *(pframemic - 13),
*(pframemic - 12), *(pframemic - 11),
*(pframemic - 10), *(pframemic - 9));
"*(pframemic-16)-*(pframemic-9) =%*phC\n",
8, pframemic - 16);
RT_TRACE(_module_rtl871x_recv_c_, _drv_err_,
"====== demp packet (len =%d) ======\n",
precvframe->pkt->len);
for (i = 0; i < precvframe->pkt->len; i = i + 8) {
RT_TRACE(_module_rtl871x_recv_c_,
_drv_err_,
"0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x:0x%02x\n",
*(precvframe->pkt->data+i),
*(precvframe->pkt->data+i+1),
*(precvframe->pkt->data+i+2),
*(precvframe->pkt->data+i+3),
*(precvframe->pkt->data+i+4),
*(precvframe->pkt->data+i+5),
*(precvframe->pkt->data+i+6),
*(precvframe->pkt->data+i+7));
_drv_err_, "%*phC\n",
8, precvframe->pkt->data + i);
}
RT_TRACE(_module_rtl871x_recv_c_, _drv_err_,
"====== demp packet end [len =%d]======\n",
......@@ -1402,11 +1388,7 @@ static void dump_rx_pkt(struct sk_buff *skb, u16 type, int level)
DBG_8723A("#############################\n");
for (i = 0; i < 64; i = i + 8)
DBG_8723A("%02X:%02X:%02X:%02X:%02X:%02X:%02X:%02X:\n",
*(ptr + i), *(ptr + i + 1), *(ptr + i + 2),
*(ptr + i + 3), *(ptr + i + 4),
*(ptr + i + 5), *(ptr + i + 6),
*(ptr + i + 7));
DBG_8723A("%*phC:\n", 8, ptr + i);
DBG_8723A("#############################\n");
}
}
......
......@@ -1454,21 +1454,11 @@ bthci_StartBeaconAndConnect(
}
if (pBTInfo->BtAsocEntry[CurrentAssocNum].AMPRole == AMP_BTAP_CREATOR) {
snprintf((char *)pBTInfo->BtAsocEntry[CurrentAssocNum].BTSsidBuf, 32, "AMP-%02x-%02x-%02x-%02x-%02x-%02x",
padapter->eeprompriv.mac_addr[0],
padapter->eeprompriv.mac_addr[1],
padapter->eeprompriv.mac_addr[2],
padapter->eeprompriv.mac_addr[3],
padapter->eeprompriv.mac_addr[4],
padapter->eeprompriv.mac_addr[5]);
snprintf((char *)pBTInfo->BtAsocEntry[CurrentAssocNum].BTSsidBuf, 32,
"AMP-%pMF", padapter->eeprompriv.mac_addr);
} else if (pBTInfo->BtAsocEntry[CurrentAssocNum].AMPRole == AMP_BTAP_JOINER) {
snprintf((char *)pBTInfo->BtAsocEntry[CurrentAssocNum].BTSsidBuf, 32, "AMP-%02x-%02x-%02x-%02x-%02x-%02x",
pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr[0],
pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr[1],
pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr[2],
pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr[3],
pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr[4],
pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr[5]);
snprintf((char *)pBTInfo->BtAsocEntry[CurrentAssocNum].BTSsidBuf, 32,
"AMP-%pMF", pBTInfo->BtAsocEntry[CurrentAssocNum].BTRemoteMACAddr);
}
FillOctetString(pBTInfo->BtAsocEntry[CurrentAssocNum].BTSsid, pBTInfo->BtAsocEntry[CurrentAssocNum].BTSsidBuf, 21);
......@@ -9475,10 +9465,8 @@ static void BTDM_Display8723ABtCoexInfo(struct rtw_adapter *padapter)
psTdmaCase = pHalData->bt_coexist.halCoex8723.btdm1Ant.curPsTdma;
else
psTdmaCase = pHalData->bt_coexist.halCoex8723.btdm2Ant.curPsTdma;
snprintf(btCoexDbgBuf, BT_TMP_BUF_SIZE, "\r\n %-35s = %02x %02x %02x %02x %02x case-%d", "PS TDMA(0x3a)", \
pHalData->bt_coexist.fw3aVal[0], pHalData->bt_coexist.fw3aVal[1],
pHalData->bt_coexist.fw3aVal[2], pHalData->bt_coexist.fw3aVal[3],
pHalData->bt_coexist.fw3aVal[4], psTdmaCase);
snprintf(btCoexDbgBuf, BT_TMP_BUF_SIZE, "\r\n %-35s = %*ph case-%d",
"PS TDMA(0x3a)", 5, pHalData->bt_coexist.fw3aVal, psTdmaCase);
DCMD_Printf(btCoexDbgBuf);
snprintf(btCoexDbgBuf, BT_TMP_BUF_SIZE, "\r\n %-35s = %d ", "Decrease Bt Power", \
......
......@@ -1021,10 +1021,8 @@ static void Hal_EfuseParseMACAddr_8723AU(struct rtw_adapter *padapter,
}
RT_TRACE(_module_hci_hal_init_c_, _drv_notice_,
"Hal_EfuseParseMACAddr_8723AU: Permanent Address =%02x:%02x:%02x:%02x:%02x:%02x\n",
pEEPROM->mac_addr[0], pEEPROM->mac_addr[1],
pEEPROM->mac_addr[2], pEEPROM->mac_addr[3],
pEEPROM->mac_addr[4], pEEPROM->mac_addr[5]);
"Hal_EfuseParseMACAddr_8723AU: Permanent Address =%pM\n",
pEEPROM->mac_addr);
}
static void readAdapterInfo(struct rtw_adapter *padapter)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment