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]
Message-ID: <20220721173733.GA1731649@bhelgaas>
Date:   Thu, 21 Jul 2022 12:37:33 -0500
From:   Bjorn Helgaas <helgaas@...nel.org>
To:     Stafford Horne <shorne@...il.com>
Cc:     LKML <linux-kernel@...r.kernel.org>, Arnd Bergmann <arnd@...db.de>,
        Pierre Morel <pmorel@...ux.ibm.com>,
        Geert Uytterhoeven <geert@...ux-m68k.org>,
        Catalin Marinas <catalin.marinas@....com>,
        Will Deacon <will@...nel.org>, Guo Ren <guoren@...nel.org>,
        Paul Walmsley <paul.walmsley@...ive.com>,
        Palmer Dabbelt <palmer@...belt.com>,
        Albert Ou <aou@...s.berkeley.edu>,
        Richard Weinberger <richard@....at>,
        Anton Ivanov <anton.ivanov@...bridgegreys.com>,
        Johannes Berg <johannes@...solutions.net>,
        Bjorn Helgaas <bhelgaas@...gle.com>,
        "Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
        linux-arm-kernel@...ts.infradead.org, linux-csky@...r.kernel.org,
        linux-riscv@...ts.infradead.org, linux-um@...ts.infradead.org,
        linux-pci@...r.kernel.org, linux-arch@...r.kernel.org
Subject: Re: [PATCH v5 4/4] asm-generic: Add new pci.h and use it

On Thu, Jul 21, 2022 at 10:49:24PM +0900, Stafford Horne wrote:
> The asm/pci.h used for many newer architectures share similar
> definitions.  Move the common parts to asm-generic/pci.h to allow for
> sharing code.
> 
> Suggested-by: Arnd Bergmann <arnd@...db.de>
> Link: https://lore.kernel.org/lkml/CAK8P3a0JmPeczfmMBE__vn=Jbvf=nkbpVaZCycyv40pZNCJJXQ@mail.gmail.com/
> Acked-by: Pierre Morel <pmorel@...ux.ibm.com>
> Acked-by: Geert Uytterhoeven <geert@...ux-m68k.org>
> Reviewed-by: Arnd Bergmann <arnd@...db.de>
> Signed-off-by: Stafford Horne <shorne@...il.com>
> ---
> Since v4:
>  - Add reviewed-by
> 
>  arch/arm64/include/asm/pci.h | 10 ++--------
>  arch/csky/include/asm/pci.h  | 17 ++---------------
>  arch/riscv/include/asm/pci.h | 23 ++++-------------------
>  arch/um/include/asm/pci.h    | 14 ++------------
>  include/asm-generic/pci.h    | 32 ++++++++++++++++++++++++++++++++
>  5 files changed, 42 insertions(+), 54 deletions(-)
>  create mode 100644 include/asm-generic/pci.h

> +++ b/include/asm-generic/pci.h
> @@ -0,0 +1,32 @@
> +/* SPDX-License-Identifier: GPL-2.0-only */
> +
> +#ifndef __ASM_GENERIC_PCI_H
> +#define __ASM_GENERIC_PCI_H
> +
> +#include <linux/types.h>

Do we need <linux/types.h> here?  I don't see anything below that
depends on it.

> +#ifndef PCIBIOS_MIN_IO
> +#define PCIBIOS_MIN_IO		0
> +#endif
> +
> +#ifndef PCIBIOS_MIN_MEM
> +#define PCIBIOS_MIN_MEM		0
> +#endif
> +
> +#ifndef pcibios_assign_all_busses
> +/* For bootloaders that do not initialize the PCI bus */
> +#define pcibios_assign_all_busses() 1
> +#endif
> +
> +/* Enable generic resource mapping code in drivers/pci/ */
> +#define ARCH_GENERIC_PCI_MMAP_RESOURCE
> +
> +#ifdef CONFIG_PCI_DOMAINS
> +static inline int pci_proc_domain(struct pci_bus *bus)
> +{
> +	/* always show the domain in /proc */
> +	return 1;
> +}
> +#endif /* CONFIG_PCI_DOMAINS */
> +
> +#endif /* __ASM_GENERIC_PCI_H */
> -- 
> 2.36.1
> 
> 
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@...ts.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