Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 1 Feb 2013 17:49:01 -0800
From:      Kevin Oberman <kob6558@gmail.com>
To:        Andrey Fesenko <f0andrey@gmail.com>
Cc:        matt <sendtomatt@gmail.com>, freebsd-mobile@freebsd.org, Hannes Mehnert <hannes@mehnert.org>, freebsd-current@freebsd.org, Ganael LAPLANCHE <ganael.laplanche@martymac.org>, Vrachnis Ilias-Dimitrios <vrachil@gmail.com>
Subject:   Re: x220 notes
Message-ID:  <CAN6yY1vpzVsz7kALg7N06Shq77nbfnDy1LQJUVBjq-Eay_8d9g@mail.gmail.com>
In-Reply-To: <CA%2BK5SrMRAZtFEo=zy_EQz8GNerQe8LxV_1sBVkFcx5moo5U92Q@mail.gmail.com>
References:  <4E836C06.9070405@gmail.com> <CAGH67wS1YR6V-DPAGtYN4RfrHSbgCrN=Ey2ngTVe6yBiBO1SZw@mail.gmail.com> <4E8374A7.90105@gmail.com> <CAGH67wT8ReUnDGXdxxOwd7x7CmRP7sDAzyFbSKrwT79tM=nZ5A@mail.gmail.com> <CAN6yY1vqNJhtxE2SVqawWxW6Jo-6M7SHwiL-Xo%2BhH-8_d8BHnQ@mail.gmail.com> <4E9BDF13.4040006@gmail.com> <4F38211D.4070305@mehnert.org> <4F40A2D4.6000000@gmail.com> <CAHi1Jsf%2BGVN6YNH_GcsECKdcDLsMQz9yQP-WNEKU8rC%2B%2B%2Biz_Q@mail.gmail.com> <4F57A8FC.8090106@gmail.com> <20120308092234.M18590@martymac.org> <4F5AC96A.3050600@gmail.com> <CAN6yY1vb7G=DOeqUoREgO8hEtmRhpJznoci5ZoHbae4qP9xQKA@mail.gmail.com> <4F5FE9C1.7010901@gmail.com> <4F6020C0.60405@gmail.com> <4F6126A2.7050301@mehnert.org> <CA%2BK5SrMRAZtFEo=zy_EQz8GNerQe8LxV_1sBVkFcx5moo5U92Q@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Jan 29, 2013 at 1:49 PM, Andrey Fesenko <f0andrey@gmail.com> wrote:
> On Wed, Mar 14, 2012 at 11:15 PM, Hannes Mehnert <hannes@mehnert.org> wrote:
>> Ciao,
>>
>> On 03/14/2012 00:38, matt wrote:
>>> I have brightness control through raw acpi..."\_BCL" and friends seem to
>>> do nothing.
>>>
>>> Most of the video methods differentiate between \VIGD (which seems to be
>>> a check for integrated graphics vs optimus, but that's still a guess)
>>> If \VIGD is true, brightness commands are sent to the EC, where they
>>> don't seem to do much yet. This is probably where we could enable
>>> something via EC/ibm-acpi?
>>> If \VIGD is false, brightness commands are handled in ACPI, although
>>> coarsely, via \VBRC.
>>>
>>> \VBRC seems to allow control over the backlight, at least, so those of
>>> you with sore eyes or the 3-cell battery may have some success using the
>>> acpi_call port (Danger!)
>>> kldload acpi_call
>>> acpi_call -p '\VBRC' -i n (where n is 0-10)
>>
>> Great news! Works for me. n is actually 0-16 (plus any other value which
>> turns the backlight off (-1 or 17 eg).
>>
>>
>> Thanks,
>>
>> Hannes
>
>
> Thanks, acpi_call -p '\VBRC' -i n [0-15] work fine, if set 17 black screen :)
>
> And other problems.
> 1) wi-fi
> standart rtl8192cu - not work
> change AR5B95 - work n-mode (thanks Adrian Chadd :) need hack BIOS
> dev.acpi_ibm.0.wlan: 1 <- read only
> hardware switch work, not send mesage
>
> 2) sound
>  # cat /dev/sndstat
> FreeBSD Audio Driver (newpcm: 64bit 2009061500/amd64)
> Installed devices:
> pcm0: <Conexant CX20590 (Analog)> (play/rec)
> pcm1: <Conexant CX20590 (Analog)> (play/rec) default
> pcm2: <Intel Cougar Point (HDMI/DP 8ch)> (play)
> pcm3: <Intel Cougar Point (HDMI/DP 8ch)> (play)
> pcm4: <Intel Cougar Point (HDMI/DP 8ch)> (play)
> sound headphones only, if set sysctl hw.snd.default_unit=0 and restart
> application, on's speakers (if remove headphones).
> Automatic switching possible?

Yes.
Put this in /boot/loader.conf:
# Load the sound driver
snd_hda_load="YES"
# and setup headphones
# Out : speaker + headphones
hint.hdac.0.cad0.nid25.config="as=1 seq=15"
# In : mic + external mic
hint.hdac.0.cad0.nid35.config="as=2"
hint.hdac.0.cad0.nid27.config="as=2 seq=15"
# Drivers for memory card reader
mmc_load="YES"
mmcsd_load="YES"
sdhci_load="YES"
# Load module to read the CPU temp
coretemp_load="YES"

This also enables the SD card reader and reading the CPU temp.

> 2.2) sound control
> in mplayer automatic fine work multimedia key
> multimedia key and system mixer, and sysctl not work

Don't know what desktop you use, but both gnome and KDE allow you to
define the sound buttons. In gnome it is under Preferences/Keyboard
Shortcuts Set "Vol Up" to "XF86AudioRaiseVolume" and "Vol Down" to
"XF86AudioLowerVolume"

>
> 3) ACPI work poorly
> 19    1 0xffffffff81f01000 37c7     acpi_video.ko
> 20    1 0xffffffff81f05000 330f     acpi_ibm.ko
> 21    1 0xffffffff81f09000 1fc      acpi_call.ko
> # sysctl -a | grep ibm
> acpi_ibm0: <IBM ThinkPad ACPI Extras> on acpi0
> acpi_ibm0: detached
> acpi_ibm0: <IBM ThinkPad ACPI Extras> on acpi0
> dev.acpi_ibm.0.%desc: IBM ThinkPad ACPI Extras
> dev.acpi_ibm.0.%driver: acpi_ibm
> dev.acpi_ibm.0.%location: handle=\_SB_.PCI0.LPC_.EC__.HKEY
> dev.acpi_ibm.0.%pnpinfo: _HID=LEN0068 _UID=0
> dev.acpi_ibm.0.%parent: acpi0
> dev.acpi_ibm.0.initialmask: 2060
> dev.acpi_ibm.0.availmask: 134217727
> dev.acpi_ibm.0.events: 1
> dev.acpi_ibm.0.eventmask: 134217727
> dev.acpi_ibm.0.hotkey: 3353
> dev.acpi_ibm.0.lcd_brightness: 0 <- not work
> dev.acpi_ibm.0.volume: 0 <- not work
> dev.acpi_ibm.0.mute: 0 <- not work
> dev.acpi_ibm.0.thinklight: 0 <- work fine :)
> dev.acpi_ibm.0.bluetooth: 0 <- work LED (bt not use, not test)
> dev.acpi_ibm.0.wlan: 1 <- read only
> dev.acpi_ibm.0.fan_speed: 3880 <- not work or read only
> dev.acpi_ibm.0.fan_level: 0
> dev.acpi_ibm.0.fan: 1

The fan speed is read-only.

> LED HDD may be work blink infrequently SSD :)
>
> 3) video work acceptable
> WITH_NEW_XORG=true
> WITH_KMS=true
>
> from terminal adjustable brightness
> acpi_call -p '\VBRC' -i n [0-15]
> I would like to consolidate these actions on the standard key # cat
> /var/run/devd.pipe
> !system=ACPI subsystem=IBM type=\_SB_.PCI0.LPC_.EC__.HKEY notify=0x10 ( Fn+Home)
> !system=ACPI subsystem=IBM type=\_SB_.PCI0.LPC_.EC__.HKEY notify=0x11 (Fn+End)

Sounds good, but you need to know the current brightness to
incrementally adjust it, I have not figured out a way to get it.
-- 
R. Kevin Oberman, Network Engineer
E-mail: kob6558@gmail.com



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