2020-11-14 13:20:49

by Jiaxun Yang

[permalink] [raw]
Subject: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

Goldfish platform is covered with dust.
However the goldfish-rtc had been used as virtualized RTC
in QEMU for RISC-V virt hw and MIPS loongson3-virt hw, thus
we can drop other parts of goldfish but leave goldfish-rtc here.

Signed-off-by: Jiaxun Yang <[email protected]>
---
drivers/rtc/Kconfig | 1 -
1 file changed, 1 deletion(-)

diff --git a/drivers/rtc/Kconfig b/drivers/rtc/Kconfig
index 65ad9d0b47ab..f784b52381b1 100644
--- a/drivers/rtc/Kconfig
+++ b/drivers/rtc/Kconfig
@@ -1935,7 +1935,6 @@ config RTC_DRV_HID_SENSOR_TIME
config RTC_DRV_GOLDFISH
tristate "Goldfish Real Time Clock"
depends on OF && HAS_IOMEM
- depends on GOLDFISH || COMPILE_TEST
help
Say yes to enable RTC driver for the Goldfish based virtual platform.

--
2.29.2


2021-01-04 13:30:57

by Geert Uytterhoeven

[permalink] [raw]
Subject: Re: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

Hi Jiaxun,

On Sat, Nov 14, 2020 at 2:20 PM Jiaxun Yang <[email protected]> wrote:
> Goldfish platform is covered with dust.
> However the goldfish-rtc had been used as virtualized RTC
> in QEMU for RISC-V virt hw and MIPS loongson3-virt hw, thus
> we can drop other parts of goldfish but leave goldfish-rtc here.
>
> Signed-off-by: Jiaxun Yang <[email protected]>

Thanks for your patch!

> --- a/drivers/rtc/Kconfig
> +++ b/drivers/rtc/Kconfig
> @@ -1935,7 +1935,6 @@ config RTC_DRV_HID_SENSOR_TIME
> config RTC_DRV_GOLDFISH
> tristate "Goldfish Real Time Clock"
> depends on OF && HAS_IOMEM
> - depends on GOLDFISH || COMPILE_TEST
> help
> Say yes to enable RTC driver for the Goldfish based virtual platform.

I was just looking to see if someone had already sent a patch to add
"depends on GOLDFISH || COMPILE_TEST", before sending one myself, when I
noticed your patch had removed it...

What about

depends on CPU_LOONGSON64 || GOLDFISH || RISCV || COMPILE_TEST

instead?

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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

2021-01-04 14:51:37

by Alexandre Belloni

[permalink] [raw]
Subject: Re: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

Hi Geert,

On 04/01/2021 14:28:26+0100, Geert Uytterhoeven wrote:
> Hi Jiaxun,
>
> On Sat, Nov 14, 2020 at 2:20 PM Jiaxun Yang <[email protected]> wrote:
> > Goldfish platform is covered with dust.
> > However the goldfish-rtc had been used as virtualized RTC
> > in QEMU for RISC-V virt hw and MIPS loongson3-virt hw, thus
> > we can drop other parts of goldfish but leave goldfish-rtc here.
> >
> > Signed-off-by: Jiaxun Yang <[email protected]>
>
> Thanks for your patch!
>
> > --- a/drivers/rtc/Kconfig
> > +++ b/drivers/rtc/Kconfig
> > @@ -1935,7 +1935,6 @@ config RTC_DRV_HID_SENSOR_TIME
> > config RTC_DRV_GOLDFISH
> > tristate "Goldfish Real Time Clock"
> > depends on OF && HAS_IOMEM
> > - depends on GOLDFISH || COMPILE_TEST
> > help
> > Say yes to enable RTC driver for the Goldfish based virtual platform.
>
> I was just looking to see if someone had already sent a patch to add
> "depends on GOLDFISH || COMPILE_TEST", before sending one myself, when I
> noticed your patch had removed it...
>
> What about
>
> depends on CPU_LOONGSON64 || GOLDFISH || RISCV || COMPILE_TEST
>
> instead?
>

But this driver also works on ARM, is it really important to restrict to
a few architectures ?

--
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

2021-01-04 15:25:01

by Geert Uytterhoeven

[permalink] [raw]
Subject: Re: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

Hi Alexandre,

On Mon, Jan 4, 2021 at 3:48 PM Alexandre Belloni
<[email protected]> wrote:
> On 04/01/2021 14:28:26+0100, Geert Uytterhoeven wrote:
> > On Sat, Nov 14, 2020 at 2:20 PM Jiaxun Yang <[email protected]> wrote:
> > > Goldfish platform is covered with dust.
> > > However the goldfish-rtc had been used as virtualized RTC
> > > in QEMU for RISC-V virt hw and MIPS loongson3-virt hw, thus
> > > we can drop other parts of goldfish but leave goldfish-rtc here.
> > >
> > > Signed-off-by: Jiaxun Yang <[email protected]>
> >
> > Thanks for your patch!
> >
> > > --- a/drivers/rtc/Kconfig
> > > +++ b/drivers/rtc/Kconfig
> > > @@ -1935,7 +1935,6 @@ config RTC_DRV_HID_SENSOR_TIME
> > > config RTC_DRV_GOLDFISH
> > > tristate "Goldfish Real Time Clock"
> > > depends on OF && HAS_IOMEM
> > > - depends on GOLDFISH || COMPILE_TEST
> > > help
> > > Say yes to enable RTC driver for the Goldfish based virtual platform.
> >
> > I was just looking to see if someone had already sent a patch to add
> > "depends on GOLDFISH || COMPILE_TEST", before sending one myself, when I
> > noticed your patch had removed it...
> >
> > What about
> >
> > depends on CPU_LOONGSON64 || GOLDFISH || RISCV || COMPILE_TEST
> >
> > instead?
> >
>
> But this driver also works on ARM, is it really important to restrict to
> a few architectures ?

Is it used on ARM platforms?
qemu:hw/riscv/Kconfig selects GOLDFISH_RTC, but that's it?

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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

2021-01-04 15:47:18

by Alexandre Belloni

[permalink] [raw]
Subject: Re: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

On 04/01/2021 16:21:31+0100, Geert Uytterhoeven wrote:
> Hi Alexandre,
>
> On Mon, Jan 4, 2021 at 3:48 PM Alexandre Belloni
> <[email protected]> wrote:
> > On 04/01/2021 14:28:26+0100, Geert Uytterhoeven wrote:
> > > On Sat, Nov 14, 2020 at 2:20 PM Jiaxun Yang <[email protected]> wrote:
> > > > Goldfish platform is covered with dust.
> > > > However the goldfish-rtc had been used as virtualized RTC
> > > > in QEMU for RISC-V virt hw and MIPS loongson3-virt hw, thus
> > > > we can drop other parts of goldfish but leave goldfish-rtc here.
> > > >
> > > > Signed-off-by: Jiaxun Yang <[email protected]>
> > >
> > > Thanks for your patch!
> > >
> > > > --- a/drivers/rtc/Kconfig
> > > > +++ b/drivers/rtc/Kconfig
> > > > @@ -1935,7 +1935,6 @@ config RTC_DRV_HID_SENSOR_TIME
> > > > config RTC_DRV_GOLDFISH
> > > > tristate "Goldfish Real Time Clock"
> > > > depends on OF && HAS_IOMEM
> > > > - depends on GOLDFISH || COMPILE_TEST
> > > > help
> > > > Say yes to enable RTC driver for the Goldfish based virtual platform.
> > >
> > > I was just looking to see if someone had already sent a patch to add
> > > "depends on GOLDFISH || COMPILE_TEST", before sending one myself, when I
> > > noticed your patch had removed it...
> > >
> > > What about
> > >
> > > depends on CPU_LOONGSON64 || GOLDFISH || RISCV || COMPILE_TEST
> > >
> > > instead?
> > >
> >
> > But this driver also works on ARM, is it really important to restrict to
> > a few architectures ?
>
> Is it used on ARM platforms?
> qemu:hw/riscv/Kconfig selects GOLDFISH_RTC, but that's it?
>

My understanding is that this was used on the original ARM based goldfish
android emulator but I don't think this was ever upstreamed.


--
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

2021-01-04 15:55:34

by Geert Uytterhoeven

[permalink] [raw]
Subject: Re: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

Hi Alexandre,

On Mon, Jan 4, 2021 at 4:43 PM Alexandre Belloni
<[email protected]> wrote:
> On 04/01/2021 16:21:31+0100, Geert Uytterhoeven wrote:
> > On Mon, Jan 4, 2021 at 3:48 PM Alexandre Belloni
> > <[email protected]> wrote:
> > > On 04/01/2021 14:28:26+0100, Geert Uytterhoeven wrote:
> > > > On Sat, Nov 14, 2020 at 2:20 PM Jiaxun Yang <[email protected]> wrote:
> > > > > Goldfish platform is covered with dust.
> > > > > However the goldfish-rtc had been used as virtualized RTC
> > > > > in QEMU for RISC-V virt hw and MIPS loongson3-virt hw, thus
> > > > > we can drop other parts of goldfish but leave goldfish-rtc here.
> > > > >
> > > > > Signed-off-by: Jiaxun Yang <[email protected]>
> > > >
> > > > Thanks for your patch!
> > > >
> > > > > --- a/drivers/rtc/Kconfig
> > > > > +++ b/drivers/rtc/Kconfig
> > > > > @@ -1935,7 +1935,6 @@ config RTC_DRV_HID_SENSOR_TIME
> > > > > config RTC_DRV_GOLDFISH
> > > > > tristate "Goldfish Real Time Clock"
> > > > > depends on OF && HAS_IOMEM
> > > > > - depends on GOLDFISH || COMPILE_TEST
> > > > > help
> > > > > Say yes to enable RTC driver for the Goldfish based virtual platform.
> > > >
> > > > I was just looking to see if someone had already sent a patch to add
> > > > "depends on GOLDFISH || COMPILE_TEST", before sending one myself, when I
> > > > noticed your patch had removed it...
> > > >
> > > > What about
> > > >
> > > > depends on CPU_LOONGSON64 || GOLDFISH || RISCV || COMPILE_TEST
> > > >
> > > > instead?
> > > >
> > >
> > > But this driver also works on ARM, is it really important to restrict to
> > > a few architectures ?
> >
> > Is it used on ARM platforms?
> > qemu:hw/riscv/Kconfig selects GOLDFISH_RTC, but that's it?
>
> My understanding is that this was used on the original ARM based goldfish
> android emulator but I don't think this was ever upstreamed.

Upstream indeed only has GOLDFISH support in arch/x86/Kconfig.
Still, that would be handled by the dependency on GOLDFISH.

Or do you mean upstream QEMU Goldfish support?

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

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

2021-01-06 13:28:35

by Alexandre Belloni

[permalink] [raw]
Subject: Re: [PATCH 1/2] rtc: goldfish: Remove GOLDFISH dependency

On 04/01/2021 16:51:40+0100, Geert Uytterhoeven wrote:
> > > Is it used on ARM platforms?
> > > qemu:hw/riscv/Kconfig selects GOLDFISH_RTC, but that's it?
> >
> > My understanding is that this was used on the original ARM based goldfish
> > android emulator but I don't think this was ever upstreamed.
>
> Upstream indeed only has GOLDFISH support in arch/x86/Kconfig.
> Still, that would be handled by the dependency on GOLDFISH.
>
> Or do you mean upstream QEMU Goldfish support?
>

Yes, I meant upstream in QEMU. If I refer to the doc from google:

'goldfish' is the name of a family of similar virtual hardware platforms, that
mostly differ in the virtual CPU they support. 'goldfish' started as an
ARM-specific platform, but has now been ported to x86 and MIPS virtual CPUs.

Goldfish was based on QEMU 0.8.2, they then moved to ranchu, this time
on a more upstream QEMU but I don't think this is upstream either.


--
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com