From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.4 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7883CC35280 for ; Wed, 2 Oct 2019 13:29:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 48C6B21A4A for ; Wed, 2 Oct 2019 13:29:59 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="c+Mg75kV" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727861AbfJBN36 (ORCPT ); Wed, 2 Oct 2019 09:29:58 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:33810 "EHLO userp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725917AbfJBN36 (ORCPT ); Wed, 2 Oct 2019 09:29:58 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x92DSx1F037156; Wed, 2 Oct 2019 13:29:44 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2019-08-05; bh=EM3e9nI3amV6xVGJaxjxz45i18U04uaHvQ94gCdzIIs=; b=c+Mg75kVq8y09t0ZUPlttkci0ZJew3k1BY8yYl6R2HwYdCKfYoLmY9l1reOE9bz5Iwmk 9qHxc3IYdyJXJOQi9GLggW1mULgFeIwMYInD1cpLYUS+HlyIe7FAIIYhRLErr8hiGs4h z3Apaqb/sayWPcMzdwAClBeDI6QlANcXRInSK2MIWsDctDHdekyY2ZiosW9Yp9A1akI0 QhwsYMEdxpau7JeQqxYWsKyeigNoYCHv/u18pjMFZJaXxa95L+W4a1M9c4fOBD4WG8IS JCXENDAt3XgmB3iA7+dTaeup3n+lvZUdsYHnNOiRjItp0Kbp3YNVSIvdH2qkMrzSlgSf lQ== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by userp2120.oracle.com with ESMTP id 2va05rvuf9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 02 Oct 2019 13:29:44 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x92DSlsc098366; Wed, 2 Oct 2019 13:29:44 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserp3020.oracle.com with ESMTP id 2vckynx97t-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 02 Oct 2019 13:29:43 +0000 Received: from abhmp0006.oracle.com (abhmp0006.oracle.com [141.146.116.12]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x92DThq4028591; Wed, 2 Oct 2019 13:29:43 GMT Received: from kadam (/41.57.98.10) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 02 Oct 2019 06:29:42 -0700 Date: Wed, 2 Oct 2019 16:29:33 +0300 From: Dan Carpenter To: Colin King Cc: Thierry Reding , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , Maxime Ripard , Chen-Yu Tsai , linux-pwm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] pwm: sun4i: redundant assignment to variable pval Message-ID: <20191002132933.GO29696@kadam> References: <20191002100844.10490-1-colin.king@canonical.com> <20191002132506.GO22609@kadam> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191002132506.GO22609@kadam> User-Agent: Mutt/1.9.4 (2018-02-28) X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9397 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910020129 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9397 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910020129 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 02, 2019 at 04:25:06PM +0300, Dan Carpenter wrote: > On Wed, Oct 02, 2019 at 11:08:44AM +0100, Colin King wrote: > > From: Colin Ian King > > > > Variable pval is being assigned a value that is never read. The > > assignment is redundant and hence can be removed. > > > > Addresses-Coverity: ("Unused value") > > Signed-off-by: Colin Ian King > > --- > > drivers/pwm/pwm-sun4i.c | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/drivers/pwm/pwm-sun4i.c b/drivers/pwm/pwm-sun4i.c > > index 6f5840a1a82d..53970d4ba695 100644 > > --- a/drivers/pwm/pwm-sun4i.c > > +++ b/drivers/pwm/pwm-sun4i.c > > @@ -156,7 +156,6 @@ static int sun4i_pwm_calculate(struct sun4i_pwm_chip *sun4i_pwm, > > if (sun4i_pwm->data->has_prescaler_bypass) { > > /* First, test without any prescaler when available */ > > prescaler = PWM_PRESCAL_MASK; > > - pval = 1; > > /* > > * When not using any prescaler, the clock period in nanoseconds > > * is not an integer so round it half up instead of > > Are you sure? It looks used to me. Ah. Never mind. My tree was out of date. regards, dan carpenter From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Carpenter Date: Wed, 02 Oct 2019 13:29:33 +0000 Subject: Re: [PATCH] pwm: sun4i: redundant assignment to variable pval Message-Id: <20191002132933.GO29696@kadam> List-Id: References: <20191002100844.10490-1-colin.king@canonical.com> <20191002132506.GO22609@kadam> In-Reply-To: <20191002132506.GO22609@kadam> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Colin King Cc: linux-pwm@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org, Maxime Ripard , Chen-Yu Tsai , Thierry Reding , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , linux-arm-kernel@lists.infradead.org On Wed, Oct 02, 2019 at 04:25:06PM +0300, Dan Carpenter wrote: > On Wed, Oct 02, 2019 at 11:08:44AM +0100, Colin King wrote: > > From: Colin Ian King > > > > Variable pval is being assigned a value that is never read. The > > assignment is redundant and hence can be removed. > > > > Addresses-Coverity: ("Unused value") > > Signed-off-by: Colin Ian King > > --- > > drivers/pwm/pwm-sun4i.c | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/drivers/pwm/pwm-sun4i.c b/drivers/pwm/pwm-sun4i.c > > index 6f5840a1a82d..53970d4ba695 100644 > > --- a/drivers/pwm/pwm-sun4i.c > > +++ b/drivers/pwm/pwm-sun4i.c > > @@ -156,7 +156,6 @@ static int sun4i_pwm_calculate(struct sun4i_pwm_chip *sun4i_pwm, > > if (sun4i_pwm->data->has_prescaler_bypass) { > > /* First, test without any prescaler when available */ > > prescaler = PWM_PRESCAL_MASK; > > - pval = 1; > > /* > > * When not using any prescaler, the clock period in nanoseconds > > * is not an integer so round it half up instead of > > Are you sure? It looks used to me. Ah. Never mind. My tree was out of date. regards, dan carpenter From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Carpenter Subject: Re: [PATCH] pwm: sun4i: redundant assignment to variable pval Date: Wed, 2 Oct 2019 16:29:33 +0300 Message-ID: <20191002132933.GO29696@kadam> References: <20191002100844.10490-1-colin.king@canonical.com> <20191002132506.GO22609@kadam> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <20191002132506.GO22609@kadam> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=m.gmane.org@lists.infradead.org To: Colin King Cc: linux-pwm@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org, Maxime Ripard , Chen-Yu Tsai , Thierry Reding , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , linux-arm-kernel@lists.infradead.org List-Id: linux-pwm@vger.kernel.org On Wed, Oct 02, 2019 at 04:25:06PM +0300, Dan Carpenter wrote: > On Wed, Oct 02, 2019 at 11:08:44AM +0100, Colin King wrote: > > From: Colin Ian King > > > > Variable pval is being assigned a value that is never read. The > > assignment is redundant and hence can be removed. > > > > Addresses-Coverity: ("Unused value") > > Signed-off-by: Colin Ian King > > --- > > drivers/pwm/pwm-sun4i.c | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/drivers/pwm/pwm-sun4i.c b/drivers/pwm/pwm-sun4i.c > > index 6f5840a1a82d..53970d4ba695 100644 > > --- a/drivers/pwm/pwm-sun4i.c > > +++ b/drivers/pwm/pwm-sun4i.c > > @@ -156,7 +156,6 @@ static int sun4i_pwm_calculate(struct sun4i_pwm_chip *sun4i_pwm, > > if (sun4i_pwm->data->has_prescaler_bypass) { > > /* First, test without any prescaler when available */ > > prescaler = PWM_PRESCAL_MASK; > > - pval = 1; > > /* > > * When not using any prescaler, the clock period in nanoseconds > > * is not an integer so round it half up instead of > > Are you sure? It looks used to me. Ah. Never mind. My tree was out of date. regards, dan carpenter From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.3 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 180B8C352AA for ; Wed, 2 Oct 2019 13:30:01 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D26D421783 for ; Wed, 2 Oct 2019 13:30:00 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="FNQJ/OLe"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="c+Mg75kV" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D26D421783 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=oracle.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=GD7YAKxmJpAZ/YHndNTHq7cc1era9VLqPLgJtRgOijI=; b=FNQJ/OLeBVgORN mR0H3bDdVwmiFvr7KFGIJdVkF/YR6j9vtGeOaIEWAOOoI6Ey/WGp0jMpPf8Fni15JzfPe9h3BnHEE CHan61fM+8l0BsKH4fwSc/sE3pePUw6ZEa6fxrr+0PPiFiGAD4M2AD0NMAsD30vL39KFcczgkEBt0 KhGyU4Q0Tw1qwAku0pS6PSSMN4S9090UPYp3EUpDWC4GO90oH1g5wGqVbvmoJnphCQ4uYI1m5emVu QJDQOnwImAhvQhwsLagA3rQCQLX63vo1uCDXbH4xAMI7x/WHmLvZl4PjxH0G/8HiFKVGGvcI/+Iwq JOE/eAUHZAwba37cXzZQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.2 #3 (Red Hat Linux)) id 1iFehW-0007bR-TP; Wed, 02 Oct 2019 13:29:54 +0000 Received: from userp2120.oracle.com ([156.151.31.85]) by bombadil.infradead.org with esmtps (Exim 4.92.2 #3 (Red Hat Linux)) id 1iFehT-0007b1-Ry for linux-arm-kernel@lists.infradead.org; Wed, 02 Oct 2019 13:29:53 +0000 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x92DSx1F037156; Wed, 2 Oct 2019 13:29:44 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2019-08-05; bh=EM3e9nI3amV6xVGJaxjxz45i18U04uaHvQ94gCdzIIs=; b=c+Mg75kVq8y09t0ZUPlttkci0ZJew3k1BY8yYl6R2HwYdCKfYoLmY9l1reOE9bz5Iwmk 9qHxc3IYdyJXJOQi9GLggW1mULgFeIwMYInD1cpLYUS+HlyIe7FAIIYhRLErr8hiGs4h z3Apaqb/sayWPcMzdwAClBeDI6QlANcXRInSK2MIWsDctDHdekyY2ZiosW9Yp9A1akI0 QhwsYMEdxpau7JeQqxYWsKyeigNoYCHv/u18pjMFZJaXxa95L+W4a1M9c4fOBD4WG8IS JCXENDAt3XgmB3iA7+dTaeup3n+lvZUdsYHnNOiRjItp0Kbp3YNVSIvdH2qkMrzSlgSf lQ== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by userp2120.oracle.com with ESMTP id 2va05rvuf9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 02 Oct 2019 13:29:44 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x92DSlsc098366; Wed, 2 Oct 2019 13:29:44 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserp3020.oracle.com with ESMTP id 2vckynx97t-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 02 Oct 2019 13:29:43 +0000 Received: from abhmp0006.oracle.com (abhmp0006.oracle.com [141.146.116.12]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x92DThq4028591; Wed, 2 Oct 2019 13:29:43 GMT Received: from kadam (/41.57.98.10) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 02 Oct 2019 06:29:42 -0700 Date: Wed, 2 Oct 2019 16:29:33 +0300 From: Dan Carpenter To: Colin King Subject: Re: [PATCH] pwm: sun4i: redundant assignment to variable pval Message-ID: <20191002132933.GO29696@kadam> References: <20191002100844.10490-1-colin.king@canonical.com> <20191002132506.GO22609@kadam> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20191002132506.GO22609@kadam> User-Agent: Mutt/1.9.4 (2018-02-28) X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9397 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910020129 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9397 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1908290000 definitions=main-1910020129 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191002_062951_991711_6D092AF4 X-CRM114-Status: GOOD ( 21.63 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-pwm@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org, Maxime Ripard , Chen-Yu Tsai , Thierry Reding , Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Wed, Oct 02, 2019 at 04:25:06PM +0300, Dan Carpenter wrote: > On Wed, Oct 02, 2019 at 11:08:44AM +0100, Colin King wrote: > > From: Colin Ian King > > > > Variable pval is being assigned a value that is never read. The > > assignment is redundant and hence can be removed. > > > > Addresses-Coverity: ("Unused value") > > Signed-off-by: Colin Ian King > > --- > > drivers/pwm/pwm-sun4i.c | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/drivers/pwm/pwm-sun4i.c b/drivers/pwm/pwm-sun4i.c > > index 6f5840a1a82d..53970d4ba695 100644 > > --- a/drivers/pwm/pwm-sun4i.c > > +++ b/drivers/pwm/pwm-sun4i.c > > @@ -156,7 +156,6 @@ static int sun4i_pwm_calculate(struct sun4i_pwm_chip *sun4i_pwm, > > if (sun4i_pwm->data->has_prescaler_bypass) { > > /* First, test without any prescaler when available */ > > prescaler = PWM_PRESCAL_MASK; > > - pval = 1; > > /* > > * When not using any prescaler, the clock period in nanoseconds > > * is not an integer so round it half up instead of > > Are you sure? It looks used to me. Ah. Never mind. My tree was out of date. regards, dan carpenter _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel