[PATCH v2 06/11] perf c2c: Refactor display filter macro

2020-12-13 Thread Leo Yan
, rather than passing field name for the data structure, it changes to pass the cache line's statistic value and the sum value, this is more flexsible, e.g. if consider to extend for sorting on all load hits which combines multiple fields from structure c2c_stats. Signed-off-by: Leo Yan ---

[PATCH v2 10/11] perf c2c: Sort on all cache hit for load operations

2020-12-13 Thread Leo Yan
nc false_sharing.exe false_sharing_example.c:155 0 11.17%0.00%0.00%0.00%0x20 0 1 2807928084:reader_thd 0x556f25bfdc73 0 148 108 513 1 [.] read_write_func false_sharing.exe false_sharing_example.c:1

[PATCH v2 07/11] perf c2c: Refactor node display macro

2020-12-13 Thread Leo Yan
e, this is flexsible for later's extension, e.g. it's easier to be used for metrics which combines multiple fields from structure c2c_stats. Signed-off-by: Leo Yan --- tools/perf/builtin-c2c.c | 17 ++--- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/tools/perf/b

[PATCH v2 08/11] perf c2c: Refactor node header

2020-12-13 Thread Leo Yan
uot;Node{cpus %loads %stores}"). For this reason, this patch changes the node header array to three flat variables and uses switch-case in function setup_nodes_header(), thus it is easier for altering the header string. Signed-off-by: Leo Yan --- tools/perf/builtin-c2c.c | 26 +

[PATCH v2 11/11] perf c2c: Update documentation for display option 'all'

2020-12-13 Thread Leo Yan
Since the new display option 'all' is introduced, this patch is to update the documentation to reflect it. Signed-off-by: Leo Yan --- tools/perf/Documentation/perf-c2c.txt | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/tools/perf/Document

[PATCH v2 09/11] perf c2c: Add local variables for output metrics

2020-12-13 Thread Leo Yan
": pointer to the sorting metrics. This is flexsible and the variables can be assigned to different strings based on the specified display type. Signed-off-by: Leo Yan --- tools/perf/builtin-c2c.c | 59 ++-- 1 file changed, 33 insertions(+), 26 deletio

Re: [RFC PATCH v2] clockevents: re-calculate event when cpu enter idle

2014-09-09 Thread Leo Yan
On 09/04/2014 09:25 AM, Leo Yan wrote: Below flow will have the redundant interrupts for broadcast timer: 1. Process A starts a hrtimer with 100ms timeout, then Process A will wait on the waitqueue to sleep; 2. The CPU which Process A runs on will enter idle and call notify

[Question]: redundant interrupts for broadcast timer

2014-08-18 Thread Leo Yan
r maybe we miss something so that introduce such kind issue? And i'm interesting now if have some idea to optimize such issue, very appreciate for suggestion and comment. Thanks, Leo Yan -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the bo

[RFC PATCH] clockevents: re-calculate event when cpu enter idle

2014-08-21 Thread Leo Yan
t idle. So every time iterate the related cpus to calculate the correct broadcast event value. Signed-off-by: Leo Yan --- kernel/time/tick-broadcast.c | 56 +--- 1 file changed, 48 insertions(+), 8 deletions(-) diff --git a/kernel/time/tick-broadcast.c b/k

[RFC PATCH v2] clockevents: re-calculate event when cpu enter idle

2014-09-03 Thread Leo Yan
nd set the next event after calculate a different event compare to previous time. Signed-off-by: Leo Yan --- kernel/time/tick-broadcast.c | 56 +--- 1 file changed, 48 insertions(+), 8 deletions(-) diff --git a/kernel/time/tick-broadcast.c b/kernel

[PATCH v1] arm64: fix bug for reloading FPSIMD state after cpu power off

2014-08-30 Thread Leo Yan
urn back to userland. Furthermore, this patch also removes the redundant operation for saving the state for idle thread; this operation is needless due kernel's idle thread will not use any VFP/NEON instruction. so that this also can benefit a bit for the latency during cpu's power off. Sig

Re: [PATCH v1] arm64: fix bug for reloading FPSIMD state after cpu power off

2014-08-31 Thread Leo Yan
On 09/01/2014 06:11 AM, Catalin Marinas wrote: On 31 Aug 2014, at 06:39, Leo Yan wrote: Now arm64 defers reloading FPSIMD state, but this optimization also introduces the bug after cpu resume back from low power mode. You are right, I can see a bug here. diff --git a/arch/arm64/kernel

[PATCH v2] arm64: fix bug for reloading FPSIMD state after cpu power off

2014-08-31 Thread Leo Yan
urn back to userland. Signed-off-by: Leo Yan --- arch/arm64/kernel/fpsimd.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/kernel/fpsimd.c b/arch/arm64/kernel/fpsimd.c index ad8aebb..3dca156 100644 --- a/arch/arm64/kernel/fpsimd.c +++ b/arch/arm64/kernel/fpsimd.c @@ -270,6

Re: [RFCv5, 01/46] arm: Frequency invariant scheduler load-tracking support

2015-07-22 Thread Leo Yan
On Wed, Jul 22, 2015 at 02:31:04PM +0100, Morten Rasmussen wrote: > On Tue, Jul 21, 2015 at 11:41:45PM +0800, Leo Yan wrote: > > Hi Morten, > > > > On Tue, Jul 07, 2015 at 07:23:44PM +0100, Morten Rasmussen wrote: > > > From: Morten Rasmussen > > > >

