All of lore.kernel.org
 help / color / mirror / Atom feed
From: tip-bot for Jiang Liu <tipbot@zytor.com>
To: linux-tip-commits@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, bp@alien8.de,
	tglx@linutronix.de, mingo@kernel.org,
	sergey.senozhatsky@gmail.com, jiang.liu@linux.intel.com
Subject: [tip:x86/apic] x86/hpet: Check for irq== 0 when allocating hpet MSI interrupts
Date: Sat, 20 Jun 2015 03:07:55 -0700	[thread overview]
Message-ID: <tip-bafac298fb20e9ae1305c710d4fd8d20c5911afa@git.kernel.org> (raw)
In-Reply-To: <558447AF.30703@linux.intel.com>

Commit-ID:  bafac298fb20e9ae1305c710d4fd8d20c5911afa
Gitweb:     http://git.kernel.org/tip/bafac298fb20e9ae1305c710d4fd8d20c5911afa
Author:     Jiang Liu <jiang.liu@linux.intel.com>
AuthorDate: Sat, 20 Jun 2015 11:50:50 +0200
Committer:  Thomas Gleixner <tglx@linutronix.de>
CommitDate: Sat, 20 Jun 2015 12:00:58 +0200

x86/hpet: Check for irq==0 when allocating hpet MSI interrupts

irq == 0 is not a valid irq for a irqdomain MSI allocation, but hpet
code checks only for negative return values.

Reported-by: Sergey Senozhatsky <sergey.senozhatsky@gmail.com>
Cc: Borislav Petkov <bp@alien8.de>
Link: http://lkml.kernel.org/r/558447AF.30703@linux.intel.com
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
---
 arch/x86/kernel/hpet.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/x86/kernel/hpet.c b/arch/x86/kernel/hpet.c
index e2449cf..c47aab3 100644
--- a/arch/x86/kernel/hpet.c
+++ b/arch/x86/kernel/hpet.c
@@ -578,7 +578,7 @@ static void hpet_msi_capability_lookup(unsigned int start_timer)
 			continue;
 
 		irq = hpet_assign_irq(hpet_domain, hdev, hdev->num);
-		if (irq < 0)
+		if (irq <= 0)
 			continue;
 
 		sprintf(hdev->name, "hpet%d", i);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
Please read the FAQ at  http://www.tux.org/lkml/

  parent reply	other threads:[~2015-06-20 10:08 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-19  7:11 [-next] !irqd_can_balance() WARNINGs at irq_move_masked_irq() Sergey Senozhatsky
2015-06-19  9:25 ` Thomas Gleixner
2015-06-19 12:21   ` Thomas Gleixner
2015-06-19 13:11     ` Sergey Senozhatsky
2015-06-19 16:09     ` Jiang Liu
2015-06-19 16:12       ` Jiang Liu
2015-06-19 16:15         ` Thomas Gleixner
2015-06-19 16:21           ` Jiang Liu
2015-06-19 16:30             ` Thomas Gleixner
2015-06-19 16:47               ` Jiang Liu
2015-06-19 17:14                 ` Sergey Senozhatsky
2015-06-20  4:32                 ` Sergey Senozhatsky
2015-06-20 10:07                 ` tip-bot for Jiang Liu [this message]
2015-06-19 16:23           ` Sergey Senozhatsky
2015-06-20  4:31     ` Sergey Senozhatsky
2015-06-20  7:52       ` Thomas Gleixner
2015-06-20  7:57         ` Sergey Senozhatsky
2015-06-20  8:13           ` Thomas Gleixner
2015-06-20  8:27             ` Sergey Senozhatsky
2015-06-20  9:12               ` Thomas Gleixner
2015-06-20 17:53                 ` Sergey Senozhatsky
2015-06-21  4:15                 ` Sergey Senozhatsky
2015-06-21 14:37                   ` Thomas Gleixner
2015-06-21 14:43                     ` [tip:x86/apic] x86/hpet: Use proper hpet device number for MSI allocation tip-bot for Thomas Gleixner
2015-06-20 17:20             ` [tip:irq/core] genirq: Remove bogus restriction in irq_move_mask_irq() tip-bot for Thomas Gleixner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tip-bafac298fb20e9ae1305c710d4fd8d20c5911afa@git.kernel.org \
    --to=tipbot@zytor.com \
    --cc=bp@alien8.de \
    --cc=hpa@zytor.com \
    --cc=jiang.liu@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=sergey.senozhatsky@gmail.com \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.