linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 net-next 0/3] Refactor lan9303_xxx_packet_processing
@ 2017-08-01 11:14 Egil Hjelmeland
  2017-08-01 11:14 ` [PATCH v2 net-next 1/3] net: dsa: lan9303: Refactor lan9303_xxx_packet_processing() Egil Hjelmeland
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Egil Hjelmeland @ 2017-08-01 11:14 UTC (permalink / raw)
  To: andrew, vivien.didelot, f.fainelli, netdev, linux-kernel, kernel
  Cc: Egil Hjelmeland

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

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2017-08-03 13:33 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-01 11:14 [PATCH v2 net-next 0/3] Refactor lan9303_xxx_packet_processing Egil Hjelmeland
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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).