[PATCH 3/3] i2c: octeon: Avoid printk after too long SMBUS message

2016-06-08 Thread Jan Glauber
Remove the warning about a too long SMBUS message because the ipmi_ssif driver triggers this warning too frequently so it spams the message log. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-)

[PATCH 0/3] Bug fixes for octeon driver

2016-06-08 Thread Jan Glauber
Testing ipmi_ssif on ThunderX several bugs were found that also apply to the Octeon i2c driver changes coming with 4.7. I'll need to rebase the pending ThunderX driver series after this fixes which I'll do shortly. Please consider for 4.7. thanks, Jan Jan Glauber (3): i2c: octeon: Missing

[PATCH 1/3] i2c: octeon: Missing AAK flag in case of I2C_M_RECV_LEN

2016-06-08 Thread Jan Glauber
are to be received. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/i2c/busses/i2c-octeon.c b/drivers/i2c/busses/i2c-octeon.c index aa5f01e..1922e4a 100644 --- a/drivers/i2c/buss

[PATCH 2/3] i2c: octeon: Add retry logic after receiving STAT_RXADDR_NAK

2016-06-08 Thread Jan Glauber
The controller specification states that when receiving STAT_RXADDR_NAK the START should be sent again. Retry several times before finally failing with -ENXIO. Without this change the IPMI SSIF driver fails executing several commands like 'ipmitool fru' on ThunderX. Signed-off-by: Jan Glauber

Re: [PATCH 2/3] i2c: octeon: Add retry logic after receiving STAT_RXADDR_NAK

2016-06-14 Thread Jan Glauber
On Thu, Jun 09, 2016 at 10:11:51PM +0200, Wolfram Sang wrote: > On Wed, Jun 08, 2016 at 08:51:18AM +0200, Jan Glauber wrote: > > The controller specification states that when receiving STAT_RXADDR_NAK > > the START should be sent again. Retry several times before finally > >

[PATCH v10 7/8] i2c: cavium: Use booleon values for booleon variables

2016-06-15 Thread Jan Glauber
Initialize booleon values with true instead of 1. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-cavium.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/i2c/busses/i2c-cavium.c b/drivers/i2c/busses/i2c-cavium.c index 56b23c2..3

[PATCH v10 2/8] i2c: octeon: Split the driver into two parts

2016-06-15 Thread Jan Glauber
Move common functionality into a separate file in preparation of the re-use from the ThunderX i2c driver. Functions are slightly re-ordered but no other changes are included. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/Makefile | 3 +- drivers/i2c/

[PATCH v10 3/8] i2c: thunderx: Add i2c driver for ThunderX SOC

2016-06-15 Thread Jan Glauber
The ThunderX SOC uses the same i2c block as the Octeon SOC. The main difference is that on ThunderX the device is a PCI device so device probing is done via PCI, interrupts are MSI-X. The clock rates can be set via device tree or ACPI. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- d

[PATCH v10 4/8] i2c: thunderx: Add SMBUS alert support

2016-06-15 Thread Jan Glauber
Add SMBUS alert interrupt support. For now only device tree is supported for specifying the alert. In case of ACPI an error is returned. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-cavium.h| 6 drivers/i2c/busses/i2c-thunderx-core.

[PATCH v10 0/8] i2c-octeon and i2c-thunderx driver

2016-06-15 Thread Jan Glauber
of of_find_node_by_name - Simplify adap.name by using device name - SMBUS ACPI handling - Re-phrase SMBUS error/not-specified message Thanks, Jan - Jan Glauber (8): i2c: octeon: Rename driver to prepare for split i2c: octeon: Split the driver into two parts

[PATCH v10 1/8] i2c: octeon: Rename driver to prepare for split

2016-06-15 Thread Jan Glauber
This is an intermediate commit in preparation of the driver split. The module rename in this commit will be reverted in the next patch, this is just done to make the series bisectible. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/Makefile

[PATCH v10 6/8] i2c: octeon: Sort include files alphabetically

2016-06-15 Thread Jan Glauber
Sort include files alphabetically to reduce probability of merge conflicts. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon-core.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/i2c/busses/i2c-octeon-core.c b/drive

[PATCH v10 5/8] i2c: octeon,thunderx: Move register offsets to struct

2016-06-15 Thread Jan Glauber
The register offsets are different between Octeon and ThunderX so move them into the algorithm struct and get rid of the define. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-cavium.c| 28 +-- drivers/i2c/busses/i2c-ca

[PATCH v10 8/8] i2c: octeon: thunderx: Add MAINTAINERS entry

