From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ahci: don't use MSI when PCI is disabled
Date: Mon, 23 Nov 2015 20:34:30 +0100 [thread overview]
Message-ID: <6160865.VIglm5oKj3@wuerfel> (raw)
In-Reply-To: <CAPcyv4gSjWZ7OPqp9fwtc9yGV9g5AKkkCLDnU-F71XsHBgYUQA@mail.gmail.com>
On Monday 23 November 2015 09:25:38 Dan Williams wrote:
>
> If we had an "static inline ahci_irq_vector(int port)" helper to
> compile out the struct msix_entry de-reference would that be
> sufficient?
Yes, that is probably a nicer way to do it. We should then also do
something like this:
@@ -2510,7 +2513,8 @@ int ahci_host_activate(struct ata_host *host, struct scsi_host_template *sht)
int irq = hpriv->irq;
int rc;
- if (hpriv->flags & (AHCI_HFLAG_MULTI_MSI | AHCI_HFLAG_MULTI_MSIX))
+ if (IS_ENABLED(CONFIG_PCI_MSI) && \
+ hpriv->flags & (AHCI_HFLAG_MULTI_MSI | AHCI_HFLAG_MULTI_MSIX))
rc = ahci_host_activate_multi_irqs(host, sht);
else if (hpriv->flags & AHCI_HFLAG_EDGE_IRQ)
rc = ata_host_activate(host, irq, ahci_single_edge_irq_intr,
which will let gcc leave out the entire ahci_host_activate_multi_irqs()
function but still flag compile errors in it even if CONFIG_PCI is
disabled.
Arnd
next prev parent reply other threads:[~2015-11-23 19:34 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-23 9:47 [PATCH] ahci: don't use MSI when PCI is disabled Arnd Bergmann
2015-11-23 17:25 ` Dan Williams
2015-11-23 19:34 ` Arnd Bergmann [this message]
2015-12-04 16:34 ` Arnd Bergmann
2015-12-04 16:37 ` Dan Williams
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=6160865.VIglm5oKj3@wuerfel \
--to=arnd@arndb.de \
--cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox