[PATCH] staging: octeon-usb: use a helper function to set the DMA mask

2018-12-04 Thread Aaro Koskinen
Use a helper function to set the DMA mask. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 9c766f5b812f

[PATCH] staging: octeon-ethernet: delete redundant include

2018-12-05 Thread Aaro Koskinen
cvmx-smix-defs.h is not needed by this driver. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-mdio.c | 1 - drivers/staging/octeon/ethernet.c | 1 - 2 files changed, 2 deletions(-) diff --git a/drivers/staging/octeon/ethernet-mdio.c b/drivers/staging/octeon/ethernet

[PATCH] staging: octeon: fix broken phylib usage

2019-01-27 Thread Aaro Koskinen
quot;) Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-mdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/octeon/ethernet-mdio.c b/drivers/staging/octeon/ethernet-mdio.c index 2848fa71a33d..d6248eecf123 100644 --- a/drivers/staging/octeon/e

Re: [PATCH] staging: octeon-usb octeon-hcd: Fix several typos.

2019-03-15 Thread Aaro Koskinen
Hi, On Sat, Mar 09, 2019 at 03:18:27PM -0300, Laura Lazzati wrote: > I found that the comments had several typos such as "aenable", "internaly" > and some others. > I fixed them all. > > Signed-off-by: Laura Lazzati I spotted one more typo that could be fixed as well: > @@ -1797,7 +1797,7 @@

[PATCH] staging: octeon-ethernet: fix incorrect PHY mode

2019-03-25 Thread Aaro Koskinen
rrect mode. Tested on EdgeRouter Lite (RGMII_RXID, at803x PHY) and D-Link DSR-500N (RGMII, broadcom PHY). Fixes: 6d4cd041f0af ("net: phy: at803x: disable delay only for RGMII mode") Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-mdio.c | 2 +- drivers/stagi

Re: [PATCH] staging: octeon-ethernet: fix incorrect PHY mode

2019-03-26 Thread Aaro Koskinen
Hi, On Tue, Mar 26, 2019 at 10:01:50AM +0100, Andrew Lunn wrote: > Humm, that is unique, as far as i know. Every other MAC driver uses > of_get_phy_mode() to get the value out of device tree. The proprietary > delay values can then be used to fine tune the basic delay setting > read from DT. Prob

Re: [PATCH] staging: octeon: Remove typedef declaration

2019-10-23 Thread Aaro Koskinen
Hi, On Tue, Oct 08, 2019 at 07:09:43AM +0300, Wambui Karuga wrote: > Fixes checkpatch.pl warning: do not add new typedefs in > drivers/staging/octeon/octeon-stubs.h:41 > > Signed-off-by: Wambui Karuga > --- > drivers/staging/octeon/octeon-stubs.h | 6 +++--- > 1 file changed, 3 insertions(+), 3

Re: [PATCH] staging: octeon: Fix incorrect type in assignment

2019-10-23 Thread Aaro Koskinen
Hi, On Thu, Oct 10, 2019 at 07:38:15AM +0300, Wambui Karuga wrote: > Fix the following warning generated by sparse in > drivers/staging/octeon/ethernet-tx.c: > > drivers/staging/octeon/ethernet-tx.c:563:50: warning: incorrect type in > assignment (different base types) > drivers/staging/octeon/e

Re: [Outreachy kernel] [PATCH v2 0/5] Remove typedef declarations in staging: octeon

2019-10-23 Thread Aaro Koskinen
Hi, On Sat, Oct 12, 2019 at 08:35:19PM +0200, Julia Lawall wrote: > On Sat, 12 Oct 2019, Wambui Karuga wrote: > > This patchset removes the addition of new typedefs data types in octeon, > > along with replacing the previous uses with the new declaration format. > > > > v2 of the series removes th

[PATCH] staging: octeon-ethernet: drop multiple NAPI instances

2014-11-07 Thread Aaro Koskinen
has issues like packet reordering and potential problems with CPU offlining/onlining. Tested on EdgeRouter Lite. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-rx.c | 109 +++ drivers/staging/octeon/ethernet.c| 6 -- drivers/staging/octeon/octeo

[PATCH 1/2] staging: octeon-usb: move helper functions

2014-11-07 Thread Aaro Koskinen
Move helper functions to make them visible to all functions. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb

[PATCH 2/2] staging: octeon-usb: eliminate cvmx_dprintf() usage