2016-06-15 Thread Jan Glauber
The i2c Octeon and ThunderX drivers are maintained by Cavium. While at it fix the whitespace errors of the next entry. Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <david.da...@cavium.com> --- MAINTAINERS | 25 + 1 file changed, 1

[RFC PATCH 1/7] arm64/perf: Basic uncore counter support for Cavium ThunderX

2016-02-12 Thread Jan Glauber
uncore/uncore_cavium.c @@ -0,0 +1,210 @@ +/* + * Cavium Thunder uncore PMU support. Derived from Intel and AMD uncore code. + * + * Copyright (C) 2015,2016 Cavium Inc. + * Author: Jan Glauber <jan.glau...@cavium.com> + */ + +#include +#include +#include +#include +#include +#include +#include

[RFC PATCH 5/7] arm64/perf: Cavium ThunderX OCX LNE uncore support

2016-02-12 Thread Jan Glauber
Support counters for the CCPI Interface controller (OCX) lanes. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/uncore/Makefile| 3 +- arch/arm64/kernel/uncore/uncore_cavium.c | 3 + arch/arm64/kernel/uncore/uncore_cavium.h | 4 +

[RFC PATCH 4/7] arm64/perf: Cavium ThunderX LMC uncore support

2016-02-12 Thread Jan Glauber
Support counters on the DRAM controllers. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/uncore/Makefile| 3 +- arch/arm64/kernel/uncore/uncore_cavium.c | 3 + arch/arm64/kernel/uncore/uncore_cavium.h | 4 + arch/arm64/kernel/

[RFC PATCH 2/7] arm64/perf: Cavium ThunderX L2C TAD uncore support

2016-02-12 Thread Jan Glauber
Support counters of the L2 Cache tag and data units. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/uncore/Makefile| 3 +- arch/arm64/kernel/uncore/uncore_cavium.c | 6 +- arch/arm64/kernel/uncore/uncore_cavium.h | 6 +- arch

[RFC PATCH 3/7] arm64/perf: Cavium ThunderX L2C CBC uncore support

2016-02-12 Thread Jan Glauber
Support counters of the L2 cache crossbar connect. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/uncore/Makefile| 3 +- arch/arm64/kernel/uncore/uncore_cavium.c | 3 + arch/arm64/kernel/uncore/uncore_cavium.h | 4 + arch/arm64/

[RFC PATCH 7/7] arm64/perf: Cavium ThunderX OCX TLK uncore support

2016-02-12 Thread Jan Glauber
Support for the OCX transmit link counters. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/uncore/Makefile| 3 +- arch/arm64/kernel/uncore/uncore_cavium.c | 3 + arch/arm64/kernel/uncore/uncore_cavium.h | 4 + arch/arm64/kernel/

[RFC PATCH 6/7] arm64/perf: Cavium ThunderX OCX FRC uncore support

2016-02-12 Thread Jan Glauber
Support for the OCX alignment counters. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/uncore/Makefile| 3 +- arch/arm64/kernel/uncore/uncore_cavium.c | 3 + arch/arm64/kernel/uncore/uncore_cavium.h | 4 + arch/arm64/kernel/

[RFC PATCH 0/7] Cavium ThunderX uncore PMU support

2016-02-12 Thread Jan Glauber
uld be put somewhere under drivers/ instead. Feedback welcome! Jan Jan Glauber (7): arm64/perf: Basic uncore counter support for Cavium ThunderX arm64/perf: Cavium ThunderX L2C TAD uncore support arm64/perf: Cavium ThunderX L2C CBC uncore support arm64/perf: Cavium ThunderX LMC unco

Re: [PATCH v3 0/5] Cavium ThunderX PMU support

2016-02-11 Thread Jan Glauber
On Wed, Feb 03, 2016 at 06:11:55PM +0100, Jan Glauber wrote: > Hi, > > I'm reposting the whole series just in case my previous attempt to > repost only the broken patch was confusing. Patches are based on > 4.5-rc2. Can I get a review for these patches? thanks, Jan > Patch

Re: [PATCH v2 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-01-29 Thread Jan Glauber
a note to > help improving the system] > > url: > https://github.com/0day-ci/linux/commits/Jan-Glauber/Cavium-ThunderX-PMU-support/20160128-225855 > base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux for-next > config: arm-corgi_defconfig (attached as .config)

