1. 23 Mar, 2021 3 commits
    • Xie He's avatar
      net: lapb: Make "lapb_t1timer_running" able to detect an already running timer · 65d2dbb3
      Xie He authored
      Problem:
      
      The "lapb_t1timer_running" function in "lapb_timer.c" is used in only
      one place: in the "lapb_kick" function in "lapb_out.c". "lapb_kick" calls
      "lapb_t1timer_running" to check if the timer is already pending, and if
      it is not, schedule it to run.
      
      However, if the timer has already fired and is running, and is waiting to
      get the "lapb->lock" lock, "lapb_t1timer_running" will not detect this,
      and "lapb_kick" will then schedule a new timer. The old timer will then
      abort when it sees a new timer pending.
      
      I think this is not right. The purpose of "lapb_kick" should be ensuring
      that the actual work of the timer function is scheduled to be done.
      If the timer function is already running but waiting for the lock,
      "lapb_kick" should not abort and reschedule it.
      
      Changes made:
      
      I added a new field "t1timer_running" in "struct lapb_cb" for
      "lapb_t1timer_running" to use. "t1timer_running" will accurately reflect
      whether the actual work of the timer is pending. If the timer has fired
      but is still waiting for the lock, "t1timer_running" will still correctly
      reflect whether the actual work is waiting to be done.
      
      The old "t1timer_stop" field, whose only responsibility is to ask a timer
      (that is already running but waiting for the lock) to abort, is no longer
      needed, because the new "t1timer_running" field can fully take over its
      responsibility. Therefore "t1timer_stop" is deleted.
      
      "t1timer_running" is not simply a negation of the old "t1timer_stop".
      At the end of the timer function, if it does not reschedule itself,
      "t1timer_running" is set to false to indicate that the timer is stopped.
      
      For consistency of the code, I also added "t2timer_running" and deleted
      "t2timer_stop".
      Signed-off-by: default avatarXie He <xie.he.0141@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      65d2dbb3
    • Kurt Kanzenbach's avatar
      net: dsa: hellcreek: Report switch name and ID · 1ab568e9
      Kurt Kanzenbach authored
      Report the driver name, ASIC ID and the switch name via devlink. This is a
      useful information for user space tooling.
      Signed-off-by: default avatarKurt Kanzenbach <kurt@kmk-computers.de>
      Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
      Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
      Reviewed-by: default avatarVladimir Oltean <olteanv@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1ab568e9
    • David S. Miller's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next · 9a255a06
      David S. Miller authored
      Pablo Neira Ayuso says:
      
      ====================
      Netfilter updates for net-next
      
      The following batch contains Netfilter updates for net-next:
      
      1) Split flowtable workqueues per events, from Oz Shlomo.
      
      2) fall-through warnings for clang, from Gustavo A. R. Silva
      
      3) Remove unused declaration in conntrack, from YueHaibing.
      
      4) Consolidate skb_try_make_writable() in flowtable datapath,
         simplify some of the existing codebase.
      
      5) Call dst_check() to fall back to static classic forwarding path.
      
      6) Update table flags from commit phase.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      9a255a06
  2. 22 Mar, 2021 37 commits