Re: [PATCH v5 3/6] perf: hisi: Add support for HiSilicon SoC L3C PMU driver

2017-10-18 Thread Zhangshaokun
Hi Mark, Thanks for your further explanation. On 2017/10/18 21:55, Mark Rutland wrote: > On Wed, Oct 18, 2017 at 09:33:30PM +0800, Zhangshaokun wrote: >> On 2017/10/17 23:16, Mark Rutland wrote: >>> On Tue, Aug 22, 2017 at 04:07:54PM +0800, Shaokun Zhang wrote: +static int hisi_l3c_pmu_init_

Re: [PATCH v5 3/6] perf: hisi: Add support for HiSilicon SoC L3C PMU driver

2017-10-18 Thread Mark Rutland
On Wed, Oct 18, 2017 at 09:33:30PM +0800, Zhangshaokun wrote: > On 2017/10/17 23:16, Mark Rutland wrote: > > On Tue, Aug 22, 2017 at 04:07:54PM +0800, Shaokun Zhang wrote: > >> +static int hisi_l3c_pmu_init_data(struct platform_device *pdev, > >> +struct hisi_pmu *l3c_pm

Re: [PATCH v5 3/6] perf: hisi: Add support for HiSilicon SoC L3C PMU driver

2017-10-18 Thread Zhangshaokun
Hi Mark, On 2017/10/17 23:16, Mark Rutland wrote: > On Tue, Aug 22, 2017 at 04:07:54PM +0800, Shaokun Zhang wrote: >> +static int hisi_l3c_pmu_init_irq(struct hisi_pmu *l3c_pmu, >> + struct platform_device *pdev) >> +{ >> +int irq, ret; >> + >> +/* Read and init

Re: [PATCH v5 3/6] perf: hisi: Add support for HiSilicon SoC L3C PMU driver

2017-10-17 Thread Mark Rutland
On Tue, Aug 22, 2017 at 04:07:54PM +0800, Shaokun Zhang wrote: > +static int hisi_l3c_pmu_init_irq(struct hisi_pmu *l3c_pmu, > + struct platform_device *pdev) > +{ > + int irq, ret; > + > + /* Read and init IRQ */ > + irq = platform_get_irq(pdev, 0); > +

[PATCH v5 3/6] perf: hisi: Add support for HiSilicon SoC L3C PMU driver

2017-08-22 Thread Shaokun Zhang
This patch adds support for L3C PMU driver in HiSilicon SoC chip, Each L3C has own control, counter and interrupt registers and is an separate PMU. For each L3C PMU, it has 8-programable counters and each counter is free-running. Interrupt is supported to handle counter (48-bits) overflow. Reviewe