Yuval Mintz says:
====================
bnx2x: Enhancements & semantic changes series
This patch series contains several semantic (or mostly semantic) patches,
as well as adding support for packet aggregations on the receive path
of windows VMs and updating bnx2x to the new FW recently accepted upstream.
Please consider applying these patches to `net-next'.
(This is a repost as net-next was still closed when this was previously
sent)
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
This new firmware fixes following bugs:
1. HW attention appears and traffic stops when iSCSI firmware tries to
retransmit iSCSI login command when the iSCSI login is carrying data
not aligned to 4-bytes.
2. FCoE traffic fails to run when running in switch-independent multi-function
mode and there's more than one interface supporting FCoE on a given port.
3. While two ports are running FCoE with at least one of them has a function
number (>1) on the same engine in a 4-port device a zeroed CQE is given,
causing FCoE traffic to stop.
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This removes the various points where the driver use bit operations in order
to schedule the sp_rtnl_task from the code, adding a single utility function
that does it instead.
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
bnx2x_panic_dump() prints all kind of driver information, including slowpath
information. Since VFs don't initialize slowpath information, a VF reaching
this flow will likely cause a panic in the system as it will access NULL
pointers.
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
There are several places in IOV related flows where PF needs to determine
whether a VF slowpath elements have already been configured (i.e., this
affect its ability to configure/remove classifications for the VF).
This patch changes the conditions for the validation and performs a cleaner
validation (e.g., by replacing several validations with a single one).
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This provides PF-side support for VFs assigned to a VM running windows
2012 with the RSC feature enabled.
Signed-off-by: Michal Kalderon <michals@broadcom.com>
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This is purely semantic - break the flow in which PF validates the VF
classification filtering requirement is valid into several sub-functions
for better readable code.
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Latest FW performs this autonomously, makes this code surplus.
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
There are some debug prints (mostly iov/statistics related) which clobber
system logs whenever their verbosity level is set for an interface.
This patch puts harsher verbosity requirements for such debug prints to be
printed.
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Expose the PHY device has_fixups boolean as a sysfs property to help
troubleshooting PHY configurations.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Add a boolean property which indicates if the PHY has had any fixup
routine ran on it. We are later going to use that boolean to expose it
as a sysfs property to help troubleshooting.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Expose the PHY device interface mode through sysfs since this is an
useful piece of information for knowing how the attached networking
device will have configured its transmit/receive path.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
of_get_phy_mode() uses a local array to map phy_interface_t values from
include/linux/net/phy.h to a string which is read from the 'phy-mode' or
'phy-connection-type' property. In preparation for exposing the PHY
interface mode through sysfs, perform the following:
- mode phy_modes from drivers/of/of_net.c to include/linux/phy.h such
that it is right below the phy_interface_t enum
- make it a static inline function returning the string such that we can
use it by just including include/linux/net/phy.h
- add a PHY_INTERFACE_MODE_MAX enum value to guard the iteration in
of_get_phy_mode()
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
The comments above phy_{clear,config}_interrupt used the word "on"
instead of "or", when talking about the return values of the functions,
fix these two typos.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Some PHYs out there can be very quirky with respect to how they would
report the auto-negotiation is completed. Allow drivers to override the
generic aneg_done() implementation by providing their own.
Since not all drivers have been updated yet to use genphy_aneg_done() as
aneg_done() callback, we explicitely check that this callback is valid
before calling into it.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
In preparation for allowing PHY drivers to potentially override their
auto-negotiation done callback, move the contents of phy_aneg_done() to
genphy_aneg_done() since that function really is the generic
implementation based on the BMSR_ANEGCOMPLETE status.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Use a convenience function: phy_speed_to_str() which will display human
readable speeds.
Suggested-by: Joe Perches <joe@perches.com>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Update phy_print_status() to also display the PHY device pause settings
(rx/tx or off).
Suggested-by: Joe Perches <joe@perches.com>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
phy_print_status() currently uses dev_name(&phydev->dev) which will
usually result in printing something along those lines for Device Tree
aware drivers:
libphy: f0b60000.etherne:0a - Link is Down
libphy: f0ba0000.etherne:00 - Link is Up - 1000/Full
This is not terribly useful for network administrators or users since we
expect a network interface name to be able to correlate link events with
interfaces. Update phy_print_status() to use netdev_info() with
phydev->attached_dev which is the backing network device for our PHY
device. The leading dash is removed since netdev_info() prefixes the
messages with "<interface>: " already.
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Shradha Shah says:
====================
Cleanup patches for the SFC driver
This patch set consists of some cleanup and housekeeping
patches for the sfc driver.
These patches help to reduce the differences between the in-
tree and out-of-tree driver.
Ben Hutchings (12):
sfc: Cache skb->data in local variable in efx_ptp_rx()
sfc: Rewrite adjustment of PPS event in a clearer way
sfc: Replace TSOH_OFFSET with the equivalent NET_IP_ALIGN
sfc: Rename 'use_options' variable in tso_start() to clearer
'use_opt_desc'
sfc: Remove unused definitions of EF10 user-mode DMA descriptors
sfc: Correct comment about number of TX queues used on EF10
sfc: Preserve rx_frm_trunc counters when resizing DMA rings
sfc: Use canonical pointer type for MAC address in
efx_set_mac_address()
sfc: Update product naming
sfc: Cosmetic changes to self-test from the out-of-tree driver
sfc: Fail self-test with -EBUSY, not -EIO, if the device is busy
sfc: Add/remove blank lines to taste
Laurence Evans (1):
sfc: Removed adhoc scheme to rate limit PTP event queue overflow
message
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Remove trailing blank lines in several files.
Use only one blank line between functions.
Add a blank line as a separator in a few places.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
We don't use 'Solarstorm' or 'Solarflare Communications' in full
any more.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Functions such as is_valid_ether_addr() expect u8 *, so use that
instead of char *.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
We allocate efx_channel structures with kzalloc() so we don't need to
zero-initialise individual fields in efx_probe_channel(). Further,
this function will be called again during DMA ring resizing and we
should not reset any statistics then.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
EF10 implements option descriptors to switch TX checksum offload
on and off between packets. We could therefore use a single
hardware TX queue per kernel TX queue, although we don't yet.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
These DMA descriptor types will only be used by the userland
networking stack.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
If CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is defined then NET_IP_ALIGN
will be defined as 0, so this macro is redundant.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
There is substantial latency in generation and handling of PPS events
from the NIC, which we have to correct for before passing a host
timestamp to the PPS subsystem. We compare clocks with the MC,
giving us two offsets to subtract from the timestamp generated by
pps_get_ts():
(a) Time from the last good sync (where we got host and NIC timestamps
for nearly the same instant) to the time we called pps_get_ts()
(b) Time from NIC top of second to the last good sync
We currently calculate (a) + (b) in a quite confusing way.
Instead, calculate (a) completely, then add (b) to it.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Use conventional net_ratelimit() instead.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Shradha Shah <sshah@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings says:
====================
ethtool: Improve documentation
This series converts most comments in <linux/ethtool.h> into kernel-doc
format, and expands them to describe the semantics as well as I
understand them. It also fixes some kernel-doc formatting errors.
I started on this at Solarflare, but they graciously allowed me to take
it away and finish it off.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
A colon almost unavoidably starts a new section. The script should be
changed to provide a way to avoid this, but for now reword the
comments to avoid using colons.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
The kernel-doc script does not tolerate the macro definition in between.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Various ethtool command structures are declared with zero-length array
at the end which are intended to be variable-length in userland
(relying on lack of compiler bounds checking). However, in the kernel
the structure and array are always allocated and passed to driver
operations separately. Make that explicit.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Convert the inline comments to kernel-doc format.
Explicitly specify that non-zero autoneg is an error if link
autonegotiation is disabled.
Specify that pause capabilities should be advertised dependent on link
autonegotiation, not the autoneg flag here. There is no way to
opt-out of pause frame autonegotiation, and this improves behaviour
when the link partner is configured to follow pause frame
autonegotiation and our interface is not.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Replace the inline comments (and some others below) with a full
explanation of the semantics, in kernel-doc format. Specify which
strings may be empty. Document the relationship with other commands.
Replace the 'deprecation' of some fields with a proper explanation of
the conversion to generalised string sets, as userland programs may
not be able to assume that ETHTOOL_GSSET_INFO is available.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
struct ethtool_cmd has very limited documentation; it contains
several obscure or obsolete fields and several with non-obvious
interpretation.
Replace the inline comments (and some others below) with a full
explanation of the semantics as well as I understand them, in
kernel-doc format. Formally deprecate some fields that seem to be of
historical use only.
Extend the comment about 32/64-bit compatibility to cover all
ethtool structures.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>