linux-m68k.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Ungerer <gerg@linux-m68k.org>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Linux/m68k <linux-m68k@vger.kernel.org>
Subject: Re: [PATCH v2 1/5] m68k: common PCI support definitions and code
Date: Mon, 28 Jun 2021 23:58:12 +1000	[thread overview]
Message-ID: <02eedc6b-e346-f8f4-ac1d-4d7d4a7c638c@linux-m68k.org> (raw)
In-Reply-To: <CAMuHMdX5vn87B=-pm8puECC74bog4YM6Uf2vY4mondntzSg65Q@mail.gmail.com>

Hi Geert,

On 28/6/21 11:29 pm, Geert Uytterhoeven wrote:
> Hi Greg,
> 
> On Mon, Jun 28, 2021 at 3:23 PM Greg Ungerer <gerg@linux-m68k.org> wrote:
>> On 28/6/21 5:44 pm, Geert Uytterhoeven wrote:
>>> On Mon, Jul 16, 2012 at 2:25 PM <gerg@snapgear.com> wrote:
>>>> From: Greg Ungerer <gerg@uclinux.org>
>>>>
>>>> Basic set of definitions and support code required to turn on CONFIG_PCI
>>>> for the m68k architecture. Nothing specific to any PCI implementation in
>>>> any m68k class CPU hardware yet.
>>>>
>>>> Signed-off-by: Greg Ungerer <gerg@uclinux.org>
>>>
>>>> --- a/arch/m68k/include/asm/io_mm.h
>>>> +++ b/arch/m68k/include/asm/io_mm.h
>>>> @@ -340,4 +340,6 @@ static inline void memcpy_toio(volatile void __iomem *dst, const void *src, int
>>>>     */
>>>>    #define xlate_dev_kmem_ptr(p)  p
>>>>
>>>> +#define ioport_map(port, nr)   ((void __iomem *)(port))
>>>
>>> So should we dop:
>>>
>>>       config NO_IOPORT_MAP
>>>               def_bool y
>>>
>>> Triggered by seeing CONFIG_GPIO_TQMX86 being removed from allmodconfig
>>> builds due to commit c6414e1a2bd26b00 ("gpio: AMD8111 and TQMX86
>>> require HAS_IOPORT_MAP").
>>
>> I guess we could.
>> But we would have to remove the iomap/iounmap definitions in kmap.h too right?
> 
> Why? Do I need more coffee?

If you do this:

diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
index 372e4e69c43a..a6d4b2b1fe5a 100644
--- a/arch/m68k/Kconfig
+++ b/arch/m68k/Kconfig
@@ -59,9 +59,6 @@ config TIME_LOW_RES
         bool
         default y
  
-config NO_IOPORT_MAP
-       def_bool y
-
  config ZONE_DMA
         bool
         default y


And the compile for an M5475 target for example you get this:

   CC      lib/strncpy_from_user.o
In file included from ./arch/m68k/include/asm/io_no.h:134,
                  from ./arch/m68k/include/asm/io.h:6,
                  from ./include/linux/io.h:13,
                  from ./include/linux/irq.h:20,
                  from ./include/asm-generic/hardirq.h:17,
                  from ./arch/m68k/include/generated/asm/hardirq.h:1,
                  from ./include/linux/hardirq.h:11,
                  from ./include/linux/interrupt.h:11,
                  from ./include/linux/pci.h:38,
                  from lib/iomap.c:7:
./arch/m68k/include/asm/kmap.h:61:20: error: redefinition of ‘ioport_map’
  #define ioport_map ioport_map
                     ^~~~~~~~~~
lib/iomap.c:362:15: note: in expansion of macro ‘ioport_map’
  void __iomem *ioport_map(unsigned long port, unsigned int nr)
                ^~~~~~~~~~
./arch/m68k/include/asm/kmap.h:61:20: note: previous definition of ‘ioport_map’ was here
  #define ioport_map ioport_map
                     ^~~~~~~~~~
./arch/m68k/include/asm/kmap.h:62:29: note: in expansion of macro ‘ioport_map’
  static inline void __iomem *ioport_map(unsigned long port, unsigned int nr)
                              ^~~~~~~~~~
./arch/m68k/include/asm/kmap.h:67:22: error: redefinition of ‘ioport_unmap’
  #define ioport_unmap ioport_unmap
                       ^~~~~~~~~~~~
lib/iomap.c:369:6: note: in expansion of macro ‘ioport_unmap’
  void ioport_unmap(void __iomem *addr)
       ^~~~~~~~~~~~
./arch/m68k/include/asm/kmap.h:67:22: note: previous definition of ‘ioport_unmap’ was here
  #define ioport_unmap ioport_unmap
                       ^~~~~~~~~~~~
./arch/m68k/include/asm/kmap.h:68:20: note: in expansion of macro ‘ioport_unmap’
  static inline void ioport_unmap(void __iomem *p)
                     ^~~~~~~~~~~~

Regards
Greg

  reply	other threads:[~2021-06-28 13:58 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-16 12:27 [PATCH v2 0/5] ColdFire PCI bus support gerg
2012-07-16 12:27 ` [PATCH v2 1/5] m68k: common PCI support definitions and code gerg
2021-06-28  7:44   ` Geert Uytterhoeven
2021-06-28 13:23     ` Greg Ungerer
2021-06-28 13:29       ` Geert Uytterhoeven
2021-06-28 13:58         ` Greg Ungerer [this message]
2012-07-16 12:27 ` [PATCH v2 2/5] m68k: add PCI bus support definitions for the ColdFire M54xx SoC family gerg
2012-07-16 12:27 ` [PATCH v2 3/5] m68k: add IO access definitions to support PCI on ColdFire platforms gerg
2012-07-16 12:27 ` [PATCH v2 4/5] m68k: add PCI bus code support for the ColdFire M54xx SoC family gerg
2012-07-16 12:27 ` [PATCH v2 5/5] m68k: allow PCI bus to be enabled for ColdFire m54xx CPUs gerg

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=02eedc6b-e346-f8f4-ac1d-4d7d4a7c638c@linux-m68k.org \
    --to=gerg@linux-m68k.org \
    --cc=geert@linux-m68k.org \
    --cc=linux-m68k@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).