Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1630498

Re: Network cooling device and how to control NIC speed on thermal condition

From Andrew Lunn <andrew@lunn.ch>
Newsgroups linux.kernel
Subject Re: Network cooling device and how to control NIC speed on thermal condition
Date 2017-04-25 15:20 +0200
Message-ID <tA8xQ-5bb-29@gated-at.bofh.it> (permalink)
References <tA4aS-2hp-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tue, Apr 25, 2017 at 10:36:28AM +0200, Waldemar Rymarkiewicz wrote:
> Hi,
> 
> I am not much aware of linux networking architecture so I'd like to
> ask first before will start to dig into the code. Appreciate any
> feedback.
> 
> I am looking on Linux thermal framework and on how to cool down the
> system effectively when it hits thermal condition. Already existing
> cooling methods cpu_cooling and clock_cooling are good. However, I
> wanted to go further and dynamically control also a switch ports'
> speed based on thermal condition. Lowering speed means less power,
> less power means lower temp.
> 
> Is there any in-kernel interface to configure switch port/NIC from other driver?

Hi Waldemar

Linux models switch ports as network interfaces, so mostly, there is
little difference between a NIC and a switch port. What you define for
one, should work for the other. Mostly.

However, i don't think you need to be too worried about the NIC level
of the stack. You can mostly do this higher up in the stack. I would
expect there is a relationship between Packets per Second and
generated heat. You might want the NIC to give you some sort of
heating coefficient, 1PPS is ~ 10uC. Given that, you want to throttle
the PPS in the generic queuing layers. This sounds like a TC filter.
You have userspace install a TC filter, which is a net_cooling device.

This however does not directly work for so called 'fastpath' traffic
in switches. Frames which ingress one switch port and egress another
switch port are mostly never seen by Linux. So a software TC filter
will not affect them. However, there is infrastructure in place to
accelerate TC filters by pushing them down into the hardware. So the
same basic concept can be used for switch fastpath traffic, but
requires a bit more work.

    Andrew

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Network cooling device and how to control NIC speed on thermal condition Waldemar Rymarkiewicz <waldemar.rymarkiewicz@gmail.com> - 2017-04-25 10:40 +0200
  Re: Network cooling device and how to control NIC speed on thermal  condition Andrew Lunn <andrew@lunn.ch> - 2017-04-25 15:20 +0200
  Re: Network cooling device and how to control NIC speed on thermal  condition Alan Cox <gnomes@lxorguk.ukuu.org.uk> - 2017-04-25 15:50 +0200
    Re: Network cooling device and how to control NIC speed on thermal condition Waldemar Rymarkiewicz <waldemar.rymarkiewicz@gmail.com> - 2017-04-28 10:10 +0200
      Re: Network cooling device and how to control NIC speed on thermal  condition Andrew Lunn <andrew@lunn.ch> - 2017-04-28 14:00 +0200
        Re: Network cooling device and how to control NIC speed on thermal condition Waldemar Rymarkiewicz <waldemar.rymarkiewicz@gmail.com> - 2017-05-08 10:20 +0200
          Re: Network cooling device and how to control NIC speed on thermal  condition Andrew Lunn <andrew@lunn.ch> - 2017-05-08 16:10 +0200
  Re: Network cooling device and how to control NIC speed on thermal  condition Florian Fainelli <f.fainelli@gmail.com> - 2017-04-25 18:30 +0200

csiph-web