mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] genirq: remove redundant ->handle_irq assignment
@ 2017-08-10  1:51 Masahiro Yamada
  2017-08-14 10:09 ` Thomas Gleixner
  0 siblings, 1 reply; 2+ messages in thread
From: Masahiro Yamada @ 2017-08-10  1:51 UTC (permalink / raw)
  To: Thomas Gleixner; +Cc: Jason Cooper, Marc Zyngier, linux-kernel, Masahiro Yamada

This function has "desc->handle_irq = handle;" a few lines above.
The second assignment is redundant.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

 kernel/irq/chip.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c
index 51ccc77f1fe0..33fa2a95d768 100644
--- a/kernel/irq/chip.c
+++ b/kernel/irq/chip.c
@@ -931,10 +931,8 @@ __irq_do_set_handler(struct irq_desc *desc, irq_flow_handler_t handle,
 		 * chained interrupt. Reset it immediately because we
 		 * do know better.
 		 */
-		if (type != IRQ_TYPE_NONE) {
+		if (type != IRQ_TYPE_NONE)
 			__irq_set_trigger(desc, type);
-			desc->handle_irq = handle;
-		}
 
 		irq_settings_set_noprobe(desc);
 		irq_settings_set_norequest(desc);
-- 
2.7.4

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] genirq: remove redundant ->handle_irq assignment
  2017-08-10  1:51 [PATCH] genirq: remove redundant ->handle_irq assignment Masahiro Yamada
@ 2017-08-14 10:09 ` Thomas Gleixner
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Gleixner @ 2017-08-14 10:09 UTC (permalink / raw)
  To: Masahiro Yamada; +Cc: Jason Cooper, Marc Zyngier, linux-kernel

On Thu, 10 Aug 2017, Masahiro Yamada wrote:

> This function has "desc->handle_irq = handle;" a few lines above.
> The second assignment is redundant.

It's not as redundant as you might think. You missed to read the comment
above that. See also commit 1e12c4a9393b7.

Thanks,

	tglx

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-08-14 10:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-10  1:51 [PATCH] genirq: remove redundant ->handle_irq assignment Masahiro Yamada
2017-08-14 10:09 ` Thomas Gleixner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®