[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: building both monolithic command line program and shared library from single source package, ddcutil



On Sun, 2020-01-26 at 23:01 -0500, Sanford Rockowitz wrote:

> I'm unaware of plans to support DDC in the Linux kernel.

I just discovered the ddcci-driver-linux project. It is available in
Debian in the ddcci-dkms binary package. I've tried it locally but it
doesn't appear to be very useful for me yet.

https://gitlab.com/ddcci-driver-linux/ddcci-driver-linux

> a Qt based C++ GUI, ddcui

I note that this isn't available in Debian yet, I am assuming that is
why you have brought this discussion to the list.

> On the other hand, there are things that ddcutil does to accommodate
> variations in monitor DDC/CI implementations that probably don't
> belong in the kernel.

I think the Linux kernel already deals with quirks for various types of
hardware, so I don't think it would be too much trouble to maintain the
code for the DDC quirk types in the Linux kernel and the application of
those quirks in udev. I think that this is typically how hardware
quirks are applied on Linux based distributions.

> Finally, unifying brightness control means alternatively using ACPI for 
> laptop displays and DDC for others. It seems to me that even if the 
> kernel supported DDC, this ACPI/DDC unification is more appropriately 
> done at a higher level than the kernel, probably in xrandr.  For the 
> time being, an application can unify these facilities using libddcutil 
> for DDC.

The Linux kernel already exposes LED information and control, display
brightness and control and so on in standard ways, which are then
consumed by userland tools, either directly or via daemons. So I think
it isn't too much of a stretch for those to be available for DDC too.
xrandr isn't used by Wayland based shells so that isn't the appropriate
layer to introduce this feature. Keeping the DDC code out of the Linux
kernel means that every single desktop has to add support for
libddcutil instead of just adding it to Linux. Since Wayland shells run
as the user rather than root, Wayland apps are not allowed to be run as
root and accessing i2c devices on Linux typically requires root,
control of monitor brightness via DDC won't be available for Wayland
shells/apps, only via terminal or X11 applications run via sudo.

> (The KDE-Neon folks currently use a private copy of libddcutil 
> for this purpose.)

Any particular reason they can't use the official version?

PS: are you aware of the ddccontrol project (also in Debian)?
It has a monitor database, shared library, command-line tools and GUI.

https://github.com/ddccontrol/ddccontrol
https://github.com/ddccontrol/ddccontrol-db

It would be great if yourself and the folks from ddcci-driver-linux and
ddccontrol could work together in order to come up with a modern design
and implementation for supporting control of monitors under Linux.

-- 
bye,
pabs

https://wiki.debian.org/PaulWise

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: