* Re: [PATCH v7 15/24] alpha/PCI: Remove WARN from __pci_mmap_fits() and __legacy_mmap_fits() [not found] ` <20260508045452.15B72C2BCB0@smtp.kernel.org> @ 2026-05-08 5:04 ` Krzysztof Wilczyński 2026-05-08 23:07 ` Bjorn Helgaas 0 siblings, 1 reply; 3+ messages in thread From: Krzysztof Wilczyński @ 2026-05-08 5:04 UTC (permalink / raw) To: sashiko; +Cc: linux-pci Hello, > > static int __legacy_mmap_fits(struct pci_controller *hose, > > struct vm_area_struct *vma, > > - unsigned long res_size, int sparse) > > + unsigned long res_size) > > This isn't a bug, but since the WARN() statement that used hose->index was > removed below, is the hose parameter still needed? It appears to be completely > unused in the function body now. Ah, yes, darn. Forgot to remove this one, too. A quick fix: diff --git i/arch/alpha/kernel/pci-sysfs.c w/arch/alpha/kernel/pci-sysfs.c index 7dae4999c5e3..94dbc470cd6c 100644 --- i/arch/alpha/kernel/pci-sysfs.c +++ w/arch/alpha/kernel/pci-sysfs.c @@ -143,8 +143,7 @@ static int sparse_mem_mmap_fits(struct pci_dev *pdev, int num) /* Legacy I/O bus mapping stuff. */ -static int __legacy_mmap_fits(struct pci_controller *hose, - struct vm_area_struct *vma, +static int __legacy_mmap_fits(struct vm_area_struct *vma, unsigned long res_size) { unsigned long nr, start, size; @@ -179,7 +178,7 @@ int pci_mmap_legacy_page_range(struct pci_bus *bus, struct vm_area_struct *vma, if (sparse) res_size <<= 5; - if (!__legacy_mmap_fits(hose, vma, res_size)) + if (!__legacy_mmap_fits(vma, res_size)) return -EINVAL; return hose_mmap_page_range(hose, vma, mmap_type, sparse); Which can be applied/squashed later. Thank you! Krzysztof ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH v7 15/24] alpha/PCI: Remove WARN from __pci_mmap_fits() and __legacy_mmap_fits() 2026-05-08 5:04 ` [PATCH v7 15/24] alpha/PCI: Remove WARN from __pci_mmap_fits() and __legacy_mmap_fits() Krzysztof Wilczyński @ 2026-05-08 23:07 ` Bjorn Helgaas 2026-05-11 7:14 ` Krzysztof Wilczyński 0 siblings, 1 reply; 3+ messages in thread From: Bjorn Helgaas @ 2026-05-08 23:07 UTC (permalink / raw) To: Krzysztof Wilczyński; +Cc: sashiko, linux-pci On Fri, May 08, 2026 at 02:04:57PM +0900, Krzysztof Wilczyński wrote: > Hello, > > > > static int __legacy_mmap_fits(struct pci_controller *hose, > > > struct vm_area_struct *vma, > > > - unsigned long res_size, int sparse) > > > + unsigned long res_size) > > > > This isn't a bug, but since the WARN() statement that used hose->index was > > removed below, is the hose parameter still needed? It appears to be completely > > unused in the function body now. > > Ah, yes, darn. Forgot to remove this one, too. A quick fix: I squashed this in, but you should double-check it because it didn't apply cleanly. > diff --git i/arch/alpha/kernel/pci-sysfs.c w/arch/alpha/kernel/pci-sysfs.c > index 7dae4999c5e3..94dbc470cd6c 100644 > --- i/arch/alpha/kernel/pci-sysfs.c > +++ w/arch/alpha/kernel/pci-sysfs.c > @@ -143,8 +143,7 @@ static int sparse_mem_mmap_fits(struct pci_dev *pdev, int num) > > /* Legacy I/O bus mapping stuff. */ > > -static int __legacy_mmap_fits(struct pci_controller *hose, > - struct vm_area_struct *vma, > +static int __legacy_mmap_fits(struct vm_area_struct *vma, > unsigned long res_size) > { > unsigned long nr, start, size; > @@ -179,7 +178,7 @@ int pci_mmap_legacy_page_range(struct pci_bus *bus, struct vm_area_struct *vma, > if (sparse) > res_size <<= 5; > > - if (!__legacy_mmap_fits(hose, vma, res_size)) > + if (!__legacy_mmap_fits(vma, res_size)) > return -EINVAL; > > return hose_mmap_page_range(hose, vma, mmap_type, sparse); > > Which can be applied/squashed later. > > Thank you! > > Krzysztof ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH v7 15/24] alpha/PCI: Remove WARN from __pci_mmap_fits() and __legacy_mmap_fits() 2026-05-08 23:07 ` Bjorn Helgaas @ 2026-05-11 7:14 ` Krzysztof Wilczyński 0 siblings, 0 replies; 3+ messages in thread From: Krzysztof Wilczyński @ 2026-05-11 7:14 UTC (permalink / raw) To: Bjorn Helgaas; +Cc: sashiko, linux-pci Hello, > > > > static int __legacy_mmap_fits(struct pci_controller *hose, > > > > struct vm_area_struct *vma, > > > > - unsigned long res_size, int sparse) > > > > + unsigned long res_size) > > > > > > This isn't a bug, but since the WARN() statement that used hose->index was > > > removed below, is the hose parameter still needed? It appears to be completely > > > unused in the function body now. > > > > Ah, yes, darn. Forgot to remove this one, too. A quick fix: > > I squashed this in, but you should double-check it because it didn't > apply cleanly. Looks good! Thank you! Krzysztof ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-05-11 7:14 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20260508043543.217179-16-kwilczynski@kernel.org>
[not found] ` <20260508045452.15B72C2BCB0@smtp.kernel.org>
2026-05-08 5:04 ` [PATCH v7 15/24] alpha/PCI: Remove WARN from __pci_mmap_fits() and __legacy_mmap_fits() Krzysztof Wilczyński
2026-05-08 23:07 ` Bjorn Helgaas
2026-05-11 7:14 ` Krzysztof Wilczyński
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox