Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 30 Jan 2023 21:52:40 -1000
From:      "parv/FreeBSD" <parv.0zero9+freebsd@gmail.com>
To:        freebsd-current@freebsd.org
Subject:   Could not change brightness anymore with i915kms & acpi_video modules c 202211
Message-ID:  <CABObuOoUDHrUF6FyTwEXTrnt3ztkoAR4x5vzjcNp7H-4F4XE7A@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
--000000000000521dde05f38aa1de
Content-Type: text/plain; charset="UTF-8"

Hi there,

Since around 2022-11, I am unable to change display brightness
of the display of a Framework laptop (Intel i5-1135G7, Iris
Xe iGPU) with "i915kms" module (from "drm-510-kmod" package/port)
& "acpi_video" (FreeBSD) kernel module.

Earlier I was able to change brightness via "hw.acpi.video" MIB ...

# - Need to have both "i915kms" & "acpi_video" modules already loaded.
#
# 20221120 - These MIBs do not work anymore as they are missing.
hw.acpi.video.lcd0.economy=10
hw.acpi.video.lcd0.fullpower=40
hw.acpi.video.lcd0.brightness=15


... now the whole of "hw.acpi.video" stub is missing. Nothing has
changed in terms of how/when "i915kms" & "acpi_video" are loaded (via
"kld_list" variable via "/etc/rc.conf" in that order).

What am I missing?


- parv


## /etc/rc.conf :
clear_tmp_enable="YES"
sendmail_enable="NONE"
sshd_enable="YES"
zfs_enable="YES"
dumpdev="AUTO"

hostname="luna"

devmatch_blacklist="ng_ubt"
devmatch_blacklist="$devmatch_blacklist if_iwlwifi"

moused_enable="YES"

kld_list="filemon"

# As of 20220316 on 14-CURRENT order of values assigned to a variable
matters
# enough that assigning "acpi_video" after "i915kms" is sufficient.
#
# WARNING - After loading 'acpi_video' module, brightness suddenly increases
# blindingly.
#
# XXX: If i915kms does not load properly on boot, say after world install,
will
#      see a blank screen & Ctrl-Alt-{Delete,Backspace,Escape} do not seem
to
#      work; need a hard reboot.
#
# 20230120 - Since around 2022-11 or 2022-12, order has no effect on
brightness.
kld_list="$kld_list i915kms"
kld_list="$kld_list acpi_video"

# Attemp to maximize battery life.
power_profile='economy'
economy_cx_lowest='Cmax'
performance_cx_lowest='C2'

wifibox_enable="YES"
defaultrouter="10.0.0.1"
defaultroot_delay="10"
ifconfig_wifibox0="SYNCDHCP"
background_dhclient_wifibox0="YES"

ntpd_enable="YES"
ntpd_flags="-G"
dbus_enable="YES"
smartd_enable="YES"

## /etc/sysctl.conf :
kern.randompid=1
vfs.usermount=1

kern.vt.kbd_halt=1
kern.vt.kbd_poweroff=1
kern.vt.kbd_reboot=1
kern.vt.kbd_debug=1
kern.vt.kbd_panic=1

vfs.zfs.arc.max=30064771072

dev.hwpstate_intel.0.epp=70
dev.hwpstate_intel.1.epp=70
dev.hwpstate_intel.2.epp=100
dev.hwpstate_intel.3.epp=100
dev.hwpstate_intel.4.epp=100
dev.hwpstate_intel.5.epp=100
dev.hwpstate_intel.6.epp=100
dev.hwpstate_intel.7.epp=100

kern.timecounter.hardware='HPET'

hw.acpi.lid_switch_state='S5'
hw.acpi.sleep_button_state='S5'

# 'acpi_video' module needs to be loaded after 'i915kms' module to have LCD
# brightness related MIBs -- hw.acpi.lcd0.* -- to have any effect. This has
# been an issue since 2014, see PR 195116,
# <https://bugs.freebsd.org/bugzilla/show_bug_cgi?id=195116>.
#
# As of 20220316 on 14-CURRENT order of values assigned to a variable
matters
# enough that assigning "acpi_video" after "i915kms" to "$kld_list" in
# "/etc/rc.conf" is sufficient.
#
# WARNING - After loading 'acpi_video' module, brightness suddenly increases
# blindinly.
#
# Default of 50 for 'hw.acpi.video.lcd0.brightness' rather too bright; 100
is
# blinding.
# - Need to have both "i915kms" & "acpi_video" modules already loaded.
#
# 20221120 - These MIBs do not work anymore as they are missing.
#hw.acpi.video.lcd0.economy=10
#hw.acpi.video.lcd0.fullpower=40
#hw.acpi.video.lcd0.brightness=15

# Power management with "i915kms" module from "drm-devel-kmod" (14-CURRENT)
# package.
# - only in "/boot/loader.conf" ...
#
#     compat.linuxkpi.i915_enable_dc=2
#     compat.linuxkpi.i915_disable_power_well=<-1|0|1>
#
#  ... that means need to load i915kms in "/boot/loader.conf" too.?
#
compat.linuxkpi.i915_fastboot=1
compat.linuxkpi.i915_enable_fbc=1

## /boot/loader.conf :
cryptodev_load="YES"
zfs_load="YES"

kern.msgbufsize=1146880

ums_load="YES"
hms_load="YES"

hw.vga.textmode=0
kern.vty=vt

# Need to load after i915kms module to have effect; so is loaded via
# /etc/rc.conf instead by adding it to $kld_list after "i915kms" as in
# 'kld_list="i915kms acpi_video"'.
#acpi_video_load="YES"

machdep.hwpstate_pkg_ctrl=0
coretemp_load="YES"

## From "/etc/rc.conf" ...
# Power management with "i915kms" module from "drm-devel-kmod" (14-CURRENT)
# package.
# - only in "/boot/loader.conf" ...
#
#     compat.linuxkpi.i915_enable_dc=2
#     compat.linuxkpi.i915_disable_power_well=<-1|0|1>
#
#  ... that means need to load i915kms in "/boot/loader.conf" too.?
#
#compat.linuxkpi.i915_fastboot=1
#compat.linuxkpi.i915_enable_fbc=1

hw.pci.do_power_nodriver=2

--000000000000521dde05f38aa1de
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_default" style=3D"font-family:monospac=
e">Hi there,</div><div class=3D"gmail_default" style=3D"font-family:monospa=
ce"><br></div><div class=3D"gmail_default" style=3D"font-family:monospace">=
Since around 2022-11, I am unable to change display brightness</div><div cl=
ass=3D"gmail_default" style=3D"font-family:monospace">of the display of a F=
ramework laptop (Intel i5-1135G7, Iris</div><div class=3D"gmail_default" st=
yle=3D"font-family:monospace">Xe iGPU) with &quot;i915kms&quot; module (fro=
m &quot;drm-510-kmod&quot; package/port)</div><div class=3D"gmail_default" =
style=3D"font-family:monospace">&amp; &quot;acpi_video&quot; (FreeBSD) kern=
el module.</div><div class=3D"gmail_default" style=3D"font-family:monospace=
"><br></div><div class=3D"gmail_default" style=3D"font-family:monospace">Ea=
rlier I was able to change brightness via &quot;hw.acpi.video&quot; MIB ...=
</div><div class=3D"gmail_default" style=3D"font-family:monospace"><br></di=
v><div class=3D"gmail_default" style=3D"font-family:monospace"># - Need to =
have both &quot;i915kms&quot; &amp; &quot;acpi_video&quot; modules already =
loaded.<br>#<br># 20221120 - These MIBs do not work anymore as they are mis=
sing.<br>hw.acpi.video.lcd0.economy=3D10<br>hw.acpi.video.lcd0.fullpower=3D=
40<br>hw.acpi.video.lcd0.brightness=3D15</div><div class=3D"gmail_default" =
style=3D"font-family:monospace"><br></div><div class=3D"gmail_default" styl=
e=3D"font-family:monospace"><br></div><div class=3D"gmail_default" style=3D=
"font-family:monospace">... now the whole of &quot;hw.acpi.video&quot; stub=
 is missing. Nothing has</div><div class=3D"gmail_default" style=3D"font-fa=
mily:monospace">changed in terms of how/when &quot;i915kms&quot; &amp; &quo=
t;acpi_video&quot; are loaded (via</div><div class=3D"gmail_default" style=
=3D"font-family:monospace">&quot;kld_list&quot; variable via &quot;/etc/rc.=
conf&quot; in that order).<br></div><br><div class=3D"gmail_default" style=
=3D"font-family:monospace">What am I missing?</div><div class=3D"gmail_defa=
ult" style=3D"font-family:monospace"><br></div><div class=3D"gmail_default"=
 style=3D"font-family:monospace"><br></div><div class=3D"gmail_default" sty=
le=3D"font-family:monospace">- parv</div><div class=3D"gmail_default" style=
=3D"font-family:monospace"><br></div><div class=3D"gmail_default" style=3D"=
font-family:monospace"><br></div><div class=3D"gmail_default" style=3D"font=
-family:monospace">## /etc/rc.conf :<br></div><div class=3D"gmail_default" =
style=3D"font-family:monospace">clear_tmp_enable=3D&quot;YES&quot;<br>sendm=
ail_enable=3D&quot;NONE&quot;<br>sshd_enable=3D&quot;YES&quot;<br>zfs_enabl=
e=3D&quot;YES&quot;<br>dumpdev=3D&quot;AUTO&quot;<br><br>hostname=3D&quot;l=
una&quot;<br><br>devmatch_blacklist=3D&quot;ng_ubt&quot;<br>devmatch_blackl=
ist=3D&quot;$devmatch_blacklist if_iwlwifi&quot;<br><br>moused_enable=3D&qu=
ot;YES&quot;<br><br>kld_list=3D&quot;filemon&quot;<br><br># As of 20220316 =
on 14-CURRENT order of values assigned to a variable matters<br># enough th=
at assigning &quot;acpi_video&quot; after &quot;i915kms&quot; is sufficient=
.<br>#<br># WARNING - After loading &#39;acpi_video&#39; module, brightness=
 suddenly increases<br># blindingly.<br>#<br># XXX: If i915kms does not loa=
d properly on boot, say after world install, will<br># =C2=A0 =C2=A0 =C2=A0=
see a blank screen &amp; Ctrl-Alt-{Delete,Backspace,Escape} do not seem to<=
br># =C2=A0 =C2=A0 =C2=A0work; need a hard reboot.<br>#<br># 20230120 - Sin=
ce around 2022-11 or 2022-12, order has no effect on brightness.<br>kld_lis=
t=3D&quot;$kld_list i915kms&quot;<br>kld_list=3D&quot;$kld_list acpi_video&=
quot;<br><br># Attemp to maximize battery life.<br>power_profile=3D&#39;eco=
nomy&#39;<br>economy_cx_lowest=3D&#39;Cmax&#39;<br>performance_cx_lowest=3D=
&#39;C2&#39;<br><br>wifibox_enable=3D&quot;YES&quot;<br>defaultrouter=3D&qu=
ot;10.0.0.1&quot;<br>defaultroot_delay=3D&quot;10&quot;<br>ifconfig_wifibox=
0=3D&quot;SYNCDHCP&quot;<br>background_dhclient_wifibox0=3D&quot;YES&quot;<=
br><br>ntpd_enable=3D&quot;YES&quot;</div><div class=3D"gmail_default" styl=
e=3D"font-family:monospace">ntpd_flags=3D&quot;-G&quot;<br>dbus_enable=3D&q=
uot;YES&quot;<br>smartd_enable=3D&quot;YES&quot;</div><div class=3D"gmail_d=
efault" style=3D"font-family:monospace"><br></div><div class=3D"gmail_defau=
lt" style=3D"font-family:monospace">## /etc/sysctl.conf :</div><div class=
=3D"gmail_default" style=3D"font-family:monospace">kern.randompid=3D1<br>vf=
s.usermount=3D1<br><br>kern.vt.kbd_halt=3D1<br>kern.vt.kbd_poweroff=3D1<br>=
kern.vt.kbd_reboot=3D1<br>kern.vt.kbd_debug=3D1<br>kern.vt.kbd_panic=3D1<br=
><br>vfs.zfs.arc.max=3D30064771072<br><br>dev.hwpstate_intel.0.epp=3D70<br>=
dev.hwpstate_intel.1.epp=3D70<br>dev.hwpstate_intel.2.epp=3D100<br>dev.hwps=
tate_intel.3.epp=3D100<br>dev.hwpstate_intel.4.epp=3D100<br>dev.hwpstate_in=
tel.5.epp=3D100<br>dev.hwpstate_intel.6.epp=3D100<br>dev.hwpstate_intel.7.e=
pp=3D100<br><br>kern.timecounter.hardware=3D&#39;HPET&#39;<br><br>hw.acpi.l=
id_switch_state=3D&#39;S5&#39;<br>hw.acpi.sleep_button_state=3D&#39;S5&#39;=
<br><br># &#39;acpi_video&#39; module needs to be loaded after &#39;i915kms=
&#39; module to have LCD<br># brightness related MIBs -- hw.acpi.lcd0.* -- =
to have any effect. This has<br># been an issue since 2014, see PR 195116,<=
br># &lt;<a href=3D"https://bugs.freebsd.org/bugzilla/show_bug_cgi?id=3D195=
116">https://bugs.freebsd.org/bugzilla/show_bug_cgi?id=3D195116</a>&gt;.<br=
>#<br># As of 20220316 on 14-CURRENT order of values assigned to a variable=
 matters<br># enough that assigning &quot;acpi_video&quot; after &quot;i915=
kms&quot; to &quot;$kld_list&quot; in<br># &quot;/etc/rc.conf&quot; is suff=
icient.<br>#<br># WARNING - After loading &#39;acpi_video&#39; module, brig=
htness suddenly increases<br># blindinly.<br>#<br># Default of 50 for &#39;=
hw.acpi.video.lcd0.brightness&#39; rather too bright; 100 is<br># blinding.=
<br># - Need to have both &quot;i915kms&quot; &amp; &quot;acpi_video&quot; =
modules already loaded.<br>#<br># 20221120 - These MIBs do not work anymore=
 as they are missing.<br>#hw.acpi.video.lcd0.economy=3D10<br>#hw.acpi.video=
.lcd0.fullpower=3D40<br>#hw.acpi.video.lcd0.brightness=3D15</div><div class=
=3D"gmail_default" style=3D"font-family:monospace"><br></div><div class=3D"=
gmail_default" style=3D"font-family:monospace"># Power management with &quo=
t;i915kms&quot; module from &quot;drm-devel-kmod&quot; (14-CURRENT)<br># pa=
ckage.<br># - only in &quot;/boot/loader.conf&quot; ...<br>#<br># =C2=A0 =
=C2=A0 compat.linuxkpi.i915_enable_dc=3D2<br># =C2=A0 =C2=A0 compat.linuxkp=
i.i915_disable_power_well=3D&lt;-1|0|1&gt;<br>#<br># =C2=A0... that means n=
eed to load i915kms in &quot;/boot/loader.conf&quot; too.?<br>#<br>compat.l=
inuxkpi.i915_fastboot=3D1<br>compat.linuxkpi.i915_enable_fbc=3D1</div><div =
class=3D"gmail_default" style=3D"font-family:monospace"><br></div><div clas=
s=3D"gmail_default" style=3D"font-family:monospace">## /boot/loader.conf :<=
/div><div class=3D"gmail_default" style=3D"font-family:monospace">cryptodev=
_load=3D&quot;YES&quot;<br>zfs_load=3D&quot;YES&quot;<br><br>kern.msgbufsiz=
e=3D1146880<br><br>ums_load=3D&quot;YES&quot;<br>hms_load=3D&quot;YES&quot;=
<br><br>hw.vga.textmode=3D0<br>kern.vty=3Dvt<br><br># Need to load after i9=
15kms module to have effect; so is loaded via<br># /etc/rc.conf instead by =
adding it to $kld_list after &quot;i915kms&quot; as in<br># &#39;kld_list=
=3D&quot;i915kms acpi_video&quot;&#39;.<br>#acpi_video_load=3D&quot;YES&quo=
t;<br><br>machdep.hwpstate_pkg_ctrl=3D0<br>coretemp_load=3D&quot;YES&quot;<=
br><br>## From &quot;/etc/rc.conf&quot; ...<br># Power management with &quo=
t;i915kms&quot; module from &quot;drm-devel-kmod&quot; (14-CURRENT)<br># pa=
ckage.<br># - only in &quot;/boot/loader.conf&quot; ...<br>#<br># =C2=A0 =
=C2=A0 compat.linuxkpi.i915_enable_dc=3D2<br># =C2=A0 =C2=A0 compat.linuxkp=
i.i915_disable_power_well=3D&lt;-1|0|1&gt;<br>#<br># =C2=A0... that means n=
eed to load i915kms in &quot;/boot/loader.conf&quot; too.?<br>#<br>#compat.=
linuxkpi.i915_fastboot=3D1<br>#compat.linuxkpi.i915_enable_fbc=3D1<br><br>h=
w.pci.do_power_nodriver=3D2</div><div class=3D"gmail_default" style=3D"font=
-family:monospace"><br></div></div>

--000000000000521dde05f38aa1de--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CABObuOoUDHrUF6FyTwEXTrnt3ztkoAR4x5vzjcNp7H-4F4XE7A>