lenovo/x200: Enable wacom digitizer support for x200t

This patch is based on commit f2b3cd63
(lenovo/x60: Support digitizer on X60t and X201t)

Tested on Thinkpad X200 Tablet (7450): all pen functionallity
works (i.e. movements, presure sensitivity and buttons)

Change-Id: I9bd18642a6ea4211dc3be065456a507fc0b72561
Signed-off-by: Alex David <opdecirkel@gmail.com>
Reviewed-on: http://review.coreboot.org/10208
Tested-by: build bot (Jenkins)
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Vladimir Serbinenko <phcoder@gmail.com>
This commit is contained in:
Alex David 2015-05-14 20:09:18 -04:00 committed by Vladimir Serbinenko
parent 99bc2ec581
commit bb03aaa7b8
5 changed files with 28 additions and 2 deletions

View File

@ -34,10 +34,11 @@ static const char tablet_numbers[][5] = {
"6363", "6364", "6365", "6366", "6363", "6364", "6365", "6366",
"6367", "6368", "7762", "7763", "6367", "6368", "7762", "7763",
"7764", "7767", "7768", "7769", "7764", "7767", "7768", "7769",
/* X200t. */
"7448", "7449", "7450", "7453",
/* X201t. */ /* X201t. */
"0053", "0831", "2985", "3093", "0053", "0831", "2985", "3093",
"3113", "3144", "3239", "4184", "3113", "3144", "3239", "4184",
"7448", "7449", "7450", "7453",
"2263", "2266", "2263", "2266",
}; };

View File

@ -21,6 +21,8 @@ config BOARD_SPECIFIC_OPTIONS # dummy
select MAINBOARD_HAS_NATIVE_VGA_INIT select MAINBOARD_HAS_NATIVE_VGA_INIT
select MAINBOARD_HAS_NATIVE_VGA_INIT_TEXTMODECFG select MAINBOARD_HAS_NATIVE_VGA_INIT_TEXTMODECFG
select INTEL_INT15 select INTEL_INT15
select SUPERIO_NSC_PC87382
select DRIVERS_LENOVO_WACOM
config MAINBOARD_DIR config MAINBOARD_DIR
string string

View File

@ -1,2 +1,2 @@
config BOARD_LENOVO_X200 config BOARD_LENOVO_X200
bool "ThinkPad X200" bool "ThinkPad X200 / X200t"

View File

@ -176,6 +176,22 @@ chip northbridge/intel/gm45
register "eventc_enable" = "0xff" register "eventc_enable" = "0xff"
register "eventd_enable" = "0xff" register "eventd_enable" = "0xff"
end end
chip superio/nsc/pc87382
device pnp 164e.3 on # Digitizer
io 0x60 = 0x200
irq 0x29 = 0xb0
irq 0x70 = 0x5
irq 0xf0 = 0x82
end
# IR, not connected
device pnp 164e.2 off end
# GPIO, not connected
device pnp 164e.7 off end
# DLPC, not connected
device pnp 164e.19 off end
end
end end
device pci 1f.2 on # SATA/IDE 1 device pci 1f.2 on # SATA/IDE 1
subsystemid 0x17aa 0x20f8 subsystemid 0x17aa 0x20f8

View File

@ -31,6 +31,7 @@
#include <ec/lenovo/pmh7/pmh7.h> #include <ec/lenovo/pmh7/pmh7.h>
#include <ec/acpi/ec.h> #include <ec/acpi/ec.h>
#include <ec/lenovo/h8/h8.h> #include <ec/lenovo/h8/h8.h>
#include "drivers/lenovo/lenovo.h"
#include "cstates.c" /* Include it, as the linker won't find #include "cstates.c" /* Include it, as the linker won't find
the overloaded weak function in there. */ the overloaded weak function in there. */
@ -49,6 +50,11 @@ const char *smbios_mainboard_bios_version(void)
return s; return s;
} }
static void fill_ssdt(void)
{
drivers_lenovo_serial_ports_ssdt_generate("\\_SB.PCI0.LPCB", 0);
}
static void mainboard_init(device_t dev) static void mainboard_init(device_t dev)
{ {
/* This sneaked in here, because X200 SuperIO chip isn't really /* This sneaked in here, because X200 SuperIO chip isn't really
@ -62,6 +68,7 @@ static void mainboard_enable(device_t dev)
install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS, GMA_INT15_PANEL_FIT_CENTERING, GMA_INT15_BOOT_DISPLAY_DEFAULT, 2); install_intel_vga_int15_handler(GMA_INT15_ACTIVE_LFP_INT_LVDS, GMA_INT15_PANEL_FIT_CENTERING, GMA_INT15_BOOT_DISPLAY_DEFAULT, 2);
dev->ops->init = mainboard_init; dev->ops->init = mainboard_init;
dev->ops->acpi_fill_ssdt_generator = fill_ssdt;
} }
struct chip_operations mainboard_ops = { struct chip_operations mainboard_ops = {