lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 23 Jul 2019 16:21:07 -0500
From:   Bjorn Helgaas <helgaas@...nel.org>
To:     Sasha Levin <sashal@...nel.org>
Cc:     Haiyang Zhang <haiyangz@...rosoft.com>,
        Randy Dunlap <rdunlap@...radead.org>,
        linux-pci <linux-pci@...r.kernel.org>,
        LKML <linux-kernel@...r.kernel.org>,
        Matthew Wilcox <willy@...radead.org>,
        Jake Oshins <jakeo@...rosoft.com>,
        KY Srinivasan <kys@...rosoft.com>,
        Stephen Hemminger <sthemmin@...rosoft.com>,
        Stephen Hemminger <stephen@...workplumber.org>,
        Dexuan Cui <decui@...rosoft.com>
Subject: Re: [PATCH] PCI: pci-hyperv: fix build errors on non-SYSFS config

On Sat, Jul 13, 2019 at 11:03:53AM -0400, Sasha Levin wrote:
> On Fri, Jul 12, 2019 at 04:04:17PM +0000, Haiyang Zhang wrote:
> > > -----Original Message-----
> > > From: Randy Dunlap <rdunlap@...radead.org>
> > > Sent: Friday, July 12, 2019 11:53 AM
> > > To: linux-pci <linux-pci@...r.kernel.org>; LKML <linux-
> > > kernel@...r.kernel.org>
> > > Cc: Matthew Wilcox <willy@...radead.org>; Jake Oshins
> > > <jakeo@...rosoft.com>; KY Srinivasan <kys@...rosoft.com>; Haiyang
> > > Zhang <haiyangz@...rosoft.com>; Stephen Hemminger
> > > <sthemmin@...rosoft.com>; Stephen Hemminger
> > > <stephen@...workplumber.org>; Sasha Levin <sashal@...nel.org>; Bjorn
> > > Helgaas <bhelgaas@...gle.com>; Dexuan Cui <decui@...rosoft.com>
> > > Subject: [PATCH] PCI: pci-hyperv: fix build errors on non-SYSFS config

Whoever merges this (see below), please update the subject line to
match:

  $ git log --oneline drivers/pci/controller/pci-hyperv.c | head -5
  4df591b20b80 PCI: hv: Fix a use-after-free bug in hv_eject_device_work()
  340d45569940 PCI: hv: Add pci_destroy_slot() in pci_devices_present_work(), if necessary
  15becc2b56c6 PCI: hv: Add hv_pci_remove_slots() when we unload the driver
  05f151a73ec2 PCI: hv: Fix a memory leak in hv_eject_device_work()
  c8ccf7599dda PCI: hv: Refactor hv_irq_unmask() to use cpumask_to_vpset()

> > > From: Randy Dunlap <rdunlap@...radead.org>
> > > 
> > > Fix build errors when building almost-allmodconfig but with SYSFS
> > > not set (not enabled).  Fixes these build errors:
> > > 
> > > ERROR: "pci_destroy_slot" [drivers/pci/controller/pci-hyperv.ko] undefined!
> > > ERROR: "pci_create_slot" [drivers/pci/controller/pci-hyperv.ko] undefined!
> > > 
> > > drivers/pci/slot.o is only built when SYSFS is enabled, so
> > > pci-hyperv.o has an implicit dependency on SYSFS.
> > > Make that explicit.
> > > 
> > > Also, depending on X86 && X86_64 is not needed, so just change that
> > > to depend on X86_64.
> > > 
> > > Fixes: a15f2c08c708 ("PCI: hv: support reporting serial number as slot
> > > information")
> > > 
> > > Signed-off-by: Randy Dunlap <rdunlap@...radead.org>
> > > Cc: Matthew Wilcox <willy@...radead.org>
> > > Cc: Jake Oshins <jakeo@...rosoft.com>
> > > Cc: "K. Y. Srinivasan" <kys@...rosoft.com>
> > > Cc: Haiyang Zhang <haiyangz@...rosoft.com>
> > > Cc: Stephen Hemminger <sthemmin@...rosoft.com>
> > > Cc: Stephen Hemminger <stephen@...workplumber.org>
> > > Cc: Sasha Levin <sashal@...nel.org>
> > > Cc: Bjorn Helgaas <bhelgaas@...gle.com>
> > > Cc: linux-pci@...r.kernel.org
> > > Cc: linux-hyperv@...r.kernel.org
> > > Cc: Dexuan Cui <decui@...rosoft.com>
> > > ---
> > > v3: corrected Fixes: tag [Dexuan Cui <decui@...rosoft.com>]
> > >     This is the Microsoft-preferred version of the patch.
> > > 
> > >  drivers/pci/Kconfig |    2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > 
> > > --- lnx-52.orig/drivers/pci/Kconfig
> > > +++ lnx-52/drivers/pci/Kconfig
> > > @@ -181,7 +181,7 @@ config PCI_LABEL
> > > 
> > >  config PCI_HYPERV
> > >          tristate "Hyper-V PCI Frontend"
> > > -        depends on X86 && HYPERV && PCI_MSI && PCI_MSI_IRQ_DOMAIN
> > > && X86_64
> > > +        depends on X86_64 && HYPERV && PCI_MSI &&
> > > PCI_MSI_IRQ_DOMAIN && SYSFS
> > >          help
> > >            The PCI device frontend driver allows the kernel to import arbitrary
> > >            PCI devices from a PCI backend to support PCI driver domains.
> > > 
> > 
> > Reviewed-by: Haiyang Zhang <haiyangz@...rosoft.com>
> 
> Queued up for hyperv-fixes, thank you!

What merge strategy do you envision for this?  Previous
drivers/pci/controller/pci-hyperv.c changes have generally been merged
by Lorenzo and incorporated into my PCI tree.

This particular patch doesn't actually touch pci-hyperv.c; it touches
drivers/pci/Kconfig, so should somehow be coordinated with me.

Does this need to be tagged for stable?  a15f2c08c708 appeared in
v4.19, so my first guess is that it's not stable material.

Bjorn

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