diff mbox

[9/9] ARM: multi_v7_defconfig: Enable DMA for Renesas serial ports

Message ID 1499693302-25120-10-git-send-email-geert+renesas@glider.be (mailing list archive)
State Accepted
Commit 52078ca712cd933844721aaa700b3bd85234841f
Delegated to: Simon Horman
Headers show

Commit Message

Geert Uytterhoeven July 10, 2017, 1:28 p.m. UTC
DMA for (H)SCIF(A|B) serial ports on Renesas R-Car Gen2 and RZ/G1 SoCs
is considered stable, hence enable it by default.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
 arch/arm/configs/multi_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

Comments

Magnus Damm July 11, 2017, 3:38 a.m. UTC | #1
Hi Geert,

On Mon, Jul 10, 2017 at 10:28 PM, Geert Uytterhoeven
<geert+renesas@glider.be> wrote:
> DMA for (H)SCIF(A|B) serial ports on Renesas R-Car Gen2 and RZ/G1 SoCs
> is considered stable, hence enable it by default.
>
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
> ---
>  arch/arm/configs/multi_v7_defconfig | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
> index ea2075d8e185f7aa..072a455008df9751 100644
> --- a/arch/arm/configs/multi_v7_defconfig
> +++ b/arch/arm/configs/multi_v7_defconfig
> @@ -330,6 +330,7 @@ CONFIG_SERIAL_IMX_CONSOLE=y
>  CONFIG_SERIAL_SH_SCI=y
>  CONFIG_SERIAL_SH_SCI_NR_UARTS=20
>  CONFIG_SERIAL_SH_SCI_CONSOLE=y
> +CONFIG_SERIAL_SH_SCI_DMA=y
>  CONFIG_SERIAL_MSM=y
>  CONFIG_SERIAL_MSM_CONSOLE=y
>  CONFIG_SERIAL_VT8500=y

Thanks, FWIW I'm very happy to see DMA enabled for the SCIF driver in mainline.

Since enabling DMA Engine still keeps PIO support around I wonder why
we need this Kconfig at all - other drivers seem to get by without
this kind of thing?
So in my opinion it would also be nice to get rid of SERIAL_SH_SCI_DMA
completely and reducing the number of special per-driver Kconfig
entries.

Cheers,

/ magnus
Geert Uytterhoeven July 11, 2017, 6:59 a.m. UTC | #2
Hi Magnus,

On Tue, Jul 11, 2017 at 5:38 AM, Magnus Damm <magnus.damm@gmail.com> wrote:
> On Mon, Jul 10, 2017 at 10:28 PM, Geert Uytterhoeven
> <geert+renesas@glider.be> wrote:
>> DMA for (H)SCIF(A|B) serial ports on Renesas R-Car Gen2 and RZ/G1 SoCs
>> is considered stable, hence enable it by default.
>>
>> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
>> ---
>>  arch/arm/configs/multi_v7_defconfig | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
>> index ea2075d8e185f7aa..072a455008df9751 100644
>> --- a/arch/arm/configs/multi_v7_defconfig
>> +++ b/arch/arm/configs/multi_v7_defconfig
>> @@ -330,6 +330,7 @@ CONFIG_SERIAL_IMX_CONSOLE=y
>>  CONFIG_SERIAL_SH_SCI=y
>>  CONFIG_SERIAL_SH_SCI_NR_UARTS=20
>>  CONFIG_SERIAL_SH_SCI_CONSOLE=y
>> +CONFIG_SERIAL_SH_SCI_DMA=y
>>  CONFIG_SERIAL_MSM=y
>>  CONFIG_SERIAL_MSM_CONSOLE=y
>>  CONFIG_SERIAL_VT8500=y
>
> Thanks, FWIW I'm very happy to see DMA enabled for the SCIF driver in mainline.
>
> Since enabling DMA Engine still keeps PIO support around I wonder why
> we need this Kconfig at all - other drivers seem to get by without
> this kind of thing?
> So in my opinion it would also be nice to get rid of SERIAL_SH_SCI_DMA
> completely and reducing the number of special per-driver Kconfig
> entries.

In general, I would agree, and remove the option at the blimp of an eye.
However, this driver is shared with H8/300 and SuperH.  While both could use
DMA (but it's not supported by Linux yet), I don't know if they are willing to
live with the increased static and dynamic memory footprint of SH_SCI DMA
support.

Whether we want to hide the option (and default to y if ARCH_RENESAS, i.e.
ARM) is another question.  Note that that wouldn't reduce code maintainability,
as the #ifdefs would be kept, and it would prevent building and testing
with/without DMA on ARM.

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
Arnd Bergmann July 11, 2017, 8:39 a.m. UTC | #3
On Tue, Jul 11, 2017 at 8:59 AM, Geert Uytterhoeven
<geert@linux-m68k.org> wrote:

> Whether we want to hide the option (and default to y if ARCH_RENESAS, i.e.
> ARM) is another question.  Note that that wouldn't reduce code maintainability,
> as the #ifdefs would be kept, and it would prevent building and testing
> with/without DMA on ARM.

arch/sh/configs/sdk7786_defconfig enables it, too, so it should at least be
a user-selectable option on SuperH if you do that.

     Arnd
Arnd Bergmann July 11, 2017, 8:42 a.m. UTC | #4
On Tue, Jul 11, 2017 at 8:59 AM, Geert Uytterhoeven
<geert@linux-m68k.org> wrote:
> Hi Magnus,
>
> On Tue, Jul 11, 2017 at 5:38 AM, Magnus Damm <magnus.damm@gmail.com> wrote:
>> On Mon, Jul 10, 2017 at 10:28 PM, Geert Uytterhoeven

>> Since enabling DMA Engine still keeps PIO support around I wonder why
>> we need this Kconfig at all - other drivers seem to get by without
>> this kind of thing?
>> So in my opinion it would also be nice to get rid of SERIAL_SH_SCI_DMA
>> completely and reducing the number of special per-driver Kconfig
>> entries.
>
> In general, I would agree, and remove the option at the blimp of an eye.
> However, this driver is shared with H8/300 and SuperH.  While both could use
> DMA (but it's not supported by Linux yet), I don't know if they are willing to
> live with the increased static and dynamic memory footprint of SH_SCI DMA
> support.

One more thing: enabling the DMA support in the console driver generally
means you cannot use printk in the DMA driver anywhere that may be called
during printk(). Not sure if that is a concern here.

      Arnd
Geert Uytterhoeven July 11, 2017, 8:57 a.m. UTC | #5
Hi Arnd,

On Tue, Jul 11, 2017 at 10:39 AM, Arnd Bergmann <arnd@arndb.de> wrote:
> On Tue, Jul 11, 2017 at 8:59 AM, Geert Uytterhoeven
> <geert@linux-m68k.org> wrote:
>
>> Whether we want to hide the option (and default to y if ARCH_RENESAS, i.e.
>> ARM) is another question.  Note that that wouldn't reduce code maintainability,
>> as the #ifdefs would be kept, and it would prevent building and testing
>> with/without DMA on ARM.
>
> arch/sh/configs/sdk7786_defconfig enables it, too, so it should at least be
> a user-selectable option on SuperH if you do that.

But that can't enable DMA, as (1) the non-DT DMA configuration was removed
due to (2) being unused.

Cfr. commit 219fb0c1436e4893 ("serial: sh-sci: Remove the platform data dma
slave rx/tx channel IDs").

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
Geert Uytterhoeven July 11, 2017, 8:59 a.m. UTC | #6
Hi Arnd,

On Tue, Jul 11, 2017 at 10:42 AM, Arnd Bergmann <arnd@arndb.de> wrote:
> On Tue, Jul 11, 2017 at 8:59 AM, Geert Uytterhoeven
> <geert@linux-m68k.org> wrote:
>> On Tue, Jul 11, 2017 at 5:38 AM, Magnus Damm <magnus.damm@gmail.com> wrote:
>>> On Mon, Jul 10, 2017 at 10:28 PM, Geert Uytterhoeven
>>> Since enabling DMA Engine still keeps PIO support around I wonder why
>>> we need this Kconfig at all - other drivers seem to get by without
>>> this kind of thing?
>>> So in my opinion it would also be nice to get rid of SERIAL_SH_SCI_DMA
>>> completely and reducing the number of special per-driver Kconfig
>>> entries.
>>
>> In general, I would agree, and remove the option at the blimp of an eye.
>> However, this driver is shared with H8/300 and SuperH.  While both could use
>> DMA (but it's not supported by Linux yet), I don't know if they are willing to
>> live with the increased static and dynamic memory footprint of SH_SCI DMA
>> support.
>
> One more thing: enabling the DMA support in the console driver generally
> means you cannot use printk in the DMA driver anywhere that may be called
> during printk(). Not sure if that is a concern here.

Not anymore, as all of these prints should have been removed/disabled already.

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
diff mbox

Patch

diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig
index ea2075d8e185f7aa..072a455008df9751 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -330,6 +330,7 @@  CONFIG_SERIAL_IMX_CONSOLE=y
 CONFIG_SERIAL_SH_SCI=y
 CONFIG_SERIAL_SH_SCI_NR_UARTS=20
 CONFIG_SERIAL_SH_SCI_CONSOLE=y
+CONFIG_SERIAL_SH_SCI_DMA=y
 CONFIG_SERIAL_MSM=y
 CONFIG_SERIAL_MSM_CONSOLE=y
 CONFIG_SERIAL_VT8500=y