From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Gaku Inami <gaku.inami.xh@renesas.com>
Cc: Mark Rutland <mark.rutland@arm.com>,
"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
<devicetree@vger.kernel.org>, Magnus Damm <magnus.damm@gmail.com>,
Rob Herring <robh+dt@kernel.org>,
Linux-Renesas <linux-renesas-soc@vger.kernel.org>,
Simon Horman <horms@verge.net.au>,
Linux ARM <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH 5/5] soc: renesas: rcar-topology: Add support to be aware cpu capacity
Date: Mon, 5 Mar 2018 11:46:03 +0100 [thread overview]
Message-ID: <CAMuHMdVZzCOqatGA4PH0Gr+noTEhQ8RAW=pK5K1e7KrAM8VS-A@mail.gmail.com> (raw)
In-Reply-To: <1519697995-6061-6-git-send-email-gaku.inami.xh@renesas.com>
Hi Inami-san,
On Tue, Feb 27, 2018 at 3:19 AM, Gaku Inami <gaku.inami.xh@renesas.com> wrote:
> Some R-Car SoCs support big LITTLE architecture produced by ARM, that
> have different power/performance characteristics between each CPUs.
> In order to aware such as difference, this patch changes the sched
> domain flags that the tasks can be scheduled with capacity awareness.
> If you use big LITTLE without this patch, the scheduler may make
> unintended behaviors.
>
> Signed-off-by: Gaku Inami <gaku.inami.xh@renesas.com>
Thanks for your patch!
> --- /dev/null
> +++ b/drivers/soc/renesas/rcar-topology.c
> @@ -0,0 +1,36 @@
> +// SPDX-License-Identifier: GPL-2.0
> +/*
> + * R-Car CPU topology for ARM big.LITTLE platforms
> + *
> + * Copyright (C) 2018 Renesas Electronics Corporation.
> + *
> + */
> +
> +#include <linux/cpuset.h>
> +#include <linux/init.h>
> +#include <linux/of.h>
> +#include <linux/sched/topology.h>
> +#include <linux/topology.h>
> +
> +static int rcar_cpu_cpu_flags(void)
> +{
> + return SD_ASYM_CPUCAPACITY;
> +}
> +
> +static struct sched_domain_topology_level rcar_topology[] = {
> +#ifdef CONFIG_SCHED_MC
> + { cpu_coregroup_mask, cpu_core_flags, SD_INIT_NAME(MC) },
> +#endif
> + { cpu_cpu_mask, rcar_cpu_cpu_flags, SD_INIT_NAME(DIE) },
> + { NULL, }
> +};
> +
> +static int __init rcar_topology_init(void)
> +{
> + if (of_machine_is_compatible("renesas,r8a7795") ||
> + of_machine_is_compatible("renesas,r8a7796"))
> + set_sched_topology(rcar_topology);
> +
> + return 0;
> +}
> +early_initcall(rcar_topology_init);
None of the above seems R-Car specific to me. So please explain why this
can't just be added to arch/arm64/kernel/topology.c instead, and enabled
unconditionally.
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
next prev parent reply other threads:[~2018-03-05 10:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-27 2:19 [PATCH 0/5] Optimization with aware of cpu capacity for R-Car Gen3 Gaku Inami
2018-02-27 2:19 ` [PATCH 1/5] arm64: dts: renesas: r8a7795: Add multi-cluster definition Gaku Inami
2018-03-05 10:37 ` Geert Uytterhoeven
2018-02-27 2:19 ` [PATCH 2/5] arm64: dts: renesas: r8a7796: " Gaku Inami
2018-03-05 10:38 ` Geert Uytterhoeven
2018-02-27 2:19 ` [PATCH 3/5] arm64: dts: renesas: r8a7795: Add cpu capacity-dmips-mhz Gaku Inami
2018-03-05 10:23 ` Geert Uytterhoeven
2018-03-07 1:48 ` Gaku Inami
2018-03-07 7:47 ` Geert Uytterhoeven
2018-03-07 8:11 ` Simon Horman
2018-03-07 8:23 ` Gaku Inami
2018-02-27 2:19 ` [PATCH 4/5] arm64: dts: renesas: r8a7796: " Gaku Inami
2018-03-05 10:24 ` Geert Uytterhoeven
2018-02-27 2:19 ` [PATCH 5/5] soc: renesas: rcar-topology: Add support to be aware cpu capacity Gaku Inami
2018-03-05 10:46 ` Geert Uytterhoeven [this message]
2018-03-06 5:11 ` Gaku Inami
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='CAMuHMdVZzCOqatGA4PH0Gr+noTEhQ8RAW=pK5K1e7KrAM8VS-A@mail.gmail.com' \
--to=geert@linux-m68k.org \
--cc=devicetree@vger.kernel.org \
--cc=gaku.inami.xh@renesas.com \
--cc=horms@verge.net.au \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-renesas-soc@vger.kernel.org \
--cc=magnus.damm@gmail.com \
--cc=mark.rutland@arm.com \
--cc=robh+dt@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).