All of lore.kernel.org
 help / color / mirror / Atom feed
From: Helge Deller <deller@gmx.de>
To: gregkh@linuxfoundation.org,
	James.Bottomley@hansenpartnership.com, arnd@arndb.de,
	krypton@ulrich-teichert.org, linux@roeck-us.net,
	torvalds@linux-foundation.org, stable <stable@vger.kernel.org>
Cc: stable-commits@vger.kernel.org
Subject: Re: Patch "parisc: Declare pci_iounmap() parisc version only when CONFIG_PCI enabled" has been added to the 4.9-stable tree
Date: Mon, 20 Sep 2021 10:43:10 +0200	[thread overview]
Message-ID: <f64c47bf-9426-73d9-a0b5-e2b8b5e2bf80@gmx.de> (raw)
In-Reply-To: <163212635420164@kroah.com>

On 9/20/21 10:25 AM, gregkh@linuxfoundation.org wrote:
>
> This is a note to let you know that I've just added the patch titled
>
>      parisc: Declare pci_iounmap() parisc version only when CONFIG_PCI enabled
>
> to the 4.9-stable tree which can be found at:
>      http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
>
> The filename of the patch is:
>       parisc-declare-pci_iounmap-parisc-version-only-when-config_pci-enabled.patch
> and it can be found in the queue-4.9 subdirectory.
>
> If you, or anyone else, feels it should not be added to the stable tree,
> please let <stable@vger.kernel.org> know about it.


No, please don't add it to any stable tree yet.
This patch was applied by Linus in order to fix build errors on the alpha
architecture, but it triggers build errors on arm64 (and maybe other arches).
The whole issue is still being analyzed, as visible in e.g. this commit:

316e8d79a0959c302b0c462ab64b069599f10eef
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Sun Sep 19 17:13:35 2021 -0700
     pci_iounmap'2: Electric Boogaloo: try to make sense of it all


Helge





>
>
>  From 9caea0007601d3bc6debec04f8b4cd6f4c2394be Mon Sep 17 00:00:00 2001
> From: Helge Deller <deller@gmx.de>
> Date: Sun, 19 Sep 2021 10:36:09 -0700
> Subject: parisc: Declare pci_iounmap() parisc version only when CONFIG_PCI enabled
>
> From: Helge Deller <deller@gmx.de>
>
> commit 9caea0007601d3bc6debec04f8b4cd6f4c2394be upstream.
>
> Linus noticed odd declaration rules for pci_iounmap() in iomap.h and
> pci_iomap.h, where it dependend on either NO_GENERIC_PCI_IOPORT_MAP or
> GENERIC_IOMAP when CONFIG_PCI was disabled.
>
> Testing on parisc seems to indicate that we need pci_iounmap() only when
> CONFIG_PCI is enabled, so the declaration of pci_iounmap() can be moved
> cleanly into pci_iomap.h in sync with the declarations of pci_iomap().
>
> Link: https://lore.kernel.org/all/CAHk-=wjRrh98pZoQ+AzfWmsTZacWxTJKXZ9eKU2X_0+jM=O8nw@mail.gmail.com/
> Signed-off-by: Helge Deller <deller@gmx.de>
> Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
> Fixes: 97a29d59fc22 ("[PARISC] fix compile break caused by iomap: make IOPORT/PCI mapping functions conditional")
> Cc: Arnd Bergmann <arnd@arndb.de>
> Cc: Guenter Roeck <linux@roeck-us.net>
> Cc: Ulrich Teichert <krypton@ulrich-teichert.org>
> Cc: James Bottomley <James.Bottomley@hansenpartnership.com>
> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> ---
>   arch/parisc/lib/iomap.c         |    4 +++-
>   include/asm-generic/iomap.h     |   10 ----------
>   include/asm-generic/pci_iomap.h |    3 +++
>   3 files changed, 6 insertions(+), 11 deletions(-)
>
> --- a/arch/parisc/lib/iomap.c
> +++ b/arch/parisc/lib/iomap.c
> @@ -436,12 +436,15 @@ void ioport_unmap(void __iomem *addr)
>   	}
>   }
>
> +#ifdef CONFIG_PCI
>   void pci_iounmap(struct pci_dev *dev, void __iomem * addr)
>   {
>   	if (!INDIRECT_ADDR(addr)) {
>   		iounmap(addr);
>   	}
>   }
> +EXPORT_SYMBOL(pci_iounmap);
> +#endif
>
>   EXPORT_SYMBOL(ioread8);
>   EXPORT_SYMBOL(ioread16);
> @@ -461,4 +464,3 @@ EXPORT_SYMBOL(iowrite16_rep);
>   EXPORT_SYMBOL(iowrite32_rep);
>   EXPORT_SYMBOL(ioport_map);
>   EXPORT_SYMBOL(ioport_unmap);
> -EXPORT_SYMBOL(pci_iounmap);
> --- a/include/asm-generic/iomap.h
> +++ b/include/asm-generic/iomap.h
> @@ -78,16 +78,6 @@ extern void ioport_unmap(void __iomem *)
>   #define ioremap_wt ioremap_nocache
>   #endif
>
> -#ifdef CONFIG_PCI
> -/* Destroy a virtual mapping cookie for a PCI BAR (memory or IO) */
> -struct pci_dev;
> -extern void pci_iounmap(struct pci_dev *dev, void __iomem *);
> -#elif defined(CONFIG_GENERIC_IOMAP)
> -struct pci_dev;
> -static inline void pci_iounmap(struct pci_dev *dev, void __iomem *addr)
> -{ }
> -#endif
> -
>   #include <asm-generic/pci_iomap.h>
>
>   #endif
> --- a/include/asm-generic/pci_iomap.h
> +++ b/include/asm-generic/pci_iomap.h
> @@ -22,6 +22,7 @@ extern void __iomem *pci_iomap_range(str
>   extern void __iomem *pci_iomap_wc_range(struct pci_dev *dev, int bar,
>   					unsigned long offset,
>   					unsigned long maxlen);
> +extern void pci_iounmap(struct pci_dev *dev, void __iomem *);
>   /* Create a virtual mapping cookie for a port on a given PCI device.
>    * Do not call this directly, it exists to make it easier for architectures
>    * to override */
> @@ -54,6 +55,8 @@ static inline void __iomem *pci_iomap_wc
>   {
>   	return NULL;
>   }
> +static inline void pci_iounmap(struct pci_dev *dev, void __iomem *addr)
> +{ }
>   #endif
>
>   #endif /* __ASM_GENERIC_IO_H */
>
>
> Patches currently in stable-queue which might be from deller@gmx.de are
>
> queue-4.9/parisc-declare-pci_iounmap-parisc-version-only-when-config_pci-enabled.patch
> queue-4.9/parisc-fix-crash-with-signals-and-alloca.patch
>


           reply	other threads:[~2021-09-20  8:43 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <163212635420164@kroah.com>]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f64c47bf-9426-73d9-a0b5-e2b8b5e2bf80@gmx.de \
    --to=deller@gmx.de \
    --cc=James.Bottomley@hansenpartnership.com \
    --cc=arnd@arndb.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=krypton@ulrich-teichert.org \
    --cc=linux@roeck-us.net \
    --cc=stable-commits@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.