2014-11-07 Thread Aaro Koskinen
Eliminate cvmx_dprintf() usage and use dev_err() instead. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c

Re: [PATCH] staging: octeon-ethernet: drop multiple NAPI instances

2014-11-07 Thread Aaro Koskinen
Hi, On Fri, Nov 07, 2014 at 01:17:23PM -0800, David Daney wrote: > On 11/07/2014 12:44 PM, Aaro Koskinen wrote: > >Octeon Ethernet driver is currently trying to wake up multiple > >CPU cores for parallel NAPI processing when needed, to cope > >with the fact that all network i

Re: [PATCH] Staging: octeon: Added several blank lines after declarations

2014-12-03 Thread Aaro Koskinen
Hi, On Wed, Dec 03, 2014 at 09:43:51PM +, Jamie Lawler wrote: > --- a/drivers/staging/octeon/ethernet-rx.c > +++ b/drivers/staging/octeon/ethernet-rx.c > @@ -84,6 +84,7 @@ static int cvm_irq_cpu; > static void cvm_oct_enable_napi(void *_) > { > int cpu = smp_processor_id(); > + >

[PATCH 2/2] staging: octeon-ethernet: add TODO

2019-04-25 Thread Aaro Koskinen
Add missing TODO to describe the plan to get this driver out of staging. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/TODO | 9 + 1 file changed, 9 insertions(+) create mode 100644 drivers/staging/octeon/TODO diff --git a/drivers/staging/octeon/TODO b/drivers/staging/octeon

[PATCH 1/2] staging: refer to TODO in Kconfig help text

2019-04-25 Thread Aaro Koskinen
Refer to TODO file instead of driver_name.README that does not seem to be used. Signed-off-by: Aaro Koskinen --- drivers/staging/Kconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/Kconfig b/drivers/staging/Kconfig index 62951e836cbc..35aa09ed3972

Re: [PATCH] staging: xgifb: delete the driver

2019-04-25 Thread Aaro Koskinen
Hi, On Fri, Jan 18, 2019 at 12:20:28PM +0100, Daniel Vetter wrote: > On Fri, Jan 18, 2019 at 11:08:28AM +0100, Greg Kroah-Hartman wrote: > > There has not been any real work done on cleaning this driver up and > > getting it out of the staging tree in years. Also, no new fb drivers > > are being

TODO advice for octeon-usb?

2019-05-20 Thread Aaro Koskinen
Hi, I'm looking for input what should be done next to get drivers/staging/octeon-usb out of staging. Thousands of checkpatch errors/warnings have been fixed (starting point was ), also the size of the driver has shrunken considerably.

[PATCH] staging: octeon-usb: use __delay() instead of cvmx_wait()

2017-11-17 Thread Aaro Koskinen
Commit edf188bee1d9 ("MIPS: Octeon: Remove usage of cvmx_wait() everywhere.") deleted cvmx_wait() but forgot to update OCTEON USB staging driver. Fix that to allow driver build. Fixes: edf188bee1d9 ("MIPS: Octeon: Remove usage of cvmx_wait() everywhere.") Signed-o

Re: [PATCH] staging: octeon-usb: use __delay() instead of cvmx_wait()

2017-11-17 Thread Aaro Koskinen
Hi, On Fri, Nov 17, 2017 at 11:45:06AM -0600, Steven J. Hill wrote: > On 11/17/2017 04:06 AM, James Hogan wrote: > > On Fri, Nov 17, 2017 at 09:50:10AM +0200, Aaro Koskinen wrote: > >> Commit edf188bee1d9 ("MIPS: Octeon: Remove usage of cvmx_wait() > >> every

Re: [PATCH v3 2/2] Staging: octeon-usb: Changes macro CVMX_WAIT_FOR_FIELD32 to function call.

2018-07-29 Thread Aaro Koskinen
Hi, On Sun, Jul 29, 2018 at 02:40:35PM +0300, Georgios Tsotsos wrote: > +/** > + * Loop through register until txfflsh or rxfflsh become zero. > + * > + * @usb: USB block > + * @address: 64bit address to read > + * @timeout_usec: Timeout > + * @fflsh_type:Indicates fflsh type,

Re: [PATCH v4 1/1] Staging: octeon-usb: Using defined error codes and applying coding style

2018-07-29 Thread Aaro Koskinen
Hi, On Sun, Jul 29, 2018 at 05:33:38PM +0300, Georgios Tsotsos wrote: > diff --git a/drivers/staging/octeon-usb/octeon-hcd.c > b/drivers/staging/octeon-usb/octeon-hcd.c > index 3f44ac260eff..edf87d1b3609 100644 > --- a/drivers/staging/octeon-usb/octeon-hcd.c > +++ b/drivers/staging/octeon-usb/oct

[RFC PATCH 03/11] MIPS: OCTEON: make __cvmx_helper_sgmii/xaui_probe void

2015-05-01 Thread Aaro Koskinen
Make __cvmx_helper_sgmii/xaui_probe void, nobody is using return values and this makes functions independent of enumeration functions. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/cvmx-helper-sgmii.c | 5 + arch/mips/cavium-octeon/executive/cvmx-helper-xaui.c | 5

[RFC PATCH 01/11] MIPS: OCTEON: cvmx-helper: use function to access interface_port_count

2015-05-01 Thread Aaro Koskinen
Use function to access interface_port_count. This allows moving functions requiring the info to different files. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/cvmx-helper.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/mips/cavium-octeon

[RFC PATCH 05/11] MIPS: OCTEON: delete calls to __cvmx_helper_npi/rgmii_probe

2015-05-01 Thread Aaro Koskinen
These calls have no side effects so drop the calls, so that we don't need to export these functions to modules. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/cvmx-helper-ethernet.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/arch/mips/cavium-octeon/executive

[RFC PATCH 00/11] MIPS: OCTEON: move all octeon-ethernet code to staging

2015-05-01 Thread Aaro Koskinen
Tested on EdgeRouter Lite, EdgeRouter Pro and D-Link DSR-1000N. Also build tested with octeon-ethernet as built-in, module and completely disabled. Patches are based on staging-next. A. Aaro Koskinen (11): MIPS: OCTEON: cvmx-helper: use function to access interface_port_count MIPS: OCTEON: mov

[RFC PATCH 07/11] MIPS: OCTEON: make all interface enumeration helpers static

2015-05-01 Thread Aaro Koskinen
Make all interface enumeration helpers static. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/cvmx-helper.c | 10 +- arch/mips/include/asm/octeon/cvmx-helper-npi.h | 11 --- arch/mips/include/asm/octeon/cvmx-helper-rgmii.h | 9 - arch/mips/include

[RFC PATCH 04/11] MIPS: OCTEON: move interface enumeration helpers to cvmx-helper

2015-05-01 Thread Aaro Koskinen
Move interface enumeration helpers to cvmx-helper. Signed-off-by: Aaro Koskinen --- .../mips/cavium-octeon/executive/cvmx-helper-npi.c | 38 --- .../cavium-octeon/executive/cvmx-helper-rgmii.c| 46 .../cavium-octeon/executive/cvmx-helper-sgmii.c| 4 - .../mips/cavium

[RFC PATCH 10/11] MIPS: OCTEON: ethernet: delete unneeded symbol exports

2015-05-01 Thread Aaro Koskinen
Delete unneeded symbol exports. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/cvmx-cmd-queue.c | 1 - drivers/staging/octeon/cvmx-helper-ethernet.c | 5 - drivers/staging/octeon/cvmx-helper-util.c | 4 drivers/staging/octeon/cvmx-pko.c | 2 -- drivers

[RFC PATCH 02/11] MIPS: OCTEON: move ethernet-specific helpers into a separate file

2015-05-01 Thread Aaro Koskinen
Move ethernet-specific helpers into a separate file. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/Makefile | 1 + .../cavium-octeon/executive/cvmx-helper-ethernet.c | 912 arch/mips/cavium-octeon/executive/cvmx-helper.c| 915

[RFC PATCH 08/11] MIPS: OCTEON: move the link helpers into a separate file

2015-05-01 Thread Aaro Koskinen
Move the link helpers into a separate file. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/Makefile | 2 +- .../cavium-octeon/executive/cvmx-helper-board.c| 511 arch/mips/cavium-octeon/executive/cvmx-link.c | 534

[RFC PATCH 06/11] MIPS: OCTEON: rename __cvmx_helper_npi/rgmii_probe

2015-05-01 Thread Aaro Koskinen
Rename __cvmx_helper_npi/rgmii_probe to __cvmx_helper_npi/rgmii_enumerate as only latter are used. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/cvmx-helper.c | 12 ++-- arch/mips/include/asm/octeon/cvmx-helper-npi.h | 7 +++ arch/mips/include/asm/octeon

[RFC PATCH 09/11] MIPS: OCTEON: move ethernet-specific helpers to staging

2015-05-01 Thread Aaro Koskinen
Move all ethernet-specific helpers to staging. Signed-off-by: Aaro Koskinen --- arch/mips/cavium-octeon/executive/Makefile| 8 +--- arch/mips/cavium-octeon/executive/cvmx-helper-board.c | 1 + arch/mips/cavium-octeon/executive/cvmx-helper.c | 1 + drivers

[RFC PATCH 11/11] MIPS: OCTEON: move all ethernet-specific headers to staging

2015-05-01 Thread Aaro Koskinen
Move all ethernet-specific headers to staging. Signed-off-by: Aaro Koskinen --- arch/mips/include/asm/octeon/cvmx-helper-board.h | 70 --- arch/mips/include/asm/octeon/cvmx-helper.h | 124 .../asm => drivers/staging}/octeon/cvmx-address.h | 0 .../staging}/oct

Re: [PATCH 2/2] staging: octeon-usb: delete the octeon usb host controller driver

2019-12-10 Thread Aaro Koskinen
Hi, On Tue, Dec 10, 2019 at 10:15:09AM +0100, Greg Kroah-Hartman wrote: > This driver was merged back in 2013 and shows no progress toward every > being merged into the "correct" part of the kernel. Do you mean all the patches since 2013 were "no progress"? Thanks. > The code doesn't even build

Re: [PATCH 1/2] staging: octeon: delete driver

2019-12-10 Thread Aaro Koskinen
On Tue, Dec 10, 2019 at 01:01:20PM +0100, Greg Kroah-Hartman wrote: > On Tue, Dec 10, 2019 at 12:40:54PM +0100, Sandro Volery wrote: > > Doesn't octeon have drivers out of staging already? > > What is this module for? > > I have no idea :( It's stated in the TODO file you are deleting (visible in

Re: [PATCH 2/2] staging: octeon-usb: delete the octeon usb host controller driver

2019-12-10 Thread Aaro Koskinen
On Tue, Dec 10, 2019 at 09:19:57PM +0100, Greg Kroah-Hartman wrote: > On Tue, Dec 10, 2019 at 09:31:54PM +0200, Aaro Koskinen wrote: > > Hi, > > > > On Tue, Dec 10, 2019 at 10:15:09AM +0100, Greg Kroah-Hartman wrote: > > > This driver was merged back in 2013 and

Re: [PATCH 1/2] staging: octeon: delete driver

2019-12-10 Thread Aaro Koskinen
On Tue, Dec 10, 2019 at 12:15:15PM -0800, Guenter Roeck wrote: > On Tue, Dec 10, 2019 at 09:46:59PM +0200, Aaro Koskinen wrote: > > On Tue, Dec 10, 2019 at 01:01:20PM +0100, Greg Kroah-Hartman wrote: > > > I have no idea :( > > > > It's stated in the TODO fil

[PATCH 4/5] staging: octeon-ethernet: make global_register_lock static

2014-03-01 Thread Aaro Koskinen
Make global_register_lock static to eliminate a sparse warning. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-rgmii.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/octeon/ethernet-rgmii.c b/drivers/staging/octeon/ethernet-rgmii.c index

[PATCH 5/5] staging: octeon-ethernet: add missing include

2014-03-01 Thread Aaro Koskinen
ethernet-mem was missing its own include file, causing sparse to complain about undeclared global functions. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-mem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/octeon/ethernet-mem.c b/drivers/staging/octeon

[PATCH 3/5] staging: octeon-ethernet: make cvm_oct_free_tx_skbs static

2014-03-01 Thread Aaro Koskinen
Make cvm_oct_free_tx_skbs static to eliminate a sparse warning. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-tx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/octeon/ethernet-tx.c b/drivers/staging/octeon/ethernet-tx.c index 47541e1

[PATCH 1/5] staging: octeon-ethernet: drop CONFIG_CAVIUM_OCTEON_NUM_PACKET_BUFFERS

2014-03-01 Thread Aaro Koskinen
We don't have such Kconfig option, so the current code is dead and the documentation is wrong. Users can adjust this setting by using module parameter or kernel command line, so we can delete this code. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-defines.h | 4 dr

[PATCH 2/5] staging: octeon-ethernet: make num_packet_buffers static

2014-03-01 Thread Aaro Koskinen
Make num_packet_buffers static to eliminate a sparse warning. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/octeon/ethernet.c b/drivers/staging/octeon/ethernet.c index 9dbc58f..ff7214a

[PATCH] staging: octeon-usb: prevent memory corruption

2014-03-19 Thread Aaro Koskinen
SLUB kernels. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=72121 Reported-by: Sergey Popov Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 108 1 file changed, 108 insertions(+) diff --git a/drivers/staging/octeon-usb/octeon

Re: [PATCH] staging: octeon-usb: prevent memory corruption

2014-03-23 Thread Aaro Koskinen
Hi, On Sat, Mar 22, 2014 at 01:13:52PM +0400, Sergey Popov wrote: > scsi 0:0:0:0: Direct-Access SanDisk Cruzer Facet 1.26 PQ: 0 ANSI: 5 > sd 0:0:0:0: [sda] 15633408 512-byte logical blocks: (8.00 GB/7.45 GiB) > usb 1-1: reset high-speed USB device number 2 using OcteonUSB > usb 1-1: reset

Re: [PATCH] xgifb coding style cleanup

2014-03-30 Thread Aaro Koskinen
there is something wrong, please let me > know and I'll be glad to fix it. > > Signed-off-by: Vitor Braga Looks fine. Reviewed-by: Aaro Koskinen A. > --- > drivers/staging/xgifb/XGI_main_26.c | 2 ++ > drivers/staging/xgifb/vb_init.c | 2 ++ > drivers/stagi

[PATCH 1/3] staging: octeon: validate interface before calling INDEX

2016-05-31 Thread Aaro Koskinen
Some helper functions call INDEX before checking if the interface is valid. Since pow0 is not a real interface, we get the following errors: cvmx_helper_get_interface_index_num: Illegal IPD port number Fix by using INDEX only when needed with real interfaces. Signed-off-by: Aaro

[PATCH 3/3] staging: octeon: delete redundant log message

2016-05-31 Thread Aaro Koskinen
There will be a separate banner message after pow0 is set up (or an error message if it failed). Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/staging/octeon/ethernet.c b/drivers/staging/octeon/ethernet.c index

[PATCH 2/3] staging: octeon: check for pow0 before calling interface helper

2016-05-31 Thread Aaro Koskinen
Check for pow0 port first before calling the interface helper. This avoids the following error log when setting up pow0 interface: cvmx_helper_get_interface_num: Illegal IPD port number Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-util.h | 7 --- 1 file changed

[PATCH] staging: octeon: refactor rgmii 10 mbps preamble error checking

2016-02-11 Thread Aaro Koskinen
h software preamble removal" logs when interfaces are being bringed up. It also avoids some corner-case crashes when the in-band interrupt triggers while the interface is being taken down. Tested on EdgeRouter Lite & D-Link DSR-1000N. Signed-off-by: Aaro Koskinen --- drivers/staging/oct

[PATCH] staging: octeon: support fixed-link phys

2016-02-13 Thread Aaro Koskinen
Support fixed-link PHYs. This allows to remove some of the board-specific link cvmx_helper code in the future. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-mdio.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/staging/octeon/ethernet-mdio.c b/drivers

[PATCH] staging: octeon-usb: support official bindings

2016-02-13 Thread Aaro Koskinen
Support official DT bindings alongside with the deprecated ones. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb

[PATCH 2/7] staging: octeon-usb: add missing braces

2016-02-16 Thread Aaro Koskinen
Some if branches are missing braces as required by coding style. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon

[PATCH 5/7] staging: octeon-usb: switch to use kernel types

2016-02-16 Thread Aaro Koskinen
Switch to use kernel types: uint64_t -> u64 uint32_t -> u32 uint16_t -> u16 uint8_t -> u8 int8_t -> s8 Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 75 +++-- drivers/staging/octeon-usb/oct

[PATCH 3/7] staging: octeon-usb: delete space after cast

2016-02-16 Thread Aaro Koskinen
Delete space after cast. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 2872653..010b861 100644 --- a

[PATCH 7/7] staging: octeon-usb: make driver name to match the file name

2016-02-16 Thread Aaro Koskinen
Make driver name to match the file name. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 68e42fe..1ec8906 100644

[PATCH 6/7] staging: octeon-usb: add spaces around operator

2016-02-16 Thread Aaro Koskinen
Add spaces around operator to improve readability. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb

[PATCH 1/7] staging: octeon-usb: delete redundant blank lines

2016-02-16 Thread Aaro Koskinen
Delete redundant blank lines. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 21 - 1 file changed, 21 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index eaf6ded..91fce2c 100644 --- a

[PATCH 4/7] staging: octeon-usb: clean up includes

2016-02-16 Thread Aaro Koskinen
Clean up includes. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 22 -- 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 010b861..3165849

[PATCH] staging: octeon: use atomic_long_t

2016-02-18 Thread Aaro Koskinen
Use atomic_long_t, so that we can avoid some 32 vs. 64-bit ifdeffery. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon/ethernet-rx.c | 24 ++-- drivers/staging/octeon/ethernet.c| 9 ++--- 2 files changed, 8 insertions(+), 25 deletions(-) diff --git a/drivers

Re: [PATCH] staging: octeon: use atomic_long_t

2016-02-19 Thread Aaro Koskinen
Hi, On Fri, Feb 19, 2016 at 10:17:54AM -0800, Greg Kroah-Hartman wrote: > On Fri, Feb 19, 2016 at 10:08:07AM -0800, David Daney wrote: > > On 02/18/2016 03:45 PM, Greg Kroah-Hartman wrote: > > >On Fri, Feb 19, 2016 at 12:20:45AM +0200, Aaro Koskinen wrote: > > >>Use

[PATCH v2] staging: octeon: drop atomic usage from rx counters

2016-02-19 Thread Aaro Koskinen
We have only one NAPI poll running at a time, so virtual port rx counters can be updated normally. Update of rx_dropped can still race with the gathering of statistics, but full accuracy is not required there. Signed-off-by: Aaro Koskinen --- Replaces this patch: http://marc.info/?t

[PATCH 10/16] staging: octeon-usb: move control transfer handling into separate function

2016-02-25 Thread Aaro Koskinen
Move control transfer handling into a separate function to avoid deep indentation. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 174 1 file changed, 88 insertions(+), 86 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon

[PATCH 01/16] staging: octeon-usb: use preferred style for NULL comparison

2016-02-25 Thread Aaro Koskinen
Use preferred coding style for NULL comparison. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 1ec8906

[PATCH 08/16] staging: octeon-usb: rename STATUS_SUCCESS to STATUS_OK

2016-02-25 Thread Aaro Koskinen
Rename STATUS_SUCCESS to STATUS_OK. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c

[PATCH 11/16] staging: octeon-usb: move bulk transfer handling into separate function

2016-02-25 Thread Aaro Koskinen
Move bulk transfer handling into a separate function to avoid deep indentation. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 38 + 1 file changed, 38 insertions(+) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers

[PATCH 04/16] staging: octeon-usb: pass transfer type to find_ready_pipe

2016-02-25 Thread Aaro Koskinen
Since we always search the same list, we can just pass the transfer type. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon

[PATCH 13/16] staging: octeon-usb: move isoc transfer handling into separate function

2016-02-25 Thread Aaro Koskinen
Move isochronous transfer handling into a separate function to avoid deep indentation. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 106 1 file changed, 53 insertions(+), 53 deletions(-) diff --git a/drivers/staging/octeon-usb

[PATCH 06/16] staging: octeon-usb: rename cvmx_usb_complete to cvmx_usb_status

2016-02-25 Thread Aaro Koskinen
Rename cvmx_usb_complete to cvmx_usb_status. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 105 1 file changed, 52 insertions(+), 53 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb

[PATCH 15/16] staging: octeon-usb: avoid an overlong line

2016-02-25 Thread Aaro Koskinen
Avoid an overlong line. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 298fcaa..17442b3 100644 --- a/drivers

[PATCH 03/16] staging: octeon-usb: eliminate redundant parameter from find_ready_pipe

2016-02-25 Thread Aaro Koskinen
current_frame always equals usb->frame_number. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 18 ++ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hc

[PATCH 02/16] staging: octeon-usb: align split lines to match open parenthesis

2016-02-25 Thread Aaro Koskinen
Align split lines to match open parenthesis. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 170 +++- 1 file changed, 81 insertions(+), 89 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb

[PATCH 09/16] staging: octeon-usb: fold cvmx_usb_state into octeon_hcd

2016-02-25 Thread Aaro Koskinen
Fold cvmx_usb_state into octeon_hcd. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 255 +++- 1 file changed, 118 insertions(+), 137 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon

[PATCH 05/16] staging: octeon-usb: simplify if statement

2016-02-25 Thread Aaro Koskinen
Simplify if statement to avoid deep nesting. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 33 +++-- 1 file changed, 15 insertions(+), 18 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb

[PATCH 14/16] staging: octeon-usb: move next pipe selection into a separate function

2016-02-25 Thread Aaro Koskinen
Move next pipe selection into a separate function to avoid deep nesting. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 49 +++-- 1 file changed, 28 insertions(+), 21 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b

[PATCH 12/16] staging: octeon-usb: move interrupt transfer handling into separate function

2016-02-25 Thread Aaro Koskinen
Move bulk transfer handling into a separate function to avoid deep indentation. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 74 + 1 file changed, 28 insertions(+), 46 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon

[PATCH 16/16] staging: octeon-usb: update TODO

2016-02-25 Thread Aaro Koskinen
Update TODO. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/TODO | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/staging/octeon-usb/TODO b/drivers/staging/octeon-usb/TODO index cc58a7e..2b29acc 100644 --- a/drivers/staging/octeon-usb/TODO +++ b

[PATCH 07/16] staging: octeon-usb: rename cvmx_usb_perform_complete to cvmx_usb_complete

2016-02-25 Thread Aaro Koskinen
Rename cvmx_usb_perform_complete to cvmx_usb_complete. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 89 - 1 file changed, 42 insertions(+), 47 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging

Re: [PATCH] staging: xgifb: XGI_main_26: Change variables that is never used

2015-01-28 Thread Aaro Koskinen
Hi, On Wed, Jan 28, 2015 at 10:38:07PM +0100, Rickard Strandqvist wrote: > Variable ar assigned a value that is never used. > Instead use the struct variable of the same name. > > This was found using a static code analysis program called cppcheck > > Signed-off-by: Rickard Strandqvist > --- >

[PATCH] staging: xgifb: fix colours on big-endian machines other than powerpc

2015-02-01 Thread Aaro Koskinen
XGI framebuffer supports big-endian machines, but it's currently enabled based on __powerpc__ define (which is wrong, as powerpc can be also little-endian now). Use __BIG_ENDIAN instead. This will fix wrong colours on such machines. Tested on parisc with XGI Z7. Signed-off-by: Aaro Kos

Re: [PATCH] staging: octeon-usb: Made octeon_usb_match const

2015-03-09 Thread Aaro Koskinen
Hi, On Mon, Mar 09, 2015 at 11:09:03PM +0100, Mateusz Kulikowski wrote: > An of_device_id should be const (checkpatch.pl warning). > > Signed-off-by: Mateusz Kulikowski Acked-by: Aaro Koskinen A. ___ devel mailing list de...@linuxdriverpr

Re: [PATCH octeon-usb] fix 'line over 80 characters'

2015-03-18 Thread Aaro Koskinen
Hi, On Wed, Mar 18, 2015 at 08:12:32PM +0530, Amitoj Kaur Chawla wrote: > This file contained a warning of a line being over 80 characters and > so the file has been edited to remove that warning. > > Signed-off-by: Amitoj Kaur Chawla > --- > drivers/staging/octeon-usb/octeon-hcd.c | 2 +- > 1

Re: [PATCH] octeon-usb: fix 'too many leading tabs'

2015-03-18 Thread Aaro Koskinen
Hi, On Wed, Mar 18, 2015 at 10:18:29PM +0530, Amitoj Kaur Chawla wrote: > This file contained a lot of warnings of line of over 80 characters > and that the code needs to be refactored due to nested if else > conditions. > > The file was accordingly edited to remove some of the warnings. > > Sig

[PATCH 10/18] staging: octeon-usb: don't poll interrupts early

2015-03-22 Thread Aaro Koskinen
Don't poll interrupts before we have registered the HCD. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 74e2f56..1a

[PATCH 02/18] staging: octeon-usb: eliminate 64-bit register access wrappers

2015-03-22 Thread Aaro Koskinen
Eliminate 64-bit register access wrappers. Since we don't implement register-level debugging outputs, these are useless. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 108 ++-- 1 file changed, 33 insertions(+), 75 deletions(-) diff

[PATCH 00/18] staging: octeon-usb: cleanups and reliability improvements

2015-03-22 Thread Aaro Koskinen
Hi, Here's some cleanups and error handling improvements for octeon-usb. Tested on two different OCTEON setups, EdgeRouter Lite & D-Link DSR-1000N mainly with USB mass storage. A. Aaro Koskinen (18): staging: octeon-usb: remove internal function parameter sanity checks staging: o

[PATCH 01/18] staging: octeon-usb: remove internal function parameter sanity checks

2015-03-22 Thread Aaro Koskinen
Remove some function parameter sanity checks from internal functions where we can rely them being called with sane parameters. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 41 - 1 file changed, 41 deletions(-) diff --git a/drivers

[PATCH 08/18] staging: octeon-usb: never retry after xacterr

2015-03-22 Thread Aaro Koskinen
Never retry after xacterr. The DMA engine cannot handle that properly and may result in wrong transfer count and hang. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 38 + 1 file changed, 5 insertions(+), 33 deletions(-) diff --git a

[PATCH 07/18] staging: octeon-usb: program DMA engine based on transfer direction

2015-03-22 Thread Aaro Koskinen
Program DMA engine based on transfer direction. We are only transferring to one direction at a time. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon

[PATCH 13/18] staging: octeon-usb: move fifo setup to controller reset from port reset

2015-03-22 Thread Aaro Koskinen
Move FIFO setup to controller reset from port reset. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index 1ad69c5

[PATCH 03/18] staging: octeon-usb: remove useless prefix from internal routines

2015-03-22 Thread Aaro Koskinen
Original CVMX code used "__" to distinguis internal USB functions from public ones. But in Linux all cvmx_usb routines are internal to this driver, so such separation is useless. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 424 +++--

[PATCH 04/18] staging: octeon-usb: remove useless prefix from pipe flags

2015-03-22 Thread Aaro Koskinen
Remove useless prefix from pipe flags and adjust comments. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 33 - 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging

[PATCH 11/18] staging: octeon-usb: use USB stack to turn on power

2015-03-22 Thread Aaro Koskinen
Use USB stack to turn on the power bit. It will also do the necessary delays. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers

[PATCH 06/18] staging: octeon-usb: use __BITFIELD_FIELD

2015-03-22 Thread Aaro Koskinen
Use __BITFIELD_FIELD to define bitfields. OCTEON can at least in theory run also in little-endian mode, so the bitfield definitions should not assume big-endian byte order. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.h | 513 +--- 1 file

[PATCH 05/18] staging: octeon-usb: delete redundant field from octeon_temp_buffer

2015-03-22 Thread Aaro Koskinen
Since we are not moving/realigning the original pointer returned by kmalloc, we don't need to store the value in a separate field. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/st

[PATCH 14/18] staging: octeon-usb: rewrite port reset

2015-03-22 Thread Aaro Koskinen
Don't disable port before resetting. Also perform reset unconditionally when requested. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 28 +++- 1 file changed, 3 insertions(+), 25 deletions(-) diff --git a/drivers/staging/octeon-usb/o

[PATCH 12/18] staging: octeon-usb: move fifo setup into a separate routine

2015-03-22 Thread Aaro Koskinen
Move FIFO setup into a separate routine. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 107 1 file changed, 53 insertions(+), 54 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon

[PATCH 15/18] staging: octeon-usb: move cvmx_usb_shutdown()

2015-03-22 Thread Aaro Koskinen
Move cvmx_usb_shutdown() to allow its use from some other functions. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 66 - 1 file changed, 32 insertions(+), 34 deletions(-) diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b

[PATCH 17/18] staging: octeon-usb: try to recover from failed hardware reset

2015-03-22 Thread Aaro Koskinen
On some hardware the USB fails to initialize to sane state after cold boot. We can detect this based on some unexpected interrupt bits, and recover by re-initializing. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 30 +++--- 1 file changed

[PATCH 18/18] stating: octeon-usb: cvmx_usb_initialize(): eliminate extra indentation

2015-03-22 Thread Aaro Koskinen
Eliminate extra indentation by putting all the code into the same block. Also delete a bogus comment. Signed-off-by: Aaro Koskinen --- drivers/staging/octeon-usb/octeon-hcd.c | 152 ++-- 1 file changed, 68 insertions(+), 84 deletions(-) diff --git a/drivers/staging

  1   2   3   4   >