1. 17 5月, 2014 2 次提交
    • B
      net: cdc_ncm: use true max dgram count for header estimates · 70559b89
      Bjørn Mork 提交于
      Many newer NCM and MBIM devices will request a maximum tx
      datagram count which is much smaller than our hard-coded
      absolute max. We can reduce the overhead without sacrificing
      any of the simplicity for these devices, by simply using the
      true negotiated count in when calculated the maximum NTH and
      NDP header sizes.
      Signed-off-by: NBjørn Mork <bjorn@mork.no>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      70559b89
    • B
      net: cdc_ncm: use ethtool to tune coalescing settings · 6c4e548f
      Bjørn Mork 提交于
      Datagram coalescing is an integral part of the NCM and MBIM
      protocols, intended to reduce the interrupt load primarily
      on the device end of the USB link.  As with all coalescing
      solutions, there is a trade-off between buffering and
      interrupts.
      
      The current defaults are based on the assumption that device
      side buffers should be the limiting factor.  However, many
      modern high speed LTE modems suffers from buffer-bloat,
      making this assumption fail. This results in sub-optimal
      performance due to excessive coalescing.  And in cases where
      such modems are connected to cheap embedded hosts there is
      often severe buffer allocation issues, giving very noticeable
      performance degradation .
      
      A start on improving this is going from build time hard
      coded limits to per device user configurable limits.  The
      ethtool coalescing API was selected as user interface
      because, although the tuned values are buffer sizes, these
      settings directly control datagram coalescing.
      Signed-off-by: NBjørn Mork <bjorn@mork.no>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6c4e548f
  2. 14 5月, 2014 1 次提交
    • B
      net: cdc_ncm/cdc_mbim: rework probing of NCM/MBIM functions · 50a0ffaf
      Bjørn Mork 提交于
      The NCM class match in the cdc_mbim driver is confusing and
      cause unexpected behaviour. The USB core guarantees that a
      USB interface is in altsetting 0 when probing starts. This
      means that devices implementing a NCM 1.0 backwards
      compatible MBIM function (a "NCM/MBIM function") always hit
      the NCM entry in the cdc_mbim driver match table. Such
      functions will never match any of the MBIM entries.
      
      This causes unexpeced behaviour for cases where the NCM and
      MBIM entries are differet, which is currently the case for
      all except Ericsson devices.
      
      Improve the probing of NCM/MBIM functions by looking up the
      device again in the cdc_mbim match table after switching to
      the MBIM identity.
      
      The shared altsetting selection is updated to better
      accommodate the new probing logic, returning the preferred
      altsetting for the control interface instead of the data
      interface. The control interface altsetting update is moved
      to the cdc_mbim driver. It is never necessary to change the
      control interface altsetting for NCM.
      
      Cc: Greg Suarez <gsuarez@smithmicro.com>
      Reported by: Yu-an Shih <yshih@nvidia.com>
      Signed-off-by: NBjørn Mork <bjorn@mork.no>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      50a0ffaf
  3. 21 3月, 2014 1 次提交
    • B
      net: cdc_ncm: respect operator preferred MTU reported by MBIM · 259fef03
      Ben Chan 提交于
      According to "Universal Serial Bus Communications Class Subclass
      Specification for Mobile Broadband Interface Model, Revision 1.0,
      Errata-1" published by USB-IF, the wMTU field of the MBIM extended
      functional descriptor indicates the operator preferred MTU for IP data
      streams.
      
      This patch modifies cdc_ncm_setup to ensure that the MTU value set on
      the usbnet device does not exceed the operator preferred MTU indicated
      by wMTU if the MBIM device exposes a MBIM extended functional
      descriptor.
      Signed-off-by: NBen Chan <benchan@chromium.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      259fef03
  4. 19 3月, 2014 1 次提交
  5. 06 11月, 2013 1 次提交
  6. 02 11月, 2013 9 次提交
  7. 17 3月, 2013 1 次提交
  8. 23 10月, 2012 2 次提交
    • G
      net: cdc_mbim: adding MBIM driver · 9bf211a3
      Greg Suarez 提交于
      The CDC Mobile Broadband Interface Model (MBIM) specification
      extends CDC NCM by
       - removing the redundant ethernet header from the point-to-point
         USB channel
       - adding support for multiple IP (v4 and/or v6) sessions multiplexed
         on the same USB channel
       - adding a MBIM control channel encapsulated in CDC
       - adding Device Service Streams (DSS), which are non IP generic data
         streams multiplexed on the same USB channel as the IP sessions
      
      MBIM devices are managed using the dedicated control channel, and no
      data will flow on the data channel until a control session has been
      established.  This driver has no knowledge of MBIM control messages.
      It just exports the control channel to a /dev/cdc-wdmX character
      device for userspace management applications. Such an application is
      therefore required to use this driver.
      
      This patch implements basic MBIM support, reusing the NCM and WDM driver
      APIs, currently limited to IP sessions with SessionID 0. DSS and
      multiplexed IP sessions are not yet supported.
      Signed-off-by: NGreg Suarez <gsuarez@smithmicro.com>
      Signed-off-by: NBjørn Mork <bjorn@mork.no>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9bf211a3
    • B
      net: cdc_ncm: export shared symbols and definitions · c91ce3b6
      Bjørn Mork 提交于
      Move symbols and definitons which can be shared with a
      MBIM driver in a new header.
      Signed-off-by: NBjørn Mork <bjorn@mork.no>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c91ce3b6