core/linux-oak to 3.18.0-8

This commit is contained in:
Kevin Mihelich 2017-05-28 02:29:07 +00:00
parent 78cec6a807
commit 638793c99b
11 changed files with 69 additions and 137 deletions

View file

@ -1,7 +1,7 @@
From 23133db85174d33389eae98c13e2f65c9ef05215 Mon Sep 17 00:00:00 2001
From 2ed826065abdfe471e0b7489c3fecc277848c471 Mon Sep 17 00:00:00 2001
From: Arnd Bergmann <arnd@arndb.de>
Date: Tue, 10 May 2016 23:30:01 +0200
Subject: [PATCH 1/9] kbuild: move -Wunused-const-variable to W=1 warning level
Subject: [PATCH 1/8] kbuild: move -Wunused-const-variable to W=1 warning level
gcc-6 started warning by default about variables that are not
used anywhere and that are marked 'const', generating many
@ -34,11 +34,11 @@ Signed-off-by: Michal Marek <mmarek@suse.com>
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index b52a844..4053d1ca 100644
index d94cde0b4369..0847d3f6c162 100644
--- a/Makefile
+++ b/Makefile
@@ -707,9 +707,10 @@ KBUILD_CFLAGS += $(call cc-option, -mno-global-merge,)
KBUILD_CFLAGS += $(call cc-option, -fcatch-undefined-behavior)
@@ -709,9 +709,10 @@ KBUILD_CFLAGS += $(call cc-option, -no-integrated-as)
KBUILD_AFLAGS += $(call cc-option, -no-integrated-as)
else
-# This warning generated too much noise in a regular build.
@ -51,7 +51,7 @@ index b52a844..4053d1ca 100644
ifdef CONFIG_FRAME_POINTER
diff --git a/scripts/Makefile.extrawarn b/scripts/Makefile.extrawarn
index f734033..5c17a5c 100644
index 48366bc8d5c8..abe5f47b1ab0 100644
--- a/scripts/Makefile.extrawarn
+++ b/scripts/Makefile.extrawarn
@@ -24,6 +24,7 @@ warning-1 += $(call cc-option, -Wmissing-prototypes)
@ -63,5 +63,5 @@ index f734033..5c17a5c 100644
warning-2 := -Waggregate-return
--
2.10.2
2.13.0

View file

@ -1,7 +1,7 @@
From 8acfd757d3588f137cf17812065f44ac37092af8 Mon Sep 17 00:00:00 2001
From 9e7ab58137c1d2a13fd5ea607968977bc54081e2 Mon Sep 17 00:00:00 2001
From: Firo Yang <firogm@gmail.com>
Date: Thu, 11 Jun 2015 09:41:10 +0800
Subject: [PATCH 2/9] md: fix a build warning
Subject: [PATCH 2/8] md: fix a build warning
Warning like this:
@ -20,7 +20,7 @@ Signed-off-by: NeilBrown <neilb@suse.de>
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/md/md.c b/drivers/md/md.c
index 9233c71..4339035 100644
index 9233c71138f1..43390353d62f 100644
--- a/drivers/md/md.c
+++ b/drivers/md/md.c
@@ -6031,7 +6031,7 @@ static int update_array_info(struct mddev *mddev, mdu_array_info_t *info)
@ -33,5 +33,5 @@ index 9233c71..4339035 100644
/* ignore bottom 8 bits of state, and allow SB_BITMAP_PRESENT to change */
((state^info->state) & 0xfffffe00)
--
2.10.2
2.13.0

View file

@ -1,68 +0,0 @@
From a136038ea86b72511873cbeff7bbdd9593d86d17 Mon Sep 17 00:00:00 2001
From: Arnd Bergmann <arnd@arndb.de>
Date: Mon, 14 Mar 2016 15:18:36 +0100
Subject: [PATCH 3/9] ath9k: fix buffer overrun for ar9287
Code that was added back in 2.6.38 has an obvious overflow
when accessing a static array, and at the time it was added
only a code comment was put in front of it as a reminder
to have it reviewed properly.
This has not happened, but gcc-6 now points to the specific
overflow:
drivers/net/wireless/ath/ath9k/eeprom.c: In function 'ath9k_hw_get_gain_boundaries_pdadcs':
drivers/net/wireless/ath/ath9k/eeprom.c:483:44: error: array subscript is above array bounds [-Werror=array-bounds]
maxPwrT4[i] = data_9287[idxL].pwrPdg[i][4];
~~~~~~~~~~~~~~~~~~~~~~~~~^~~
It turns out that the correct array length exists in the local
'intercepts' variable of this function, so we can just use that
instead of hardcoding '4', so this patch changes all three
instances to use that variable. The other two instances were
already correct, but it's more consistent this way.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 940cd2c12ebf ("ath9k_hw: merge the ar9287 version of ath9k_hw_get_gain_boundaries_pdadcs")
Signed-off-by: David S. Miller <davem@davemloft.net>
---
drivers/net/wireless/ath/ath9k/eeprom.c | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/net/wireless/ath/ath9k/eeprom.c b/drivers/net/wireless/ath/ath9k/eeprom.c
index 971d770..2ac0548 100644
--- a/drivers/net/wireless/ath/ath9k/eeprom.c
+++ b/drivers/net/wireless/ath/ath9k/eeprom.c
@@ -408,10 +408,9 @@ void ath9k_hw_get_gain_boundaries_pdadcs(struct ath_hw *ah,
if (match) {
if (AR_SREV_9287(ah)) {
- /* FIXME: array overrun? */
for (i = 0; i < numXpdGains; i++) {
minPwrT4[i] = data_9287[idxL].pwrPdg[i][0];
- maxPwrT4[i] = data_9287[idxL].pwrPdg[i][4];
+ maxPwrT4[i] = data_9287[idxL].pwrPdg[i][intercepts - 1];
ath9k_hw_fill_vpd_table(minPwrT4[i], maxPwrT4[i],
data_9287[idxL].pwrPdg[i],
data_9287[idxL].vpdPdg[i],
@@ -421,7 +420,7 @@ void ath9k_hw_get_gain_boundaries_pdadcs(struct ath_hw *ah,
} else if (eeprom_4k) {
for (i = 0; i < numXpdGains; i++) {
minPwrT4[i] = data_4k[idxL].pwrPdg[i][0];
- maxPwrT4[i] = data_4k[idxL].pwrPdg[i][4];
+ maxPwrT4[i] = data_4k[idxL].pwrPdg[i][intercepts - 1];
ath9k_hw_fill_vpd_table(minPwrT4[i], maxPwrT4[i],
data_4k[idxL].pwrPdg[i],
data_4k[idxL].vpdPdg[i],
@@ -431,7 +430,7 @@ void ath9k_hw_get_gain_boundaries_pdadcs(struct ath_hw *ah,
} else {
for (i = 0; i < numXpdGains; i++) {
minPwrT4[i] = data_def[idxL].pwrPdg[i][0];
- maxPwrT4[i] = data_def[idxL].pwrPdg[i][4];
+ maxPwrT4[i] = data_def[idxL].pwrPdg[i][intercepts - 1];
ath9k_hw_fill_vpd_table(minPwrT4[i], maxPwrT4[i],
data_def[idxL].pwrPdg[i],
data_def[idxL].vpdPdg[i],
--
2.10.2

View file

@ -1,7 +1,7 @@
From 105567d05a8f1f25a9241e9e464fd3ff9c811642 Mon Sep 17 00:00:00 2001
From 3f821de907c637437fe74f810aba5d28a17b9989 Mon Sep 17 00:00:00 2001
From: David Miller <davem@davemloft.net>
Date: Tue, 7 Apr 2015 23:05:42 -0400
Subject: [PATCH 4/9] netfilter: Fix switch statement warnings with recent gcc.
Subject: [PATCH 3/8] netfilter: Fix switch statement warnings with recent gcc.
More recent GCC warns about two kinds of switch statement uses:
@ -26,7 +26,7 @@ Acked-by: Pablo Neira Ayuso <pablo@netfilter.org>
5 files changed, 17 insertions(+), 3 deletions(-)
diff --git a/net/bridge/netfilter/nft_reject_bridge.c b/net/bridge/netfilter/nft_reject_bridge.c
index 48da2c5..6a10b88 100644
index 48da2c54a69e..6a10b88f3371 100644
--- a/net/bridge/netfilter/nft_reject_bridge.c
+++ b/net/bridge/netfilter/nft_reject_bridge.c
@@ -375,6 +375,8 @@ static int nft_reject_bridge_dump(struct sk_buff *skb,
@ -39,7 +39,7 @@ index 48da2c5..6a10b88 100644
return 0;
diff --git a/net/ipv4/netfilter/nft_reject_ipv4.c b/net/ipv4/netfilter/nft_reject_ipv4.c
index ed33299..95fe37c 100644
index ed33299c56d1..95fe37c72b32 100644
--- a/net/ipv4/netfilter/nft_reject_ipv4.c
+++ b/net/ipv4/netfilter/nft_reject_ipv4.c
@@ -32,6 +32,8 @@ void nft_reject_ipv4_eval(const struct nft_expr *expr,
@ -52,7 +52,7 @@ index ed33299..95fe37c 100644
data[NFT_REG_VERDICT].verdict = NF_DROP;
diff --git a/net/ipv6/netfilter/nft_reject_ipv6.c b/net/ipv6/netfilter/nft_reject_ipv6.c
index 0bc19fa..367bd48 100644
index 0bc19fa87821..367bd4841a0c 100644
--- a/net/ipv6/netfilter/nft_reject_ipv6.c
+++ b/net/ipv6/netfilter/nft_reject_ipv6.c
@@ -34,6 +34,8 @@ void nft_reject_ipv6_eval(const struct nft_expr *expr,
@ -65,7 +65,7 @@ index 0bc19fa..367bd48 100644
data[NFT_REG_VERDICT].verdict = NF_DROP;
diff --git a/net/netfilter/nft_compat.c b/net/netfilter/nft_compat.c
index 265e190..6595dd1 100644
index 265e190f2218..6595dd163b88 100644
--- a/net/netfilter/nft_compat.c
+++ b/net/netfilter/nft_compat.c
@@ -274,11 +274,11 @@ static void nft_match_eval(const struct nft_expr *expr,
@ -84,7 +84,7 @@ index 265e190..6595dd1 100644
break;
}
diff --git a/net/netfilter/nft_ct.c b/net/netfilter/nft_ct.c
index cc56030..18d520e 100644
index cc5603016242..18d520e0ca0a 100644
--- a/net/netfilter/nft_ct.c
+++ b/net/netfilter/nft_ct.c
@@ -56,6 +56,8 @@ static void nft_ct_get_eval(const struct nft_expr *expr,
@ -124,5 +124,5 @@ index cc56030..18d520e 100644
}
--
2.10.2
2.13.0

View file

@ -1,7 +1,7 @@
From 0d93c60e0137b227cf26c139b9560243baab07ec Mon Sep 17 00:00:00 2001
From bd4a2deebae87cff9b9462cd08b3ec6af76ad384 Mon Sep 17 00:00:00 2001
From: Chen Gang <gang.chen.5i5j@gmail.com>
Date: Wed, 24 Dec 2014 23:04:54 +0800
Subject: [PATCH 5/9] netfilter: nfnetlink_cthelper: Remove 'const' and '&' to
Subject: [PATCH 4/8] netfilter: nfnetlink_cthelper: Remove 'const' and '&' to
avoid warnings
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -44,7 +44,7 @@ Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/netfilter/nfnetlink_cthelper.c b/net/netfilter/nfnetlink_cthelper.c
index 9e287cb..a5599fc 100644
index 9e287cb56a04..a5599fc51a6f 100644
--- a/net/netfilter/nfnetlink_cthelper.c
+++ b/net/netfilter/nfnetlink_cthelper.c
@@ -86,7 +86,7 @@ nfnl_cthelper_parse_tuple(struct nf_conntrack_tuple *tuple,
@ -66,5 +66,5 @@ index 9e287cb..a5599fc 100644
}
--
2.10.2
2.13.0

View file

@ -1,7 +1,7 @@
From 46c3c433ed22addff1b8dc3a820381d0a166f668 Mon Sep 17 00:00:00 2001
From 412e403b486388f47a399bc791070726e1b6c743 Mon Sep 17 00:00:00 2001
From: "David S. Miller" <davem@davemloft.net>
Date: Mon, 27 Apr 2015 13:20:34 -0400
Subject: [PATCH 6/9] netfilter; Add some missing default cases to switch
Subject: [PATCH 5/8] netfilter; Add some missing default cases to switch
statements in nft_reject.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
@ -30,7 +30,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
2 files changed, 4 insertions(+)
diff --git a/net/netfilter/nft_reject.c b/net/netfilter/nft_reject.c
index 57d3e1a..0522fc9 100644
index 57d3e1af5630..0522fc9bfb0a 100644
--- a/net/netfilter/nft_reject.c
+++ b/net/netfilter/nft_reject.c
@@ -63,6 +63,8 @@ int nft_reject_dump(struct sk_buff *skb, const struct nft_expr *expr)
@ -43,7 +43,7 @@ index 57d3e1a..0522fc9 100644
return 0;
diff --git a/net/netfilter/nft_reject_inet.c b/net/netfilter/nft_reject_inet.c
index 7b5f9d5..1fb065a 100644
index 7b5f9d58680a..1fb065a77474 100644
--- a/net/netfilter/nft_reject_inet.c
+++ b/net/netfilter/nft_reject_inet.c
@@ -105,6 +105,8 @@ static int nft_reject_inet_dump(struct sk_buff *skb,
@ -56,5 +56,5 @@ index 7b5f9d5..1fb065a 100644
return 0;
--
2.10.2
2.13.0

View file

@ -1,7 +1,7 @@
From cb4a97a3f63b9d08d8cc87d843123ca16da98be0 Mon Sep 17 00:00:00 2001
From 6d8ab10cd86d3936072b0099b5b879074840c0ac Mon Sep 17 00:00:00 2001
From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Sat, 29 Oct 2016 12:04:40 -0600
Subject: [PATCH 7/9] usbtv: remove unused variable
Subject: [PATCH 6/8] usbtv: remove unused variable
Signed-off-by: Kevin Mihelich <kevin@archlinuxarm.org>
---
@ -9,7 +9,7 @@ Signed-off-by: Kevin Mihelich <kevin@archlinuxarm.org>
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/media/usb/usbtv/usbtv-video.c b/drivers/media/usb/usbtv/usbtv-video.c
index a5eb726..4f450c6 100644
index a5eb726b2a0f..4f450c61ea74 100644
--- a/drivers/media/usb/usbtv/usbtv-video.c
+++ b/drivers/media/usb/usbtv/usbtv-video.c
@@ -602,7 +602,7 @@ static int usbtv_queue_setup(struct vb2_queue *vq,
@ -22,5 +22,5 @@ index a5eb726..4f450c6 100644
if (*nbuffers < 2)
--
2.10.2
2.13.0

View file

@ -1,14 +1,14 @@
From 4cd89a74933fab10ac1f72601b05ce45dce6356f Mon Sep 17 00:00:00 2001
From b97d0ae34150c75903b645bf49636e67bdd44f46 Mon Sep 17 00:00:00 2001
From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Thu, 26 May 2016 06:29:07 -0600
Subject: [PATCH 8/9] add extra errata 843419 build flags
Subject: [PATCH 7/8] add extra errata 843419 build flags
---
arch/arm64/Makefile | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile
index b7da5c3..5e27fa3 100644
index b7da5c34aac1..5e27fa3850c8 100644
--- a/arch/arm64/Makefile
+++ b/arch/arm64/Makefile
@@ -35,6 +35,7 @@ CHECKFLAGS += -D__aarch64__
@ -20,5 +20,5 @@ index b7da5c3..5e27fa3 100644
# Default value
--
2.10.2
2.13.0

View file

@ -1,7 +1,7 @@
From dc5f66d51c1959806cddf9d05093fb75273f887a Mon Sep 17 00:00:00 2001
From 2c8e7b746adc1a27a5c4232e005074ff8a5f78f1 Mon Sep 17 00:00:00 2001
From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Sat, 5 Nov 2016 15:28:36 -0600
Subject: [PATCH 9/9] Downgrade mmc1 speed
Subject: [PATCH 8/8] Downgrade mmc1 speed
200MHz causes errors reading the card and filesystem corruption.
@ -11,10 +11,10 @@ Signed-off-by: Kevin Mihelich <kevin@archlinuxarm.org>
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/boot/dts/mediatek/mt8173-oak.dtsi b/arch/arm64/boot/dts/mediatek/mt8173-oak.dtsi
index 476ea16..c79cdbf 100644
index d64da67ef24d..b6e1835307e8 100644
--- a/arch/arm64/boot/dts/mediatek/mt8173-oak.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8173-oak.dtsi
@@ -418,10 +418,10 @@
@@ -420,10 +420,10 @@
pinctrl-0 = <&mmc1_pins_default>;
pinctrl-1 = <&mmc1_pins_uhs>;
bus-width = <4>;
@ -28,5 +28,5 @@ index 476ea16..c79cdbf 100644
wp-gpios = <&pio 42 GPIO_ACTIVE_HIGH>;
vmmc-supply = <&mt6397_vmch_reg>;
--
2.10.2
2.13.0

View file

@ -7,8 +7,8 @@ pkgbase=linux-oak
_kernelname=${pkgbase#linux}
_desc="Oak Chromebooks"
pkgver=3.18.0
pkgrel=7
_commit=5dd2f9ce6c44dab605b3614b5ae4a27a3d0c565e
pkgrel=8
_commit=d57fda44257ae0e898a530d9537e65f3a74ef861
arch=('aarch64')
url="https://chromium.googlesource.com/chromiumos/third_party/kernel/+/chromeos-3.18"
license=('GPL2')
@ -17,29 +17,27 @@ options=('!strip')
source=("https://chromium.googlesource.com/chromiumos/third_party/kernel/+archive/${_commit}.tar.gz"
'0001-kbuild-move-Wunused-const-variable-to-W-1-warning-le.patch'
'0002-md-fix-a-build-warning.patch'
'0003-ath9k-fix-buffer-overrun-for-ar9287.patch'
'0004-netfilter-Fix-switch-statement-warnings-with-recent-.patch'
'0005-netfilter-nfnetlink_cthelper-Remove-const-and-to-avo.patch'
'0006-netfilter-Add-some-missing-default-cases-to-switch-s.patch'
'0007-usbtv-remove-unused-variable.patch'
'0008-add-extra-errata-843419-build-flags.patch'
'0009-Downgrade-mmc1-speed.patch'
'0003-netfilter-Fix-switch-statement-warnings-with-recent-.patch'
'0004-netfilter-nfnetlink_cthelper-Remove-const-and-to-avo.patch'
'0005-netfilter-Add-some-missing-default-cases-to-switch-s.patch'
'0006-usbtv-remove-unused-variable.patch'
'0007-add-extra-errata-843419-build-flags.patch'
'0008-Downgrade-mmc1-speed.patch'
'config'
'kernel.its'
'kernel.keyblock'
'kernel_data_key.vbprivk'
'cmdline')
md5sums=('fe9dfbf734de4ba872c384830e405d8a'
'651be13e7d7f49db4bfe0ef5f21ffee3'
'843053a21da143004ae06ce7ef8f85e1'
'e4fd093922d688d35a0c6f1a045b75f5'
'234d57c4e23e091600dceb8831a42c62'
'f32a108e5bb0f8a1a0e8089cc7e6d445'
'3b08c86ebec9efcc6ed761a7aa3fb61a'
'92b754e3b482dfed1d3224d033cb2e6d'
'6426e55bd8d4a416bd3e937aef4ea4f4'
'cb5d65e711aa4410f5ab7646632b8a21'
'72d24931ad8506cab289ac4e28026dd7'
md5sums=('2ddf0c97acb2f1a9b4a37c3428d21f23'
'903af17c4197ed26845b6435caeeee5e'
'1f557baf555c190b455234db053dd6c6'
'd009d824fe0350cbba32de5d9f7b2006'
'b2a7517e8f996e2e48318fcc210ef913'
'fad90f4bb981ada9cd9db60c71e6466c'
'cbfbaee600b4d53c08630bee6ce8ffcb'
'2f87e4803fb113fd9fbc948b356d3c9d'
'c522b9ddd7d58e17621c5e8e5c00eec3'
'8acf55cbebd9c56d34186dfd27b6fe97'
'aef13cb59516e9313cb8947350f717d6'
'61c5ff73c136ed07a7aadbf58db3d96a'
'584777ae88bce2c5659960151b64c7d8'
@ -48,13 +46,12 @@ md5sums=('fe9dfbf734de4ba872c384830e405d8a'
prepare() {
git apply 0001-kbuild-move-Wunused-const-variable-to-W-1-warning-le.patch
git apply 0002-md-fix-a-build-warning.patch
git apply 0003-ath9k-fix-buffer-overrun-for-ar9287.patch
git apply 0004-netfilter-Fix-switch-statement-warnings-with-recent-.patch
git apply 0005-netfilter-nfnetlink_cthelper-Remove-const-and-to-avo.patch
git apply 0006-netfilter-Add-some-missing-default-cases-to-switch-s.patch
git apply 0007-usbtv-remove-unused-variable.patch
git apply 0008-add-extra-errata-843419-build-flags.patch
git apply 0009-Downgrade-mmc1-speed.patch
git apply 0003-netfilter-Fix-switch-statement-warnings-with-recent-.patch
git apply 0004-netfilter-nfnetlink_cthelper-Remove-const-and-to-avo.patch
git apply 0005-netfilter-Add-some-missing-default-cases-to-switch-s.patch
git apply 0006-usbtv-remove-unused-variable.patch
git apply 0007-add-extra-errata-843419-build-flags.patch
git apply 0008-Downgrade-mmc1-speed.patch
cp config .config

View file

@ -1,6 +1,6 @@
#
# Automatically generated file; DO NOT EDIT.
# Linux/arm64 3.18.0-7 Kernel Configuration
# Linux/arm64 3.18.0-8 Kernel Configuration
#
CONFIG_ARM64=y
CONFIG_64BIT=y
@ -1119,6 +1119,8 @@ CONFIG_BT_HCIUART_3WIRE=y
CONFIG_BT_HCIUART_INTEL=y
# CONFIG_BT_HCIUART_BCM is not set
# CONFIG_BT_HCIUART_QCA is not set
# CONFIG_BT_HCIUART_AG6XX is not set
# CONFIG_BT_HCIUART_MRVL is not set
CONFIG_BT_HCIBCM203X=m
CONFIG_BT_HCIBPA10X=m
CONFIG_BT_HCIBFUSB=m
@ -3101,6 +3103,7 @@ CONFIG_DRM_PANEL_SIMPLE=y
# CONFIG_DRM_PANEL_S6E8AA0 is not set
# CONFIG_DRM_PANEL_JDI_LPM102A188A is not set
# CONFIG_DRM_POWERVR_ROGUE is not set
# CONFIG_DRM_POWERVR_ROGUE_1_7 is not set
CONFIG_DRM_MEDIATEK=y
CONFIG_DRM_MEDIATEK_HDMI=y