aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/broadcom
AgeCommit message (Collapse)AuthorFilesLines
2014-09-05cnic : Cleanup CONFIG_IPV6 & VLAN checkAnish Bhatt2-3/+3
The cnic module needs to ensure that if ipv6 support is compiled as a module, then the cnic module cannot be compiled as built-in as it depends on ipv6. Made this check cleaner via Kconfig Use simpler IS_ENABLED for CONFIG_VLAN_8021Q check Signed-off-by: Anish Bhatt <[email protected]> Acked-by: Michael Chan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-09-05bnx2x: Fix link problems for 1G SFP RJ45 moduleYaniv Rosner3-36/+50
When 1G SFP RJ45 module is detected, driver must reset the Tx laser in order to prevent link issues. As part of change, the link_attr_sync was relocated from vars to params. Signed-off-by: Yaniv Rosner <[email protected]> Signed-off-by: Yuval Mintz <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-09-02bnx2x: Configure device endianity on driver load and reset endianity on removal.Manish Chopra1-18/+39
Some hosts can be both little and big endian. In certain scenarios a big endian kernel can kexec a little endian kernel. This patch fixes this case from both ends: 1) Return endianity to original values on shutdown (in case little endian kernel boots after we shutdown). 2) Do not rely on HW reset values when loading driver in little endian kernel but configure them explicitly (in case previous kernel was big endian and did not reset the HW). Signed-off-by: Manish Chopra <[email protected]> Signed-off-by: Ariel Elior <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-09-02tg3: prevent ifup/ifdown during PCI error recoveryIvan Vecera2-0/+17
The patch fixes race conditions between PCI error recovery callbacks and potential ifup/ifdown. First, if ifup (tg3_open) is called between tg3_io_error_detected() and tg3_io_resume() then tp->timer is armed twice before expiry. Once during tg3_open() and again during tg3_io_resume(). This results in BUG at kernel/time/timer.c:945. Second, if ifdown (tg3_close) is called between tg3_io_error_detected() and tg3_io_resume() then tg3_napi_disable() is called twice without a tg3_napi_enable between. Once during tg3_io_error_detected() and again during tg3_close(). The tg3_io_resume() then hangs on rtnl_lock(). v2: Added logging messages per Prashant's request Cc: Prashant Sreedharan <[email protected]> Cc: Michael Chan <[email protected]> Signed-off-by: Ivan Vecera <[email protected]> Acked-by: Prashant Sreedharan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-22net: ethernet: broadcom: bnx2x: Remove redundant #ifdefRasmus Villemoes1-4/+0
Nothing defines _ASM_GENERIC_INT_L64_H, it is a weird way to check for 64 bit longs, and u64 should be printed using %llx anyway. Signed-off-by: Rasmus Villemoes <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-21bnx2x: Revert UNDI flushing mechanismYuval Mintz1-75/+17
Commit 91ebb929b6f8 ("bnx2x: Add support for Multi-Function UNDI") [which was later supposedly fixed by de682941eef3 ("bnx2x: Fix UNDI driver unload")] introduced a bug in which in some [yet-to-be-determined] scenarios the alternative flushing mechanism which was to guarantee the Rx buffers are empty before resetting them during device probe will fail. If this happens, when device will be loaded once more a fatal attention will occur; Since this most likely happens in boot from SAN scenarios, the machine will fail to load. Notice this may occur not only in the 'Multi-Function' scenario but in the regular scenario as well, i.e., this introduced a regression in the driver's ability to perform boot from SAN. The patch reverts the mechanism and applies the old scheme to multi-function devices as well as to single-function devices. Signed-off-by: Yuval Mintz <[email protected]> Signed-off-by: Ariel Elior <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-14Merge tag 'pci-v3.17-changes-2' of ↵Linus Torvalds4-6/+6
git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci Pull DEFINE_PCI_DEVICE_TABLE removal from Bjorn Helgaas: "Part two of the PCI changes for v3.17: - Remove DEFINE_PCI_DEVICE_TABLE macro use (Benoit Taine) It's a mechanical change that removes uses of the DEFINE_PCI_DEVICE_TABLE macro. I waited until later in the merge window to reduce conflicts, but it's possible you'll still see a few" * tag 'pci-v3.17-changes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: PCI: Remove DEFINE_PCI_DEVICE_TABLE macro use
2014-08-13tg3: fix return value in tg3_get_stats64Govindarajulu Varadarajan1-1/+2
When tp->hw_stats is 0, tg3_get_stats64 should display previously recorded stats. So it returns &tp->net_stats_prev. But the caller, dev_get_stats, ignores the return value. Fix this by assigning tp->net_stats_prev to stats and returning stats. Signed-off-by: Govindarajulu Varadarajan <[email protected]> Acked-by: Prashant Sreedharan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-12PCI: Remove DEFINE_PCI_DEVICE_TABLE macro useBenoit Taine4-6/+6
We should prefer `struct pci_device_id` over `DEFINE_PCI_DEVICE_TABLE` to meet kernel coding style guidelines. This issue was reported by checkpatch. A simplified version of the semantic patch that makes this change is as follows (http://coccinelle.lip6.fr/): // <smpl> @@ identifier i; declarer name DEFINE_PCI_DEVICE_TABLE; initializer z; @@ - DEFINE_PCI_DEVICE_TABLE(i) + const struct pci_device_id i[] = z; // </smpl> [bhelgaas: add semantic patch] Signed-off-by: Benoit Taine <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]>
2014-08-11net: bcmgenet: correctly resume adapter from Wake-on-LANFlorian Fainelli1-4/+6
In case we configured the adapter to be a wake up source from Wake-on-LAN, but we never actually woke up using Wake-on-LAN, we will leave the adapter in MagicPacket matching mode, which prevents any other type of packets from reaching the RX engine. Fix this by calling bcmgenet_power_up() with GENET_POWER_WOL_MAGIC to restore the adapter configuration in bcmgenet_resume(). The second problem we had was an imbalanced clock disabling in bcmgenet_wol_resume(), the Wake-on-LAN slow clock is only enabled in bcmgenet_suspend() if we configured Wake-on-LAN, yet we unconditionally disabled the clock in bcmgenet_wol_resume(). Fixes: 8c90db72f926 ("net: bcmgenet: suspend and resume from Wake-on-LAN") Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-11net: bcmgenet: update UMAC_CMD only when link is detectedFlorian Fainelli1-2/+6
When we bring the interface down, phy_stop() will schedule the PHY state machine to call our link adjustment callback. By the time we do so, we may have clock gated off the GENET hardware block, and this will cause bus errors to happen in bcmgenet_mii_setup(): Make sure that we only touch the UMAC_CMD register when there is an actual link. This is safe to do for two reasons: - updating the Ethernet MAC registers only make sense when a physical link is present - the PHY library state machine first set phydev->link = 0 before invoking phydev->adjust_link in the PHY_HALTED case Fixes: 240524089d7a ("net: bcmgenet: only update UMAC_CMD if something changed") Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-11net: bcmgenet: correctly suspend and resume PHY deviceFlorian Fainelli1-2/+11
Make sure that we properly suspend and resume the PHY device when we enter low power modes. We had two calls to bcmgenet_mii_reset() which will issue a software-reset to the PHY without using the PHY library, get rid of them since they are completely bogus and mess up with the PHY library state. Make sure that we reset the PHY library cached values (link, pause and duplex) to allow the link adjustment callback to be invoked when needed. Fixes: b6e978e50444 ("net: bcmgenet: add suspend/resume callbacks") Fixes: 1c1008c793fa4 ("net: bcmgenet: add main driver file") Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-11net: bcmgenet: request and enable main clock earlierFlorian Fainelli1-7/+7
bcmgenet_set_hw_params() will read the hardware version and compare it with the one we are getting from Device Tree. Due to the clock being enabled too late, bcmgenet_set_hw_params() will cause bus errors since the GENET hardware block is still gated off by the time bcmgenet_set_hw_params() is called, this will also make us fail the version check since we will read the value 0 from the hardware. Fix this by requesting the clock before the first piece of code that needs to access hardware register. Fixes: 1c1008c793fa4 ("net: bcmgenet: add main driver file") Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-07net: bcmgenet: fix reference counting for phy nodeUwe Kleine-König1-2/+4
For the fixed phy setup make sure to not overwrite a valid value of phy_dn (that is holding a reference to a phy-handle) and also acquire a reference to the MAC node to consistently return with the phy_dn pointer holding a reference. Also add the corresponding of_node_put in the error path and the remove function. Fixes: 9abf0c2b717a ("net: bcmgenet: use the new fixed PHY helpers") Fixes: aa09677cba42 ("net: bcmgenet: add MDIO routines") Signed-off-by: Uwe Kleine-König <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-08-05Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller1-10/+12
Conflicts: drivers/net/Makefile net/ipv6/sysctl_net_ipv6.c Two ipv6_table_template[] additions overlap, so the index of the ipv6_table[x] assignments needed to be adjusted. In the drivers/net/Makefile case, we've gotten rid of the garbage whereby we had to list every single USB networking driver in the top-level Makefile, there is just one "USB_NETWORKING" that guards everything. Signed-off-by: David S. Miller <[email protected]>
2014-08-05tg3: Modify tg3_tso_bug() to handle multiple TX ringsPrashant Sreedharan1-10/+12
tg3_tso_bug() was originally designed to handle only HW TX ring 0, Commit d3f6f3a1d818410c17445bce4f4caab52eb102f1 ("tg3: Prevent page allocation failure during TSO workaround") changed the driver logic to use tg3_tso_bug() for all HW TX rings that are enabled. This patch fixes the regression by modifying tg3_tso_bug() to handle multiple HW TX rings. Signed-off-by: Prashant Sreedharan <[email protected]> Signed-off-by: Michael Chan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-30net: bcmgenet: correct spellingBrian Norris1-11/+11
Signed-off-by: Brian Norris <[email protected]> Cc: Florian Fainelli <[email protected]> Cc: David S. Miller <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-30Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller4-0/+16
Signed-off-by: David S. Miller <[email protected]>
2014-07-24bnx2x: fix crash during TSO tunnelingDmitry Kravkov2-0/+10
When TSO packet is transmitted additional BD w/o mapping is used to describe the packed. The BD needs special handling in tx completion. kernel: Call Trace: kernel: <IRQ> [<ffffffff815e19ba>] dump_stack+0x19/0x1b kernel: [<ffffffff8105dee1>] warn_slowpath_common+0x61/0x80 kernel: [<ffffffff8105df5c>] warn_slowpath_fmt+0x5c/0x80 kernel: [<ffffffff814a8c0d>] ? find_iova+0x4d/0x90 kernel: [<ffffffff814ab0e2>] intel_unmap_page.part.36+0x142/0x160 kernel: [<ffffffff814ad0e6>] intel_unmap_page+0x26/0x30 kernel: [<ffffffffa01f55d7>] bnx2x_free_tx_pkt+0x157/0x2b0 [bnx2x] kernel: [<ffffffffa01f8dac>] bnx2x_tx_int+0xac/0x220 [bnx2x] kernel: [<ffffffff8101a0d9>] ? read_tsc+0x9/0x20 kernel: [<ffffffffa01f8fdb>] bnx2x_poll+0xbb/0x3c0 [bnx2x] kernel: [<ffffffff814d041a>] net_rx_action+0x15a/0x250 kernel: [<ffffffff81067047>] __do_softirq+0xf7/0x290 kernel: [<ffffffff815f3a5c>] call_softirq+0x1c/0x30 kernel: [<ffffffff81014d25>] do_softirq+0x55/0x90 kernel: [<ffffffff810673e5>] irq_exit+0x115/0x120 kernel: [<ffffffff815f4358>] do_IRQ+0x58/0xf0 kernel: [<ffffffff815e94ad>] common_interrupt+0x6d/0x6d kernel: <EOI> [<ffffffff810bbff7>] ? clockevents_notify+0x127/0x140 kernel: [<ffffffff814834df>] ? cpuidle_enter_state+0x4f/0xc0 kernel: [<ffffffff81483615>] cpuidle_idle_call+0xc5/0x200 kernel: [<ffffffff8101bc7e>] arch_cpu_idle+0xe/0x30 kernel: [<ffffffff810b4725>] cpu_startup_entry+0xf5/0x290 kernel: [<ffffffff815cfee1>] start_secondary+0x265/0x27b kernel: ---[ end trace 11aa7726f18d7e80 ]--- Fixes: a848ade408b ("bnx2x: add CSUM and TSO support for encapsulation protocols") Reported-by: Yulong Pei <[email protected]> Cc: Michal Schmidt <[email protected]> Signed-off-by: Dmitry Kravkov <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-24bnx2x: fix set_setting for some PHYsYaniv Rosner1-0/+1
Allow set_settings() to complete succesfully even if link is not estabilished and port type isn't known yet. Signed-off-by: Yaniv Rosner <[email protected]> Signed-off-by: Dmitry Kravkov <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-23net: bcmgenet: use kcalloc instead of kzallocFlorian Fainelli2-4/+4
There were two places that used kzalloc() with a multiplied sizeof(), replace these with kcalloc as recommended by checkpatch.pl. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-23net: bcmgenet: add missing braces to some if statementsFlorian Fainelli1-4/+5
checkpatch.pl flagged two locations that did not comply to "CHECK: braces {} should be used on all arms of this statement", fix them. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-23net: bcmgenet: add and remove missing blank linesFlorian Fainelli1-3/+1
checkpatch.pl flagged two blank lines which are not needed, and one that was missing, fix them. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-23net: bcmgenet: re-align multiple lines correctlyFlorian Fainelli3-147/+142
checkpatch.pl flagged a lot of "CHECK: Alignment should match open parenthesis" checks, fix all of them to make the driver neater. While at it fix some obvious typos and re-arrange some of the lines to avoid going over 80 columns. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-23net: bcmgenet: remove FSF mail addressFlorian Fainelli3-30/+2
Use a smaller GPLv2 header and remove all the boilerplate code as well as the FSF mail address. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-22net: bcmgenet: correctly pad short packetsFlorian Fainelli1-0/+5
Packets shorter than ETH_ZLEN were not padded with zeroes, hence leaking potentially sensitive information. This bug has been present since the driver got accepted in commit 1c1008c793fa46703a2fee469f4235e1c7984333 ("net: bcmgenet: add main driver file"). Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: only update UMAC_CMD if something changedFlorian Fainelli1-2/+3
The link adjustment callback can be called as frequently as desired by the PHY library, as such, let's avoid doing a Read/Modify/Write sequence if nothing changed, since these register accesses can be expensive. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: hook ethtool set/get_wol operationsFlorian Fainelli1-0/+2
Now that Wake-on-LAN support mode is fully integrated into the driver, allow an user to query and configure Wake-on-LAN in the driver. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: suspend and resume from Wake-on-LANFlorian Fainelli1-0/+12
Update bcmgenet_suspend() to prepare the hardware for being put into Wake-on-LAN mode if the device can wakeup the system, and Wake-on-LAN is enabled. Whether we resume from Wake-on-LAN or not, make sure that bcmgenet_resume() disables the UniMAC MagicPacket matching mode and puts the hardware in a state where it can receive all incoming packets. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: fix bcmgenet_wol_resumeFlorian Fainelli1-7/+1
bcmgenet_wol_resume() will create an unbalanced clock state for the wol_clk clock pointer since everywhere else in the code, we always call clk_prepare_enable() and clk_disable_unprepare(). This function also calls init_umac() which is neither correct nor necessary since bcmgenet_resume() and bcmgenet_open() already does that. Finally calling bcmgenet_wol_resume() in bcmgenet_open() is not correct, since the interface would not have been able to put us in Wake-on-LAN mode if it was not UP before. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: handle UMAC_IRQ_MPD_R interrupt bitFlorian Fainelli1-0/+7
Handle UMAC_IRQ_MPD_R interrupt bit in our workqueue to make sure that we properly re-configure the GENET adapter from Wake-on-LAN. bcmgenet_power_up() makes sure that we will not leave the UniMAC hardware in MagicPacket matching mode, since that would prevent any other packet from being received. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: handle GENET_POWER_WOL_MAGICFlorian Fainelli1-0/+7
Update bcmgenet_power_{up,down} to handle the case where the adapter has been suspend respectively resumed from Wake-on-LAN using MagicPackets. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: add Wake-on-LAN support codeFlorian Fainelli3-1/+216
Add all the required code to program the GENET hardware to enter Wake-on-LAN mode and wake using MagicPackets with or without SecureOn password. This code is hooked to the build system, but is not yet referenced from ethtool or the main bcmgenet driver. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: request Wake-on-LAN interruptFlorian Fainelli2-2/+19
Attempt to the request the Wake-on-LAN interrupt bit, and if successful, advertise wakeup capability instead of doing this unconditionnally. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: add suspend/resume callbacksFlorian Fainelli1-0/+95
Implement suspend/resume callbacks in the GENET driver. This makes sure that we de-initialize and re-initialize the hardware correctly before entering suspend and when resuming. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: modularize bcmgenet_{open,close}Florian Fainelli1-33/+53
Introduce a bunch of helper functions: bcmgenet_netif_start, bcmgenet_netif_stop and bcmgenet_intr_disable to help reuse code that is going to be necessary for suspend/resume. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: add umac_enable_set helperFlorian Fainelli1-13/+24
Factor the code touching the UniMAC RX/TX enable bits since we are going to re-use it for implementing suspend/resume. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-21net: bcmgenet: remove wol_enabled conditional codeFlorian Fainelli2-10/+0
Checking for wol_enabled in bcmgenet_close() is bogus, since no other code places set priv->wol_enabled. Remove that as it will conflict with the upcoming and functional Wake-on-LAN implementation. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-17Update setapp/getapp prototypes in dcbnl_rtnl_ops to return int instead of u8Anish Bhatt1-2/+2
v2: fixed issue with checking return of dcbnl_rtnl_ops->getapp() Signed-off-by: Anish Bhatt <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-16Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller5-45/+21
Signed-off-by: David S. Miller <[email protected]>
2014-07-13net: bcmgenet: fix RGMII_MODE_EN bitFlorian Fainelli1-1/+1
RGMII_MODE_EN bit was defined to 0, while it is actually 6. It was not much of a problem on older designs where this was a no-op, and the RGMII data-path would always be enabled, but newer GENET controllers need to explicitely enable their RGMII data-pad using this bit. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-09net: systemport: use kcalloc instead of kzallocFlorian Fainelli1-3/+3
checkpatch.pl flagged two uses of kzalloc() for allocating and zeroing arrays, use kcalloc() instead as recommended. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-09net: systemport: align multiple lines correctlyFlorian Fainelli1-59/+58
checkpatch.pl flagged a bunch of: "CHECK: Alignment should match open parenthesis" problems, fix all of them. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-07net: systemport: add Wake-on-LAN supportFlorian Fainelli2-3/+164
Support for Wake-on-LAN using Magic Packet with or without SecureOn password is implemented doing the following: - setting the password to the relevant UniMAC registers - flagging the device as a wakeup source for the system, as well as its Wake-on-LAN interrupt - prepare the hardware for entering WoL mode - enabling the MPD interrupt to wake us The Device Tree binding documentation is also reflected to specify the third optional Wake-on-LAN interrupt line. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-07net: systemport: rename rx_csum_en to rx_chk_enFlorian Fainelli2-6/+6
This boolean tells us whether we are using the RXCHK hardware block, so use a variable name that reflects that. RXCHK might be used in the future to implement Wake-on-LAN using ARP or unicast packets. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-07net: systemport: add suspend and resume supportFlorian Fainelli1-4/+160
Implement the hardware recommended suspend/resume procedure for SYSTEMPORT. We leverage the previous factoring work such that we can logically break all suspend/resume operations into disctint RX and TX code paths. When the system enters S3, we will loose all register contents, so make sure that we correctly re-program all the hardware and software views of the RX & TX rings as well. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-07net: systemport: add bcm_sysport_netif_{enable,stop}Florian Fainelli1-13/+27
Factor common code that either enables or disables the network interface with the networking stack. We are going to reuse these functions for suspend/resume callbacks. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-07net: systemport: update umac_enable_set to take a bitmaskFlorian Fainelli1-12/+7
Quite often we need to enable either the transmitter or the receiver bits in UMAC_CMD, use umac_enable_set() to do that for us. This is a preliminary change to introduce suspend/resume support in the driver. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-01net: bcmgenet: do not set packet length for RX buffersFlorian Fainelli1-7/+0
Hardware will provide this information as soon as we will start processing incoming packets, so there is no need to set the RX buffer length during buffer allocation. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2014-07-01net: bcmgenet: start with carrier offFlorian Fainelli1-0/+3
We use the PHY library which will determine the link state for us, make sure we start with a carrier off until libphy has completed the link training. Signed-off-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>