Re: [PATCH] hwmon: (oxp-sensors) Add tt_toggle attribute on supported boards

From: Guenter Roeck
Date: Wed Jun 07 2023 - 13:33:47 EST


On 6/7/23 05:40, Joaquin Aramendia wrote:
Hello again. And sorry for my late reply. I'm struggling to find a
good solution to this functionality. It most definitely feels icky to
be attached to the hwmon driver so it should be a different driver for
those devices. Would misc be a good place for that single toggle? or
maybe platform? The latter seems most fitting since is very device
specific.

You are attaching the attribute to the hwmon device. Moving the driver
to another directory would just be an attempt to avoid review by a
hwmon maintainer. Just for that reason I would NACK such an attempt.

By no means I intend to avoid review. Don't get me wrong. I'm trying
to understand what the best practice would be in this scenario. The
driver is part reverse engineering and part asking contacts from the
manufacturer (who is no longer in the company so it is reverse
engineering at this point). So any new functionality we find might be
a different driver for what i gather since it is not related to
hardware monitoring. The oxp-sensors as is now it is mostly done and
it works well for the users.


Why don't you just attach the attribute to the platform device as I
had suggested earlier ?

Guenter