Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933068AbdHVPbk (ORCPT ); Tue, 22 Aug 2017 11:31:40 -0400 Received: from mail-pf0-f195.google.com ([209.85.192.195]:37849 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932946AbdHVPbi (ORCPT ); Tue, 22 Aug 2017 11:31:38 -0400 From: Himanshu Jha To: gregkh@linuxfoundation.org Cc: linux-kernel@vger.kernel.org, Himanshu Jha Subject: [PATCH] drivers: staging: rtl8192e: make const qualified argument Date: Tue, 22 Aug 2017 21:01:02 +0530 Message-Id: <1503415862-16551-1-git-send-email-himanshujha199640@gmail.com> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1712 Lines: 41 The ether_addr_copy expects const u8* as its second argument, therefore pass const qualified argument instead of non-const argument. Signed-off-by: Himanshu Jha --- drivers/staging/rtl8192e/rtl819x_BAProc.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/staging/rtl8192e/rtl819x_BAProc.c b/drivers/staging/rtl8192e/rtl819x_BAProc.c index 1720e1b..f34a4ee 100644 --- a/drivers/staging/rtl8192e/rtl819x_BAProc.c +++ b/drivers/staging/rtl8192e/rtl819x_BAProc.c @@ -97,10 +97,9 @@ static struct sk_buff *rtllib_ADDBA(struct rtllib_device *ieee, u8 *Dst, BAReq = skb_put(skb, sizeof(struct rtllib_hdr_3addr)); - ether_addr_copy(BAReq->addr1, Dst); - ether_addr_copy(BAReq->addr2, ieee->dev->dev_addr); - - ether_addr_copy(BAReq->addr3, ieee->current_network.bssid); + ether_addr_copy(BAReq->addr1, (const u8 *)Dst); + ether_addr_copy(BAReq->addr2, (const u8 *)ieee->dev->dev_addr); + ether_addr_copy(BAReq->addr3, (const u8 *)ieee->current_network.bssid); BAReq->frame_ctl = cpu_to_le16(RTLLIB_STYPE_MANAGE_ACT); tag = skb_put(skb, 9); @@ -160,9 +159,9 @@ static struct sk_buff *rtllib_DELBA(struct rtllib_device *ieee, u8 *dst, Delba = skb_put(skb, sizeof(struct rtllib_hdr_3addr)); - ether_addr_copy(Delba->addr1, dst); - ether_addr_copy(Delba->addr2, ieee->dev->dev_addr); - ether_addr_copy(Delba->addr3, ieee->current_network.bssid); + ether_addr_copy(Delba->addr1, (const u8 *)dst); + ether_addr_copy(Delba->addr2, (const u8 *)ieee->dev->dev_addr); + ether_addr_copy(Delba->addr3, (const u8 *)ieee->current_network.bssid); Delba->frame_ctl = cpu_to_le16(RTLLIB_STYPE_MANAGE_ACT); tag = skb_put(skb, 6); -- 2.7.4