All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: Russell Johnson <rjohnson@domain.hid>
Cc: 'xenomai-core' <xenomai@xenomai.org>
Subject: Re: [Xenomai-core] Handling PCI MSI interrupts
Date: Thu, 16 Feb 2006 10:36:47 +0100	[thread overview]
Message-ID: <43F447AF.4020604@domain.hid> (raw)
In-Reply-To: <008501c63284$ef549ed0$1e01a8c0@domain.hid>

Russell Johnson wrote:
> 
>>It's definitely an Adeos issue and msi.c needs fixing. What 
>>about this patch, do 
>>things improve with it (against 2.6.15-ipipe-1.2-00)?
> 
> 
> I'm currently patching my setup which started with ipipe-2.6.14-i386-1.0-12.
> I've been having no luck with any MSI devices in the system even if they
> have supposedly had MSI disabled.  I'll post my testing results in the next
> day or so.

The latest patch was incomplete; you might be luckier with this one. I've merged 
Jeroen's last observations on this issue and mine.

--- 2.6.15/drivers/pci/msi.c	2006-01-03 04:21:10.000000000 +0100
+++ 2.6.15-ipipe/drivers/pci/msi.c	2006-02-16 10:30:27.000000000 +0100
@@ -149,6 +149,21 @@
  	msi_set_mask_bit(vector, 0);
  }

+#ifdef CONFIG_IPIPE
+static void ack_MSI_irq_w_maskbits(unsigned int vector)
+{
+    mask_MSI_irq(vector);
+    __ack_APIC_irq();
+}
+static void ack_MSI_irq_wo_maskbits(unsigned int vector)
+{
+    __ack_APIC_irq();
+}
+#else /* !CONFIG_IPIPE */
+#define ack_MSI_irq_wo_maskbits  do_nothing
+#define ack_MSI_irq_w_maskbits   mask_MSI_irq
+#endif /* CONFIG_IPIPE */
+
  static unsigned int startup_msi_irq_wo_maskbit(unsigned int vector)
  {
  	struct msi_desc *entry;
@@ -212,7 +227,7 @@
  	.shutdown	= shutdown_msi_irq,
  	.enable		= unmask_MSI_irq,
  	.disable	= mask_MSI_irq,
-	.ack		= mask_MSI_irq,
+	.ack		= ack_MSI_irq_w_maskbits,
  	.end		= end_msi_irq_w_maskbit,
  	.set_affinity	= set_msi_irq_affinity
  };
@@ -228,7 +243,7 @@
  	.shutdown	= shutdown_msi_irq,
  	.enable		= unmask_MSI_irq,
  	.disable	= mask_MSI_irq,
-	.ack		= mask_MSI_irq,
+	.ack		= ack_MSI_irq_w_maskbits,
  	.end		= end_msi_irq_w_maskbit,
  	.set_affinity	= set_msi_irq_affinity
  };
@@ -244,7 +259,7 @@
  	.shutdown	= shutdown_msi_irq,
  	.enable		= do_nothing,
  	.disable	= do_nothing,
-	.ack		= do_nothing,
+	.ack		= ack_MSI_irq_wo_maskbits,
  	.end		= end_msi_irq_wo_maskbit,
  	.set_affinity	= set_msi_irq_affinity
  };

-- 

Philippe.


  reply	other threads:[~2006-02-16  9:36 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-14 15:44 [Xenomai-core] Handling PCI MSI interrupts Jeroen Van den Keybus
2006-02-14 17:50 ` Philippe Gerum
2006-02-14 18:07   ` Jeroen Van den Keybus
2006-02-14 18:17     ` Jan Kiszka
2006-02-14 18:26       ` Philippe Gerum
2006-02-14 18:52         ` Jeroen Van den Keybus
2006-02-14 19:22           ` Jeroen Van den Keybus
2006-02-14 19:33           ` Jeroen Van den Keybus
2006-02-14 21:41             ` Jeroen Van den Keybus
2006-02-14 21:56               ` Philippe Gerum
2006-02-15 11:00                 ` Jeroen Van den Keybus
2006-02-15 18:02                   ` Jeroen Van den Keybus
2006-02-15 18:34                     ` Jeroen Van den Keybus
2006-02-15 20:09                       ` Philippe Gerum
2006-02-15 20:50                         ` Jeroen Van den Keybus
2006-02-15 22:48                           ` Philippe Gerum
2006-02-15 22:58                           ` Jeroen Van den Keybus
2006-02-15 23:09                         ` Russell Johnson
2006-02-16  9:36                           ` Philippe Gerum [this message]
2006-02-16 14:23                             ` Russell Johnson
2006-02-17 12:54                               ` Jeroen Van den Keybus
2006-02-17 13:08                                 ` Philippe Gerum
2006-02-17 14:43                                   ` Russell Johnson
2006-02-17 15:45                                     ` Philippe Gerum
2006-02-17 15:57                                   ` Jeroen Van den Keybus
2006-02-17 16:07                                     ` Philippe Gerum
2006-02-17 16:49                                       ` Jeroen Van den Keybus
2006-02-17 18:37                                         ` Jeroen Van den Keybus
2006-02-17 18:39                                           ` Philippe Gerum
2006-02-19 18:50                                             ` Philippe Gerum
2006-02-14 18:23     ` Philippe Gerum

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=43F447AF.4020604@domain.hid \
    --to=rpm@xenomai.org \
    --cc=rjohnson@domain.hid \
    --cc=xenomai@xenomai.org \
    /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.