Skip to content
This repository was archived by the owner on Feb 18, 2022. It is now read-only.

Commit f38f4c6

Browse files
committed
Updates for kernel 5.7.15
1 parent bbc3c55 commit f38f4c6

7 files changed

Lines changed: 448 additions & 427 deletions

File tree

build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ set -eu -o pipefail
44

55
## Update docker image tag, because kernel build is using `uname -r` when defining package version variable
66
# KERNEL_VERSION=$(curl -s https://www.kernel.org | grep '<strong>' | head -3 | tail -1 | cut -d'>' -f3 | cut -d'<' -f1)
7-
KERNEL_VERSION=5.7.12
7+
KERNEL_VERSION=5.7.15
88
#KERNEL_REPOSITORY=git://kernel.ubuntu.com/virgin/linux-stable.git
99
KERNEL_REPOSITORY=https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git
1010
REPO_PATH=$(pwd)

patch_driver.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ BUILD_PATH=/tmp/build-kernel
88
# Patches
99
APPLE_SMC_DRIVER_GIT_URL=https://github.com/aunali1/linux-mbp-arch
1010
APPLE_SMC_DRIVER_BRANCH_NAME=master
11-
APPLE_SMC_DRIVER_COMMIT_HASH=a2401217c79e4c3c9a0b3e5e1c28e87a9986e314
11+
APPLE_SMC_DRIVER_COMMIT_HASH=aa8d8579b88f67cc21592a439937f73d174e836f
1212
## BCE
1313
#APPLE_BCE_DRIVER_GIT_URL=https://github.com/aunali1/mbp2018-bridge-drv.git
1414
#APPLE_BCE_DRIVER_BRANCH_NAME=aur

patches/4001-touchpad.patch

