1. 04 11月, 2014 1 次提交
    • H
      tun: Fix csum_start with VLAN acceleration · a8f9bfdf
      Herbert Xu 提交于
      When VLAN acceleration is in use on the xmit path, we end up
      setting csum_start to the wrong place.  The result is that the
      whoever ends up doing the checksum setting will corrupt the packet
      instead of writing the checksum to the expected location, usually
      this means writing the checksum with an offset of -4.
      
      This patch fixes this by adjusting csum_start when VLAN acceleration
      is detected.
      
      Fixes: 6680ec68 ("tuntap: hardware vlan tx support")
      Cc: stable@vger.kernel.org
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a8f9bfdf
  2. 02 11月, 2014 5 次提交
    • L
      smc91x: retrieve IRQ and trigger flags in a modern way · d52fdbb7
      Linus Walleij 提交于
      The SMC91x is written to explicitly look up the IRQ resource
      from the platform device and extract the IRQ and flags, however
      the platform_get_irq() does additional things, like call
      of_irq_get() in the device tree case, which will translate
      the IRQ using the irqdomain and defer the probe if the
      IRQ host cannot be found.
      
      As we're not looking up the resource, this will not retrieve
      the IRQ flags, but that is better done using
      irqd_get_trigger_type(), as the trigger is what the driver
      wants to modify. We take care to preserve the semantics that
      will make the trigger type provided from the resource
      override any local specifier.
      
      Tested on the Nomadik NHK15 which has its SMC91x IRQ line
      connected to a STMPE2401 GPIO expander on I2C.
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d52fdbb7
    • C
      drivers: net: ethernet: xilinx: xilinx_emaclite: Compatible with 'xlnx,... · 1db3ddff
      Chen Gang 提交于
      drivers: net: ethernet: xilinx: xilinx_emaclite: Compatible with 'xlnx, xps-ethernetlite-2.00.b' for QEMU using
      
      When use current latest upstream qemu (current version: 2.1.2), need let
      driver compatible with 'xlnx,xps-ethernetlite-2.00.b', or can not find
      net device in microblaze qemu. Related QEMU commands under fedora 20:
      
        yum install libvirt
        yum install tunctl
        tunctl -b
        ip link set tap0 up
        brctl addif virbr0 tap0
        ./microblaze-softmmu/qemu-system-microblaze -M petalogix-s3adsp1800 \
          -kernel ../linux-stable.microblaze/arch/microblaze/boot/linux.bin \
          -no-reboot -append "console=ttyUL0,115200 doreboot" -nographic \
          -net nic,vlan=0,model=xlnx.xps-ethernetlite,macaddr=00:16:35:AF:94:00 \
          -net tap,vlan=0,ifname=tap0,script=no,downscript=no
      
        in microblaze qemu bash (guest machine):
      
          ifconfig eth0 add 192.168.122.2 netmask 255.255.255.0
          ifconfig eth0 up
      
      After add this patch, can find the device, and can be used by 'telnetd'
      (need cross-build busybox with glibc for it), then outside can telnet to
      it without password.
      Signed-off-by: NChen Gang <gang.chen.5i5j@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1db3ddff
    • F
      net: systemport: do not crash freeing an unitialized TX ring · 914adb55
      Florian Fainelli 提交于
      Callers of bcm_sysport_init_tx_ring() can currently fail, and will
      always call bcm_sysport_fini_tx_ring() in a loop ending at the number of
      TX queues (32) without checking if the TX ring was successfully
      initialized or not.
      
      Update bcm_sysport_fini_tx_ring() to return early and avoid a crash
      de-referencing ring->cbs if the TX ring was not initialized, since
      ring->cbs is the last part of the initialization done by
      bcm_sysport_init_tx_ring() that could fail.
      
      Fixes: 80105bef ("net: systemport: add Broadcom SYSTEMPORT Ethernet MAC driver")
      Reported-by: NMaxime Bizon <mbizon@freebox.fr>
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      914adb55
    • F
      net: systemport: fix DMA allocation/freeing sizes · 3e8fc38c
      Florian Fainelli 提交于
      We should not be allocating a single byte of DMA coherent memory, but
      instead a full-sized struct dma_desc (8 bytes).
      
      Fixes: 80105bef ("net: systemport: add Broadcom SYSTEMPORT Ethernet MAC driver")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      3e8fc38c
    • S
      net: mvpp2: fix possible memory leak · 43737473
      Sudip Mukherjee 提交于
      we are allocating memory using kzalloc for struct mvpp2_prs_entry,
      but later when we are getting error we were just returning the error
      value without releasing the memory.
      Signed-off-by: NSudip Mukherjee <sudip@vectorindia.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      43737473
  3. 01 11月, 2014 11 次提交
  4. 31 10月, 2014 18 次提交
  5. 30 10月, 2014 5 次提交