From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Lunn Subject: Re: [PATCH net 0/2] aqc111: Thermal throttling feature Date: Wed, 12 Dec 2018 21:38:46 +0100 Message-ID: <20181212203846.GD14328@lunn.ch> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Florian Fainelli , "davem@davemloft.net" , "netdev@vger.kernel.org" , Dmitry Bezrukov To: Igor Russkikh Return-path: Received: from vps0.lunn.ch ([185.16.172.187]:45016 "EHLO vps0.lunn.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726297AbeLLUiv (ORCPT ); Wed, 12 Dec 2018 15:38:51 -0500 Content-Disposition: inline In-Reply-To: Sender: netdev-owner@vger.kernel.org List-ID: > A whole separate concern is how much userspace should be involved here. > It could be a very device specific (and therefore driver specific) logic > on how to do device's thermal control. Hi Igor Well, if you fully expose the PHY to Linux using a PHY driver, it would not be device specific at all. The PHY layer knows how to ask the PHY to drop to lower speeds. The Marvell PHYs with their temperature sensors could also use this core code. You are running into trouble because you want to both to hide the PHY from Linux, but also have Linux control the PHY to avoid it melting. This is why i actually think you should be doing this in firmware. Andrew