All of lore.kernel.org
 help / color / mirror / Atom feed
From: Egil Hjelmeland <privat@egil-hjelmeland.no>
To: andrew@lunn.ch, vivien.didelot@savoirfairelinux.com,
	f.fainelli@gmail.com, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org, kernel@pengutronix.de
Cc: Egil Hjelmeland <privat@egil-hjelmeland.no>
Subject: [PATCH v2 net-next 0/3] Refactor lan9303_xxx_packet_processing
Date: Tue,  1 Aug 2017 13:14:36 +0200	[thread overview]
Message-ID: <20170801111439.1143-1-privat@egil-hjelmeland.no> (raw)

This series is purely non functional. It changes the 
lan9303_enable_packet_processing,
lan9303_disable_packet_processing() to pass port number (0,1,2) as
parameter instead of port offset. This aligns them with
other functions in the module, and makes it possible to simplify the code.

First patch: Change lan9303_xxx_packet_processing parameter:
 - Pass port number (0,1,2) as parameter.
 - Introduced lan9303_write_switch_port() 
 - Plus replaced a constant 0x400 with LAN9303_SWITCH_PORT_REG()

Second patch: Introduce LAN9303_NUM_PORTS=3, used in next patch.

Third patch: Simplify lan9303_xxx_packet_processing usage.

Comments welcome!

Changes v1 -> v2:
 - introduced lan9303_write_switch_port() in first patch
 - inserted LAN9303_NUM_PORTS patch
 - Use LAN9303_NUM_PORTS in last patch. Plus whitespace change.  

Egil Hjelmeland (3):
  net: dsa: lan9303: Refactor lan9303_xxx_packet_processing()
  net: dsa: lan9303: define LAN9303_NUM_PORTS 3
  net: dsa: lan9303: Simplify lan9303_xxx_packet_processing() usage

 drivers/net/dsa/lan9303-core.c | 78 ++++++++++++++++++++++--------------------
 1 file changed, 40 insertions(+), 38 deletions(-)

-- 
2.11.0

             reply	other threads:[~2017-08-01 11:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-01 11:14 Egil Hjelmeland [this message]
2017-08-01 11:14 ` [PATCH v2 net-next 1/3] net: dsa: lan9303: Refactor lan9303_xxx_packet_processing() Egil Hjelmeland
2017-08-01 13:39   ` Andrew Lunn
2017-08-01 13:50     ` Egil Hjelmeland
2017-08-01 14:02       ` Andrew Lunn
2017-08-01 14:43         ` Egil Hjelmeland
2017-08-01 11:14 ` [PATCH v2 net-next 2/3] net: dsa: lan9303: define LAN9303_NUM_PORTS 3 Egil Hjelmeland
2017-08-01 11:49   ` Juergen Borleis
2017-08-01 12:31     ` Egil Hjelmeland
2017-08-01 13:27       ` Andrew Lunn
2017-08-01 13:45         ` Egil Hjelmeland
2017-08-03  9:53         ` Egil Hjelmeland
2017-08-03 13:33           ` Andrew Lunn
2017-08-01 11:14 ` [PATCH v2 net-next 3/3] net: dsa: lan9303: Simplify lan9303_xxx_packet_processing() usage Egil Hjelmeland

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170801111439.1143-1-privat@egil-hjelmeland.no \
    --to=privat@egil-hjelmeland.no \
    --cc=andrew@lunn.ch \
    --cc=f.fainelli@gmail.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=vivien.didelot@savoirfairelinux.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.