From patchwork Wed May 16 08:49:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 10403105 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5B1E8601F9 for ; Wed, 16 May 2018 08:49:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 484E028803 for ; Wed, 16 May 2018 08:49:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3A10A28813; Wed, 16 May 2018 08:49:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A47E928803 for ; Wed, 16 May 2018 08:49:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752038AbeEPItR (ORCPT ); Wed, 16 May 2018 04:49:17 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:46046 "EHLO userp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752643AbeEPItO (ORCPT ); Wed, 16 May 2018 04:49:14 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w4G8kxI1182187; Wed, 16 May 2018 08:49:09 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : mime-version : content-type; s=corp-2017-10-26; bh=M6Y5dLVxptVtbkCsorTJXgU3pZrBbwdCzH72XWYC9AI=; b=BaCCceGVT4u65rX5+j0H5iWhXvx19tvWxnGhQGPq1YCJQ90DxXUaR+KVx81GOsl/y+0O rNbLu5D0kXFm5C0lRU5uwmP+cI0Zti0BrttwFITs7vR2HlUz1gSyouPFiX6x1VzA6jzz SFtitr7KqIuVGy3InC4YbTOzTb7YJpSNfAnF+V0qKDZqSZiCwOJZUjGKKfVhWZ4XRpEO MbzKbC2WFTaQSuNSXYvWHO+gAfgOo7G+NSwAi209C0ol7q0eLG/QEC+ruH9wCFbnHKMj 7HWWbofEv20juCjHr6A+AraYOXirT8itnxcgPYiGHphROvL7x5G2g0cpj7WHUvDN78Ot nw== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp2120.oracle.com with ESMTP id 2hx29w3ua3-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 16 May 2018 08:49:09 +0000 Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id w4G8n83G030147 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 16 May 2018 08:49:09 GMT Received: from abhmp0003.oracle.com (abhmp0003.oracle.com [141.146.116.9]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id w4G8n85N020582; Wed, 16 May 2018 08:49:08 GMT Received: from mwanda (/197.254.35.146) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 16 May 2018 01:49:08 -0700 Date: Wed, 16 May 2018 11:49:01 +0300 From: Dan Carpenter To: Viresh Kumar Cc: Nishanth Menon , Stephen Boyd , linux-pm@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH] PM / OPP: silence an uninitialized variable warning Message-ID: <20180516084900.GC23043@mwanda> MIME-Version: 1.0 Content-Disposition: inline X-Mailer: git-send-email haha only kidding User-Agent: Mutt/1.9.4 (2018-02-28) X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8894 signatures=668698 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=2 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=842 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1711220000 definitions=main-1805160089 Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Smatch complains that "rate" can be uninitialized here. Signed-off-by: Dan Carpenter diff --git a/drivers/opp/of.c b/drivers/opp/of.c index 7026e9f484ea..afc844806db0 100644 --- a/drivers/opp/of.c +++ b/drivers/opp/of.c @@ -317,7 +317,8 @@ static int _opp_add_static_v2(struct opp_table *opp_table, struct device *dev, /* Check if the OPP supports hardware's hierarchy of versions or not */ if (!_opp_is_supported(dev, opp_table, np)) { - dev_dbg(dev, "OPP not supported by hardware: %llu\n", rate); + dev_dbg(dev, "OPP not supported by hardware: %lu\n", + new_opp->rate); goto free_opp; }