Received: by 10.213.65.16 with SMTP id m16csp255011imf; Mon, 12 Mar 2018 02:39:23 -0700 (PDT) X-Google-Smtp-Source: AG47ELto4FtAzDkfm15XgF1Msts7SBgn7maFlLxVX680yU24kCOy/JXuaMY5CyHx2rcx8/wLG03m X-Received: by 10.99.159.10 with SMTP id g10mr6036225pge.407.1520847563195; Mon, 12 Mar 2018 02:39:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1520847563; cv=none; d=google.com; s=arc-20160816; b=GFPedLQdFL3JAgxf/WJkzU6oicm2qpfivdJvC+kmaqmDZ6UHiZVpRum52IquB6aWhW ZFZQJ/bFVH+JkQ17Wblv0Uht8xrXMzmVrPslVM6UmaWncaPsYCEtaGdfLvkwtU7hHS4e x+iTilHS4YRuE4fGudlS/qvXbkaahDdYJfOaNTAlPWA4eH4aPjUzzxXMp0OrS8S3VrYT GJ3+0LGgiqIRtQHPVDqySAXs1iWhTbU9eh0fYIggRYnABCsfrm8VRWVLENGsNDsCzU5X eITUfVyAA0KQDeIo5Ng76n98+A/qERLtUiYz+cuWZgv53Ywd2abdyuIhUvWAXVLqqzcS TEkg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:date:from:dkim-signature:arc-authentication-results; bh=JNZzN0kofAgDdkea5wxf0IMsGp63jdb/iHjBx/aWmB8=; b=ZuudqbkwjWLfX0ETb0J257cuD/X7Ji2QX1dJ9Jy7WkahHALsS2/rh7JAbB/18L6IZi bGS6/JtfsFJCxDuaR5O+f1DtY4YAGTg2a+RhygmkIiDTaADN9r+7fkxZXVRUhAlEqPeE tSTiifOWGriEK1KWP5AE6Wl+t/U3jM4KCjPN/62+fiDQFQGp51DSufvLHjNU0sxn3Oqs VWlRQoF/23knmFl1grUnDz6xYr/+sN/YS0R8cWxvddrtjlayI/RclnpPMJa9OscAZyrs LIaESFgEE9BLT52+IGeDpw8H/7jHLVn1hCZ7gnA3lZfyv8ssuIvugpYydoCoN5NXbFF0 9RrQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=PAcIhZ/l; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m13si4795996pgd.641.2018.03.12.02.39.08; Mon, 12 Mar 2018 02:39:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=PAcIhZ/l; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932217AbeCLJiV (ORCPT + 99 others); Mon, 12 Mar 2018 05:38:21 -0400 Received: from mail-io0-f193.google.com ([209.85.223.193]:42221 "EHLO mail-io0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750752AbeCLJiT (ORCPT ); Mon, 12 Mar 2018 05:38:19 -0400 Received: by mail-io0-f193.google.com with SMTP id u84so10641656iod.9; Mon, 12 Mar 2018 02:38:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:date:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=JNZzN0kofAgDdkea5wxf0IMsGp63jdb/iHjBx/aWmB8=; b=PAcIhZ/lirDG6XMJd8sC03M9mfGAnLOCKbIGHeuYgpnZJP0IBb2MQbJdKUEMmXCVCz thzp7s+ZPtb4ayfJsZ/anb4y/39/twVlhAbZWqcrKGTY+BacTlRkvHBaVtCz+zDRobh7 gNpk4gW6/i0zIS3GYkfEsaN9SakJ7grVa6PV90J9H2qxXdheJKN7aXnrxe8qVx5krYvj 4DZ6Cl503kQwBXRr3qih1HZMvpkP7gwJEY89xx9NR9JSIgnrhpQvcBj38CvI/zwZm8Do mZ0YzWOAX/cnjKIJxwgV7d8ZtvaHy1mIPvIkpMN6gy7ZlKa9CclaZJFrqmConVZD3dRC Ub5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:date:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=JNZzN0kofAgDdkea5wxf0IMsGp63jdb/iHjBx/aWmB8=; b=KY9bG9cUdfDcOLK9vUPa1CIV8rfmnBsI7ZuupTNrcZag3N0ictbyGq8AUuSSrZmAi2 eQbsze6CvyH1bMlJ6453UAB5sBDAoRUGquQ5N9MCO9gycpzkegqJYRgd60Qh4mWfrEF5 1pI1giSWU0cApo+zD/QZEeySQFhqjeCXP4RzN3SxGzcaWE6AotC3Z0DSd+/6zB1jbY6i fZpJmXk/P4XlKbPtLonhhWTZ5GgiYNltw7uCHOMLVUbXPotglv8he5JF7/D/Rpbn7Txp vvqcvVAS37Sb8SaNwNyJTqH1NNsugvuYGiulIyxIucxOa3ejOzwIdVLR+xZwD509/18N p3Tg== X-Gm-Message-State: AElRT7HBkdht0wl6Lcdkb75uj90NtJwDfLFhnCeG6+052Xoemg/1JE8R KlxX/+IisvF/0+cS4+r8WqI= X-Received: by 10.107.25.77 with SMTP id 74mr8524032ioz.33.1520847499050; Mon, 12 Mar 2018 02:38:19 -0700 (PDT) Received: from hariprasath ([2405:204:714d:efc4:a583:666e:901d:538]) by smtp.gmail.com with ESMTPSA id u68sm4821152iou.0.2018.03.12.02.38.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 12 Mar 2018 02:38:17 -0700 (PDT) From: "" X-Google-Original-From: "" Date: Mon, 12 Mar 2018 15:08:08 +0530 To: hariprasath.elango@gmail.com Cc: aditya.shankar@microchip.com, vbabu3@visteon.com, Hari Prasath , Ganesh Krishna , Greg Kroah-Hartman , linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] staging: wilc1000: use pre-defined macro is_broadcast_ether_addr Message-ID: <20180312093808.GA9044@hariprasath> References: <20180312084715.30103-1-hariprasath.elango@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180312084715.30103-1-hariprasath.elango@gmail.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 12, 2018 at 02:17:15PM +0530, hariprasath.elango@gmail.com wrote: > From: Hari Prasath > > Use the kernel pre-defined macro is_broadcast_ether_addr() instead of > doing a memcmp here. > > Signed-off-by: Hari Prasath > --- > drivers/staging/wilc1000/linux_mon.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/staging/wilc1000/linux_mon.c b/drivers/staging/wilc1000/linux_mon.c > index bbdfc7a..f93f411 100644 > --- a/drivers/staging/wilc1000/linux_mon.c > +++ b/drivers/staging/wilc1000/linux_mon.c > @@ -27,7 +27,6 @@ static struct net_device *wilc_wfi_mon; /* global monitor netdev */ > > static u8 srcadd[6]; > static u8 bssid[6]; > -static u8 broadcast[] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; > /** > * @brief WILC_WFI_monitor_rx > * @details > @@ -193,7 +192,7 @@ static netdev_tx_t WILC_WFI_mon_xmit(struct sk_buff *skb, > > skb_pull(skb, rtap_len); > > - if (skb->data[0] == 0xc0 && (!(memcmp(broadcast, &skb->data[4], 6)))) { > + if (skb->data[0] == 0xc0 && is_broadcast_ether_addr(&skb->data[4])) { > skb2 = dev_alloc_skb(skb->len + sizeof(struct wilc_wfi_radiotap_cb_hdr)); > if (!skb2) > return -ENOMEM; > -- > 2.10.0.GIT > Kindly discard this patch. I will send a v2 as sent mail ID and signed-off are not matching