Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1212794 > unrolled thread

[PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning

Started byyalin wang <yalin.wang2010@gmail.com>
First post2015-08-25 10:20 +0200
Last post2015-08-28 06:40 +0200
Articles 3 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning yalin wang <yalin.wang2010@gmail.com> - 2015-08-25 10:20 +0200
    Re: [PATCH] dma/ipu: change ipu_irq_handler() to remove compile  warning Vinod Koul <vinod.koul@intel.com> - 2015-08-28 06:40 +0200
      Re: [PATCH] dma/ipu: change ipu_irq_handler() to remove compile  warning Vinod Koul <vinod.koul@intel.com> - 2015-08-28 06:40 +0200

#1212794 — [PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning

Fromyalin wang <yalin.wang2010@gmail.com>
Date2015-08-25 10:20 +0200
Subject[PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning
Message-ID<q1hCy-P0-17@gated-at.bofh.it>
Change ipu_irq_handler() to avoid gcc warning:

drivers/dma/ipu/ipu_irq.c:305:4: warning: 'irq' may be used
uninitialized in this function [-Wmaybe-uninitialized]
    generic_handle_irq(irq);

Signed-off-by: yalin wang <yalin.wang2010@gmail.com>
---
 drivers/dma/ipu/ipu_irq.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/dma/ipu/ipu_irq.c b/drivers/dma/ipu/ipu_irq.c
index 7489d2a..1a74eee 100644
--- a/drivers/dma/ipu/ipu_irq.c
+++ b/drivers/dma/ipu/ipu_irq.c
@@ -286,23 +286,21 @@ static void ipu_irq_handler(unsigned int __irq, struct irq_desc *desc)
 		raw_spin_unlock(&bank_lock);
 		while ((line = ffs(status))) {
 			struct ipu_irq_map *map;
-			unsigned int irq;
 
 			line--;
 			status &= ~(1UL << line);
 
 			raw_spin_lock(&bank_lock);
 			map = src2map(32 * i + line);
-			if (map)
-				irq = map->irq;
 			raw_spin_unlock(&bank_lock);
 
 			if (!map) {
 				pr_err("IPU: Interrupt on unmapped source %u bank %d\n",
 				       line, i);
 				continue;
+			} else {
+				generic_handle_irq(map->irq);
 			}
-			generic_handle_irq(irq);
 		}
 	}
 }
-- 
1.9.1

--
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]


#1215083 — Re: [PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning

FromVinod Koul <vinod.koul@intel.com>
Date2015-08-28 06:40 +0200
SubjectRe: [PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning
Message-ID<q2jCh-Zu-3@gated-at.bofh.it>
In reply to#1212794
On Tue, Aug 25, 2015 at 04:01:08PM +0800, yalin wang wrote:
> Change ipu_irq_handler() to avoid gcc warning:
> 
> drivers/dma/ipu/ipu_irq.c:305:4: warning: 'irq' may be used
> uninitialized in this function [-Wmaybe-uninitialized]
>     generic_handle_irq(irq);

Applied after fixing subsystem name

-- 
~Vinod

--
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] | [next] | [standalone]


#1215085 — Re: [PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning

FromVinod Koul <vinod.koul@intel.com>
Date2015-08-28 06:40 +0200
SubjectRe: [PATCH] dma/ipu: change ipu_irq_handler() to remove compile warning
Message-ID<q2jCh-Zu-5@gated-at.bofh.it>
In reply to#1215083
On Fri, Aug 28, 2015 at 10:03:32AM +0530, Vinod Koul wrote:
> On Tue, Aug 25, 2015 at 04:01:08PM +0800, yalin wang wrote:
> > Change ipu_irq_handler() to avoid gcc warning:
> > 
> > drivers/dma/ipu/ipu_irq.c:305:4: warning: 'irq' may be used
> > uninitialized in this function [-Wmaybe-uninitialized]
> >     generic_handle_irq(irq);
> 
> Applied after fixing subsystem name

Just to be clear, V2 of this patch was applied


-- 
~Vinod
--
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