1. 15 Jun, 2014 2 commits
    • Tom Herbert's avatar
      net: Fix save software checksum complete · 46fb51eb
      Tom Herbert authored
      Geert reported issues regarding checksum complete and UDP.
      The logic introduced in commit 7e3cead5
      ("net: Save software checksum complete") is not correct.
      
      This patch:
      1) Restores code in __skb_checksum_complete_header except for setting
         CHECKSUM_UNNECESSARY. This function may be calculating checksum on
         something less than skb->len.
      2) Adds saving checksum to __skb_checksum_complete. The full packet
         checksum 0..skb->len is calculated without adding in pseudo header.
         This value is saved in skb->csum and then the pseudo header is added
         to that to derive the checksum for validation.
      3) In both __skb_checksum_complete_header and __skb_checksum_complete,
         set skb->csum_valid to whether checksum of zero was computed. This
         allows skb_csum_unnecessary to return true without changing to
         CHECKSUM_UNNECESSARY which was done previously.
      4) Copy new csum related bits in __copy_skb_header.
      Reported-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      46fb51eb
    • Tom Herbert's avatar
      net: Fix GSO constants to match NETIF flags · 4b28252c
      Tom Herbert authored
      Joseph Gasparakis reported that VXLAN GSO offload stopped working with
      i40e device after recent UDP changes. The problem is that the
      SKB_GSO_* bits are out of sync with the corresponding NETIF flags. This
      patch fixes that. Also, we add BUILD_BUG_ONs in net_gso_ok for several
      GSO constants that were missing to avoid the problem in the future.
      Reported-by: default avatarJoseph Gasparakis <joseph.gasparakis@intel.com>
      Signed-off-by: default avatarTom Herbert <therbert@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4b28252c
  2. 13 Jun, 2014 3 commits
  3. 12 Jun, 2014 35 commits
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next · f9da455b
      Linus Torvalds authored
      Pull networking updates from David Miller:
      
       1) Seccomp BPF filters can now be JIT'd, from Alexei Starovoitov.
      
       2) Multiqueue support in xen-netback and xen-netfront, from Andrew J
          Benniston.
      
       3) Allow tweaking of aggregation settings in cdc_ncm driver, from Bjørn
          Mork.
      
       4) BPF now has a "random" opcode, from Chema Gonzalez.
      
       5) Add more BPF documentation and improve test framework, from Daniel
          Borkmann.
      
       6) Support TCP fastopen over ipv6, from Daniel Lee.
      
       7) Add software TSO helper functions and use them to support software
          TSO in mvneta and mv643xx_eth drivers.  From Ezequiel Garcia.
      
       8) Support software TSO in fec driver too, from Nimrod Andy.
      
       9) Add Broadcom SYSTEMPORT driver, from Florian Fainelli.
      
      10) Handle broadcasts more gracefully over macvlan when there are large
          numbers of interfaces configured, from Herbert Xu.
      
      11) Allow more control over fwmark used for non-socket based responses,
          from Lorenzo Colitti.
      
      12) Do TCP congestion window limiting based upon measurements, from Neal
          Cardwell.
      
      13) Support busy polling in SCTP, from Neal Horman.
      
      14) Allow RSS key to be configured via ethtool, from Venkata Duvvuru.
      
      15) Bridge promisc mode handling improvements from Vlad Yasevich.
      
      16) Don't use inetpeer entries to implement ID generation any more, it
          performs poorly, from Eric Dumazet.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1522 commits)
        rtnetlink: fix userspace API breakage for iproute2 < v3.9.0
        tcp: fixing TLP's FIN recovery
        net: fec: Add software TSO support
        net: fec: Add Scatter/gather support
        net: fec: Increase buffer descriptor entry number
        net: fec: Factorize feature setting
        net: fec: Enable IP header hardware checksum
        net: fec: Factorize the .xmit transmit function
        bridge: fix compile error when compiling without IPv6 support
        bridge: fix smatch warning / potential null pointer dereference
        via-rhine: fix full-duplex with autoneg disable
        bnx2x: Enlarge the dorq threshold for VFs
        bnx2x: Check for UNDI in uncommon branch
        bnx2x: Fix 1G-baseT link
        bnx2x: Fix link for KR with swapped polarity lane
        sctp: Fix sk_ack_backlog wrap-around problem
        net/core: Add VF link state control policy
        net/fsl: xgmac_mdio is dependent on OF_MDIO
        net/fsl: Make xgmac_mdio read error message useful
        net_sched: drr: warn when qdisc is not work conserving
        ...
      f9da455b
    • Linus Torvalds's avatar
      Merge tag 'dm-3.16-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm · 0e04c641
      Linus Torvalds authored
      Pull device mapper updates from Mike Snitzer:
       "This pull request is later than I'd have liked because I was waiting
        for some performance data to help finally justify sending the
        long-standing dm-crypt cpu scalability improvements upstream.
      
        Unfortunately we came up short, so those dm-crypt changes will
        continue to wait, but it seems we're not far off.
      
         . Add dm_accept_partial_bio interface to DM core to allow DM targets
           to only process a portion of a bio, the remainder being sent in the
           next bio.  This enables the old dm snapshot-origin target to only
           split write bios on chunk boundaries, read bios are now sent to the
           origin device unchanged.
      
         . Add DM core support for disabling WRITE SAME if the underlying SCSI
           layer disables it due to command failure.
      
         . Reduce lock contention in DM's bio-prison.
      
         . A few small cleanups and fixes to dm-thin and dm-era"
      
      * tag 'dm-3.16-changes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm:
        dm thin: update discard_granularity to reflect the thin-pool blocksize
        dm bio prison: implement per bucket locking in the dm_bio_prison hash table
        dm: remove symbol export for dm_set_device_limits
        dm: disable WRITE SAME if it fails
        dm era: check for a non-NULL metadata object before closing it
        dm thin: return ENOSPC instead of EIO when error_if_no_space enabled
        dm thin: cleanup noflush_work to use a proper completion
        dm snapshot: do not split read bios sent to snapshot-origin target
        dm snapshot: allocate a per-target structure for snapshot-origin target
        dm: introduce dm_accept_partial_bio
        dm: change sector_count member in clone_info from sector_t to unsigned
      0e04c641
    • Linus Torvalds's avatar
      Merge tag 'pci-v3.16-changes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci · 7550cfab
      Linus Torvalds authored
      Pull more PCI updates from Bjorn Helgaas:
       "Here are some more things I'd like to see in v3.16-rc1:
      
         - DMA alias iterator, part of some work to fix IOMMU issues
         - MVEBU, Tegra, DesignWare changes that I forgot to include before
         - Some whitespace code cleanup
      
        Details:
      
        IOMMU
          - Add DMA alias iterator (Alex Williamson)
          - Add DMA alias quirks for ASMedia, ITE, Tundra bridges (Alex Williamson)
          - Add DMA alias quirks for Marvell, Ricoh devices (Alex Williamson)
          - Add DMA alias quirk for HighPoint devices (Jérôme Carretero)
      
        MSI
          - Fix leak in free_msi_irqs() (Alexei Starovoitov)
      
        Marvell MVEBU
          - Remove unnecessary use of 'conf_lock' spinlock (Andrew Murray)
          - Avoid setting an undefined window size (Jason Gunthorpe)
          - Allow several windows with the same target/attribute (Thomas Petazzoni)
          - Split PCIe BARs into multiple MBus windows when needed (Thomas Petazzoni)
          - Fix off-by-one in the computed size of the mbus windows (Willy Tarreau)
      
        NVIDIA Tegra
          - Use new OF interrupt mapping when possible (Lucas Stach)
      
        Synopsys DesignWare
          - Remove unnecessary use of 'conf_lock' spinlock (Andrew Murray)
          - Use new OF interrupt mapping when possible (Lucas Stach)
          - Split Exynos and i.MX bindings (Lucas Stach)
          - Fix comment for setting number of lanes (Mohit Kumar)
          - Fix iATU programming for cfg1, io and mem viewport (Mohit Kumar)
      
        Miscellaneous
          - EXPORT_SYMBOL cleanup (Ryan Desfosses)
          - Whitespace cleanup (Ryan Desfosses)
          - Merge multi-line quoted strings (Ryan Desfosses)"
      
      * tag 'pci-v3.16-changes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci: (21 commits)
        PCI: Add function 1 DMA alias quirk for HighPoint RocketRaid 642L
        PCI/MSI: Fix memory leak in free_msi_irqs()
        PCI: Merge multi-line quoted strings
        PCI: Whitespace cleanup
        PCI: Move EXPORT_SYMBOL so it immediately follows function/variable
        PCI: Add bridge DMA alias quirk for ITE bridge
        PCI: designware: Split Exynos and i.MX bindings
        PCI: Add bridge DMA alias quirk for ASMedia and Tundra bridges
        PCI: Add support for PCIe-to-PCI bridge DMA alias quirks
        PCI: Add function 1 DMA alias quirk for Marvell devices
        PCI: Add function 0 DMA alias quirk for Ricoh devices
        PCI: Add support for DMA alias quirks
        PCI: Convert pci_dev_flags definitions to bit shifts
        PCI: Add DMA alias iterator
        PCI: mvebu: Use '%pa' for printing 'phys_addr_t' type
        PCI: mvebu: Remove unnecessary use of 'conf_lock' spinlock
        PCI: designware: Remove unnecessary use of 'conf_lock' spinlock
        PCI: designware: Use new OF interrupt mapping when possible
        PCI: designware: Fix iATU programming for cfg1, io and mem viewport
        PCI: designware: Fix comment for setting number of lanes
        ...
      7550cfab
    • Linus Torvalds's avatar
      Merge tag 'pm+acpi-3.16-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 19c1940f
      Linus Torvalds authored
      Pull more ACPI and power management updates from Rafael Wysocki:
       "These are fixups on top of the previous PM+ACPI pull request,
        regression fixes (ACPI hotplug, cpufreq ppc-corenet), other bug fixes
        (ACPI reset, cpufreq), new PM trace points for system suspend
        profiling and a copyright notice update.
      
        Specifics:
      
         - I didn't remember correctly that the Hans de Goede's ACPI video
           patches actually didn't flip the video.use_native_backlight
           default, although we had discussed that and decided to do that.
           Since I said we would do that in the previous PM+ACPI pull request,
           make that change for real now.
      
         - ACPI bus check notifications for PCI host bridges don't cause the
           bus below the host bridge to be checked for changes as they should
           because of a mistake in the ACPI-based PCI hotplug (ACPIPHP)
           subsystem that forgets to add hotplug contexts to PCI host bridge
           ACPI device objects.  Create hotplug contexts for PCI host bridges
           too as appropriate.
      
         - Revert recent cpufreq commit related to the big.LITTLE cpufreq
           driver that breaks arm64 builds.
      
         - Fix for a regression in the ppc-corenet cpufreq driver introduced
           during the 3.15 cycle and causing the driver to use the remainder
           from do_div instead of the quotient.  From Ed Swarthout.
      
         - Resets triggered by panic activate a BUG_ON() in vmalloc.c on
           systems where the ACPI reset register is located in memory address
           space.  Fix from Randy Wright.
      
         - Fix for a problem with cpufreq governors that decisions made by
           them may be suboptimal due to the fact that deferrable timers are
           used by them for CPU load sampling.  From Srivatsa S Bhat.
      
         - Fix for a problem with the Tegra cpufreq driver where the CPU
           frequency is temporarily switched to a "stable" level that is
           different from both the initial and target frequencies during
           transitions which causes udelay() to expire earlier than it should
           sometimes.  From Viresh Kumar.
      
         - New trace points and rework of some existing trace points for
           system suspend/resume profiling from Todd Brandt.
      
         - Assorted cpufreq fixes and cleanups from Stratos Karafotis and
           Viresh Kumar.
      
         - Copyright notice update for suspend-and-cpuhotplug.txt from
           Srivatsa S Bhat"
      
      * tag 'pm+acpi-3.16-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        ACPI / hotplug / PCI: Add hotplug contexts to PCI host bridges
        PM / sleep: trace events for device PM callbacks
        cpufreq: cpufreq-cpu0: remove dependency on THERMAL and REGULATOR
        cpufreq: tegra: update comment for clarity
        cpufreq: intel_pstate: Remove duplicate CPU ID check
        cpufreq: Mark CPU0 driver with CPUFREQ_NEED_INITIAL_FREQ_CHECK flag
        PM / Documentation: Update copyright in suspend-and-cpuhotplug.txt
        cpufreq: governor: remove copy_prev_load from 'struct cpu_dbs_common_info'
        cpufreq: governor: Be friendly towards latency-sensitive bursty workloads
        PM / sleep: trace events for suspend/resume
        cpufreq: ppc-corenet-cpu-freq: do_div use quotient
        Revert "cpufreq: Enable big.LITTLE cpufreq driver on arm64"
        cpufreq: Tegra: implement intermediate frequency callbacks
        cpufreq: add support for intermediate (stable) frequencies
        ACPI / video: Change the default for video.use_native_backlight to 1
        ACPI: Fix bug when ACPI reset register is implemented in system memory
      19c1940f
    • Linus Torvalds's avatar
      Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds · 7c574cf6
      Linus Torvalds authored
      Pull LED updates from Bryan Wu:
       "I just found merge window is open and I'm quite busy and almost forget
        to send out this pull request.  Thanks Russell and Alexandre ping me
        about this.
      
        So basically we got some clean up and leds-pwm fixing patches from
        Russell"
      
      * 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds:
        leds: Remove duplicated OOM message for individual driver
        drivers/leds: Replace __get_cpu_var use through this_cpu_ptr
        leds: lp55xx: add DT bindings for LP55231
        leds: 88pm860x: Fix missing refcount decrement for parent of_node
        leds: 88pm860x: Use of_get_child_by_name
        leds: leds-pwm: add DT support for LEDs wired to supply
        leds: leds-pwm: implement PWM inversion
        leds: leds-pwm: convert OF parsing code to use led_pwm_add()
        leds: leds-pwm: provide a common function to setup a single led-pwm device
        leds: pca9685: Remove leds-pca9685 driver
        dell-led: add mic mute led interface
      7c574cf6
    • Linus Torvalds's avatar
      Merge tag 'backlight-for-linus-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight · af76004c
      Linus Torvalds authored
      Pull backlight fixes from Lee Jones:
       "This merely contains some very basic build/run-time bug fixes"
      
      * tag 'backlight-for-linus-3.16' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight:
        backlight: gpio-backlight: Fix warning when the GPIO is on a I2C chip
        video/backlight: s6e63m0: Fix string type mismatch
        video/backlight: LP8788 needs PWM
        video/backlight: LP855X needs PWM
        video/pxa: LCD_CORGI needs BACKLIGHT_CLASS_DEVICE
        video/backlight: LM3630A needs PWM
      af76004c
    • Linus Torvalds's avatar
      Merge tag 'mfd-for-linus-3.16-1' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd · bae14e7a
      Linus Torvalds authored
      Pull more MFD updates from Lee Jones:
       "I missed collecting these patches due to a branch/tag naming
        ambiguity.  Completely my own fault, as I mindlessly named a branch
        and tag identically.  Sorry for the fuss.
      
        This pull-request contains some misplaced patches from Tony Lindgren
        that should have been part of the initial one"
      
      * tag 'mfd-for-linus-3.16-1' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd:
        mfd: twl4030-power: Add a configuration to turn off oscillator during off-idle
        mfd: twl4030-power: Add support for board specific configuration
        mfd: twl4030-power: Add recommended idle configuration
        mfd: twl4030-power: Add generic reset configuration
        mfd: twl4030-power: Fix some defines for SW_EVENTS
        mfd: twl4030-power: Fix hang on reboot if sleep configuration was loaded earlier
      bae14e7a
    • Linus Torvalds's avatar
      Merge tag 'mmc-v3.16-2' of git://git.linaro.org/people/ulf.hansson/mmc · 171c0621
      Linus Torvalds authored
      Pull MMC fixes from Ulf Hansson:
       "Here are some mmc fixes for 3.16.
      
         - fix some various compiler warnings
         - make atmel-mci compile again
         - fix regression for sdhci-msm"
      
      * tag 'mmc-v3.16-2' of git://git.linaro.org/people/ulf.hansson/mmc:
        mmc: simplify SDHCI Kconfig dependencies
        mmc: omap: don't select TPS65010
        mmc: mvsdio: avoid compiler warning
        mmc: atmel-mci: incude asm/cacheclush.h
        mmc: sdhci-msm: Fix fallout from sdhci refactoring
        mmc: usdhi6rol0: fix compiler warnings
      171c0621
    • Linus Torvalds's avatar
      Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux · 682b7c1c
      Linus Torvalds authored
      Pull drm updates from Dave Airlie:
       "This is the main drm merge window pull request, changes all over the
        place, mostly normal levels of churn.
      
        Highlights:
      
        Core drm:
           More cleanups, fix race on connector/encoder naming, docs updates,
           object locking rework in prep for atomic modeset
      
        i915:
           mipi DSI support, valleyview power fixes, cursor size fixes,
           execlist refactoring, vblank improvements, userptr support, OOM
           handling improvements
      
        radeon:
           GPUVM tuning and large page size support, gart fixes, deep color
           HDMI support, HDMI audio cleanups
      
        nouveau:
           - displayport rework should fix lots of issues
           - initial gk20a support
           - gk110b support
           - gk208 fixes
      
        exynos:
           probe order fixes, HDMI changes, IPP consolidation
      
        msm:
           debugfs updates, misc fixes
      
        ast:
           ast2400 support, sync with UMS driver
      
        tegra:
           cleanups, hdmi + hw cursor for Tegra 124.
      
        panel:
           fixes existing panels add some new ones.
      
        ipuv3:
           moved from staging to drivers/gpu"
      
      * 'drm-next' of git://people.freedesktop.org/~airlied/linux: (761 commits)
        drm/nouveau/disp/dp: fix tmds passthrough on dp connector
        drm/nouveau/dp: probe dpcd to determine connectedness
        drm/nv50-: trigger update after all connectors disabled
        drm/nv50-: prepare for attaching a SOR to multiple heads
        drm/gf119-/disp: fix debug output on update failure
        drm/nouveau/disp/dp: make use of postcursor when its available
        drm/g94-/disp/dp: take max pullup value across all lanes
        drm/nouveau/bios/dp: parse lane postcursor data
        drm/nouveau/dp: fix support for dpms
        drm/nouveau: register a drm_dp_aux channel for each dp connector
        drm/g94-/disp: add method to power-off dp lanes
        drm/nouveau/disp/dp: maintain link in response to hpd signal
        drm/g94-/disp: bash and wait for something after changing lane power regs
        drm/nouveau/disp/dp: split link config/power into two steps
        drm/nv50/disp: train PIOR-attached DP from second supervisor
        drm/nouveau/disp/dp: make use of existing output data for link training
        drm/gf119/disp: start removing direct vbios parsing from supervisor
        drm/nv50/disp: start removing direct vbios parsing from supervisor
        drm/nouveau/disp/dp: maintain receiver caps in response to hpd signal
        drm/nouveau/disp/dp: create subclass for dp outputs
        ...
      682b7c1c
    • Michal Schmidt's avatar
      rtnetlink: fix userspace API breakage for iproute2 < v3.9.0 · e5eca6d4
      Michal Schmidt authored
      When running RHEL6 userspace on a current upstream kernel, "ip link"
      fails to show VF information.
      
      The reason is a kernel<->userspace API change introduced by commit
      88c5b5ce ("rtnetlink: Call nlmsg_parse() with correct header length"),
      after which the kernel does not see iproute2's IFLA_EXT_MASK attribute
      in the netlink request.
      
      iproute2 adjusted for the API change in its commit 63338dca4513
      ("libnetlink: Use ifinfomsg instead of rtgenmsg in rtnl_wilddump_req_filter").
      
      The problem has been noticed before:
      http://marc.info/?l=linux-netdev&m=136692296022182&w=2
      (Subject: Re: getting VF link info seems to be broken in 3.9-rc8)
      
      We can do better than tell those with old userspace to upgrade. We can
      recognize the old iproute2 in the kernel by checking the netlink message
      length. Even when including the IFLA_EXT_MASK attribute, its netlink
      message is shorter than struct ifinfomsg.
      
      With this patch "ip link" shows VF information in both old and new
      iproute2 versions.
      Signed-off-by: default avatarMichal Schmidt <mschmidt@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e5eca6d4
    • Per Hurtig's avatar
      tcp: fixing TLP's FIN recovery · bef1909e
      Per Hurtig authored
      Fix to a problem observed when losing a FIN segment that does not
      contain data.  In such situations, TLP is unable to recover from
      *any* tail loss and instead adds at least PTO ms to the
      retransmission process, i.e., RTO = RTO + PTO.
      Signed-off-by: default avatarPer Hurtig <per.hurtig@kau.se>
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Acked-by: default avatarNandita Dukkipati <nanditad@google.com>
      Acked-by: default avatarNeal Cardwell <ncardwell@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bef1909e
    • David S. Miller's avatar
      Merge branch 'fec' · fba0e1a3
      David S. Miller authored
      Fugang Duan says:
      
      ====================
      net: fec: Enable Software TSO to improve the tx performance
      
      Add SG and software TSO support for FEC.
      This feature allows to improve outbound throughput performance.
      Tested on imx6dl sabresd board, running iperf tcp tests shows:
              * 82% improvement comparing with NO SG & TSO patch
      
      $ ethtool -K eth0 sg on
      $ ethtool -K eth0 tso on
      [  3] local 10.192.242.108 port 35388 connected with 10.192.242.167 port 5001
      [ ID] Interval       Transfer     Bandwidth
      [  3]  0.0- 3.0 sec   181 MBytes   506 Mbits/sec
      * cpu loading is 30%
      
      $ ethtool -K eth0 sg off
      $ ethtool -K eth0 tso off
      [  3] local 10.192.242.108 port 52618 connected with 10.192.242.167 port 5001
      [ ID] Interval       Transfer     Bandwidth
      [  3]  0.0- 3.0 sec  99.5 MBytes   278 Mbits/sec
      
      FEC HW support IP header and TCP/UDP hw checksum, support multi buffer descriptor transfer
      one frame, but don't support HW TSO. And imx6q/dl SOC FEC Gbps speed has HW bus Bandwidth
      limitation (400Mbps ~ 700Mbps), imx6sx SOC FEC Gbps speed has no HW bandwidth limitation.
      
      The patch set just enable TSO feature, which is done following the mv643xx_eth driver.
      
      Test result analyze:
      imx6dl sabresd board: there have 82% improvement, since imx6dl FEC HW has bandwidth limitation,
                            the performance with SW TSO is a milestone.
      
      Addition test:
      imx6sx sdb board:
      upstream still don't support imx6sx due to some patches being upstream... they use same FEC IP.
      Use the SW TSO patches test imx6sx sdb board in internal kernel tree:
      No SW TSO patch: tx bandwidth 840Mbps, cpu loading is 100%.
      SW TSO patch:    tx bandwidth 942Mbps, cpu loading is 65%.
      It means the patch set have great improvement for imx6sx FEC performance.
      
      V2:
      * From Frank Li's suggestion:
      	Change the API "fec_enet_txdesc_entry_free" name to "fec_enet_get_free_txdesc_num".
      * Summary David Laight and Eric Dumazet's thoughts:
      	RX BD entry number change to 256.
      * From ezequiel's suggestion:
      	Follow the latest TSO fixes from his solution to rework the queue stop/wake-up.
      	Avoid unmapping the TSO header buffers.
      * From Eric Dumazet's suggestion:
      	Avoid more bytes copy, just copying the unaligned part of the payload into first
      	descriptor. The suggestion will bring more complex for the driver, and imx6dl FEC
      	DMA need 16 bytes alignment, but cpu loading is not problem that cpu loading is
      	30%, the current performance is so better. Later chip like imx6sx Gigbit FEC DMA
      	support byte alignment, so there don't exist memory copy. So, the V2 version drop
      	the suggestion.
      	Anyway, thanks for Eric's response and suggestion.
      
      V3:
      * From David Laight's feedback:
      	Decide to drop RX BD entry number change for the SW TSO patch set.
      	I will generate one separate patch to increase RX BDs entry for interrupt coalescing feature which
      	will be supported in my later patch set.
      
      V4:
      * From David Laight's feedback:
      	Remove the conditional in .fec_enet_get_bd_index().
      
      V5:
      * Patch #4 update:
        From David Laight's feedback:
      	"expect fec_enet_get_free_txdesc_num() to return one less than it does currently."
      	Change the function:
      	Return space available, 0..size-1.  it always leave one free entry. Which is same as linux circ_buf.
      
      Thanks for Eric and ezequiel's help and idea.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      fba0e1a3
    • Nimrod Andy's avatar
      net: fec: Add software TSO support · 79f33912
      Nimrod Andy authored
      Add software TSO support for FEC.
      This feature allows to improve outbound throughput performance.
      
      Tested on imx6dl sabresd board, running iperf tcp tests shows:
      - 16.2% improvement comparing with FEC SG patch
      - 82% improvement comparing with NO SG & TSO patch
      
      $ ethtool -K eth0 tso on
      $ iperf -c 10.192.242.167 -t 3 &
      [  3] local 10.192.242.108 port 35388 connected with 10.192.242.167 port 5001
      [ ID] Interval       Transfer     Bandwidth
      [  3]  0.0- 3.0 sec   181 MBytes   506 Mbits/sec
      
      During the testing, CPU loading is 30%.
      Since imx6dl FEC Bandwidth is limited to SOC system bus bandwidth, the
      performance with SW TSO is a milestone.
      
      CC: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
      CC: Eric Dumazet <eric.dumazet@gmail.com>
      CC: David Laight <David.Laight@ACULAB.COM>
      CC: Li Frank <B20596@freescale.com>
      Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      79f33912
    • Nimrod Andy's avatar
      net: fec: Add Scatter/gather support · 6e909283
      Nimrod Andy authored
      Add Scatter/gather support for FEC.
      This feature allows to improve outbound throughput performance.
      
      Tested on imx6dl sabresd board:
      Running iperf tests shows a 55.4% improvement.
      
      $ ethtool -K eth0 sg off
      $ iperf -c 10.192.242.167 -t 3 &
      [  3] local 10.192.242.108 port 52618 connected with 10.192.242.167 port 5001
      [ ID] Interval       Transfer     Bandwidth
      [  3]  0.0- 3.0 sec  99.5 MBytes   278 Mbits/sec
      
      $ ethtool -K eth0 sg on
      $ iperf -c 10.192.242.167 -t 3 &
      [  3] local 10.192.242.108 port 52617 connected with 10.192.242.167 port 5001
      [ ID] Interval       Transfer     Bandwidth
      [  3]  0.0- 3.0 sec   154 MBytes   432 Mbits/sec
      
      CC: Li Frank <B20596@freescale.com>
      Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6e909283
    • Nimrod Andy's avatar
      net: fec: Increase buffer descriptor entry number · 55d0218a
      Nimrod Andy authored
      In order to support SG, software TSO, let's increase BD entry number.
      
      CC: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
      CC: Eric Dumazet <eric.dumazet@gmail.com>
      CC: David Laight <David.Laight@ACULAB.COM>
      Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      55d0218a
    • Nimrod Andy's avatar
      net: fec: Factorize feature setting · 09d1e541
      Nimrod Andy authored
      In order to enhance the code readable, let's factorize the
      feature list.
      Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      09d1e541
    • Nimrod Andy's avatar
      net: fec: Enable IP header hardware checksum · 96c50caa
      Nimrod Andy authored
      IP header checksum is calcalated by network layer in default.
      To support software TSO, it is better to use HW calculate the
      IP header checksum.
      
      FEC hw checksum feature request the checksum field in frame
      is zero, otherwise the calculative CRC is not correct.
      
      For segmentated TCP packet, HW calculate the IP header checksum again,
      it doesn't bring any impact. For SW TSO, HW calculated checksum bring
      better performance.
      Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      96c50caa
    • Nimrod Andy's avatar
      net: fec: Factorize the .xmit transmit function · 61a4427b
      Nimrod Andy authored
      Make the code more readable and easy to support other features like
      SG, TSO, moving the common transmit function to one api.
      
      And the patch also factorize the getting BD index to it own function.
      
      CC: David Laight <David.Laight@ACULAB.COM>
      Signed-off-by: default avatarFugang Duan <B38611@freescale.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      61a4427b
    • Linus Lüssing's avatar
      bridge: fix compile error when compiling without IPv6 support · 3993c4e1
      Linus Lüssing authored
      Some fields in "struct net_bridge" aren't available when compiling the
      kernel without IPv6 support. Therefore adding a check/macro to skip the
      complaining code sections in that case.
      
      Introduced by 2cd41431
      ("bridge: memorize and export selected IGMP/MLD querier port")
      Reported-by: default avatarkbuild test robot <fengguang.wu@intel.com>
      Signed-off-by: default avatarLinus Lüssing <linus.luessing@web.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      3993c4e1
    • Linus Lüssing's avatar
      bridge: fix smatch warning / potential null pointer dereference · 6c03ee8b
      Linus Lüssing authored
      "New smatch warnings:
        net/bridge/br_multicast.c:1368 br_ip6_multicast_query() error:
          we previously assumed 'group' could be null (see line 1349)"
      
      In the rare (sort of broken) case of a query having a Maximum
      Response Delay of zero, we could create a potential null pointer
      dereference.
      
      Fixing this by skipping the multicast specific MLD Query parsing again
      if no multicast group address is available.
      
      Introduced by dc4eb53a
      ("bridge: adhere to querier election mechanism specified by RFCs")
      Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Signed-off-by: default avatarLinus Lüssing <linus.luessing@web.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6c03ee8b
    • François Cachereul's avatar
      via-rhine: fix full-duplex with autoneg disable · 17958438
      François Cachereul authored
      With some specific configuration (VT6105M on Soekris 5510 and depending
      on the device at the other end), fragmented packets were not transmitted
      when forcing 100 full-duplex with autoneg disable.
      
      This fix now write full-duplex chips register when forcing full or
      half-duplex not only when autoneg is enable.
      Signed-off-by: default avatarFrançois Cachereul <f.cachereul@alphalink.fr>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      17958438
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 16b90578
      Linus Torvalds authored
      Pull vfs updates from Al Viro:
       "This the bunch that sat in -next + lock_parent() fix.  This is the
        minimal set; there's more pending stuff.
      
        In particular, I really hope to get acct.c fixes merged this cycle -
        we need that to deal sanely with delayed-mntput stuff.  In the next
        pile, hopefully - that series is fairly short and localized
        (kernel/acct.c, fs/super.c and fs/namespace.c).  In this pile: more
        iov_iter work.  Most of prereqs for ->splice_write with sane locking
        order are there and Kent's dio rewrite would also fit nicely on top of
        this pile"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (70 commits)
        lock_parent: don't step on stale ->d_parent of all-but-freed one
        kill generic_file_splice_write()
        ceph: switch to iter_file_splice_write()
        shmem: switch to iter_file_splice_write()
        nfs: switch to iter_splice_write_file()
        fs/splice.c: remove unneeded exports
        ocfs2: switch to iter_file_splice_write()
        ->splice_write() via ->write_iter()
        bio_vec-backed iov_iter
        optimize copy_page_{to,from}_iter()
        bury generic_file_aio_{read,write}
        lustre: get rid of messing with iovecs
        ceph: switch to ->write_iter()
        ceph_sync_direct_write: stop poking into iov_iter guts
        ceph_sync_read: stop poking into iov_iter guts
        new helper: copy_page_from_iter()
        fuse: switch to ->write_iter()
        btrfs: switch to ->write_iter()
        ocfs2: switch to ->write_iter()
        xfs: switch to ->write_iter()
        ...
      16b90578
    • David S. Miller's avatar
      Merge branch 'bnx2x' · a4d3de0d
      David S. Miller authored
      Yuval Mintz says:
      
      ====================
      bnx2x: Bug fixes patch series
      
      This patch series contains various bug fixes - 2 link related fixes,
      one sriov-related issue and an additional fix for a theoretical bug
      on new boards.
      
      Please consider applying these patches to `net'.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a4d3de0d
    • Ariel Elior's avatar
      bnx2x: Enlarge the dorq threshold for VFs · f2cfa997
      Ariel Elior authored
      A malicious VF might try to starve the other VFs & PF by creating
      contineous doorbell floods. In order to negate this, HW has a threshold of
      doorbells per client, which will stop the client doorbells from arriving
      if crossed.
      
      The threshold currently configured for VFs is too low - under extreme traffic
      scenarios, it's possible for a VF to reach the threshold and thus for its
      fastpath to stop working.
      Signed-off-by: default avatarAriel Elior <ariel.elior@qlogic.com>
      Signed-off-by: default avatarYuval Mintz <yuval.mintz@qlogic.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f2cfa997
    • Yuval Mintz's avatar
      bnx2x: Check for UNDI in uncommon branch · b17b0ca1
      Yuval Mintz authored
      If L2FW utilized by the UNDI driver has the same version number as that
      of the regular FW, a driver loading after UNDI and receiving an uncommon
      answer from management will mistakenly assume the loaded FW matches its
      own requirement and try to exist the flow via FLR.
      Signed-off-by: default avatarYuval Mintz <yuval.mintz@qlogic.com>
      Signed-off-by: default avatarAriel Elior <ariel.elior@qlogic.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b17b0ca1
    • Yaniv Rosner's avatar
      bnx2x: Fix 1G-baseT link · a2755be5
      Yaniv Rosner authored
      Set the phy access mode even in case of link-flap avoidance.
      Signed-off-by: default avatarYaniv Rosner <yaniv.rosner@qlogic.com>
      Signed-off-by: default avatarYuval Mintz <yuval.mintz@qlogic.com>
      Signed-off-by: default avatarAriel Elior <ariel.elior@qlogic.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a2755be5
    • Yaniv Rosner's avatar
      bnx2x: Fix link for KR with swapped polarity lane · dad91ee4
      Yaniv Rosner authored
      This avoids clearing the RX polarity setting in KR mode when polarity lane
      is swapped, as otherwise this will result in failed link.
      Signed-off-by: default avatarYaniv Rosner <yaniv.rosner@qlogic.com>
      Signed-off-by: default avatarYuval Mintz <yuval.mintz@qlogic.com>
      Signed-off-by: default avatarAriel Elior <ariel.elior@qlogic.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      dad91ee4
    • Xufeng Zhang's avatar
      sctp: Fix sk_ack_backlog wrap-around problem · d3217b15
      Xufeng Zhang authored
      Consider the scenario:
      For a TCP-style socket, while processing the COOKIE_ECHO chunk in
      sctp_sf_do_5_1D_ce(), after it has passed a series of sanity check,
      a new association would be created in sctp_unpack_cookie(), but afterwards,
      some processing maybe failed, and sctp_association_free() will be called to
      free the previously allocated association, in sctp_association_free(),
      sk_ack_backlog value is decremented for this socket, since the initial
      value for sk_ack_backlog is 0, after the decrement, it will be 65535,
      a wrap-around problem happens, and if we want to establish new associations
      afterward in the same socket, ABORT would be triggered since sctp deem the
      accept queue as full.
      Fix this issue by only decrementing sk_ack_backlog for associations in
      the endpoint's list.
      Fix-suggested-by: default avatarNeil Horman <nhorman@tuxdriver.com>
      Signed-off-by: default avatarXufeng Zhang <xufeng.zhang@windriver.com>
      Acked-by: default avatarDaniel Borkmann <dborkman@redhat.com>
      Acked-by: default avatarVlad Yasevich <vyasevich@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d3217b15
    • Rafael J. Wysocki's avatar
      Merge branch 'pm-sleep' · d715a226
      Rafael J. Wysocki authored
      * pm-sleep:
        PM / sleep: trace events for device PM callbacks
        PM / sleep: trace events for suspend/resume
      d715a226
    • Rafael J. Wysocki's avatar
      Merge branch 'pm-cpufreq' · 589e18a9
      Rafael J. Wysocki authored
      * pm-cpufreq:
        cpufreq: cpufreq-cpu0: remove dependency on THERMAL and REGULATOR
        cpufreq: tegra: update comment for clarity
        cpufreq: intel_pstate: Remove duplicate CPU ID check
        cpufreq: Mark CPU0 driver with CPUFREQ_NEED_INITIAL_FREQ_CHECK flag
        cpufreq: governor: remove copy_prev_load from 'struct cpu_dbs_common_info'
        cpufreq: governor: Be friendly towards latency-sensitive bursty workloads
        cpufreq: ppc-corenet-cpu-freq: do_div use quotient
        Revert "cpufreq: Enable big.LITTLE cpufreq driver on arm64"
        cpufreq: Tegra: implement intermediate frequency callbacks
        cpufreq: add support for intermediate (stable) frequencies
      589e18a9
    • Rafael J. Wysocki's avatar
      Merge branches 'acpi-general' and 'acpi-video' · de815a6d
      Rafael J. Wysocki authored
      * acpi-general:
        ACPI: Fix bug when ACPI reset register is implemented in system memory
      
      * acpi-video:
        ACPI / video: Change the default for video.use_native_backlight to 1
      de815a6d
    • Rafael J. Wysocki's avatar
      Merge branch 'acpi-hotplug' · 9d674f21
      Rafael J. Wysocki authored
      * acpi-hotplug:
        ACPI / hotplug / PCI: Add hotplug contexts to PCI host bridges
      9d674f21
    • Arnd Bergmann's avatar
      mmc: simplify SDHCI Kconfig dependencies · 5d01b768
      Arnd Bergmann authored
      We have a number of front-end drivers for SDHCI_PLTFM, some of them
      use 'select MMC_SDHCI_PLTFM', others use 'depends on'. This is
      inconsistent and confusing, and in one case has also led to a
      build error because of incomplete dependencies:
      
      warning: (MMC_SDHCI_PXAV3 && MMC_SDHCI_PXAV2 && MMC_SDHCI_BCM_KONA) selects MMC_SDHCI_PLTFM which has unmet direct dependencies (MMC && MMC_SDHCI)
      drivers/built-in.o: In function `sdhci_sirf_resume':
      :(.text+0xaaacb4): undefined reference to `sdhci_resume_host'
      drivers/built-in.o: In function `sdhci_sirf_suspend':
      :(.text+0xaaacf8): undefined reference to `sdhci_suspend_host'
      drivers/built-in.o: In function `sdhci_sirf_probe':
      :(.text+0xaaaf44): undefined reference to `sdhci_add_host'
      :(.text+0xaaaf50): undefined reference to `sdhci_remove_host'
      
      This changes Kconfig to use 'depends on MMC_SDHCI_PLTFM' for all these
      cases, to fix the build error and make the logic more logical.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
      5d01b768
    • Arnd Bergmann's avatar
      mmc: omap: don't select TPS65010 · 60a549fc
      Arnd Bergmann authored
      The MMC host driver should not select the pmic driver, since that
      may have other dependencies, notably i2c in this case. It's not
      clear what the exact requirement of the driver is, but to preserve
      the behavior, this patch changes the 'select' into 'depends on',
      meaning you now have to turn on TPS65010 explicitly and then
      MMC_OMAP.
      
      Found during randconfig build testing.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: linux-omap@vger.kernel.org
      Cc: Jarkko Nikula <jarkko.nikula@bitmer.com>
      Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
      60a549fc
    • Arnd Bergmann's avatar
      mmc: mvsdio: avoid compiler warning · d7fe833f
      Arnd Bergmann authored
      gcc correctly points out that hw_state can be used uninitially
      in the mvsd_setup_data() function. This rearranges the function
      to ensure it always contains a proper value.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Nicolas Pitre <nico@fluxnic.net>
      Cc: Chris Ball <chris@printf.net>
      Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Cc: Jason Cooper <jason@lakedaemon.net>
      Cc: Andrew Lunn <andrew@lunn.ch>
      Cc: linux-mmc@vger.kernel.org
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
      d7fe833f