1. 30 8月, 2008 36 次提交
  2. 27 8月, 2008 4 次提交
    • D
    • G
      dccp ccid-3: Replace lazy BUG_ON with condition · eff253c4
      Gerrit Renker 提交于
      The BUG_ON(w_tot == 0) only holds if there is no more than 1 loss interval in
      the loss history. If there is only a single loss interval, the calc_i_mean()
      routine need in fact not be called (RFC 3448, 6.3.1). 
      Signed-off-by: NGerrit Renker <gerrit@erg.abdn.ac.uk>
      eff253c4
    • G
      dccp: Toggle debug output without module unloading · 157439fa
      Gerrit Renker 提交于
      This sets the sysfs permissions so that root can toggle the `debug'
      parameter available for nearly every DCCP module. This is useful 
      since there are various module inter-dependencies. The debug flag
      can now be toggled at runtime using
      
        echo 1 > /sys/module/dccp/parameters/dccp_debug
        echo 1 > /sys/module/dccp_ccid2/parameters/ccid2_debug
        echo 1 > /sys/module/dccp_ccid3/parameters/ccid3_debug
        echo 1 > /sys/module/dccp_tfrc_lib/parameters/tfrc_debug
      
      The last is not very useful yet, since no code at the moment calls
      the tfrc_debug() macro.
      Signed-off-by: NGerrit Renker <gerrit@erg.abdn.ac.uk>
      157439fa
    • G
      dccp: Empty the write queue when disconnecting · b569d5a1
      Gerrit Renker 提交于
      dccp_disconnect() can be called due to several reasons:
      
       1. when the connection setup failed (inet_stream_connect());
       2. when shutting down (inet_shutdown(), inet_csk_listen_stop());
       3. when aborting the connection (dccp_close() with 0 linger time).
      
      In case (1) the write queue is empty. This patch empties the write queue,
      if in case (2) or (3) it was not yet empty.
      
      This avoids triggering the write-queue BUG_TRAP in sk_stream_kill_queues()
      later on.
      
      It also seems natural to do: when breaking an association, to delete all
      packets that were originally intended for the soon-disconnected end (compare
      with call to tcp_write_queue_purge in tcp_disconnect()).
      Signed-off-by: NGerrit Renker <gerrit@erg.abdn.ac.uk>
      b569d5a1