History log of /freebsd-11-stable/sys/dev/acpi_support/acpi_ibm.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 347636 16-May-2019 gonzo

MFC r346647:

[acpi_ibm] Add support for newer Thinkpad models

Add support for newer Thinkpad models with id LEN0268. Was tested on
Thinkpad T480 and ThinkPad X1 Yoga 2nd gen.

PR: 229120
Submitted by: Ali Abdallah <aliovx@gmail.com>


# 302408 07-Jul-2016 gjb

Copy head@r302406 to stable/11 as part of the 11.0-RELEASE cycle.
Prune svn:mergeinfo from the new branch, as nothing has been merged
here.

Additional commits post-branch will follow.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


/freebsd-11-stable/MAINTAINERS
/freebsd-11-stable/cddl
/freebsd-11-stable/cddl/contrib/opensolaris
/freebsd-11-stable/cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/print
/freebsd-11-stable/cddl/contrib/opensolaris/cmd/zfs
/freebsd-11-stable/cddl/contrib/opensolaris/lib/libzfs
/freebsd-11-stable/contrib/amd
/freebsd-11-stable/contrib/apr
/freebsd-11-stable/contrib/apr-util
/freebsd-11-stable/contrib/atf
/freebsd-11-stable/contrib/binutils
/freebsd-11-stable/contrib/bmake
/freebsd-11-stable/contrib/byacc
/freebsd-11-stable/contrib/bzip2
/freebsd-11-stable/contrib/com_err
/freebsd-11-stable/contrib/compiler-rt
/freebsd-11-stable/contrib/dialog
/freebsd-11-stable/contrib/dma
/freebsd-11-stable/contrib/dtc
/freebsd-11-stable/contrib/ee
/freebsd-11-stable/contrib/elftoolchain
/freebsd-11-stable/contrib/elftoolchain/ar
/freebsd-11-stable/contrib/elftoolchain/brandelf
/freebsd-11-stable/contrib/elftoolchain/elfdump
/freebsd-11-stable/contrib/expat
/freebsd-11-stable/contrib/file
/freebsd-11-stable/contrib/gcc
/freebsd-11-stable/contrib/gcclibs/libgomp
/freebsd-11-stable/contrib/gdb
/freebsd-11-stable/contrib/gdtoa
/freebsd-11-stable/contrib/groff
/freebsd-11-stable/contrib/ipfilter
/freebsd-11-stable/contrib/ldns
/freebsd-11-stable/contrib/ldns-host
/freebsd-11-stable/contrib/less
/freebsd-11-stable/contrib/libarchive
/freebsd-11-stable/contrib/libarchive/cpio
/freebsd-11-stable/contrib/libarchive/libarchive
/freebsd-11-stable/contrib/libarchive/libarchive_fe
/freebsd-11-stable/contrib/libarchive/tar
/freebsd-11-stable/contrib/libc++
/freebsd-11-stable/contrib/libc-vis
/freebsd-11-stable/contrib/libcxxrt
/freebsd-11-stable/contrib/libexecinfo
/freebsd-11-stable/contrib/libpcap
/freebsd-11-stable/contrib/libstdc++
/freebsd-11-stable/contrib/libucl
/freebsd-11-stable/contrib/libxo
/freebsd-11-stable/contrib/llvm
/freebsd-11-stable/contrib/llvm/projects/libunwind
/freebsd-11-stable/contrib/llvm/tools/clang
/freebsd-11-stable/contrib/llvm/tools/lldb
/freebsd-11-stable/contrib/llvm/tools/llvm-dwarfdump
/freebsd-11-stable/contrib/llvm/tools/llvm-lto
/freebsd-11-stable/contrib/mdocml
/freebsd-11-stable/contrib/mtree
/freebsd-11-stable/contrib/ncurses
/freebsd-11-stable/contrib/netcat
/freebsd-11-stable/contrib/ntp
/freebsd-11-stable/contrib/nvi
/freebsd-11-stable/contrib/one-true-awk
/freebsd-11-stable/contrib/openbsm
/freebsd-11-stable/contrib/openpam
/freebsd-11-stable/contrib/openresolv
/freebsd-11-stable/contrib/pf
/freebsd-11-stable/contrib/sendmail
/freebsd-11-stable/contrib/serf
/freebsd-11-stable/contrib/sqlite3
/freebsd-11-stable/contrib/subversion
/freebsd-11-stable/contrib/tcpdump
/freebsd-11-stable/contrib/tcsh
/freebsd-11-stable/contrib/tnftp
/freebsd-11-stable/contrib/top
/freebsd-11-stable/contrib/top/install-sh
/freebsd-11-stable/contrib/tzcode/stdtime
/freebsd-11-stable/contrib/tzcode/zic
/freebsd-11-stable/contrib/tzdata
/freebsd-11-stable/contrib/unbound
/freebsd-11-stable/contrib/vis
/freebsd-11-stable/contrib/wpa
/freebsd-11-stable/contrib/xz
/freebsd-11-stable/crypto/heimdal
/freebsd-11-stable/crypto/openssh
/freebsd-11-stable/crypto/openssl
/freebsd-11-stable/gnu/lib
/freebsd-11-stable/gnu/usr.bin/binutils
/freebsd-11-stable/gnu/usr.bin/cc/cc_tools
/freebsd-11-stable/gnu/usr.bin/gdb
/freebsd-11-stable/lib/libc/locale/ascii.c
/freebsd-11-stable/sys/cddl/contrib/opensolaris
/freebsd-11-stable/sys/contrib/dev/acpica
/freebsd-11-stable/sys/contrib/ipfilter
/freebsd-11-stable/sys/contrib/libfdt
/freebsd-11-stable/sys/contrib/octeon-sdk
/freebsd-11-stable/sys/contrib/x86emu
/freebsd-11-stable/sys/contrib/xz-embedded
/freebsd-11-stable/usr.sbin/bhyve/atkbdc.h
/freebsd-11-stable/usr.sbin/bhyve/bhyvegc.c
/freebsd-11-stable/usr.sbin/bhyve/bhyvegc.h
/freebsd-11-stable/usr.sbin/bhyve/console.c
/freebsd-11-stable/usr.sbin/bhyve/console.h
/freebsd-11-stable/usr.sbin/bhyve/pci_fbuf.c
/freebsd-11-stable/usr.sbin/bhyve/pci_xhci.c
/freebsd-11-stable/usr.sbin/bhyve/pci_xhci.h
/freebsd-11-stable/usr.sbin/bhyve/ps2kbd.c
/freebsd-11-stable/usr.sbin/bhyve/ps2kbd.h
/freebsd-11-stable/usr.sbin/bhyve/ps2mouse.c
/freebsd-11-stable/usr.sbin/bhyve/ps2mouse.h
/freebsd-11-stable/usr.sbin/bhyve/rfb.c
/freebsd-11-stable/usr.sbin/bhyve/rfb.h
/freebsd-11-stable/usr.sbin/bhyve/sockstream.c
/freebsd-11-stable/usr.sbin/bhyve/sockstream.h
/freebsd-11-stable/usr.sbin/bhyve/usb_emul.c
/freebsd-11-stable/usr.sbin/bhyve/usb_emul.h
/freebsd-11-stable/usr.sbin/bhyve/usb_mouse.c
/freebsd-11-stable/usr.sbin/bhyve/vga.c
/freebsd-11-stable/usr.sbin/bhyve/vga.h
# 300421 22-May-2016 loos

Fix the deciKelvin to Celsius conversion in kernel.

After r285994, sysctl(8) was fixed to use 273.15 instead of 273.20 as 0C
reference and as result, the temperature read in sysctl(8) now exibits a
+0.1C difference.

This commit fix the kernel references to match the reference value used in
sysctl(8) after r285994.

Sponsored by: Rubicon Communications (Netgate)


# 298955 03-May-2016 pfg

sys/dev: minor spelling fixes.

Most affect comments, very few have user-visible effects.


# 284358 13-Jun-2015 ngie

Fix previous commit (r284357)

I forgot to convert the && to a ||

Pointyhat to: ngie
X-MFC with: r283678, r284336, r284357


# 284357 13-Jun-2015 ngie

Fix inverted check by skipping over the model-specific checks if the maker
or product is NULL, not if they are both not NULL

Reported by: araujo, kib
X-MFC with: r283678, r284336
Pointyhat to: allanjude


# 284336 13-Jun-2015 allanjude

acpi_ibm.ko panics if SMBIOS information is not available

Add a check for NULL before strcmp on smbios information incase it is not populated

Differential Revision: https://reviews.freebsd.org/D2750
Reviewed by: ngie, jhb
Approved by: rpaulo
Sponsored by: ScaleEngine Inc.


# 283678 29-May-2015 rpaulo

acpi_ibm: add per-model default events mask.

Add support for the hotkeys on a Lenovo X1 3rd gen. This also enables
event reporting by default.


# 283360 24-May-2015 ganbold

This implements default-state support as described in:

https://www.kernel.org/doc/Documentation/devicetree/bindings/leds/leds-gpio.txt

Without this booting the VSATV102 causes the blue "working" led to turn
off when the kernel starts up. With this the led (which is turned on by
the firmware) stays on since that's the default state specified in the FDT.

Expanded the meaning of the led_create_state state parameter in order
to implement support for "keep". The original values were:

== 0 Off
!= 0 On

The new values are:

== -1 don't change / keep current setting
== 0 Off
!= -1 && != 0 On

This should have no effect on acpi_asus_attach which only calls
led_create_state with state set to 1. Updated acpi_ibm_attach
in order to avoid surprises.

Differential Revision: https://reviews.freebsd.org/D2615
Submitted by: John Wehle
Reviewed by: gonzo, loos


# 283012 16-May-2015 rpaulo

acpi_ibm: whitespace.


# 273773 28-Oct-2014 hselasky

The SYSCTL data pointers can come from userspace and must not be
directly accessed. Although this will work on some platforms, it can
throw an exception if the pointer is invalid and then panic the kernel.

Add a missing SYSCTL_IN() of "SCTP_BASE_STATS" structure.

MFC after: 3 days
Sponsored by: Mellanox Technologies


# 273377 21-Oct-2014 hselasky

Fix multiple incorrect SYSCTL arguments in the kernel:

- Wrong integer type was specified.

- Wrong or missing "access" specifier. The "access" specifier
sometimes included the SYSCTL type, which it should not, except for
procedural SYSCTL nodes.

- Logical OR where binary OR was expected.

- Properly assert the "access" argument passed to all SYSCTL macros,
using the CTASSERT macro. This applies to both static- and dynamically
created SYSCTLs.

- Properly assert the the data type for both static and dynamic
SYSCTLs. In the case of static SYSCTLs we only assert that the data
pointed to by the SYSCTL data pointer has the correct size, hence
there is no easy way to assert types in the C language outside a
C-function.

- Rewrote some code which doesn't pass a constant "access" specifier
when creating dynamic SYSCTL nodes, which is now a requirement.

- Updated "EXAMPLES" section in SYSCTL manual page.

MFC after: 3 days
Sponsored by: Mellanox Technologies


# 246128 30-Jan-2013 sbz

Use DEVMETHOD_END macro defined in sys/bus.h instead of {0, 0} sentinel on device_method_t arrays

Reviewed by: cognet
Approved by: cognet


# 242305 29-Oct-2012 bapt

add support for newer Lenovo ThinkPads to acpi_ibm

PR: kern/164538
Submitted by: Pierre Imai <pierre@imai.at>
MFC after: 2 weeks


# 237493 23-Jun-2012 iwasaki

Add in-driver event handler.

MFC after: 3 days


# 217566 18-Jan-2011 mdf

Fix a few more SYSCTL_PROC() that were missing a CTLFLAG type specifier.


# 217323 12-Jan-2011 mdf

sysctl(9) cleanup checkpoint: amd64 GENERIC builds cleanly.

Commit the rest of the devices.


# 209064 11-Jun-2010 jkim

Remove unused assignment.

Found by: clang static analyzer
Found by: Coverity Prevent[tm] (CID 4537, 4538, 4539)


# 202771 21-Jan-2010 jkim

Merge ACPICA 20100121.


# 201605 05-Jan-2010 iwasaki

Update acpi_ibm syctl nodes on resume.

This should fix some Thinkpad specific problems such as
connecting to a headphone jack is not functional on X41.

Reviewed by: takawata
MFC after: 1 week


# 197460 24-Sep-2009 jhb

Remove unnecessary locking from attach(). This fixes a LOR between the
acpi_ibm lock and the sysctl lock.

MFC after: 3 days


# 197350 20-Sep-2009 jhb

Re-remove the IBM0057 ID used for PS/2 mouse controllers. The asl for the
61p includes the hotkey device as IBM0068 and the mouse as IBM0057 similar
to other systems.

Submitted by: marius
MFC after: 3 days


# 193530 05-Jun-2009 jkim

Import ACPICA 20090521.


# 192030 12-May-2009 brueffer

Remove unused variables.

Found with: Coverity Prevent(tm)
CID: 544, 545


# 179155 20-May-2008 pjd

Add ID for T61p, which is not IBM really, but well.


# 178193 14-Apr-2008 phk

Convert amd64 and i386 to share the atrtc device driver.


# 172980 25-Oct-2007 jhb

Don't attach to the "IBM0057" ID. This ID is used by IBM machines for
the PS/2 mouse controller. Thus, when acpi_ibm(4) claimed the mouse
device, the mouse would stop working. The one ACPI dump of an R40 that
I've looked at includes an HKEY device with the proper "IBM0068" ID, so
I'm not sure how the "IBM0057" ID could have helped at all.

MFC after: 1 week
Approved by: njl


# 169031 24-Apr-2007 markus

Utilize led_create_state in order to preserve the status of the ThinkLight
on driver attach.

PR: kern/112044
Submitted by: Henrik Brix Andersen <henrik@brixandersen.dk>
Approved by: emax (mentor) (earlier version)


# 167814 22-Mar-2007 jkim

Catch up with ACPI-CA 20070320 import.


# 161289 14-Aug-2006 takawata

Improve exception string format.
PR:100671
MFC after: 3 days


# 161288 14-Aug-2006 takawata

Remove debug messages on notify handler.

PR:100671


# 154326 13-Jan-2006 markus

- Add support for setting the fan control mode to manual or automatic
- Add support for adjusting the fan speed if the fan control mode is manual

Documentation for the relevant embedded controller register was obtained from
http://www.thinkwiki.org/wiki/Patch_for_controlling_fan_speed

Tested on: R51 by Fabian Keil
T41p by markus
Requested by: many
Approved by: philip
MFC after: 1 week


# 150003 11-Sep-2005 obrien

Canonize the include of acpi.h.


# 148710 04-Aug-2005 markus

Don't lock when holding led_mtx, instead use AcpiOsQueueForExecution to defer
the locking.

Idea taken from: acpi_asus(4)

Approved by: philip
Reported by: avatar
Gordon Bergling <gbergling@0xfce3.net>
MFC after: 1 week


# 147468 17-Jun-2005 cracauer

Add the ID of my Thinkpad R40. Makes the module detect and with the
exception of fans everything seems to work fine. No ill effects
observed.
Reviewed by: Nate Lawson (on acpi list)
Approved by: re (Ken Smith)


# 147246 10-Jun-2005 markus

- Only create the led(4) interface, if setting the thinklight is possible
- Initialize val_ec with the content of the volume EC register
for ACPI_IBM_METHOD_VOLUME and ACPI_IBM_METHOD_MUTE in acpi_ibm_sysctl_set()
if there is no CMOS handle present. This fixes setting volume and mute on
such models.

Submitted by: ru
Approved by: philip


# 147196 09-Jun-2005 markus

Import a mostly rewritten and extended version of acpi_ibm:

- Restructured for easier extensibility and maintainability
- To be more uniform with the other ACPI extras drivers and to better reflect
their actual meaning, some sysctls were moved:
o brightness -> lcd_brightness
o keylight -> thinklight
o enable -> events
o misckey -> hotkey
o avail_mask -> availmask
o key_mask -> eventmask
- New "initialmask" sysctl, which holds the initial eventmask
- The "wlan" sysctl is now read-only, since writing to it didn't have
any effect
- The "version" sysctl was removed, since it seems to be the same (0x100)
on all models I have seen
- Support for more hotkeys by the "hotkey" sysctl
- Improved support of ACPI events. Disabled by default, since it unexpectedly
changes the behaviour of some keys. (on my T41p there are now 24 different
keypress events that get reported)
- write support for: volume, mute, lcd_brightness and thinklight
- led(4) interface for the thinklight [1]
- New sysctls "fan" and "fan_speed" to support reading of fan status and speed
- New sysctl "thermal" to support reading of up to 8 thermal sensors

Reviewed by: philip
Approved by: philip
Submitted by: simon [1]
Inspired by: The Linux ibm_acpi driver by Borislav Deianov
http://ibm-acpi.sourceforge.net/
The ThinkPad Button program (tpb) by Markus Braun
http://www.nongnu.org/tpb/
Thanks to: brueffer, dvl, njl, philip, simon, takawata and the many
testers from freebsd-acpi@ and freebsd-mobile@


# 143002 02-Mar-2005 obrien

Fix SCM ID's.


# 138825 13-Dec-2004 njl

Unify ACPI_DEBUG support for all OEM drivers under ACPI_OEM. Since more than
one will never be supported on the same platform, this does not hurt
debugging.

MFC after: 3 days


# 138774 13-Dec-2004 scottl

Allow the acpi_ibm module to be built with ACPI_DEBUG.


# 138627 09-Dec-2004 takawata

Add IBM Laptop extra device driver.
This depends on ACPI and RTC registers.

Reviewed by: njl