Commit 6cf17f9a authored by Pierre Morel's avatar Pierre Morel Committed by Vasily Gorbik

s390/pci: define kernel parameters for PCI multifunction

Using PCI multifunctions in S390 is a new feature we may want
to ignore to continue provide the same topology as in the past
to userland even if the configuration supports exposing the
topology of a multi-Function device.

A new boolean parameters allows to overwrite the kernel
pci configuration:

- pci=norid when on, disallow the use a new firmware field,
  RID, which provides the PCI <bus>:<device>.<function> part
  of the PCI address.

To be used in the following patches and satisfy the checkpatch.pl
the variable is exposed in pci.h
Signed-off-by: default avatarPierre Morel <pmorel@linux.ibm.com>
Reviewed-by: default avatarNiklas Schnelle <schnelle@linux.ibm.com>
Signed-off-by: default avatarVasily Gorbik <gor@linux.ibm.com>
parent d08d6f5d
...@@ -168,6 +168,7 @@ static inline bool zdev_enabled(struct zpci_dev *zdev) ...@@ -168,6 +168,7 @@ static inline bool zdev_enabled(struct zpci_dev *zdev)
extern const struct attribute_group *zpci_attr_groups[]; extern const struct attribute_group *zpci_attr_groups[];
extern unsigned int s390_pci_force_floating __initdata; extern unsigned int s390_pci_force_floating __initdata;
extern unsigned int s390_pci_no_rid;
/* ----------------------------------------------------------------------------- /* -----------------------------------------------------------------------------
Prototypes Prototypes
......
...@@ -48,6 +48,8 @@ static unsigned int zpci_num_domains_allocated; ...@@ -48,6 +48,8 @@ static unsigned int zpci_num_domains_allocated;
min(((unsigned long) ZPCI_NR_DEVICES * PCI_STD_NUM_BARS / 2), \ min(((unsigned long) ZPCI_NR_DEVICES * PCI_STD_NUM_BARS / 2), \
ZPCI_IOMAP_MAX_ENTRIES) ZPCI_IOMAP_MAX_ENTRIES)
unsigned int s390_pci_no_rid;
static DEFINE_SPINLOCK(zpci_iomap_lock); static DEFINE_SPINLOCK(zpci_iomap_lock);
static unsigned long *zpci_iomap_bitmap; static unsigned long *zpci_iomap_bitmap;
struct zpci_iomap_entry *zpci_iomap_start; struct zpci_iomap_entry *zpci_iomap_start;
...@@ -844,6 +846,10 @@ char * __init pcibios_setup(char *str) ...@@ -844,6 +846,10 @@ char * __init pcibios_setup(char *str)
s390_pci_force_floating = 1; s390_pci_force_floating = 1;
return NULL; return NULL;
} }
if (!strcmp(str, "norid")) {
s390_pci_no_rid = 1;
return NULL;
}
return str; return str;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment