<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Hi Nikolaus,</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">On Monday, 24 November 2025 16:35:28 CET H. Nikolaus Schaller wrote:</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">...</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> > Sorry, I don't quite understand your remark. To integrate this voltage</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> > regulator component into the Linux regulator abstraction, I'm providing a</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> > current limit control function. To provide such a function, the voltage</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> > level on a pin has to be controlled. AFAIK, the kernel abstraction used</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> > to set precise voltages on lines is an IO channel.</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> I was curious to learn about this topic and looked into the data sheet:</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> https://www.analog.com/media/en/technical-documentation/data-sheets/8054fa.p</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> df</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> As far as I see the LTM8054 does not even have a programming interface.</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> So is it reasonable to provide a dedicated driver at all?</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> The figure on page 20 seems to suggest that there is an external DAC</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> which drives the regulator. And the regulator drives for example a fan.</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> So I would think of a driver for the specific DAC and ignore the specific</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> LTM chip at all.</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">In my use case, the LTM8054 feeds a DC output port on which various devices </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">may be plugged. Dynamic output current limitation and output voltage level </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">control for these devices is a requirement, as well as stepped voltage </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">transitions, thus the need for a proper regulator device.</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">The LTM8054's feedback pin can be driven by a different DAC, which allows for </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">dynamic output voltage control. This is a more complex upstreaming topic </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">however, so I've left it out of this initial series. There are other component </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">functions which fit in squarely into the regulator framework, such as </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">input current limit control and soft-start. But I understand that the current </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">driver might look a bit "bare".</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> What could be necessary is if you really want to be able to "regulate"</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> the current going to Vout, some bridge between regulator API and some</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> IIO DAC.</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> And enabling/disabling the regulator by some GPIO can be described in</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> the DT already through a "regulator-fixed".</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">> </p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">This is a possibility, but when you bring in all of these other hardware </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">functions that I mentionned e.g. output voltage control and stepping, you'll </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">end up with several different devices which look unrelated from userspace, but </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">actually control the same chip.</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Userspace will also have to know about some hardware details to properly </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">control the DACs, such as the values of the sense and feedback resistors. In </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">my opinion, this bypasses the kernel's abstraction of hardware.</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Thanks,</p>
<br /><p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">-- </p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Romain Gantois, Bootlin</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">Embedded Linux and Kernel engineering</p>
<p style="margin-top:0;margin-bottom:0;margin-left:0;margin-right:0;">https://bootlin.com</p>
<br /></body>
</html>