Lines changed: 176 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,176 @@
1+
diff --git a/drivers/hid/hid-apple.c b/drivers/hid/hid-apple.c
2+
index 6ac8becc2372..b1143139599a 100644
3+
--- a/drivers/hid/hid-apple.c
4+
+++ b/drivers/hid/hid-apple.c
5+
@@ -561,6 +561,16 @@ static const struct hid_device_id apple_devices[] = {
6+
.driver_data = APPLE_HAS_FN },
7+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_JIS),
8+
.driver_data = APPLE_HAS_FN | APPLE_RDESC_JIS },
9+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A),
10+
+ .driver_data = APPLE_HAS_FN },
11+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B),
12+
+ .driver_data = APPLE_HAS_FN },
13+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C),
14+
+ .driver_data = APPLE_HAS_FN },
15+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D),
16+
+ .driver_data = APPLE_HAS_FN },
17+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING11_T2),
18+
+ .driver_data = APPLE_HAS_FN },
19+
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_ANSI),
20+
.driver_data = APPLE_NUMLOCK_EMULATION | APPLE_HAS_FN },
21+
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_ISO),
22+
diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
23+
index 3a400ce603c4..d7c678017b12 100644
24+
--- a/drivers/hid/hid-ids.h
25+
+++ b/drivers/hid/hid-ids.h
26+
@@ -168,6 +168,11 @@
27+
#define USB_DEVICE_ID_APPLE_WELLSPRING9_ANSI 0x0272
28+
#define USB_DEVICE_ID_APPLE_WELLSPRING9_ISO 0x0273
29+
#define USB_DEVICE_ID_APPLE_WELLSPRING9_JIS 0x0274
30+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A 0x027a
31+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B 0x027b
32+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C 0x027c
33+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D 0x027d
34+
+#define USB_DEVICE_ID_APPLE_WELLSPRING11_T2 0x0340
35+
#define USB_DEVICE_ID_APPLE_FOUNTAIN_TP_ONLY 0x030a
36+
#define USB_DEVICE_ID_APPLE_GEYSER1_TP_ONLY 0x030b
37+
#define USB_DEVICE_ID_APPLE_IRCONTROL 0x8240
38+
diff --git a/drivers/hid/hid-quirks.c b/drivers/hid/hid-quirks.c
39+
index 0e7b2d998395..ba9c0dcbea9e 100644
40+
--- a/drivers/hid/hid-quirks.c
41+
+++ b/drivers/hid/hid-quirks.c
42+
@@ -274,6 +274,11 @@ static const struct hid_device_id hid_have_special_driver[] = {
43+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_ANSI) },
44+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_ISO) },
45+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_JIS) },
46+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A) },
47+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B) },
48+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C) },
49+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D) },
50+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING11_T2) },
51+
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_ANSI) },
52+
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_ISO) },
53+
{ HID_BLUETOOTH_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_ALU_WIRELESS_2009_JIS) },
54+
@@ -908,6 +913,11 @@ static const struct hid_device_id hid_mouse_ignore_list[] = {
55+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_ANSI) },
56+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_ISO) },
57+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING9_JIS) },
58+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A) },
59+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B) },
60+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C) },
61+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D) },
62+
+ { HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_WELLSPRING11_T2) },
63+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_FOUNTAIN_TP_ONLY) },
64+
{ HID_USB_DEVICE(USB_VENDOR_ID_APPLE, USB_DEVICE_ID_APPLE_GEYSER1_TP_ONLY) },
65+
{ }
66+
diff --git a/drivers/input/mouse/bcm5974.c b/drivers/input/mouse/bcm5974.c
67+
index 59a14505b9cd..63ab0b804a94 100644
68+
--- a/drivers/input/mouse/bcm5974.c
69+
+++ b/drivers/input/mouse/bcm5974.c
70+
@@ -82,6 +82,17 @@
71+
#define USB_DEVICE_ID_APPLE_WELLSPRING9_ANSI 0x0272
72+
#define USB_DEVICE_ID_APPLE_WELLSPRING9_ISO 0x0273
73+
#define USB_DEVICE_ID_APPLE_WELLSPRING9_JIS 0x0274
74+
+/* T2-Attached Devices */
75+
+/* MacbookAir8,1 (2018) */
76+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A 0x027a
77+
+/* MacbookPro15,2 (2018) */
78+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B 0x027b
79+
+/* MacbookPro15,1 (2018) */
80+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C 0x027c
81+
+/* MacbookPro15,4 (2019) */
82+
+#define USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D 0x027d
83+
+/* MacbookPro16,1 (2019)*/
84+
+#define USB_DEVICE_ID_APPLE_WELLSPRING11_T2 0x0340
85+
86+
#define BCM5974_DEVICE(prod) { \
87+
.match_flags = (USB_DEVICE_ID_MATCH_DEVICE | \
88+
@@ -147,6 +158,16 @@ static const struct usb_device_id bcm5974_table[] = {
89+
BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING9_ANSI),
90+
BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING9_ISO),
91+
BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING9_JIS),
92+
+ /* MacbookAir8,1 */
93+
+ BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A),
94+
+ /* MacbookPro15,2 */
95+
+ BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B),
96+
+ /* MacbookPro15,1 */
97+
+ BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C),
98+
+ /* MacbookPro15,4 */
99+
+ BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D),
100+
+ /* MacbookPro16,1 */
101+
+ BCM5974_DEVICE(USB_DEVICE_ID_APPLE_WELLSPRING11_T2),
102+
/* Terminating entry */
103+
{}
104+
};
105+
@@ -483,6 +504,71 @@ static const struct bcm5974_config bcm5974_config_table[] = {
106+
{ SN_COORD, -203, 6803 },
107+
{ SN_ORIENT, -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION }
108+
},
109+
+ {
110+
+ USB_DEVICE_ID_APPLE_WELLSPRING10_T2_A,
111+
+ 0,
112+
+ 0,
113+
+ HAS_INTEGRATED_BUTTON,
114+
+ 0, sizeof(struct bt_data),
115+
+ 0x83, DATAFORMAT(TYPE4),
116+
+ { SN_PRESSURE, 0, 300 },
117+
+ { SN_WIDTH, 0, 2048 },
118+
+ { SN_COORD, -6243, 6749 },
119+
+ { SN_COORD, -170, 7685 },
120+
+ { SN_ORIENT, -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION }
121+
+ },
122+
+ {
123+
+ USB_DEVICE_ID_APPLE_WELLSPRING10_T2_B,
124+
+ 0,
125+
+ 0,
126+
+ HAS_INTEGRATED_BUTTON,
127+
+ 0, sizeof(struct bt_data),
128+
+ 0x83, DATAFORMAT(TYPE4),
129+
+ { SN_PRESSURE, 0, 300 },
130+
+ { SN_WIDTH, 0, 2048 },
131+
+ { SN_COORD, -6243, 6749 },
132+
+ { SN_COORD, -170, 7685 },
133+
+ { SN_ORIENT, -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION }
134+
+ },
135+
+ {
136+
+ USB_DEVICE_ID_APPLE_WELLSPRING10_T2_C,
137+
+ 0,
138+
+ 0,
139+
+ HAS_INTEGRATED_BUTTON,
140+
+ 0, sizeof(struct bt_data),
141+
+ 0x83, DATAFORMAT(TYPE4),
142+
+ { SN_PRESSURE, 0, 300 },
143+
+ { SN_WIDTH, 0, 2048 },
144+
+ { SN_COORD, -7456, 7976 },
145+
+ { SN_COORD, -1768, 7685 },
146+
+ { SN_ORIENT, -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION }
147+
+ },
148+
+ {
149+
+ USB_DEVICE_ID_APPLE_WELLSPRING10_T2_D,
150+
+ 0,
151+
+ 0,
152+
+ HAS_INTEGRATED_BUTTON,
153+
+ 0, sizeof(struct bt_data),
154+
+ 0x83, DATAFORMAT(TYPE4),
155+
+ { SN_PRESSURE, 0, 300 },
156+
+ { SN_WIDTH, 0, 2048 },
157+
+ { SN_COORD, -6243, 6749 },
158+
+ { SN_COORD, -170, 7685 },
159+
+ { SN_ORIENT, -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION }
160+
+ },
161+
+ {
162+
+ USB_DEVICE_ID_APPLE_WELLSPRING11_T2,
163+
+ 0,
164+
+ 0,
165+
+ HAS_INTEGRATED_BUTTON,
166+
+ 0, sizeof(struct bt_data),
167+
+ 0x83, DATAFORMAT(TYPE4),
168+
+ { SN_PRESSURE, 0, 300 },
169+
+ { SN_WIDTH, 0, 2048 },
170+
+ { SN_COORD, -7456, 7976 },
171+
+ { SN_COORD, -1768, 7685 },
172+
+ { SN_ORIENT, -MAX_FINGER_ORIENTATION, MAX_FINGER_ORIENTATION }
173+
+ },
174+
{}
175+
};
176+

0 commit comments

Comments
 (0)