Re: [PATCH v10 2/5] rtc: goldfish: introduce goldfish_ioread32()/goldfish_iowrite32()

From
Geert Uytterhoeven <geert@linux-m68k.org>
Date
2022-01-19 09:58:52
Also in
linux-m68k, lkml
Reply to
Laurent Vivier, 2022-01-19
Hi Laurent,

On Wed, Jan 19, 2022 at 10:11 AM Laurent Vivier [off-list ref] wrote:
Le 19/01/2022 à 09:49, Arnd Bergmann a écrit :
quoted
On Wed, Jan 19, 2022 at 9:21 AM Geert Uytterhoeven [off-list ref] wrote:
quoted
On Wed, Jan 19, 2022 at 1:05 AM Laurent Vivier [off-list ref] wrote:

I've just discovered include/linux/goldfish.h, which already has gf_*()
accessors for 64-bit, so it'd make sense to move the above there,
and adjust the names.
Yes, good idea.
So the idea is to put goldfish accessors inside a "#ifdef CONFIG_M68K ... #else ... #endif" in
include/linux/goldfish.h and not in generic-asm/io.h for the generic version and
m68k/include/ams/io.h for the m68k version?
No, just move

+#ifndef goldfish_ioread32
+#define goldfish_ioread32 ioread32
+#endif
+#ifndef goldfish_iowrite32
+#define goldfish_iowrite32 iowrite32
+#endif

to <linux/goldfish.h>, and rename them to gf_*().

Architectures can still override them in their own <asm/io.h>
(<linux/goldfish.h> includes <linux/io.h>).

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds
Thread (10 messages) 10 messages, 3 authors, last reply 2022-01-19
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help