Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1217320 > unrolled thread
| Started by | Alex Shi <alex.shi@linaro.org> |
|---|---|
| First post | 2015-09-02 07:20 +0200 |
| Last post | 2015-09-02 11:00 +0200 |
| Articles | 2 — 1 participant |
Back to article view | Back to linux.kernel
[PATCH] irqchip/gicv3-its: comfort build warnings Alex Shi <alex.shi@linaro.org> - 2015-09-02 07:20 +0200
Re: [PATCH] irqchip/gicv3-its: comfort build warnings Alex Shi <alex.shi@linaro.org> - 2015-09-02 11:00 +0200
| From | Alex Shi <alex.shi@linaro.org> |
|---|---|
| Date | 2015-09-02 07:20 +0200 |
| Subject | [PATCH] irqchip/gicv3-its: comfort build warnings |
| Message-ID | <q48CJ-3QR-5@gated-at.bofh.it> |
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 <alex.shi@linaro.org>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: Jason Cooper <jason@lakedaemon.net>
---
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;
--
2.3.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Alex Shi <alex.shi@linaro.org> |
|---|---|
| Date | 2015-09-02 11:00 +0200 |
| Message-ID | <q4c3F-8x-17@gated-at.bofh.it> |
| In reply to | #1217320 |
On 09/02/2015 03:52 PM, Marc Zyngier wrote: > On 02/09/15 06:16, Alex Shi wrote: >> 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. > > Which compiler are you using? I'm not seeing these warnings here. aarch64-linux-gnu-gcc (Ubuntu/Linaro 4.8.2-13ubuntu1) 4.8.2 20140110 (prerelease) [ibm/gcc-4_8-branch merged from gcc-4_8-branch, revision 205847] $make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- defconfig > > Thanks, > > M. > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web