summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-02-28wext: add checked wrappers for adding events/points to streamsJohannes Berg
These checked wrappers are necessary for the next patch, which will use them to avoid sending out partial scan results. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-28mac80211: remove TX latency measurement codeJohannes Berg
Revert commit ad38bfc916da ("mac80211: Tx frame latency statistics") (along with some follow-up fixes). This code turned out not to be as useful in the current form as we thought, and we've internally hacked it up more, but that's not very suitable for upstream (for now), and we might just do that with tracing instead. Therefore, for now at least, remove this code. We might also need to use the skb->tstamp field for the TCP performance issue, which is more important than the debugging. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-28nl/mac80211: allow zero plink timeout to disable STA expirationMasashi Honma
Both wpa_supplicant and mac80211 have and inactivity timer. By default wpa_supplicant will be timed out in 5 minutes and mac80211's it is 30 minutes. If wpa_supplicant uses a longer timer than mac80211, it will get unexpected disconnection by mac80211. Using 0xffffffff instead as the configured value could solve this w/o changing the code, but due to integer overflow in the expression used this doesn't work. The expression is: (current jiffies) > (frame Rx jiffies + NL80211_MESHCONF_PLINK_TIMEOUT * 250) On 32bit system, the right side would overflow and be a very small value if NL80211_MESHCONF_PLINK_TIMEOUT is sufficiently large, causing unexpectedly early disconnections. Instead allow disabling the inactivity timer to avoid this situation, by passing the (previously invalid and useless) value 0. Signed-off-by: Masashi Honma <masashi.honma@gmail.com> [reword/rewrap commit log] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-28mac80211_hwsim: support any address in userspaceBob Copeland
Due to the checks in get_hwsim_data_ref_from_addr, wmediumd was only able to use the second mac address (those starting with 0x42). This is confusing and needlessly limiting, so allow any configured address. Signed-off-by: Bob Copeland <me@bobcopeland.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-28cfg80211-wext: export symbols only when neededJohannes Berg
When a fully converted cfg80211 driver needs cfg80211-wext for userspace API purposes, the symbols need not be exported. When other drivers (orinoco/hermes or ipw2200) are enabled, they do need the symbols exported as they use them directly. Make those drivers select a new CFG80211_WEXT_EXPORT Kconfig symbol (instead of just CFG80211_WEXT) and export the functions only if requested - this saves about 1/2k due to the size of EXPORT_SYMBOL() itself. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-28mac80211: iterate using station list in AP SMPSJohannes Berg
When changing AP SMPS, we need to look up all the stations for this interface, so there's no reason to iterate over hash chains rather than doing the simpler iteration over the station list. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-28mac80211: don't look up stations for multicast addressesJohannes Berg
Since multicast addresses don't exist as stations, don't attempt to look them up in the hashtable on TX. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-02-23bridge: add vlan info to bridge setlink and dellink notification messagesRoopa Prabhu
vlan add/deletes are not notified to userspace today. This patch adds vlan info to bridge newlink/dellink notifications generated from the bridge driver. Notifications use the RTEXT_FILTER_BRVLAN_COMPRESSED flag to compress vlans into ranges whereever applicable. The size calculations does not take ranges into account for simplicity. This has the potential for allocating a larger skb than required. There is an existing inconsistency with bridge NEWLINK and DELLINK change notifications. Both generate NEWLINK notifications. Since its always a NEWLINK notification, this patch includes all vlans the port belongs to in the notification. The NEWLINK and DELLINK request messages however only include the vlans to be added and deleted. Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22net: __aligned(size) is preferred over __attribute__((aligned(size)))Ameen Ali
Signed-off-by: Ameen Ali <AmeenAli023@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22batman-adv: Fix use of seq_has_overflowed()Joe Perches
net-next commit 6d91147d183c ("batman-adv: Remove uses of return value of seq_printf") incorrectly changed the overflow occurred return from -1 to 1. Change it back so that the test of batadv_write_buffer_text's return value in batadv_gw_client_seq_print_text works properly. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22net: Remove state argument from skb_find_text()Bojan Prtvar
Although it is clear that textsearch state is intentionally passed to skb_find_text() as uninitialized argument, it was never used by the callers. Therefore, we can simplify skb_find_text() by making it local variable. Signed-off-by: Bojan Prtvar <prtvar.b@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22ethtool: use "ops" name consistenty in ethtool_set_rxfh()Dan Carpenter
"dev->ethtool_ops" and "ops" are the same, but we should use "ops" everywhere to be consistent. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22ipv6: Replace "#include <asm/uaccess>" with "#include <linux/uaccess>"Alex W Slater
Fix checkpatch.pl warning "Use #include <linux/uaccess.h> instead of <asm/uaccess.h>" Signed-off-by: Alex W Slater <alex.slater.dev@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22Merge branch 'bna-next'David S. Miller
Rasesh Mody says: ==================== bna: Update the Driver and Firmware Version These patches re-brands the BNA driver to QLogic. The patches update the BNA driver version to 3.2.25.1 and firmware version to 3.2.5.1. The patches are tested against 3.19.0. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22bna: Update the Driver and Firmware VersionRasesh Mody
This patch updates the BNA driver version to 3.2.25.1 and the firmware version to 3.2.5.1 Signed-off-by: Rasesh Mody <rasesh.mody@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-22bna: QLogic BR-series Adapters Driver RebrandingRasesh Mody
Re-brand the BNA driver to QLogic. Signed-off-by: Rasesh Mody <rasesh.mody@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20sunvnet: failed trigger should not cause BUG_ON()David L Stevens
An error return from __vnet_tx_trigger() sets the TX descriptor to VIO_DESC_FREE while leaving port->tx_bufs[txi].skb set. This leads to a BUG_ON() the next time this descriptor is used. This patch frees the pending skb when getting a trigger error to match the VIO_DESC_FREE state. Signed-off-by: David L Stevens <david.stevens@oracle.com> Acked-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20bonding: simple code refactorMahesh Bandewar
Remove duplicate code. Signed-off-by: Mahesh Bandewar <maheshb@google.com> Signed-off-by: Andy Gospodarek <gospo@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20net: macb: Add big endian CPU supportArun Chandran
This patch converts all __raw_readl and __raw_writel function calls to their corresponding readl_relaxed and writel_relaxed variants. It also tells the driver to set ahb_endian_swp_mgmt_en bit in dma_cfg when the CPU is configured in big endian mode. Signed-off-by: Arun Chandran <achandran@mvista.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20Merge branch 'bnx2x-next'David S. Miller
Rasesh Mody says: ==================== bnx2-cnic: Driver Version Upgrades This patch set includes bnx2 and cnic drivers' re-branding changes, fix for a chip initialization issue and updates the bnx2 driver version to 2.2.6 and cnic driver version to 2.5.21. Please apply these patches to net-next. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20bnx2-cnic: Driver Version UpdateRasesh Mody
This patch updates BNX2 driver version to 2.2.6 and CNIC driver version to 2.5.21. Signed-off-by: Rasesh Mody <rasesh.mody@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20bnx2: Fix for Chip InitializationRasesh Mody
Do not enable filter SORT MODE in chip init routine. This patch addresses an issue where BCM5716 sporadically drops packets when changing multicast list. Signed-off-by: Rasesh Mody <rasesh.mody@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20bnx2-cnic: Driver Rebranding ChangesRasesh Mody
This patch provides additional changes as a part of BNX2 and CNIC driver re-branding effort. Signed-off-by: Rasesh Mody <rasesh.mody@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20igmp: add __ip_mc_{join|leave}_group()Eric Dumazet
There is a need to perform igmp join/leave operations while RTNL is held. Make ip_mc_{join|leave}_group() wrappers around __ip_mc_{join|leave}_group() to avoid the proliferation of work queues. For example, vxlan_igmp_join() could possibly be removed. Signed-off-by: Eric Dumazet <edumazet@google.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20hso: always read interface number from the current altsettingAleksander Morgado
Always read bInterfaceNumber from the current altsetting, not from the first one available in the altsetting array. This is coming from code review, not related to any specific bug. Signed-off-by: Aleksander Morgado <aleksander@aleksander.es> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20Merge branch 'ppc_bpf'David S. Miller
Denis Kirjanov says: ==================== bpf: Enable BPF JIT on ppc32 This patch series enables BPF JIT on ppc32. There are relatevily few chnages in the code to make it work. All test_bpf tests passed both on 7447a and P2041-based machines. Changelog: v1 - > v2: Reordered Kconfig patch in the series ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20ppc: Kconfig: Enable BPF JIT on ppc32Denis Kirjanov
Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20ppc: bpf: Add SKF_AD_CPU for ppc32Denis Kirjanov
Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20ppc: bpf: rename bpf_jit_64.S to bpf_jit_asm.SDenis Kirjanov
Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20ppc: bpf: update jit to use compatibility macrosDenis Kirjanov
Use helpers from the asm-compat.h to wrap up assembly mnemonics Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20ppc: bpf: add reqired opcodes for ppc32Denis Kirjanov
Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20ppc: bpf: add required compatibility macros for jitDenis Kirjanov
Signed-off-by: Denis Kirjanov <kda@linux-powerpc.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20batman-adv: Remove uses of return value of seq_printfJoe Perches
This function is soon going to return void so remove the return value use. Convert the return value to test seq_has_overflowed() instead. Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Antonio Quartulli <antonio@meshcoding.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20tcp: silence registration messagestephen hemminger
This message isn't really needed it justs waits time/space. Signed-off-by: Stephen Hemminger <stephen@networkplumber.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20Merge branch 'be2net-next'David S. Miller
Sriharsha Basavapatna says: ==================== be2net patch-set This patch set contains a few code refactoring changes to make it easy to support new TX WRB formats in future ASICs. Please consider applying it to net-next tree. Patch 1: Refactors chip specific code to setup tx wrb into a separate routine. Patch 2: Refactors tx enqueue function to remove a bit of duplicate code and improves wrb setup steps. Patch 3: Minor refactoring in tx compl to limit CQE accesses to 1 routine. Patch 4: Adds a few inline functions. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20be2net: Add a few inline functions to test TXQ conditionsSriharsha Basavapatna
- Check qfull condition - Check qwake condition - Check pkts pending completion Signed-off-by: Sriharsha Basavapatna <sriharsha.basavapatna@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20be2net: Minor code cleanup in tx completion processSriharsha Basavapatna
- To avoid multiple accesses to CQE, extract compl_status and end_idx from be_tx_compl_get(). Signed-off-by: Sriharsha Basavapatna <sriharsha.basavapatna@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20be2net: Refactor be_xmit_enqueue() routineSriharsha Basavapatna
- Reduce code duplication by moving WRB-frags setup into a function. - Do not setup WRB-header before frags are setup, which is unncessary if there's errors while setting up frags. We should only grab an entry for the header, setup the frags and if everything is fine setup the header. - The error cleanup can be moved into a small function. Signed-off-by: Sriharsha Basavapatna <sriharsha.basavapatna@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-20be2net: Refactor wrb_fill_hdr() routineSriharsha Basavapatna
The WRB header is setup by wrb_fill_hdr() routine. This routine currently gets some of the WRB params as args and figures out rest of the WRB params by looking at various fields in skb (like gso, checksum, vlan-tag etc). All these params could instead be retrieved from the skb into a structure and passed to this routine. This separates wrb_fill_hdr() to only provide chip-specific code to fill the WRB. This also makes it simple to support chips with different WRB formats. Signed-off-by: Sriharsha Basavapatna <sriharsha.basavapatna@emulex.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19Merge branch 'mv88e6171_indirect_phy'David S. Miller
Andrew Lunn says: ==================== Indirect phy access for mv88e6171 These two patches allow the mv88e6171 driver to access the port phys using indirect addressing. Depending on pin strapping, the switch either uses a single address on the host MDIO bus, requiring the port phys are accessed indirectly, or the switch uses a number of addresses on the host bus and the phys can be directly accessed. The 370RD, the first supported platform to use the 6171 uses multiple addresses, so this indirect mode was not required. However the WRT1900AC has the switch configured to use a single address, and so indirect access is needed. The mv88e6352 already has all the needed code. Refactor it into the shared mv88e6xxx and then use it in the mv88e6171 driver. Tested on the 370RD and WRT1900AC. It would be good if Guenter Roeck could test on his platform to ensure i've not broken anything for the mv88e6352. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19net: dsa: mv88e6171: Enable access to phys via internal mdio busAndrew Lunn
When the device is configured to use single chip addressing mode, the phy devices of the port are not accessible on the host MDIO bus. Instead the switch internal MDIO bus must be used. For this to work, the phy polling unit must be enabled. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19net: dsa: mv88e6352: Refactor shareable codeAndrew Lunn
The mv88e6352 allows access to the port phys via an internal mdio bus which is accessed using registers in the GLOBAL 2 range. The mv88e6171 and probably other devices use the same mechanism. Move this code into the shared mv88e6xxx.c library. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Tested-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19net: eth: altera: Change reset_mac failure message masks from err to dbgVince Bridgers
This debug output is not really an error message since mac reset can fail if the phy clocks are gated, specifically when the phy has been placed in a powered down or isolation mode. The netdev output masks were changed from err to dbg, and comments added in the code. Signed-off-by: Vince Bridgers <vbridger@opensource.altera.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19net: eth: altera: Change access ports to mdio for all xMII applicationsVince Bridgers
Change use of Altera TSE's MDIO access from phy 0 registers to phy 1 registers. This allows support for GMII, MII, RGMII, and SGMII designs where the external PHY is always accesible through Altera TSE's MDIO phy 1 registers and Altera's PCS is accessible through MDIO phy 0 registers for SGMII applications. Signed-off-by: Vince Bridgers <vbridger@opensource.altera.com> Tested-by: Kai Lin Ng <kailng@altera.com> Tested-by: Dalon Westergreen <dwesterg@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19Merge branch 'r8152-next'David S. Miller
Hayes Wang says: ==================== Adjust the settings about USB_RX_EARLY_AGG v2: For patch #1, replace u32 ocp_data; ocp_data = tp->coalesce / 8; with u32 ocp_data = tp->coalesce / 8; And replace struct net_device *dev = tp->netdev; u32 ocp_data; ocp_data = (agg_buf_sz - dev->mtu - VLAN_ETH_HLEN - VLAN_HLEN) / 4; with u32 mtu = tp->netdev->mtu; u32 ocp_data = (agg_buf_sz - mtu - VLAN_ETH_HLEN - VLAN_HLEN) / 4; Use *switch* statement to replace the checking of *if*. v1: The USB_RX_EARLY_AGG contains timeout and size. Separate them, and they could be set independently. Then, the ethtool could be used to change the timeout according to situation of the platform. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19r8152: support setting rx coalescehayeswang
Support setting the rx coalesce. Then someone could change the rx agg timeout value through ethtool. Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19r8152: change rx early size when the mtu is changedhayeswang
The rx early size is calculated with the mtu, so it has to be re-calculated when the mtu is changed. Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-19r8152: separate USB_RX_EARLY_AGGhayeswang
Separate USB_RX_EARLY_AGG into USB_RX_EARLY_TIMEOUT and USB_RX_EARLY_SIZE. Replace r8153_set_rx_agg() with r8153_set_rx_early_timeout() and r8153_set_rx_early_size(). Set the default timeout value according to the USB speed. Signed-off-by: Hayes Wang <hayeswang@realtek.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2015-02-18Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller
2015-02-18Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netLinus Torvalds
Pull networking updates from David Miller: 1) Missing netlink attribute validation in nft_lookup, from Patrick McHardy. 2) Restrict ipv6 partial checksum handling to UDP, since that's the only case it works for. From Vlad Yasevich. 3) Clear out silly device table sentinal macros used by SSB and BCMA drivers. From Joe Perches. 4) Make sure the remote checksum code never creates a situation where the remote checksum is applied yet the tunneling metadata describing the remote checksum transformation is still present. Otherwise an external entity might see this and apply the checksum again. From Tom Herbert. 5) Use msecs_to_jiffies() where applicable, from Nicholas Mc Guire. 6) Don't explicitly initialize timer struct fields, use setup_timer() and mod_timer() instead. From Vaishali Thakkar. 7) Don't invoke tg3_halt() without the tp->lock held, from Jun'ichi Nomura. 8) Missing __percpu annotation in ipvlan driver, from Eric Dumazet. 9) Don't potentially perform skb_get() on shared skbs, also from Eric Dumazet. 10) Fix COW'ing of metrics for non-DST_HOST routes in ipv6, from Martin KaFai Lau. 11) Fix merge resolution error between the iov_iter changes in vhost and some bug fixes that occurred at the same time. From Jason Wang. 12) If rtnl_configure_link() fails we have to perform a call to ->dellink() before unregistering the device. From WANG Cong. * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (39 commits) net: dsa: Set valid phy interface type rtnetlink: call ->dellink on failure when ->newlink exists com20020-pci: add support for eae single card vhost_net: fix wrong iter offset when setting number of buffers net: spelling fixes net/core: Fix warning while make xmldocs caused by dev.c net: phy: micrel: disable NAND-tree for KSZ8021, KSZ8031, KSZ8051, KSZ8081 ipv6: fix ipv6_cow_metrics for non DST_HOST case openvswitch: Fix key serialization. r8152: restore hw settings hso: fix rx parsing logic when skb allocation fails tcp: make sure skb is not shared before using skb_get() bridge: netfilter: Move sysctl-specific error code inside #ifdef ipv6: fix possible deadlock in ip6_fl_purge / ip6_fl_gc ipvlan: add a missing __percpu pcpu_stats tg3: Hold tp->lock before calling tg3_halt() from tg3_init_one() bgmac: fix device initialization on Northstar SoCs (condition typo) qlcnic: Delete existing multicast MAC list before adding new net/mlx5_core: Fix configuration of log_uar_page_sz sunvnet: don't change gso data on clones ...