From patchwork Wed Sep 2 05:16:14 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Alex Shi X-Patchwork-Id: 52953 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f197.google.com (mail-wi0-f197.google.com [209.85.212.197]) by patches.linaro.org (Postfix) with ESMTPS id E5EBF22E23 for ; Wed, 2 Sep 2015 05:16:28 +0000 (UTC) Received: by wicgc1 with SMTP id gc1sf2205399wic.3 for ; Tue, 01 Sep 2015 22:16:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :mime-version:content-type:content-transfer-encoding:sender :precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=WQSOA2V7OYca8VDGMzFoHg+rgM4kKUvmJAP6D1Wd76w=; b=Egs7h0wWdJRhSLZsMsFMJu0b9kMORU8qFzVGdj3BF1+MB20L+CV9wmGPbYHfxYV5oo T1CH+Mlyx6QVerx/mWiR7xu1PiSOeVTryhWwege7gjJG2b7nDk8edMOPU2XeXQxLgYFa yrptXiwa1p7iIBxDqBmH178HmR3iTr3M7CChMKh8kl6mRVa2xif58CGvOzb+EcdJ/NSJ 1SptdALyyIQRD1j8KxJXYysnwEqQTX/iX5nYuNa/J5y1fFxUEQxJ/G6MNP0G+S/RRAeF EpxPlXdFhTtHnzCKodIKrp1S5LV3B63kSzHQLpW6Dlb7ksSr1oVFqD37Bxa0MJO2Cvoe sqDA== X-Gm-Message-State: ALoCoQmhUA5IyoRjLrQ/9bincK+MEeOq9vZ4rcPHMBSnEUhvzjS+VyT0CKJUopAxcKoH5mgv9qMA X-Received: by 10.180.100.71 with SMTP id ew7mr491880wib.0.1441170987387; Tue, 01 Sep 2015 22:16:27 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.120.164 with SMTP id ld4ls41363lab.62.gmail; Tue, 01 Sep 2015 22:16:27 -0700 (PDT) X-Received: by 10.152.6.231 with SMTP id e7mr14801281laa.78.1441170987205; Tue, 01 Sep 2015 22:16:27 -0700 (PDT) Received: from mail-la0-f41.google.com (mail-la0-f41.google.com. [209.85.215.41]) by mx.google.com with ESMTPS id z1si18582570lbw.159.2015.09.01.22.16.26 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 01 Sep 2015 22:16:27 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.41 as permitted sender) client-ip=209.85.215.41; Received: by lamp12 with SMTP id p12so13509400lam.0 for ; Tue, 01 Sep 2015 22:16:26 -0700 (PDT) X-Received: by 10.152.178.165 with SMTP id cz5mr8410463lac.29.1441170986797; Tue, 01 Sep 2015 22:16:26 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.164.42 with SMTP id yn10csp299778lbb; Tue, 1 Sep 2015 22:16:25 -0700 (PDT) X-Received: by 10.68.249.66 with SMTP id ys2mr53469578pbc.82.1441170985674; Tue, 01 Sep 2015 22:16:25 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w1si27569544pdr.69.2015.09.01.22.16.24; Tue, 01 Sep 2015 22:16:25 -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; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751686AbbIBFQX (ORCPT + 28 others); Wed, 2 Sep 2015 01:16:23 -0400 Received: from mail-pa0-f46.google.com ([209.85.220.46]:34779 "EHLO mail-pa0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750955AbbIBFQV (ORCPT ); Wed, 2 Sep 2015 01:16:21 -0400 Received: by padhy1 with SMTP id hy1so19930252pad.1 for ; Tue, 01 Sep 2015 22:16:21 -0700 (PDT) X-Received: by 10.67.15.66 with SMTP id fm2mr27717600pad.82.1441170981178; Tue, 01 Sep 2015 22:16:21 -0700 (PDT) Received: from localhost.localdomain ([162.243.130.63]) by smtp.gmail.com with ESMTPSA id s13sm20059353pdi.70.2015.09.01.22.16.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 01 Sep 2015 22:16:20 -0700 (PDT) From: Alex Shi To: Thomas Gleixner , Jason Cooper , Marc Zyngier , linux-kernel@vger.kernel.org (open list:IRQCHIP DRIVERS) Cc: Alex Shi Subject: [PATCH] irqchip/gicv3-its: comfort build warnings Date: Wed, 2 Sep 2015 13:16:14 +0800 Message-Id: <1441170974-5547-1-git-send-email-alex.shi@linaro.org> X-Mailer: git-send-email 2.3.3 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: alex.shi@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.41 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , There are some warnings in gicv3-its. It looks like they are set in its_lpi_alloc_chunks(), but in fact, both of them(lpi_base/nr_lpis) still have some chances as unset variables. Anyway to comfort gcc if it's not a issue. drivers/irqchip/irq-gic-v3-its.c: In function ‘its_msi_prepare’: drivers/irqchip/irq-gic-v3-its.c:1148:26: warning: ‘lpi_base’ may be used uninitialized in this function [-Wmaybe-uninitialized] dev->event_map.lpi_base = lpi_base; ^ drivers/irqchip/irq-gic-v3-its.c:1116:6: note: ‘lpi_base’ was declared here int lpi_base; ^ drivers/irqchip/irq-gic-v3-its.c:1149:25: warning: ‘nr_lpis’ may be used uninitialized in this function [-Wmaybe-uninitialized] dev->event_map.nr_lpis = nr_lpis; ^ drivers/irqchip/irq-gic-v3-its.c:1117:6: note: ‘nr_lpis’ was declared here int nr_lpis; ^ Signed-off-by: Alex Shi Cc: Marc Zyngier Cc: Jason Cooper --- drivers/irqchip/irq-gic-v3-its.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c index 26b55c5..0f0af18 100644 --- a/drivers/irqchip/irq-gic-v3-its.c +++ b/drivers/irqchip/irq-gic-v3-its.c @@ -1113,8 +1113,8 @@ static struct its_device *its_create_device(struct its_node *its, u32 dev_id, unsigned long flags; u16 *col_map = NULL; void *itt; - int lpi_base; - int nr_lpis; + int lpi_base = 0; + int nr_lpis = 0; int nr_ites; int sz;