1. 18 Jun, 2015 3 commits
  2. 16 Jun, 2015 21 commits
  3. 15 Jun, 2015 16 commits
    • David S. Miller's avatar
      Merge tag 'nfc-next-4.2-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/nfc-next · 023033b1
      David S. Miller authored
      Samuel Ortiz says:
      
      ====================
      NFC 4.2 pull request
      
      This is the NFC pull request for 4.2.
      
      - NCI drivers can now define their own handlers for processing
        proprietary NCI responses and notifications.
      
      - NFC vendors can use a dedicated netlink API to send their own
        proprietary commands, like e.g. all commands needed to implement
        vendor specific manufacturing tools.
      
      - A new generic NCI over UART driver against which any NCI chipset
        running on top of a serial interface can register.
      
      - The st21nfcb driver is renamed to st-nci as it can and will support
        most of ST Microelectronics NCI chipsets.
      
      - The st21nfcb driver can put its CLF in hibernate mode and save
        significant amount of power.
      
      - A few st21nfcb minor fixes.
      
      - The NXP NCI driver now supports ACPI enumeration.
      
      - The Marvell NCI driver now supports both USB and serial
        physical interfaces.
      
      - The Marvell NCI drivers also supports NCI frames being muxed
        over HCI. This is a setting that can be defined by a DT property.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      023033b1
    • David S. Miller's avatar
      Merge branch 'bond-netlink-3ad-attrs' · cadfaf43
      David S. Miller authored
      Nikolay Aleksandrov says:
      
      ====================
      bonding: extend the 3ad exported attributes
      
      These are two small patches that export actor_oper_port_state and
      partner_oper_port_state via netlink and sysfs, until now they were only
      exported via bond's proc entry. If this set gets accepted I have an iproute2
      patch prepared that will export them with which I tested these changes.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      cadfaf43
    • Nikolay Aleksandrov's avatar
      bonding: export slave's partner_oper_port_state via sysfs and netlink · 46ea297e
      Nikolay Aleksandrov authored
      Export the partner_oper_port_state of each port via sysfs and netlink.
      In 802.3ad mode it is valuable for the user to be able to check the
      partner_oper state, it is already exported via bond's proc entry.
      Signed-off-by: default avatarNikolay Aleksandrov <razor@blackwall.org>
      Signed-off-by: default avatarAndy Gospodarek <gospo@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      46ea297e
    • Nikolay Aleksandrov's avatar
      bonding: export slave's actor_oper_port_state via sysfs and netlink · 254cb6db
      Nikolay Aleksandrov authored
      Export the actor_oper_port_state of each port via sysfs and netlink.
      In 802.3ad mode it is valuable for the user to be able to check the
      actor_oper state, it is already exported via bond's proc entry.
      Signed-off-by: default avatarNikolay Aleksandrov <razor@blackwall.org>
      Signed-off-by: default avatarAndy Gospodarek <gospo@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      254cb6db
    • David S. Miller's avatar
      Merge branch 'rocker-no-wait' · 4d367963
      David S. Miller authored
      Scott Feldman says:
      
      ====================
      rocker: revert back to support for nowait processes
      
      One of the items removed from the rocker driver in the Spring Cleanup patch
      series was the ability to mark processing in the driver as "no wait" for
      those contexts where we cannot sleep.  Turns out, we have "no wait"
      contexts where we want to program the device and we don't want to defer the
      processing to a process context.  So re-add the ROCKER_OP_FLAG_NOWAIT flag
      to mark such processes, and propagate flags to mem allocator and to the
      device cmd executor.  With NOWAIT, mem allocs are GFP_ATOMIC and device
      cmds are queued to the device, but the driver will not wait (sleep) for the
      response back from the device.
      
      My bad for removing NOWAIT support in the first place; I thought we could
      swing non-sleep contexts to process context using a work queue, for
      example, but there is push-back to keep processing in original context.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4d367963
    • Scott Feldman's avatar
      rocker: move port stop to 'no wait' processing · f66feaa9
      Scott Feldman authored
      rocker_port_stop can be called from atomic and non-atomic contexts.  Since
      we can't test what context we're getting called in, do the processing as
      'no wait', which will cover all cases.
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f66feaa9
    • Scott Feldman's avatar
    • Scott Feldman's avatar
      rocker: mark STP update as 'no wait' processing · ac28393e
      Scott Feldman authored
      We can get STP updates from the bridge driver in atomic and non-atomic
      contexts.  Since we can't test what context we're getting called in,
      do the STP processing as 'no wait', which will cover all cases.
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ac28393e
    • Scott Feldman's avatar
      rocker: mark neigh update event processing as 'no wait' · 02a9fbfc
      Scott Feldman authored
      Neigh update event handler runs in a context where we can't sleep, so mark
      processing in driver with ROCKER_OP_FLAG_NOWAIT.  NOWAIT will use
      GFP_ATOMIC for allocations and will queue cmds to the device's cmd ring but
      will not wait (sleep) for cmd response back from device.
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      02a9fbfc
    • Scott Feldman's avatar
      rocker: revert back to support for nowait processes · 179f9a25
      Scott Feldman authored
      One of the items removed from the rocker driver in the Spring Cleanup patch
      series was the ability to mark processing in the driver as "no wait" for
      those contexts where we cannot sleep.  Turns out, we have "no wait"
      contexts where we want to program the device.  So re-add the
      ROCKER_OP_FLAG_NOWAIT flag to mark such processes, and propagate flags to
      mem allocator and to the device cmd executor.  With NOWAIT, mem allocs are
      GFP_ATOMIC and device cmds are queued to the device, but the driver will
      not wait (sleep) for the response back from the device.
      
      My bad for removing NOWAIT support in the first place; I thought we could
      swing non-sleep contexts to process context using a work queue, for
      example, but there is push-back to keep processing in original context.
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      179f9a25
    • Scott Feldman's avatar
      rocker: fix neigh tbl index increment race · 4d81db41
      Scott Feldman authored
      rocker->neigh_tbl_next_index is used to generate unique indices for neigh
      entries programmed into the device.  The way new indices were generated was
      racy with the new prepare-commit transaction model.  A simple fix here
      removes the race.  The race was with two processes getting the same index,
      one process using prepare-commit, the other not:
      
      Proc A					Proc B
      
      PREPARE phase
      get neigh_tbl_next_index
      
      					NONE phase
      					get neigh_tbl_next_index
      					neigh_tbl_next_index++
      
      COMMIT phase
      neigh_tbl_next_index++
      
      Both A and B got the same index.  The fix is to store and increment
      neigh_tbl_next_index in the PREPARE (or NONE) phase and use value in COMMIT
      phase:
      
      Proc A					Proc B
      
      PREPARE phase
      get neigh_tbl_next_index
      neigh_tbl_next_index++
      
      					NONE phase
      					get neigh_tbl_next_index
      					neigh_tbl_next_index++
      
      COMMIT phase
      // use value stashed in PREPARE phase
      Reported-by: default avatarSimon Horman <simon.horman@netronome.com>
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Reviewed-by: default avatarSimon Horman <simon.horman@netronome.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4d81db41
    • Scott Feldman's avatar
      rocker: gaurd against NULL rocker_port when removing ports · a0720310
      Scott Feldman authored
      The ports array is filled in as ports are probed, but if probing doesn't
      finish, we need to stop only those ports that where probed successfully.
      Check the ports array for NULL to skip un-probed ports when stopping.
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Acked-by: default avatarJiri Pirko <jiri@resnulli.us>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a0720310
    • Eric Dumazet's avatar
      net: make u64_stats_init() a function · 9464ca65
      Eric Dumazet authored
      Using a function instead of a macro is cleaner and remove
      following W=1 warnings (extract)
      
      In file included from net/ipv6/ip6_vti.c:29:0:
      net/ipv6/ip6_vti.c: In function ‘vti6_dev_init_gen’:
      include/linux/netdevice.h:2029:18: warning: variable ‘stat’ set but not
      used [-Wunused-but-set-variable]
          typeof(type) *stat;   \
                        ^
      net/ipv6/ip6_vti.c:862:16: note: in expansion of macro
      ‘netdev_alloc_pcpu_stats’
        dev->tstats = netdev_alloc_pcpu_stats(struct pcpu_sw_netstats);
                      ^
        CC [M]  net/ipv6/sit.o
      In file included from net/ipv6/sit.c:30:0:
      net/ipv6/sit.c: In function ‘ipip6_tunnel_init’:
      include/linux/netdevice.h:2029:18: warning: variable ‘stat’ set but not
      used [-Wunused-but-set-variable]
          typeof(type) *stat;   \
                        ^
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      9464ca65
    • Scott Feldman's avatar
      bridge: use either ndo VLAN ops or switchdev VLAN ops to install MASTER vlans · 7f109539
      Scott Feldman authored
      v2:
      
      Move struct switchdev_obj automatics to inner scope where there used.
      
      v1:
      
      To maintain backward compatibility with the existing iproute2 "bridge vlan"
      command, let bridge's setlink/dellink handler call into either the port
      driver's 8021q ndo ops or the port driver's bridge_setlink/dellink ops.
      
      This allows port driver to choose 8021q ops or the newer
      bridge_setlink/dellink ops when implementing VLAN add/del filtering on the
      device.  The iproute "bridge vlan" command does not need to be modified.
      
      To summarize using the "bridge vlan" command examples, we have:
      
      1) bridge vlan add|del vid VID dev DEV
      
      Here iproute2 sets MASTER flag.  Bridge's bridge_setlink/dellink is called.
      Vlan is set on bridge for port.  If port driver implements ndo 8021q ops,
      call those to port driver can install vlan filter on device.  Otherwise, if
      port driver implements bridge_setlink/dellink ops, call those to install
      vlan filter to device.  This option only works if port is bridged.
      
      2) bridge vlan add|del vid VID dev DEV master
      
      Same as 1)
      
      3) bridge vlan add|del vid VID dev DEV self
      
      Bridge's bridge_setlink/dellink isn't called.  Port driver's
      bridge_setlink/dellink is called, if implemented.  This option works if
      port is bridged or not.  If port is not bridged, a VLAN can still be
      added/deleted to device filter using this variant.
      
      4) bridge vlan add|del vid VID dev DEV master self
      
      This is a combination of 1) and 3), but will only work if port is bridged.
      Signed-off-by: default avatarScott Feldman <sfeldma@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7f109539
    • David S. Miller's avatar
      Merge branch 'bpf-share-helpers' · 9f42c8b3
      David S. Miller authored
      Alexei Starovoitov says:
      
      ====================
      v1->v2: switched to init_user_ns from current_user_ns as suggested by Andy
      
      Introduce new helpers to access 'struct task_struct'->pid, tgid, uid, gid, comm
      fields in tracing and networking.
      
      Share bpf_trace_printk() and bpf_get_smp_processor_id() helpers between
      tracing and networking.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      9f42c8b3
    • Alexei Starovoitov's avatar
      ab1973d3