linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Frederic Barrat <fbarrat@linux.ibm.com>
To: linuxppc-dev@lists.ozlabs.org, clg@kaod.org,
	christophe_lombard@fr.ibm.com, ajd@linux.ibm.com,
	ukrishn@linux.ibm.com, mrochs@linux.ibm.com
Cc: haren@linux.ibm.com, groug@kaod.org
Subject: [PATCH v2 4/4] ocxl: Remove custom service to allocate interrupts
Date: Fri,  3 Apr 2020 17:38:38 +0200	[thread overview]
Message-ID: <20200403153838.29224-5-fbarrat@linux.ibm.com> (raw)
In-Reply-To: <20200403153838.29224-1-fbarrat@linux.ibm.com>

We now allocate interrupts through xive directly.

Reviewed-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Greg Kurz <groug@kaod.org>
Signed-off-by: Frederic Barrat <fbarrat@linux.ibm.com>
---
 arch/powerpc/include/asm/pnv-ocxl.h   |  3 ---
 arch/powerpc/platforms/powernv/ocxl.c | 30 ---------------------------
 2 files changed, 33 deletions(-)

diff --git a/arch/powerpc/include/asm/pnv-ocxl.h b/arch/powerpc/include/asm/pnv-ocxl.h
index 7de82647e761..e90650328c9c 100644
--- a/arch/powerpc/include/asm/pnv-ocxl.h
+++ b/arch/powerpc/include/asm/pnv-ocxl.h
@@ -30,7 +30,4 @@ extern int pnv_ocxl_spa_setup(struct pci_dev *dev, void *spa_mem, int PE_mask,
 extern void pnv_ocxl_spa_release(void *platform_data);
 extern int pnv_ocxl_spa_remove_pe_from_cache(void *platform_data, int pe_handle);
 
-extern int pnv_ocxl_alloc_xive_irq(u32 *irq, u64 *trigger_addr);
-extern void pnv_ocxl_free_xive_irq(u32 irq);
-
 #endif /* _ASM_PNV_OCXL_H */
diff --git a/arch/powerpc/platforms/powernv/ocxl.c b/arch/powerpc/platforms/powernv/ocxl.c
index 8c65aacda9c8..ecdad219d704 100644
--- a/arch/powerpc/platforms/powernv/ocxl.c
+++ b/arch/powerpc/platforms/powernv/ocxl.c
@@ -2,7 +2,6 @@
 // Copyright 2017 IBM Corp.
 #include <asm/pnv-ocxl.h>
 #include <asm/opal.h>
-#include <asm/xive.h>
 #include <misc/ocxl-config.h>
 #include "pci.h"
 
@@ -484,32 +483,3 @@ int pnv_ocxl_spa_remove_pe_from_cache(void *platform_data, int pe_handle)
 	return rc;
 }
 EXPORT_SYMBOL_GPL(pnv_ocxl_spa_remove_pe_from_cache);
-
-int pnv_ocxl_alloc_xive_irq(u32 *irq, u64 *trigger_addr)
-{
-	__be64 flags, trigger_page;
-	s64 rc;
-	u32 hwirq;
-
-	hwirq = xive_native_alloc_irq();
-	if (!hwirq)
-		return -ENOENT;
-
-	rc = opal_xive_get_irq_info(hwirq, &flags, NULL, &trigger_page, NULL,
-				NULL);
-	if (rc || !trigger_page) {
-		xive_native_free_irq(hwirq);
-		return -ENOENT;
-	}
-	*irq = hwirq;
-	*trigger_addr = be64_to_cpu(trigger_page);
-	return 0;
-
-}
-EXPORT_SYMBOL_GPL(pnv_ocxl_alloc_xive_irq);
-
-void pnv_ocxl_free_xive_irq(u32 irq)
-{
-	xive_native_free_irq(irq);
-}
-EXPORT_SYMBOL_GPL(pnv_ocxl_free_xive_irq);
-- 
2.25.1


  parent reply	other threads:[~2020-04-03 15:40 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-03 15:38 [PATCH v2 0/4] ocxl: Cleanup AFU interrupt allocation Frederic Barrat
2020-04-03 15:38 ` [PATCH v2 1/4] scsi: cxlflash: Access interrupt trigger page from xive directly Frederic Barrat
2020-04-03 15:48   ` Cédric Le Goater
2020-04-03 15:51   ` Matthew R. Ochs
2020-04-03 15:38 ` [PATCH v2 2/4] ocxl: " Frederic Barrat
2020-04-03 15:38 ` [PATCH v2 3/4] ocxl: Don't return trigger page when allocating an interrupt Frederic Barrat
2020-04-03 16:08   ` Andrew Donnellan
2020-04-03 15:38 ` Frederic Barrat [this message]
2020-04-03 16:09   ` [PATCH v2 4/4] ocxl: Remove custom service to allocate interrupts Andrew Donnellan
2020-09-09 13:37 ` [PATCH v2 0/4] ocxl: Cleanup AFU interrupt allocation Michael Ellerman

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=20200403153838.29224-5-fbarrat@linux.ibm.com \
    --to=fbarrat@linux.ibm.com \
    --cc=ajd@linux.ibm.com \
    --cc=christophe_lombard@fr.ibm.com \
    --cc=clg@kaod.org \
    --cc=groug@kaod.org \
    --cc=haren@linux.ibm.com \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mrochs@linux.ibm.com \
    --cc=ukrishn@linux.ibm.com \
    /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;
as well as URLs for NNTP newsgroup(s).