Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp314827pxf; Thu, 8 Apr 2021 03:49:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy+7oXLaPiluncy/rAkByb/FCbL5woxpvDrjPuMyIDqW2zU8NKHgGCqlzUkVIHvfouhAgQ+ X-Received: by 2002:a63:e19:: with SMTP id d25mr7539803pgl.24.1617878947145; Thu, 08 Apr 2021 03:49:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617878947; cv=none; d=google.com; s=arc-20160816; b=QZm0aH9U4aEWVDXTrs749ev53ph6CfQ/TCCWLF5lw9PwbT5t8F/XZhL2og+0GDQaOV mx2r15Oq7q6ZEEQLcr9SAtq8flkvy3jdybPOq5b1DDDm6z2dk3GXtqaMdQbocQg5U2N0 Sd9zZSbwNS9DTt7YSX27q+lClVhn3c6WsMe2mz1SN2RA58aVV4C5dibw5O4t22PaZm4I klvvNaCuTW8CnsiJntXgIr0+fFpwcWFbEVyRqIYGCZ8ggsZ+2NfikmCPq4TyMOXdIVfR oZW98/4C98hQkYGJY1Ba8OYBChL5zA/LwUNIHHLKaOfiR6lq6+nb9Jl8jm+hLAzeubb3 v4SA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=9nPhML4xfD/Ka6xawScfdsUmltKo/abu+AKymqxNUeA=; b=UjvRnJhfvhcYxVFtNj45uczjAjuf1kv0H+3+BbEhemdP1q+NKOwYOuFJFEfO56PjPz Ps7NIpD+/NbRk+Nu34IToY3d3S24mSvMFGnwX7XNgH5JuzL6S0KeyuVd61t0FsVdyTjP bA9G8kQQx1QfInAKMHt0WuC38iDbBiJCNmrNiO9ZKkCHqQqdyYpXDTSK+DtY0nQbbZiU vFU6wz2tUIZmO8x5ET9smtHecVdOqZ7GkOv+g+AWM0jnM5WqVvplP0dYtFQObyxA0BH5 cjE4OtaRqqgJajSb5l9xMn6qw76FfXjOmyOhITTHXJ4PXuddU5WZpSp9eIUjUEVC5j9Y m8hg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=EJdKpA+Q; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n20si9037081pjt.131.2021.04.08.03.48.54; Thu, 08 Apr 2021 03:49:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=EJdKpA+Q; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229921AbhDHKs1 (ORCPT + 99 others); Thu, 8 Apr 2021 06:48:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:50892 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229721AbhDHKsW (ORCPT ); Thu, 8 Apr 2021 06:48:22 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 99AC861130; Thu, 8 Apr 2021 10:48:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1617878891; bh=PLEqyjaoSZqxWZzmTtM4yUUjZCs5Y+H9HNoAmhQTFiI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=EJdKpA+QCLdUbMnCb83YjVkbIuXr8kScNBngpcWH3Nj79mI3J23MuUIFludXnOpU7 MmCTuWKP1PBLgGmP+afC60zBBlo1CtyRHAmSIY6rygbOja7GvsMs9QqI7u91MOjrGv U0T0ZmlUF9QQrtYqkpIXjHw5S1ijlWA2fdiv0k5E= Date: Thu, 8 Apr 2021 12:48:08 +0200 From: Greg KH To: Jiapeng Chong Cc: linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: [PATCH] staging: ks7010: remove useless variable Message-ID: References: <1617875479-58849-1-git-send-email-jiapeng.chong@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1617875479-58849-1-git-send-email-jiapeng.chong@linux.alibaba.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 08, 2021 at 05:51:19PM +0800, Jiapeng Chong wrote: > Fix the following gcc warning: > > drivers/staging/ks7010/ks_hostif.c:929:19: warning: variable ‘noise’ set > but not used [-Wunused-but-set-variable]. > > Reported-by: Abaci Robot > Signed-off-by: Jiapeng Chong > --- > drivers/staging/ks7010/ks_hostif.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/staging/ks7010/ks_hostif.c b/drivers/staging/ks7010/ks_hostif.c > index 8bc3b7d..499161d 100644 > --- a/drivers/staging/ks7010/ks_hostif.c > +++ b/drivers/staging/ks7010/ks_hostif.c > @@ -926,14 +926,13 @@ void hostif_bss_scan_confirm(struct ks_wlan_private *priv) > void hostif_phy_information_confirm(struct ks_wlan_private *priv) > { > struct iw_statistics *wstats = &priv->wstats; > - u8 rssi, signal, noise; > + u8 rssi, signal; > u8 link_speed; > u32 transmitted_frame_count, received_fragment_count; > u32 failed_count, fcs_error_count; > > rssi = get_byte(priv); > signal = get_byte(priv); > - noise = get_byte(priv); Are you sure you did not just break the functionality of the device here? thanks, greg k-h