Gentoo Archives: gentoo-commits

From: "Alexey Shvetsov (alexxy)" <alexxy@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in app-laptop/tp_smapi/files: tp_smapi-0.40-2.6.37.patch fix_header_check.patch
Date: Mon, 29 Nov 2010 01:14:35
Message-Id: 20101129011425.B0A9B20054@flycatcher.gentoo.org
1 alexxy 10/11/29 01:14:25
2
3 Added: tp_smapi-0.40-2.6.37.patch fix_header_check.patch
4 Log:
5 [app-laptop/tp_smapi] Fix bugs #294251 #346493
6
7 (Portage version: 2.2.0_alpha6/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.1 app-laptop/tp_smapi/files/tp_smapi-0.40-2.6.37.patch
11
12 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-laptop/tp_smapi/files/tp_smapi-0.40-2.6.37.patch?rev=1.1&view=markup
13 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-laptop/tp_smapi/files/tp_smapi-0.40-2.6.37.patch?rev=1.1&content-type=text/plain
14
15 Index: tp_smapi-0.40-2.6.37.patch
16 ===================================================================
17 diff -urN tp_smapi-0.40.orig/thinkpad_ec.c tp_smapi-0.40/thinkpad_ec.c
18 --- tp_smapi-0.40.orig/thinkpad_ec.c 2008-12-16 08:03:06.000000000 +0300
19 +++ tp_smapi-0.40/thinkpad_ec.c 2010-11-22 18:16:54.000000000 +0300
20 @@ -88,7 +88,11 @@
21 #define TPC_PREFETCH_JUNK (INITIAL_JIFFIES+1) /* Ignore prefetch */
22
23 /* Locking: */
24 +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)
25 static DECLARE_MUTEX(thinkpad_ec_mutex);
26 +#else
27 +static DEFINE_SEMAPHORE(thinkpad_ec_mutex);
28 +#endif
29
30 /* Kludge in case the ACPI DSDT reserves the ports we need. */
31 static int force_io; /* Willing to do IO to ports we couldn't reserve? */
32 diff -urN tp_smapi-0.40.orig/tp_smapi.c tp_smapi-0.40/tp_smapi.c
33 --- tp_smapi-0.40.orig/tp_smapi.c 2008-12-16 08:03:06.000000000 +0300
34 +++ tp_smapi-0.40/tp_smapi.c 2010-11-22 18:17:29.000000000 +0300
35 @@ -109,7 +109,11 @@
36 #define SMAPI_PORT2 0x4F /* fixed port, meaning unclear */
37 static unsigned short smapi_port; /* APM control port, normally 0xB2 */
38
39 +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)
40 static DECLARE_MUTEX(smapi_mutex);
41 +#else
42 +static DEFINE_SEMAPHORE(smapi_mutex);
43 +#endif
44
45 /**
46 * find_smapi_port - read SMAPI port from NVRAM
47
48
49
50 1.1 app-laptop/tp_smapi/files/fix_header_check.patch
51
52 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-laptop/tp_smapi/files/fix_header_check.patch?rev=1.1&view=markup
53 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-laptop/tp_smapi/files/fix_header_check.patch?rev=1.1&content-type=text/plain
54
55 Index: fix_header_check.patch
56 ===================================================================
57 *** Makefile.orig Mon Nov 23 08:55:42 2009
58 --- Makefile Mon Nov 23 08:57:48 2009
59 ***************
60 *** 27,33 ****
61
62 DEBUG := 0
63
64 ! ifneq ($(shell [ -f $(KBUILD)/include/linux/aio_abi.h ] && echo 1),1)
65 $(warning Building tp_smapi requires Linux kernel 2.6.19 or newer, and matching kernel headers.)
66 $(warning You may need to override the following Make variables:)
67 $(warning . KVER=$(KVER))
68 --- 27,33 ----
69
70 DEBUG := 0
71
72 ! ifneq ($(shell [ -f $(KSRC)/include/linux/aio_abi.h ] && echo 1),1)
73 $(warning Building tp_smapi requires Linux kernel 2.6.19 or newer, and matching kernel headers.)
74 $(warning You may need to override the following Make variables:)
75 $(warning . KVER=$(KVER))