Merge branch 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec...
[firefly-linux-kernel-4.4.55.git] / drivers / pci / pci-sysfs.c
index c85438a367d530e6db996ce79c66767e5aa84cb7..a8a277a2e0d05ad414d64d347dbfd7517538673c 100644 (file)
@@ -369,7 +369,7 @@ pci_read_config(struct file *filp, struct kobject *kobj,
        u8 *data = (u8*) buf;
 
        /* Several chips lock up trying to read undefined config space */
-       if (security_capable(filp->f_cred, CAP_SYS_ADMIN) == 0) {
+       if (security_capable(&init_user_ns, filp->f_cred, CAP_SYS_ADMIN) == 0) {
                size = dev->cfg_size;
        } else if (dev->hdr_type == PCI_HEADER_TYPE_CARDBUS) {
                size = 128;