[PATCH v2 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-01-29 Thread Jan Glauber
ARMv8.1 increases the PMU event number space. Detect the presence of this PMUv3 type and extend the event mask. The event mask is moved to struct arm_pmu so different event masks can exist, depending on the PMU type. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm/

[PATCH v3 0/5] Cavium ThunderX PMU support

2016-02-03 Thread Jan Glauber
. Without this change perf does not work at all on ThunderX. Patch 5 extends the event mask according to ARMv8.1 and also affects arm32. Changes to v2: - fixed arm compile errors Changes to v1: - renamed thunderx dt pmu binding to thunder --Jan Jan Glauber (5): arm64/perf: Rename Cortex A57

[PATCH v3 2/5] arm64/perf: Add Cavium ThunderX PMU support

2016-02-03 Thread Jan Glauber
icache prefetch counters Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 69 +- 1 file changed, 68 insertions(+), 1 deletion(-) diff --git a/arch/arm64/kernel/perf_event.c b/arch/arm64/kernel/perf_event.c index 3

[PATCH v3 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-02-03 Thread Jan Glauber
counter always sets the upper 32 bits so overflow interrupts are generated as before. Original patch from Andrew Pinksi <andrew.pin...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 21 - 1 file changed, 1

[PATCH v3 1/5] arm64/perf: Rename Cortex A57 events

2016-02-03 Thread Jan Glauber
The implemented Cortex A57 events are not A57 specific. They are recommended by ARM and can be found on other ARMv8 SOCs like Cavium ThunderX too. Therefore move these events to the common PMUv3 table. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.

[PATCH v3 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-02-03 Thread Jan Glauber
ARMv8.1 increases the PMU event number space. Detect the presence of this PMUv3 type and extend the event mask. The event mask is moved to struct arm_pmu so different event masks can exist, depending on the PMU type. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm/

[PATCH v3 3/5] arm64: dts: Add Cavium ThunderX specific PMU

2016-02-03 Thread Jan Glauber
Add a compatible string for the Cavium ThunderX PMU. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- Documentation/devicetree/bindings/arm/pmu.txt | 1 + arch/arm64/boot/dts/cavium/thunder-88xx.dtsi | 5 + 2 files changed, 6 insertions(+) diff --git a/Documentation/devicetree/bi

[PATCH v2 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-01-28 Thread Jan Glauber
counter always sets the upper 32 bits so overflow interrupts are generated as before. Original patch from Andrew Pinksi <andrew.pin...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 21 - 1 file changed, 1

[PATCH v2 1/5] arm64/perf: Rename Cortex A57 events

2016-01-28 Thread Jan Glauber
The implemented Cortex A57 events are not A57 specific. They are recommended by ARM and can be found on other ARMv8 SOCs like Cavium ThunderX too. Therefore move these events to the common PMUv3 table. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.

[PATCH v2 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-01-28 Thread Jan Glauber
ARMv8.1 increases the PMU event number space. Detect the presence of this PMUv3 type and extend the event mask. The event mask is moved to struct arm_pmu so different event masks can exist, depending on the PMU type. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/

[PATCH v2 2/5] arm64/perf: Add Cavium ThunderX PMU support

2016-01-28 Thread Jan Glauber
icache prefetch counters Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 69 +- 1 file changed, 68 insertions(+), 1 deletion(-) diff --git a/arch/arm64/kernel/perf_event.c b/arch/arm64/kernel/perf_event.c index 3

[PATCH v2 0/5] Cavium ThunderX PMU support

2016-01-28 Thread Jan Glauber
Hi Mark & Will, I'm resending the arm64 PMU patches. The only difference to the first version is that I dropped the x on thunder in order to be consistent with the existing device tree name. Thanks, Jan Jan Glauber (5): arm64/perf: Rename Cortex A57 events arm64/perf: Add Cavium Thun

[PATCH v2 3/5] arm64: dts: Add Cavium ThunderX specific PMU

2016-01-28 Thread Jan Glauber
Add a compatible string for the Cavium ThunderX PMU. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- Documentation/devicetree/bindings/arm/pmu.txt | 1 + arch/arm64/boot/dts/cavium/thunder-88xx.dtsi | 5 + 2 files changed, 6 insertions(+) diff --git a/Documentation/devicetree/bi

[RFC PATCH 1/2] i2c: Split i2c-octeon driver and add ThunderX support

2016-02-24 Thread Jan Glauber
The ThunderX SOC uses the same i2c block as the Octeon SOC. The main difference is that on ThunderX the device is a PCI device so device probing is done via PCI. Split the current Octeon driver into an Octeon and a common part and add the ThunderX support. Signed-off-by: Jan Glauber <jg

[RFC PATCH 0/2] ThunderX i2c driver

2016-02-24 Thread Jan Glauber
Hi, these two patches add support for the Cavium ThunderX SOC. The patches are on-top of the previous i2c-octeon series. Please review, feedback welcome! Jan Jan Glauber (2): i2c: Split i2c-octeon driver and add ThunderX support i2c

[RFC PATCH 2/2] i2c: thunderx: Add smbus support

2016-02-24 Thread Jan Glauber
Add smbus alert interrupt support. Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/busses/i2c-cavium.h| 4 drivers/i2c/busses/i2c-thunderx-core.c | 31 +++ 2 files changed, 3

Re: [PATCH v4 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-02-22 Thread Jan Glauber
On Thu, Feb 18, 2016 at 05:34:28PM +, Will Deacon wrote: > On Thu, Feb 18, 2016 at 05:50:13PM +0100, Jan Glauber wrote: > > With the long cycle counter bit (LC) disabled the cycle counter is not > > working on ThunderX SOC (ThunderX only implements Aarch64). >

Re: [PATCH v4 3/5] arm64: dts: Add Cavium ThunderX specific PMU

2016-02-22 Thread Jan Glauber
On Thu, Feb 18, 2016 at 05:32:48PM +, Will Deacon wrote: > On Thu, Feb 18, 2016 at 05:50:12PM +0100, Jan Glauber wrote: > > Add a compatible string for the Cavium ThunderX PMU. > > Stupid question, but is "thunder" the name of the CPU or the SoC or ...? > &

[Resend PATCH 03/10] i2c-octeon: Enable high-level controller and improve on bus contention

2016-02-29 Thread Jan Glauber
or of ACK on final byte of non-final read msgs too. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 583 ++-- 1 file changed, 504 insertions(+), 79 del

[Resend PATCH 10/10] i2c: thunderx: add smbus support

2016-02-29 Thread Jan Glauber
Add smbus alert interrupt support. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-cavium.h| 4 drivers/i2c/busses/i2c-thunderx-core.c | 31 +++ 2 files changed, 35 insertions(+) diff --git a/drivers/i2c/busses/i2c-cavi

[Resend PATCH 05/10] i2c-octeon: Add support for cn78XX chips

2016-02-29 Thread Jan Glauber
From: David Daney <dda...@caviumnetworks.com> cn78XX has a different interrupt architecture, so we have to manage the interrupts differently. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/

[Resend PATCH 07/10] i2c-octeon: Faster operation when IFLG signals late

2016-02-29 Thread Jan Glauber
easure ~5.2kB/s, about 1/2 what's achievable, and much better than the worst-case 100 bytes/sec before. Signed-off-by: Peter Swain <psw...@cavium.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/

[Resend PATCH 00/10] i2c-octeon and i2c-thunderx drivers

2016-02-29 Thread Jan Glauber
Daney (4): i2c-octeon: Support I2C_M_RECV_LEN i2c-octeon: Enable high-level controller and improve on bus contention i2c-octeon: Add support for cn78XX chips i2c-octeon: Add workaround for chips with broken irqs Jan Glauber (4): i2c-octeon: Cleanup i2c-octeon driver dt-bindings: i2c: add

[Resend PATCH 06/10] i2c-octeon: Flush TWSI writes with readback

2016-02-29 Thread Jan Glauber
From: Peter Swain <psw...@cavium.com> Signed-off-by: Peter Swain <psw...@cavium.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/busses/i2c-octeon.c | 19 --- 1 file changed, 12 in

[Resend PATCH 04/10] dt-bindings: i2c: add Octeon cn78xx TWSI

2016-02-29 Thread Jan Glauber
Add compatible string for Cavium Octeon cn78XX SOCs TWSI. Cc: Rob Herring <robh...@kernel.org> Cc: Pawel Moll <pawel.m...@arm.com> Cc: Mark Rutland <mark.rutl...@arm.com> Cc: Ian Campbell <ijc+devicet...@hellion.org.uk> Cc: Kumar Gala <ga...@codeaurora.org> Sig

[Resend PATCH 08/10] i2c-octeon: Add workaround for chips with broken irqs

2016-02-29 Thread Jan Glauber
; Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 46 + 1 file changed, 46 insertions(+) diff --git a/drivers/i2c/busses/i2c-octeon.c b/drivers/i2c/busses/i2c-octeon.c index e3552e5..3c2f848 100644 --- a/drivers/i2c/b

[Resend PATCH 01/10] i2c-octeon: Cleanup i2c-octeon driver

2016-02-29 Thread Jan Glauber
Cleanup only without functional change. Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/busses/i2c-octeon.c | 442 +--- 1 file changed, 230 insertions(+), 212 deletions(-) diff --g

[Resend PATCH 02/10] i2c-octeon: Support I2C_M_RECV_LEN

2016-02-29 Thread Jan Glauber
From: David Daney <dda...@caviumnetworks.com> If I2C_M_RECV_LEN is set consider the length byte. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 15 +-- 1 file changed, 1

[Resend PATCH 09/10] i2c: split i2c-octeon driver and add ThunderX support

2016-02-29 Thread Jan Glauber
The ThunderX SOC uses the same i2c block as the Octeon SOC. The main difference is that on ThunderX the device is a PCI device so device probing is done via PCI. Split the current Octeon driver into an Octeon and a common part and add the ThunderX support. Signed-off-by: Jan Glauber <jg

Re: [PATCH v3 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-02-17 Thread Jan Glauber
On Tue, Feb 16, 2016 at 03:12:53PM +, Will Deacon wrote: > On Tue, Feb 16, 2016 at 09:00:15AM +0100, Jan Glauber wrote: > > On Mon, Feb 15, 2016 at 08:04:04PM +, Will Deacon wrote: > > > > [...] > > > > > On Wed, Feb 03, 2016 at

[RFC PATCH 0/8] i2c-octeon update

2016-02-18 Thread Jan Glauber
for chips with broken irqs Jan Glauber (2): i2c-octeon: Cleanup i2c-octeon driver dt-bindings: i2c: add Octeon cn78xx TWSI Peter Swain (2): i2c-octeon: Flush TWSI writes with readback i2c-octeon: Faster operation when IFLG signals late .../devicetree/bindings/i2c/i2c-octeon.txt

[RFC PATCH 1/8] i2c-octeon: Cleanup i2c-octeon driver

2016-02-18 Thread Jan Glauber
Cleanup only without functional change. Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/busses/i2c-octeon.c | 442 +--- 1 file changed, 230 insertions(+), 212 deletions(-) diff --g

[RFC PATCH 2/8] i2c-octeon: Support I2C_M_RECV_LEN

2016-02-18 Thread Jan Glauber
From: David Daney <dda...@caviumnetworks.com> If I2C_M_RECV_LEN is set consider the length byte. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 15 +-- 1 file changed, 1

[RFC PATCH 7/8] i2c-octeon: Faster operation when IFLG signals late

2016-02-18 Thread Jan Glauber
easure ~5.2kB/s, about 1/2 what's achievable, and much better than the worst-case 100 bytes/sec before. Signed-off-by: Peter Swain <psw...@cavium.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/

[RFC PATCH 6/8] i2c-octeon: Flush TWSI writes with readback

2016-02-18 Thread Jan Glauber
From: Peter Swain <psw...@cavium.com> Signed-off-by: Peter Swain <psw...@cavium.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/busses/i2c-octeon.c | 19 --- 1 file changed, 12 in

[RFC PATCH 4/8] dt-bindings: i2c: add Octeon cn78xx TWSI

2016-02-18 Thread Jan Glauber
Add compatible string for Cavium Octeon cn78XX SOCs TWSI. Cc: Rob Herring <robh...@kernel.org> Cc: Pawel Moll <pawel.m...@arm.com> Cc: Mark Rutland <mark.rutl...@arm.com> Cc: Ian Campbell <ijc+devicet...@hellion.org.uk> Cc: Kumar Gala <ga...@codeaurora.org> Sig

[RFC PATCH 5/8] i2c-octeon: Add support for cn78XX chips

2016-02-18 Thread Jan Glauber
From: David Daney <dda...@caviumnetworks.com> cn78XX has a different interrupt architecture, so we have to manage the interrupts differently. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/

[RFC PATCH 8/8] i2c-octeon: Add workaround for chips with broken irqs

2016-02-18 Thread Jan Glauber
; Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 46 + 1 file changed, 46 insertions(+) diff --git a/drivers/i2c/busses/i2c-octeon.c b/drivers/i2c/busses/i2c-octeon.c index e3552e5..3c2f848 100644 --- a/drivers/i2c/b

[RFC PATCH 3/8] i2c-octeon: Enable high-level controller and improve on bus contention

2016-02-18 Thread Jan Glauber
or of ACK on final byte of non-final read msgs too. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 583 ++-- 1 file changed, 504 insertions(+), 79 del

Re: [PATCH v3 1/5] arm64/perf: Rename Cortex A57 events

2016-02-18 Thread Jan Glauber
On Mon, Feb 15, 2016 at 08:06:13PM +, Will Deacon wrote: > On Mon, Feb 15, 2016 at 07:40:37PM +, Will Deacon wrote: > > On Wed, Feb 03, 2016 at 06:11:56PM +0100, Jan Glauber wrote: > > > The implemented Cortex A57 events are not A57 specific. > > > They are

Re: [PATCH v3 1/5] arm64/perf: Rename Cortex A57 events

2016-02-18 Thread Jan Glauber
On Thu, Feb 18, 2016 at 11:24:29AM +, Will Deacon wrote: > On Thu, Feb 18, 2016 at 10:13:07AM +0100, Jan Glauber wrote: > > On Mon, Feb 15, 2016 at 08:06:13PM +, Will Deacon wrote: > > > On Mon, Feb 15, 2016 at 07:40:37PM +, Will Deacon wrote: > > > > On W

[PATCH v4 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-02-18 Thread Jan Glauber
ARMv8.1 increases the PMU event number space to 16 bit so increase the EVTYPE mask. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm64/kernel/perf_event.c b/arch/arm64/

[PATCH v4 3/5] arm64: dts: Add Cavium ThunderX specific PMU

2016-02-18 Thread Jan Glauber
Add a compatible string for the Cavium ThunderX PMU. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- Documentation/devicetree/bindings/arm/pmu.txt | 1 + arch/arm64/boot/dts/cavium/thunder-88xx.dtsi | 5 + 2 files changed, 6 insertions(+) diff --git a/Documentation/devicetree/bi

[PATCH v4 0/5] Cavium ThunderX PMU support

2016-02-18 Thread Jan Glauber
compile errors Changes to v1: - renamed thunderx dt pmu binding to thunder Jan Jan Glauber (5): arm64/perf: Rename Cortex A57 events arm64/perf: Add Cavium ThunderX PMU support arm64: dts: Add Cavium ThunderX specific PMU arm64

[PATCH v4 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-02-18 Thread Jan Glauber
counter always sets the upper 32 bits so overflow interrupts are generated as before. Original patch from Andrew Pinksi <andrew.pin...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 21 - 1 file changed, 1

[PATCH v4 1/5] arm64/perf: Rename Cortex A57 events

2016-02-18 Thread Jan Glauber
The implemented Cortex A57 events are strictly-speaking not A57 specific. They are ARM recommended implementation defined events and can be found on other ARMv8 SOCs like Cavium ThunderX too. Therefore rename these events to allow using them in other implementations too. Signed-off-by: Jan

[PATCH v4 2/5] arm64/perf: Add Cavium ThunderX PMU support

2016-02-18 Thread Jan Glauber
icache prefetch counters Signed-off-by: Jan Glauber <jglau...@cavium.com> --- arch/arm64/kernel/perf_event.c | 69 +- 1 file changed, 68 insertions(+), 1 deletion(-) diff --git a/arch/arm64/kernel/perf_event.c b/arch/arm64/kernel/perf_event.c index 2

Re: [PATCH v4 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-02-18 Thread Jan Glauber
On Thu, Feb 18, 2016 at 05:34:28PM +, Will Deacon wrote: > On Thu, Feb 18, 2016 at 05:50:13PM +0100, Jan Glauber wrote: > > With the long cycle counter bit (LC) disabled the cycle counter is not > > working on ThunderX SOC (ThunderX only implements Aarch64). >

Re: [RFC PATCH 1/7] arm64/perf: Basic uncore counter support for Cavium ThunderX

2016-02-15 Thread Jan Glauber
Hi Mark, thanks for reviewing! I'll need several mails to address all questions. On Fri, Feb 12, 2016 at 05:36:59PM +, Mark Rutland wrote: > On Fri, Feb 12, 2016 at 05:55:06PM +0100, Jan Glauber wrote: > > Provide uncore facilities for non-CPU performance counter units. > >

Re: [RFC PATCH 1/7] arm64/perf: Basic uncore counter support for Cavium ThunderX

2016-02-15 Thread Jan Glauber
On Mon, Feb 15, 2016 at 02:27:27PM +, Mark Rutland wrote: > > > > 1) The PMU detection solely relies on PCI device detection. If a > > > >matching PCI device is found the PMU is created. The code can deal > > > >with multiple units of the same type, e.g. more than one memory > > > >

Re: [PATCH v3 5/5] arm64/perf: Extend event mask for ARMv8.1

2016-02-16 Thread Jan Glauber
On Mon, Feb 15, 2016 at 08:04:04PM +, Will Deacon wrote: [...] > On Wed, Feb 03, 2016 at 06:12:00PM +0100, Jan Glauber wrote: > > + cpu_pmu->event_mask = 0x; /* ARMv8.1 extended events */ > > + else > > + cpu_pmu->event_mask = ARMV8_EVTY

Re: [PATCH v3 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-02-16 Thread Jan Glauber
On Mon, Feb 15, 2016 at 07:55:29PM +, Will Deacon wrote: > On Wed, Feb 03, 2016 at 06:11:59PM +0100, Jan Glauber wrote: > > @@ -768,8 +776,11 @@ static void armv8pmu_reset(void *info) > > armv8pmu_disable_intens(idx); > > } > > > > - /* Init

Re: [RFC PATCH 1/7] arm64/perf: Basic uncore counter support for Cavium ThunderX

2016-02-16 Thread Jan Glauber
On Fri, Feb 12, 2016 at 05:36:59PM +, Mark Rutland wrote: > On Fri, Feb 12, 2016 at 05:55:06PM +0100, Jan Glauber wrote: > > Provide uncore facilities for non-CPU performance counter units. > > Based on Intel/AMD uncore pmu support. > > > > The uncore PMUs

Re: [PATCH v4 4/5] arm64/perf: Enable PMCR long cycle counter bit

2016-02-29 Thread Jan Glauber
On Mon, Feb 29, 2016 at 03:39:35PM +, Will Deacon wrote: > Hi Jan, > > I've queued this lot on my perf/updates branch, but I just noticed an > oddity whilst dealing with some potential conflicts with the kvm tree. > > On Thu, Feb 18, 2016 at 05:50:13PM +0100,

[PATCH v4 08/14] i2c-octeon: Flush TWSI writes with readback

2016-03-18 Thread Jan Glauber
From: Peter Swain <psw...@cavium.com> Signed-off-by: Peter Swain <psw...@cavium.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/busses/i2c-octeon.c | 19 --- 1 file changed, 12 in

[PATCH v4 12/14] i2c-octeon: Split the driver into two parts

2016-03-18 Thread Jan Glauber
Move common functionality into a separate file in preparation of the re-use from the ThunderX i2c driver. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/Makefile | 3 +- drivers/i2c/busses/i2c-cavium.c | 822 + drive

[PATCH v4 02/14] i2c-octeon: Cleanup resource allocation code

2016-03-18 Thread Jan Glauber
Remove resource values from struct i2c_octeon and use devm_ioremap_resource helper. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 18 +++--- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/drivers/i2c/busses/i2c-octe

[PATCH v4 01/14] i2c-octeon: Cleanup i2c-octeon driver

2016-03-18 Thread Jan Glauber
if the result is not used (octeon_i2c_stop, octeon_i2c_set_clock) - remove debug code from octeon_i2c_stop - renamed some functions for readability - update copyright Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 190 ++---

Re: [PATCH v3 02/14] i2c-octeon: Cleanup i2c-octeon driver

2016-03-14 Thread Jan Glauber
On Sat, Mar 12, 2016 at 04:35:00PM +0100, Wolfram Sang wrote: > On Mon, Mar 07, 2016 at 04:10:45PM +0100, Jan Glauber wrote: > > Cleanup only without functional change. > > I like most of the changes, but there are still some functional changes > left. > > > -static

Re: [PATCH v3 03/14] i2c-octeon: Cleanup resource allocation code

2016-03-14 Thread Jan Glauber
On Sat, Mar 12, 2016 at 04:37:15PM +0100, Wolfram Sang wrote: > On Mon, Mar 07, 2016 at 04:10:46PM +0100, Jan Glauber wrote: > > From: David Daney <david.da...@cavium.com> > > > > Use resource start and size directly. > > > > Signed-off-by: David Daney

Re: [PATCH v3 05/14] i2c-octeon: Make adapter timeout tunable

2016-03-14 Thread Jan Glauber
On Sat, Mar 12, 2016 at 04:46:12PM +0100, Wolfram Sang wrote: > On Mon, Mar 07, 2016 at 04:10:48PM +0100, Jan Glauber wrote: > > From: Peter Swain <psw...@cavium.com> > > > > Make the i2c adapter timeout a module parameter to allow upper-level > > target devic

Re: [RFC PATCH 1/7] arm64/perf: Basic uncore counter support for Cavium ThunderX

2016-03-11 Thread Jan Glauber
On Fri, Feb 12, 2016 at 05:36:59PM +, Mark Rutland wrote: > On Fri, Feb 12, 2016 at 05:55:06PM +0100, Jan Glauber wrote: [...] > > +int thunder_uncore_event_init(struct perf_event *event) > > +{ > > + struct hw_perf_event *hwc = >hw; > > +

[PATCH v4 05/14] i2c-octeon: Enable high-level controller and improve on bus contention

2016-03-19 Thread Jan Glauber
or of ACK on final byte of non-final read msgs too. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 783 1 file changed, 629 insertions(+), 154 del

[PATCH v4 09/14] i2c-octeon: Faster operation when IFLG signals late

2016-03-19 Thread Jan Glauber
easure ~5.2kB/s, about 1/2 what's achievable, and much better than the worst-case 100 bytes/sec before. Signed-off-by: Peter Swain <psw...@cavium.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> Acked-by: David Daney <dda...@caviumnetworks.com> --- drivers/i2c/

[PATCH v4 04/14] i2c-octeon: Support I2C_M_RECV_LEN

2016-03-19 Thread Jan Glauber
From: David Daney <david.da...@cavium.com> If I2C_M_RECV_LEN is set consider the length byte. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 22 +- 1 file chan

[PATCH v4 10/14] i2c-octeon: Add workaround for broken irqs on CN3860

2016-03-19 Thread Jan Glauber
From: David Daney <david.da...@cavium.com> CN3860 does not interrupt the CPU when the i2c status changes. If we get a timeout, and see the status has in fact changed, we know we have this problem, and drop back to polling. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed

[PATCH v4 14/14] i2c-thunderx: Add smbus alert support

2016-03-19 Thread Jan Glauber
Add smbus alert interrupt support. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-cavium.h| 6 ++ drivers/i2c/busses/i2c-thunderx-core.c | 35 ++ 2 files changed, 41 insertions(+) diff --git a/drivers/i2c/buss

[PATCH v4 03/14] i2c-octeon: Change adapter timeout and retry default values

2016-03-19 Thread Jan Glauber
Convert the adapter timeout to 2 ms instead of a fixed number of jiffies and set retries to 10. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/i2c-octeon.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/i2c/busses/i2c-octeon.c b/drive

[PATCH v4 11/14] i2c-octeon: Rename driver to prepare for split

2016-03-19 Thread Jan Glauber
This is just an intermediate commit in preparation of the driver split. The module rename in this commit will be reverted in the next patch, this is just done to make the series bisectible. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/Makefile

[PATCH v4 13/14] i2c-thunderx: Add i2c driver for ThunderX SOC

2016-03-18 Thread Jan Glauber
The ThunderX SOC uses the same i2c block as the Octeon SOC. The main difference is that on ThunderX the device is a PCI device so device probing is done via PCI, interrupts are MSIX and the clock is taken from device tree. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/

[PATCH v4 07/14] i2c-octeon: Add support for cn78xx chips

2016-03-18 Thread Jan Glauber
From: David Daney <david.da...@cavium.com> cn78xx has a different interrupt architecture, so we have to manage the interrupts differently. Signed-off-by: David Daney <dda...@caviumnetworks.com> Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/i2c/busses/

[PATCH v4 06/14] dt-bindings: i2c: Add Octeon cn78xx TWSI

2016-03-18 Thread Jan Glauber
Add compatible string for Cavium Octeon cn78XX SOCs TWSI. Cc: Rob Herring <robh...@kernel.org> Cc: Pawel Moll <pawel.m...@arm.com> Cc: Mark Rutland <mark.rutl...@arm.com> Cc: Ian Campbell <ijc+devicet...@hellion.org.uk> Cc: Kumar Gala <ga...@codeaurora.org> Sig

[PATCH v4 00/14] i2c-octeon and i2c-thunderx drivers

2016-03-18 Thread Jan Glauber
i2c-octeon: Add support for cn78xx chips i2c-octeon: Add workaround for broken irqs on CN3860 Jan Glauber (8): i2c-octeon: Cleanup i2c-octeon driver i2c-octeon: Cleanup resource allocation code i2c-octeon: Change adapter timeout and retry default values dt-bindings: i2c: Add Octeon cn78xx

[PATCH v2 2/5] arm64/perf: Cavium ThunderX L2C TAD uncore support

2016-03-09 Thread Jan Glauber
Support counters of the L2 Cache tag and data units. Also support pass2 added/modified counters by checking MIDR. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/perf/uncore/Makefile| 3 +- drivers/perf/uncore/uncore_cavium.c | 6 +- drivers/perf/

[PATCH v2 0/5] Cavium ThunderX uncore PMU support

2016-03-09 Thread Jan Glauber
device limit - trimmed include files Feedback welcome! Jan - Jan Glauber (5): arm64/perf: Basic uncore counter support for Cavium ThunderX arm64/perf: Cavium ThunderX L2C TAD uncore support arm64/perf: Cavium ThunderX L2C CBC uncore support

[PATCH v2 4/5] arm64/perf: Cavium ThunderX LMC uncore support

2016-03-09 Thread Jan Glauber
Support counters on the DRAM controllers. Also support pass2 added counters by checking MIDR. Signed-off-by: Jan Glauber <jglau...@cavium.com> --- drivers/perf/uncore/Makefile| 3 +- drivers/perf/uncore/uncore_cavium.c | 3 + drivers/perf/uncore/uncore_cavium.h

  1   2   3   4   5   6   >