Re: [RFCv5, 01/46] arm: Frequency invariant scheduler load-tracking support

2015-07-23 Thread Leo Yan
On Thu, Jul 23, 2015 at 12:06:26PM +0100, Morten Rasmussen wrote: > On Wed, Jul 22, 2015 at 10:59:04PM +0800, Leo Yan wrote: > > On Wed, Jul 22, 2015 at 02:31:04PM +0100, Morten Rasmussen wrote: > > > On Tue, Jul 21, 2015 at 11:41:45PM +0800, Leo Yan wrote: > > > >

Re: [PATCH v3 4/5] clk: Hi6220: add stub clock driver

2015-08-03 Thread Leo Yan
Hi Stephen, On Mon, Aug 03, 2015 at 02:37:52PM -0700, Stephen Boyd wrote: > On 08/03, Leo Yan wrote: > > diff --git a/drivers/clk/hisilicon/clk-hi6220-stub.c > > b/drivers/clk/hisilicon/clk-hi6220-stub.c > > new file mode 100644 > > index 000..0931666 > > --

[PATCH v4 4/4] arm64: dts: add Hi6220's stub clock node

2015-08-04 Thread Leo Yan
Enable SRAM node and stub clock node for Hi6220; furthermore add the CPU's clock so it will be used by cpufreq-dt driver. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 23 +++ 1 file changed, 23 insertions(+) diff --git a/arch/arm64/boo

[PATCH v4 2/4] dt-bindings: clk: Hi6220: Document stub clock driver

2015-08-04 Thread Leo Yan
Document the new compatible for stub clock driver which is used for CPU and DDR's dynamic frequency scaling. Signed-off-by: Leo Yan --- .../devicetree/bindings/clock/hi6220-clock.txt| 19 ++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/Document

[PATCH v4 1/4] dt-bindings: arm: Hi6220: add doc for SRAM controller

2015-08-04 Thread Leo Yan
Document "hisilicon,hi6220-sramctrl" for SRAM controller. Signed-off-by: Leo Yan --- .../devicetree/bindings/arm/hisilicon/hisilicon.txt| 18 ++ 1 file changed, 18 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/hisilicon/hisilicon.txt b/Doc

[PATCH v4 0/4] clk: hisilicon: support stub clock

2015-08-04 Thread Leo Yan
3.011307.1062b247.en.html [2] http://archive.arm.linux.org.uk/lurker/message/20150803.011334.4b6f2fc7.en.html Leo Yan (4): dt-bindings: arm: Hi6220: add doc for SRAM controller dt-bindings: clk: Hi6220: Document stub clock driver clk: Hi6220: add stub clock driver arm64: dts: add Hi6220's stub

[PATCH v4 3/4] clk: Hi6220: add stub clock driver

2015-08-04 Thread Leo Yan
controller to handle this requirement. This driver will use syscon APIs to pass SRAM memory region and use common mailbox APIs for channels accessing. This init driver will support cpu frequency change firstly. Signed-off-by: Leo Yan --- drivers/clk/hisilicon/Kconfig | 2 +- drivers

Re: [RFC PATCH 2/3] mailbox: Hisilicon: add mailbox driver

2015-08-04 Thread Leo Yan
Hi Paul, On Tue, Aug 04, 2015 at 10:30:24AM +0200, Paul Bolle wrote: > (This RFC was part of this mornings catch of my crude mail filter. So, > for what it's worth, what follows are a few random comments for the few > things I'm able to spot.) > > On ma, 2015-08-03 at 0

Re: [RFC PATCH 2/3] mailbox: Hisilicon: add mailbox driver

2015-08-04 Thread Leo Yan
Hi Paul, On Tue, Aug 04, 2015 at 04:49:30PM +0800, Leo Yan wrote: > On Tue, Aug 04, 2015 at 10:30:24AM +0200, Paul Bolle wrote: > > (This RFC was part of this mornings catch of my crude mail filter. So, > > for what it's worth, what follows are a few random comments for th

Re: [RFC PATCH 2/3] mailbox: Hisilicon: add mailbox driver

2015-08-04 Thread Leo Yan
On Tue, Aug 04, 2015 at 11:17:39AM +0200, Paul Bolle wrote: > On di, 2015-08-04 at 16:49 +0800, Leo Yan wrote: > > On Tue, Aug 04, 2015 at 10:30:24AM +0200, Paul Bolle wrote: > > > On ma, 2015-08-03 at 09:13 +0800, Leo Yan wrote: > > > > --- /dev/null > >

Re: [RFC PATCH 0/3] mailbox: hisilicon: add mailbox driver

2015-08-05 Thread Leo Yan
Hi Jassi, Thanks for review. On Wed, Aug 05, 2015 at 04:22:01PM +0530, Jassi Brar wrote: > On Mon, Aug 3, 2015 at 6:43 AM, Leo Yan wrote: [...] > > For easily extending for Hisilicon series SoCs (SoCs may have difference > > for register's definition with each other),

Re: [PATCH] sched: fix tsk->pi_lock isn't held when do_set_cpus_allowed()

2015-08-25 Thread Leo Yan
s_allowed(struct task_struct *tsk, > struct cpumask *pmask) > > void cpuset_cpus_allowed_fallback(struct task_struct *tsk) > { > + unsigned long flags; > + > rcu_read_lock(); > + raw_spin_lock_irqsave(&tsk->pi_lock, flags); > do_set_cpus_allowed(tsk, task_cs(tsk)->e

Re: [PATCH v1 1/3] dt-bindings: mailbox: Document Hi6220 mailbox driver

2015-08-25 Thread Leo Yan
Hi Sudeep, Thanks for review, please see below comment. On Tue, Aug 25, 2015 at 12:17:20PM +0100, Sudeep Holla wrote: > On 19/08/15 10:37, Leo Yan wrote: > >Document the new compatible for Hisilicon Hi6220 mailbox driver. > > > >Signed-off-by: Leo Yan > >--- > >

Re: [PATCH v1 3/3] arm64: dts: add Hi6220 mailbox node

2015-08-25 Thread Leo Yan
Hi Sudeep, On Tue, Aug 25, 2015 at 12:36:12PM +0100, Sudeep Holla wrote: > > > On 19/08/15 10:37, Leo Yan wrote: > >On Hi6220, below memory regions in DDR have specific purpose: > > > > 0x05e0, - 0x05ef,: For MCU firmware using at runtime; > > 0

Re: [PATCH v1 3/3] arm64: dts: add Hi6220 mailbox node

2015-08-25 Thread Leo Yan
On Tue, Aug 25, 2015 at 09:43:14PM +0800, Haojian Zhuang wrote: > On Tue, 2015-08-25 at 11:42 +0100, Mark Rutland wrote: > > > > Are you then going to hack GRUB, release a special HiKey version of > > > > GRUB, not support any other versions, and still can your firmware > > > > UEFI? > > > > > > I

Re: [PATCH v1 3/3] arm64: dts: add Hi6220 mailbox node

2015-08-26 Thread Leo Yan
Hi Haojian, On Wed, Aug 26, 2015 at 09:25:41AM +0800, Haojian Zhuang wrote: > On Wed, 2015-08-26 at 00:00 +0800, Leo Yan wrote: > > On Tue, Aug 25, 2015 at 09:43:14PM +0800, Haojian Zhuang wrote: > > > On Tue, 2015-08-25 at 11:42 +0100, Mark Rutland wrote: > > > >

[PATCH] drivers/rtc/rtc-pl031.c: reset registers in init flow

2015-07-28 Thread Leo Yan
So finally miss with match value and will not trigger waken up event anymore. This issue can be dismissed by reset registers in initialization flow; And this code have no harm for ST's variant. Signed-off-by: Leo Yan --- drivers/rtc/rtc-pl031.c | 6 ++ 1 file changed, 6 insertions(+

[PATCH] drivers/rtc/rtc-pl031.c: fix typo for author email

2015-07-28 Thread Leo Yan
The email address missed character ">", so add it. Signed-off-by: Leo Yan --- drivers/rtc/rtc-pl031.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/rtc-pl031.c b/drivers/rtc/rtc-pl031.c index 99181fff..41dcb7d 100644 --- a/drivers/rtc/rtc-pl031.c

Re: [rtc-linux] [PATCH] drivers/rtc/rtc-pl031.c: reset registers in init flow

2015-07-29 Thread Leo Yan
Hi Linus, On Wed, Jul 29, 2015 at 11:08:30AM +0200, Linus Walleij wrote: > On Wed, Jul 29, 2015 at 8:02 AM, Leo Yan wrote: > > > When use rtc-pl031 for suspend test on Hisilicon's SoC Hi6220, Usually > > the data register (DR) will read back as value zero. So the suspend

Re: [RFC PATCH 0/3] mailbox: hisilicon: add mailbox driver

2015-08-10 Thread Leo Yan
Hi Jassi, On Mon, Aug 10, 2015 at 12:32:05PM +0530, Jassi Brar wrote: > On Thu, Aug 6, 2015 at 4:47 AM, Leo Yan wrote: > > Hi Jassi, > > > > Thanks for review. > > > > On Wed, Aug 05, 2015 at 04:22:01PM +0530, Jassi Brar wrote: > >> On M

Re: [RFCv5, 18/46] arm: topology: Define TC2 energy and provide it to the scheduler

2015-08-17 Thread Leo Yan
Hi Morten, On Tue, Jul 07, 2015 at 07:24:01PM +0100, Morten Rasmussen wrote: > From: Dietmar Eggemann > > This patch is only here to be able to test provisioning of energy related > data from an arch topology shim layer to the scheduler. Since there is no > code today which deals with extracting

Re: [RFCv5 PATCH 25/46] sched: Add over-utilization/tipping point indicator

2015-08-17 Thread Leo Yan
ags) > if (!se) { > update_rq_runnable_avg(rq, rq->nr_running); > add_nr_running(rq, 1); > + if (!task_new && !rq->rd->overutilized && > + cpu_overutilized(rq->cpu)) > + rq->rd->overutilized = true

Re: [RFCv5 PATCH 32/46] sched: Energy-aware wake-up task placement

2015-08-17 Thread Leo Yan
Hi Morten, On Tue, Jul 07, 2015 at 07:24:15PM +0100, Morten Rasmussen wrote: > Let available compute capacity and estimated energy impact select > wake-up target cpu when energy-aware scheduling is enabled and the > system in not over-utilized (above the tipping point). > > energy_aware_wake_cpu(

[PATCH v1 0/3] mailbox: hisilicon: add Hi6220 mailbox driver

2015-08-19 Thread Leo Yan
e the abstract common driver layer and only commit driver dedicated for Hi6220 * According to Paul Bolle's review, fix typo issue for Kconfig and remove unnecessary dependency with OF and fix minor for mailbox driver * Refine a little for dts nodes Leo Yan (3): dt-bindings: mailbox: Docum

[PATCH v1 3/3] arm64: dts: add Hi6220 mailbox node

2015-08-19 Thread Leo Yan
evice node for mailbox in dts. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 20 +--- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 8 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220-hike

[PATCH v1 2/3] mailbox: Hi6220: add mailbox driver

2015-08-19 Thread Leo Yan
, GPU and DDR. Signed-off-by: Leo Yan --- drivers/mailbox/Kconfig | 8 + drivers/mailbox/Makefile | 2 + drivers/mailbox/hi6220-mailbox.c | 513 +++ 3 files changed, 523 insertions(+) create mode 100644 drivers/mailbox/hi6220-mailbox.c

[PATCH v1 1/3] dt-bindings: mailbox: Document Hi6220 mailbox driver

2015-08-19 Thread Leo Yan
Document the new compatible for Hisilicon Hi6220 mailbox driver. Signed-off-by: Leo Yan --- .../bindings/mailbox/hisilicon,hi6220-mailbox.txt | 57 ++ 1 file changed, 57 insertions(+) create mode 100644 Documentation/devicetree/bindings/mailbox/hisilicon,hi6220

[PATCH v2 0/3] mailbox: hisilicon: add Hi6220 mailbox driver

2015-08-19 Thread Leo Yan
dts nodes Leo Yan (3): dt-bindings: mailbox: Document Hi6220 mailbox driver mailbox: Hi6220: add mailbox driver arm64: dts: add Hi6220 mailbox node .../bindings/mailbox/hisilicon,hi6220-mailbox.txt | 57 +++ arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 20 +- arch/arm64/boot/dts

[PATCH v2 1/3] dt-bindings: mailbox: Document Hi6220 mailbox driver

2015-08-19 Thread Leo Yan
Document the new compatible for Hisilicon Hi6220 mailbox driver. Signed-off-by: Leo Yan --- .../bindings/mailbox/hisilicon,hi6220-mailbox.txt | 57 ++ 1 file changed, 57 insertions(+) create mode 100644 Documentation/devicetree/bindings/mailbox/hisilicon,hi6220

[PATCH v2 2/3] mailbox: Hi6220: add mailbox driver

2015-08-19 Thread Leo Yan
, GPU and DDR. Signed-off-by: Leo Yan --- drivers/mailbox/Kconfig | 8 + drivers/mailbox/Makefile | 2 + drivers/mailbox/hi6220-mailbox.c | 519 +++ 3 files changed, 529 insertions(+) create mode 100644 drivers/mailbox/hi6220-mailbox.c

[PATCH v2 3/3] arm64: dts: add Hi6220 mailbox node

2015-08-19 Thread Leo Yan
evice node for mailbox in dts. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 20 +--- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 8 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220-hike

Re: [PATCH v2 2/3] mailbox: Hi6220: add mailbox driver

2015-08-20 Thread Leo Yan
Hi Yiping, Thanks for review, please see below comments. On Thu, Aug 20, 2015 at 01:42:58PM +0800, YiPing Xu wrote: > On 2015/8/20 10:53, Leo Yan wrote: > >Add driver for Hi6220 mailbox, the mailbox communicates with MCU; for > >sending data, it can support two method

Re: [PATCH] Documentation: minor typo fix in mailbox.txt

2015-08-13 Thread Leo Yan
On Thu, Aug 13, 2015 at 06:04:11PM -0600, Jonathan Corbet wrote: > On Mon, 3 Aug 2015 09:30:25 +0800 > Leo Yan wrote: > > > Fix minor typo so that can pass correct pointer variable for > > container_of(). > > Looks good to me, applied to the docs tree. I als

Re: [RFCv6 PATCH 03/10] sched: scheduler-driven cpu frequency selection

2015-12-15 Thread Leo Yan
fter you set state with TASK_INTERRUPTIBLE, if there have some scheduling happen within cpufreq_sched_try_driver_target(), then the thread will be remove from rq. But generally we suppose the thread will be on rq and can continue run after next tick. Juri's suggestion can fix this issue. And we c

Re: [RFCv6 PATCH 03/10] sched: scheduler-driven cpu frequency selection

2015-12-16 Thread Leo Yan
Hi Steve, On Wed, Dec 16, 2015 at 05:24:56PM -0800, Steve Muckle wrote: > Hi Leo, > > On 12/15/2015 07:48 PM, Leo Yan wrote: > > I also think "set_current_state(TASK_INTERRUPTIBLE)" will introduce > > logic error when software flow run into "else" blo

Re: [PATCH 5/6] sched/fair: Get rid of scaling utilization by capacity_orig

2015-09-11 Thread Leo Yan
Hi Morten, On Tue, Sep 08, 2015 at 05:53:31PM +0100, Morten Rasmussen wrote: > On Tue, Sep 08, 2015 at 03:31:58PM +0100, Morten Rasmussen wrote: > > On Tue, Sep 08, 2015 at 02:52:05PM +0200, Peter Zijlstra wrote: > > > > > > Something like teh below.. > > > > > > Another thing to ponder; the dow

Re: [PATCH 5/6] sched/fair: Get rid of scaling utilization by capacity_orig

2015-09-11 Thread Leo Yan
On Fri, Sep 11, 2015 at 11:02:33AM +0100, Morten Rasmussen wrote: > On Fri, Sep 11, 2015 at 03:46:51PM +0800, Leo Yan wrote: > > Hi Morten, > > > > On Tue, Sep 08, 2015 at 05:53:31PM +0100, Morten Rasmussen wrote: > > > On Tue, Sep 08, 2015 at 03:31:58PM +0100, Mort

Re: [PATCH 1/4] arm64: dts: Reserve memory regions for hi6220

2015-10-29 Thread Leo Yan
On Wed, Oct 28, 2015 at 11:32:29PM -0500, Rob Herring wrote: > On Fri, Oct 9, 2015 at 9:20 AM, Leo Yan wrote: > > On Fri, Oct 09, 2015 at 08:50:13AM -0500, Rob Herring wrote: > >> On Fri, Oct 9, 2015 at 8:30 AM, Mark Rutland wrote: > >> > On Fri, Oct 09, 2015 at

Re: [RFCv5 PATCH 27/46] sched, cpuidle: Track cpuidle state index in the scheduler

2015-07-20 Thread Leo Yan
hed / idle: Move the default idle call code to a separate function Thanks, Leo Yan -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [RFCv5, 01/46] arm: Frequency invariant scheduler load-tracking support

2015-07-21 Thread Leo Yan
ter_notifier(&cpufreq_notifier, > CPUFREQ_TRANSITION_NOTIFIER); > + if (ret) > + return ret; > + > + return cpufreq_register_notifier(&cpufreq_policy_notifier, > +

Re: [RFCv5 PATCH 11/46] sched: Remove blocked load and utilization contributions of dying tasks

2015-07-21 Thread Leo Yan
On Tue, Jul 07, 2015 at 07:23:54PM +0100, Morten Rasmussen wrote: > Tasks being dequeued for the last time (state == TASK_DEAD) are dequeued > with the DEQUEUE_SLEEP flag which causes their load and utilization > contributions to be added to the runqueue blocked load and utilization. > Hence they w

[PATCH v2 RESEND 0/4] arm64: Hi6220: enable CPU idle states

2016-01-21 Thread Leo Yan
ly pass one clock phandle [1] http://article.gmane.org/gmane.linux.kernel.commits.head/573361 Leo Yan (4): arm64: dts: Reserve memory regions for hi6220 arm64: Kconfig: select sp804 timer for ARCH_HISI arm64: dts: add sp804 timer node for Hi6220 arm64: dts: enable idle states for Hi6220 arch/arm64/Kconfig.

[PATCH v2 RESEND 1/4] arm64: dts: Reserve memory regions for hi6220

2016-01-21 Thread Leo Yan
patch reserves these memory regions in DT. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts | 16 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts b/arch/arm64/boot/dts/hisilicon/hi6220-hikey.dts

[PATCH v2 RESEND 2/4] arm64: Kconfig: select sp804 timer for ARCH_HISI

2016-01-21 Thread Leo Yan
Select sp804 timer for ARCH_HISI, which is used as broadcast timer. Signed-off-by: Leo Yan --- arch/arm64/Kconfig.platforms | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm64/Kconfig.platforms b/arch/arm64/Kconfig.platforms index 4043c35..94c410d 100644 --- a/arch/arm64

[PATCH v2 RESEND 3/4] arm64: dts: add sp804 timer node for Hi6220

2016-01-21 Thread Leo Yan
Add sp804 timer for hi6220, so it can be used as broadcast timer. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 9 + 1 file changed, 9 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index

[PATCH v2 RESEND 4/4] arm64: dts: enable idle states for Hi6220

2016-01-21 Thread Leo Yan
Add cpu and cluster level's low power state for Hi6220. Acked-by: Sudeep Holla Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 31 +++ 1 file changed, 31 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64

Re: [PATCH v2] thermal: re-calculate k_po/k_pu when update sustainable power

2015-12-31 Thread Leo Yan
Hi Eduardo, Thanks for review. On Thu, Dec 31, 2015 at 09:21:26AM -0800, Eduardo Valentin wrote: > On Wed, Dec 30, 2015 at 06:38:40PM +0800, Leo Yan wrote: > > k_po/k_pu are in essence ratio values compared with sustainable power. > > So when update sustainable power, we can r

Re: [PATCH v2] thermal: re-calculate k_po/k_pu when update sustainable power

2016-01-04 Thread Leo Yan
On Mon, Jan 04, 2016 at 11:22:26AM +, Daniel Thompson wrote: > On 01/01/16 00:03, Leo Yan wrote: > >Hi Eduardo, > > > >Thanks for review. > > > >On Thu, Dec 31, 2015 at 09:21:26AM -0800, Eduardo Valentin wrote: > >>On Wed, Dec 30, 2015 at 06:38:40PM +

Re: [PATCH] thermal: hisilicon: increase temperature resolution

2016-02-18 Thread Leo Yan
Hi Rui, Eduardo, On Wed, Dec 30, 2015 at 01:13:02PM +0800, Leo Yan wrote: > When calculate temperature, old code firstly do division and then > convert to "millicelsius" unit. This will lose resolution and only can > read back temperature with "Celsius" unit. >

Re: [PATCH] thermal: use %d to print S32 parameters

2016-02-18 Thread Leo Yan
On Wed, Jan 13, 2016 at 09:22:16AM +, Javi Merino wrote: > On Wed, Jan 13, 2016 at 04:33:56PM +0800, Leo Yan wrote: > > Power allocator's parameters are S32 type, so use %d to print them. > > Indeed. The name of the macro is create_s32_tzp_attr(), it's > explicit

Re: Regard of thermal power allocator's coefficients

2016-02-19 Thread Leo Yan
Hi Javi, On Thu, Feb 18, 2016 at 03:19:26PM +, Javi Merino wrote: > On Mon, Feb 15, 2016 at 12:47:51PM +0800, Leo Yan wrote: [...] > > > > So want to firstly to confirm if should we pass coefficients by using > > > > device tree? Is someone working on related wor

Regard of thermal power allocator's coefficients

2016-02-14 Thread Leo Yan
elcome any suggestion. Thanks, Leo Yan

Re: Regard of thermal power allocator's coefficients

2016-02-14 Thread Leo Yan
Hi Eduardo, Thanks for replying. On Sun, Feb 14, 2016 at 09:12:19AM -0800, Eduardo Valentin wrote: > On Sun, Feb 14, 2016 at 07:00:41PM +0800, Leo Yan wrote: [...] > > So want to firstly to confirm if should we pass coefficients by using > > device tree? Is someone working on r

[PATCH v7 RESEND 1/4] dt-bindings: mailbox: Document Hi6220 mailbox driver

2016-02-15 Thread Leo Yan
Document DT binding for Hisilicon Hi6220 mailbox driver. Acked-by: Rob Herring Signed-off-by: Leo Yan --- .../bindings/mailbox/hisilicon,hi6220-mailbox.txt | 74 ++ 1 file changed, 74 insertions(+) create mode 100644 Documentation/devicetree/bindings/mailbox/hisilicon

[PATCH v7 RESEND 0/4] mailbox: hisilicon: add Hi6220 mailbox driver

2016-02-15 Thread Leo Yan
ix typo issue for Kconfig and remove unnecessary dependency with OF and fix minor for mailbox driver * Refine a little for dts nodes Leo Yan (4): dt-bindings: mailbox: Document Hi6220 mailbox driver mailbox: Hi6220: add mailbox driver arm64: dts: add mailbox node for Hi6220 arm64: dts: add Hi6220&

[PATCH v7 RESEND 4/4] arm64: dts: add Hi6220's stub clock node

2016-02-15 Thread Leo Yan
Enable SRAM node and stub clock node for Hi6220, which uses mailbox channel 1 for CPU's frequency change. Furthermore, add the CPU clock phandle in CPU's node and using operating-points-v2 to register operating points. So can be used by cpufreq-dt driver. Signed-off-by: Leo Yan ---

[PATCH v7 RESEND 2/4] mailbox: Hi6220: add mailbox driver

2016-02-15 Thread Leo Yan
receiving data, it will depend on the interrupt to notify the channel has incoming message. Now mailbox driver is used to send message to MCU to control dynamic voltage and frequency scaling for CPU, GPU and DDR. Signed-off-by: Leo Yan --- drivers/mailbox/Kconfig | 8 + drivers/mailbox

[PATCH v7 RESEND 3/4] arm64: dts: add mailbox node for Hi6220

2016-02-15 Thread Leo Yan
This patch add device mailbox node for Hi6220 in DT. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 8 1 file changed, 8 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index 2585236..23c79e1

Re: [PATCH v7 RESEND 0/4] mailbox: hisilicon: add Hi6220 mailbox driver

2016-02-15 Thread Leo Yan
On Mon, Feb 15, 2016 at 09:50:22PM +0800, Leo Yan wrote: > Hi6220 mailbox supports up to 32 channels. Each channel is unidirectional > with a maximum message size of 8 words. I/O is performed using register > access (there is no DMA) and the cell raises an interrupt when messages >

Re: [PATCH 3/3] arm64: dts: register Hi6220's thermal zone for power allocator

2016-02-24 Thread Leo Yan
Hi Javi, Thanks for review. On Wed, Feb 24, 2016 at 06:28:57PM +, Javi Merino wrote: > On Sat, Feb 20, 2016 at 11:52:09PM +0800, Leo Yan wrote: > > With profiling Hi6220's power modeling so get dynamic coefficient and > > sustainable power. So pass these parameters f

[PATCH v2 1/5] thermal: change "hysteresis" as optional property

2016-02-25 Thread Leo Yan
The property "hysteresis" is mandatory for trip points, so if without it the thermal zone cannot register successfully. But "hysteresis" is ignored in the thermal subsystem and only inquired by several thermal sensor drivers. So change "hysteresis" as optional prope

[PATCH v2 0/5] thermal: hisilicon: enable power allocator for Hi6220

2016-02-25 Thread Leo Yan
to fix IRQ imbalance enabling issue Leo Yan (5): thermal: change "hysteresis" as optional property thermal: hisilicon: support to use any sensor thermal: hisilicon: fix IRQ imbalance enabling arm64: dts: register Hi6220's thermal sensor arm64: dts: register Hi6220's the

[PATCH v2 5/5] arm64: dts: register Hi6220's thermal zone for power allocator

2016-02-25 Thread Leo Yan
ned-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 33 +++ 1 file changed, 33 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index 50ba1b0..d8b963c 100644 --- a/arch/arm64/boot/dts/hisili

[PATCH v2 2/5] thermal: hisilicon: support to use any sensor

2016-02-25 Thread Leo Yan
ymore. So this patch is to fix this issue. It allows the thermal sensor driver can register any number sensors at initialization phase, and fix up code for other related code to skip related sensor's accessing if the sensor has not been enabled in initialization phase. Signed-off-b

[PATCH v2 3/5] thermal: hisilicon: fix IRQ imbalance enabling

2016-02-25 Thread Leo Yan
thermal zone. Also change to use the function irq_get_irqchip_state() to read back real interrupt line state. Signed-off-by: Leo Yan --- drivers/thermal/hisi_thermal.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/thermal/hisi_thermal.c b/drivers/thermal/hisi

[PATCH v2 4/5] arm64: dts: register Hi6220's thermal sensor

2016-02-25 Thread Leo Yan
Bind thermal sensor driver for Hi6220. Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 9 + 1 file changed, 9 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon/hi6220.dtsi b/arch/arm64/boot/dts/hisilicon/hi6220.dtsi index f588be9..50ba1b0 100644 --- a

[PATCH] arm64: dts: Add L2 cache topology to Hi6220

2016-02-25 Thread Leo Yan
This patch adds the L2 cache topology on Hi6220. Hi6220 has two clusters, every cluster has 512KiB L2 cache (32KiB x 16 ways). Signed-off-by: Leo Yan --- arch/arm64/boot/dts/hisilicon/hi6220.dtsi | 16 1 file changed, 16 insertions(+) diff --git a/arch/arm64/boot/dts/hisilicon

[PATCH] serial/amba-pl011: fix minor bugs for pio mode

2015-05-04 Thread Leo Yan
resend it again, finally will send the duplicate chars. So change to check FIFO is full or not, if full then return false, otherwise send out char and return true. Signed-off-by: Leo Yan --- drivers/tty/serial/amba-pl011.c | 20 +++- 1 file changed, 11 insertions(+), 9

[PATCH RESEND] serial/amba-pl011: fix minor bugs for pio mode

2015-05-04 Thread Leo Yan
resend it again, finally will send the duplicate chars. So change to check FIFO is full or not, if full then return false, otherwise send out char and return true. Signed-off-by: Leo Yan --- drivers/tty/serial/amba-pl011.c | 20 +++- 1 file changed, 11 insertions(+), 9

[PATCH] Bluetooth: btwilink: remove DEBUG define

2015-05-05 Thread Leo Yan
Remove the DEBUG define as the debug code; so can remove mass debug info from log buffer when using dmesg. Signed-off-by: Leo Yan --- drivers/bluetooth/btwilink.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/bluetooth/btwilink.c b/drivers/bluetooth/btwilink.c

Re: [PATCH] serial/amba-pl011: fix minor bugs for pio mode

2015-05-05 Thread Leo Yan
On Tue, May 05, 2015 at 12:11:56PM +0100, Dave P Martin wrote: > On Tue, May 05, 2015 at 04:00:25AM +0100, Leo Yan wrote: > [...] > > Thanks for the fixes, but I already posted patches that probably fix the > issues you are observing, And Greg took them into his tty-testing branc

Re: [PATCH] serial/amba-pl011: fix minor bugs for pio mode

2015-05-05 Thread Leo Yan
On Tue, May 05, 2015 at 08:09:27PM +0800, Leo Yan wrote: > On Tue, May 05, 2015 at 12:11:56PM +0100, Dave P Martin wrote: > > On Tue, May 05, 2015 at 04:00:25AM +0100, Leo Yan wrote: > > [...] > > > > Thanks for the fixes, but I already posted patches that probably

Re: [PATCH v5 0/6] arm64,hi6220: Enable Hisilicon Hi6220 SoC

2015-05-11 Thread Leo Yan
uot;; - The bootloader has not initialized register *cntfrq_el0* so will introduce the failure during init arch timer. For init cntfrq_el0, we need fix this issue in Hisilicon's old bootloader, rather than directly add "clock-frequency" for arch timer's node in DTS. i will try

[PATCH] thermal: fix the casting issue for long type

2015-02-25 Thread Leo Yan
int" type, this can be compatible for 32 bits and 64 bits system. Signed-off-by: Leo Yan --- drivers/thermal/of-thermal.c | 4 ++-- drivers/thermal/thermal_core.c | 6 +++--- include/linux/thermal.h| 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/thermal/of-

Re: [PATCH] thermal: fix the casting issue for long type

2015-02-26 Thread Leo Yan
hi Punit, On Thu, Feb 26, 2015 at 10:24:30AM +, Punit Agrawal wrote: > Hi Leo, > > Leo Yan writes: > > > When enable the thermal on arm64 platform, it will report failure when > > call function *thermal_zone_bind_cooling_device()*. > > > > The failure

[PATCH 0/2] cpufreq: hisilicon acpu support

2015-02-26 Thread Leo Yan
This series adds support for hisilicon acpu cpufreq driver, which has been tested on Linaro's 96board "hikey" with hi6220 SoC. Leo Yan (2): cpufreq: hisilicon: add acpu driver dt-bindings: cpufreq: document for hisilicon acpu driver .../bindings/cpufreq/cpufreq-hisi-acpu.tx

[PATCH 2/2] dt-bindings: cpufreq: document for hisilicon acpu driver

2015-02-26 Thread Leo Yan
y the dtb flag "hisilicon,coupled-clusters". Signed-off-by: Leo Yan --- .../bindings/cpufreq/cpufreq-hisi-acpu.txt | 112 + 1 file changed, 112 insertions(+) create mode 100644 Documentation/devicetree/bindings/cpufreq/cpufreq-hisi-acpu.txt diff --git

[PATCH 1/2] cpufreq: hisilicon: add acpu driver

2015-02-26 Thread Leo Yan
Add acpu driver for hisilicon SoC, acpu is application processor subsystem. Dependent on the H/W design, the silicon may has the coupled clock domain for all clusters, or every cluster can have the dedicated clock domain. So this driver will support both implementations. Signed-off-by: Leo Yan

[PATCH 1/2] cpufreq-dt: support cluster level clock

2015-03-03 Thread Leo Yan
parameter "clk_domain_boundary" to indicate whether the clock domain is bound to system level, cluster level or CPU level. Signed-off-by: Leo Yan --- drivers/cpufreq/Kconfig | 5 +++-- drivers/cpufreq/cpufreq-dt.c | 14 +- include/linux/cpufreq-dt.h | 16 ---

[PATCH 0/2] cpufreq-dt: support for cluster level clock

2015-03-03 Thread Leo Yan
patch is only compiled successfully. Leo Yan (2): cpufreq-dt: support cluster level clock ARM: mvebu: update cpufreq-dt's platform data arch/arm/mach-mvebu/pmsu.c | 2 +- drivers/cpufreq/Kconfig | 5 +++-- drivers/cpufreq/cpufreq-dt.c | 14 +- include/linux/cpufreq

[PATCH 2/2] ARM: mvebu: update cpufreq-dt's platform data

2015-03-03 Thread Leo Yan
Change to use cpufreq-dt's platform data of clk_domain_boundary; in the old code the initial value is true, that means every CPU has the dedicated clock. So assign as CPUFREQ_DT_CLK_PER_CPU. Signed-off-by: Leo Yan --- arch/arm/mach-mvebu/pmsu.c | 2 +- 1 file changed, 1 insertion(+), 1 del

Re: [PATCH 1/2] cpufreq-dt: support cluster level clock

2015-03-03 Thread Leo Yan
On Tue, Mar 03, 2015 at 06:40:23PM +0530, Viresh Kumar wrote: > On 3 March 2015 at 18:33, Leo Yan wrote: > > In the previous code, cpufreq-dt driver support single clock shared by > > all CPUs or every CPU has dedicated clock; but it cannot support cluster > > level clock

Re: [PATCH 1/2] cpufreq-dt: support cluster level clock

2015-03-03 Thread Leo Yan
On Tue, Mar 03, 2015 at 08:49:25PM +0530, Viresh Kumar wrote: > On 3 March 2015 at 19:33, Leo Yan wrote: > > I'm just thinking to finish things in one time. From my previous > > experience, clocks per cluster are common cases for ARM's > > multi-clusters, so i think

Re: [PATCH 1/2] cpufreq: hisilicon: add acpu driver

2015-03-02 Thread Leo Yan
Hi Viresh, On Mon, Mar 02, 2015 at 11:44:28AM +0530, Viresh Kumar wrote: > On 26 February 2015 at 18:51, Leo Yan wrote: > > Add acpu driver for hisilicon SoC, acpu is application processor > > subsystem. Dependent on the H/W design, the silicon may has the coupled > >

Re: [PATCH 1/2] cpufreq: hisilicon: add acpu driver

2015-03-02 Thread Leo Yan
On Mon, Mar 02, 2015 at 04:34:34PM +0530, Viresh Kumar wrote: > On 2 March 2015 at 16:20, Leo Yan wrote: > > i'm glad to use more general method, let me give more input so that we > > can see if can figure out a better way. ;) > > And I am glad to hear that :) >

Re: [PATCH RFC] sched/fair: let cpu's cfs_rq to reflect task migration

2016-04-04 Thread Leo Yan
On Mon, Apr 04, 2016 at 09:48:23AM +0100, Morten Rasmussen wrote: > On Sat, Apr 02, 2016 at 03:11:54PM +0800, Leo Yan wrote: > > On Fri, Apr 01, 2016 at 03:28:49PM -0700, Steve Muckle wrote: > > > I think I follow - Leo please correct me if I mangle your intentions. > > >

<    1   2   3   4   5   6   7   8   9   10   >