[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 1/6] Revert "In xen_create_msi_irq, extract the domain id of the MSI device."
This reverts commit 661692690f8cf5a5ceccec1f4d221ec2381974 I did not remove the domid attribute from the structs as they are going to be used in the subsequent patches. Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx> --- drivers/xen/events.c | 44 -------------------------------------------- 1 files changed, 0 insertions(+), 44 deletions(-) diff --git a/drivers/xen/events.c b/drivers/xen/events.c index 9c56d60..f8bbf4c 100644 --- a/drivers/xen/events.c +++ b/drivers/xen/events.c @@ -45,7 +45,6 @@ #include <xen/interface/xen.h> #include <xen/interface/event_channel.h> -#include <xen/xenbus.h> #include "../pci/msi.h" /* @@ -627,43 +626,6 @@ out: spin_unlock(&irq_mapping_update_lock); return rc; } -#define XS_PCI_SEARCH "/local/domain/0/backend/pci/" -#define XS_PCI_SEARCH_LEN 28 - -static int get_domid_for_dev(char *nodename, char *path, char *val, void *data) -{ - struct pci_dev *dev = (struct pci_dev *)data; - - /* We are looking for: - * CB inv[/local/domain/0/backend/pci/3/0/dev-1]=0000:00:14.5 */ - - if (!dev || !pci_name(dev)) - return -ENODEV; - - if (strncmp(nodename, XS_PCI_SEARCH, XS_PCI_SEARCH_LEN) == 0) - { - if (strncmp(path, "dev", 3) == 0) { - char *name = NULL; - unsigned int domid; - - /* The val contains: 0000:00:14.5 */ - if (strcmp(val, pci_name(dev)) != 0) - return 0; - - /* From here on, extract the Domain ID */ - name = strstr(nodename, "pci/"); - if (!name) - return 0; - - if (sscanf(name, "pci/%u", &domid) != 1) - return 0; - - dev_dbg(&dev->dev,"Assigned to domain %u.\n", domid); - return domid; - } - } - return 0; -} int xen_create_msi_irq(struct pci_dev *dev, struct msi_desc *msidesc, int type, int pirq_override) @@ -675,12 +637,6 @@ int xen_create_msi_irq(struct pci_dev *dev, struct msi_desc *msidesc, int pos; u32 table_offset, bir; - /* Walk the XenStore keys to see if the device is assigned to any - * domain. If so, extract the domain id. */ - domid = rc = xenbus_walk( "/local/domain/0", get_domid_for_dev, dev); - if (rc <= 0) - domid = DOMID_SELF; - memset(&map_irq, 0, sizeof(map_irq)); map_irq.domid = domid; map_irq.type = MAP_PIRQ_TYPE_MSI; -- 1.6.2.5 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |