]> git.baikalelectronics.ru Git - kernel.git/commit
net: cdc_ncm: allow tuning min_tx_pkt
authorBjørn Mork <bjorn@mork.no>
Fri, 30 May 2014 07:31:09 +0000 (09:31 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 2 Jun 2014 23:01:31 +0000 (16:01 -0700)
commit1c074c1f6c77724e8661f26a628e51f719de3487
treed1f73e2464988933d01bcd3b2c703104eda192c0
parentb30f639e2344bbb9829865bc4b087e7a3c9e6cdc
net: cdc_ncm: allow tuning min_tx_pkt

The min_tx_pkt variable decides the cutoff point where the driver
will stop padding out NTBs to maximum size. The padding is a tradeoff
where we use some USB bus bandwidth to allow the device to receive
fixed size buffers. Different devices will have different optimal
settings, spanning from no padding at all to padding every NTB.
There is no way to automatically figure out which setting is best
for a specific device.

The default value is a reasonable tradeoff, calculated based on the
USB packet size and out NTB max size. This may have to be changed
along with any tx_max changes.

Signed-off-by: Bjørn Mork <bjorn@mork.no>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/cdc_ncm.c