From: Greg Kroah-Hartman Date: Thu, 7 Mar 2019 17:44:29 +0000 (+0100) Subject: 4.9-stable patches X-Git-Tag: v5.0.1~32 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=49357e6f9f21128b69d186af537807632a01724f;p=thirdparty%2Fkernel%2Fstable-queue.git 4.9-stable patches added patches: staging-android-ion-fix-sys-heap-pool-s-gfp_flags.patch staging-comedi-ni_660x-fix-missing-break-in-switch-statement.patch staging-wilc1000-fix-to-set-correct-value-for-vif_num.patch --- diff --git a/queue-4.9/series b/queue-4.9/series index 5cfbb87ecc8..b81da5c974d 100644 --- a/queue-4.9/series +++ b/queue-4.9/series @@ -4,3 +4,6 @@ usb-serial-ftdi_sio-add-id-for-hjelmslund-electronics-usb485.patch cpufreq-use-struct-kobj_attribute-instead-of-struct-global_attr.patch ncpfs-fix-build-warning-of-strncpy.patch isdn-isdn_tty-fix-build-warning-of-strncpy.patch +staging-comedi-ni_660x-fix-missing-break-in-switch-statement.patch +staging-wilc1000-fix-to-set-correct-value-for-vif_num.patch +staging-android-ion-fix-sys-heap-pool-s-gfp_flags.patch diff --git a/queue-4.9/staging-android-ion-fix-sys-heap-pool-s-gfp_flags.patch b/queue-4.9/staging-android-ion-fix-sys-heap-pool-s-gfp_flags.patch new file mode 100644 index 00000000000..f053f30dda0 --- /dev/null +++ b/queue-4.9/staging-android-ion-fix-sys-heap-pool-s-gfp_flags.patch @@ -0,0 +1,39 @@ +From 9bcf065e28122588a6cbee08cf847826dacbb438 Mon Sep 17 00:00:00 2001 +From: Qing Xia +Date: Fri, 1 Feb 2019 14:59:46 +0800 +Subject: staging: android: ion: fix sys heap pool's gfp_flags + +From: Qing Xia + +commit 9bcf065e28122588a6cbee08cf847826dacbb438 upstream. + +In the first loop, gfp_flags will be modified to high_order_gfp_flags, +and there will be no chance to change back to low_order_gfp_flags. + +Fixes: e7f63771b60e ("ION: Sys_heap: Add cached pool to spead up cached buffer alloc") +Signed-off-by: Qing Xia +Cc: stable +Signed-off-by: Jing Xia +Reviewed-by: Yuming Han +Reviewed-by: Zhaoyang Huang +Reviewed-by: Orson Zhai +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/staging/android/ion/ion_system_heap.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/drivers/staging/android/ion/ion_system_heap.c ++++ b/drivers/staging/android/ion/ion_system_heap.c +@@ -307,10 +307,10 @@ static int ion_system_heap_create_pools( + bool cached) + { + int i; +- gfp_t gfp_flags = low_order_gfp_flags; + + for (i = 0; i < NUM_ORDERS; i++) { + struct ion_page_pool *pool; ++ gfp_t gfp_flags = low_order_gfp_flags; + + if (orders[i] > 4) + gfp_flags = high_order_gfp_flags; diff --git a/queue-4.9/staging-comedi-ni_660x-fix-missing-break-in-switch-statement.patch b/queue-4.9/staging-comedi-ni_660x-fix-missing-break-in-switch-statement.patch new file mode 100644 index 00000000000..f0a0905222e --- /dev/null +++ b/queue-4.9/staging-comedi-ni_660x-fix-missing-break-in-switch-statement.patch @@ -0,0 +1,35 @@ +From 479826cc86118e0d87e5cefb3df5b748e0480924 Mon Sep 17 00:00:00 2001 +From: "Gustavo A. R. Silva" +Date: Tue, 12 Feb 2019 12:44:50 -0600 +Subject: staging: comedi: ni_660x: fix missing break in switch statement + +From: Gustavo A. R. Silva + +commit 479826cc86118e0d87e5cefb3df5b748e0480924 upstream. + +Add missing break statement in order to prevent the code from falling +through to the default case and return -EINVAL every time. + +This bug was found thanks to the ongoing efforts to enable +-Wimplicit-fallthrough. + +Fixes: aa94f2888825 ("staging: comedi: ni_660x: tidy up ni_660x_set_pfi_routing()") +Cc: stable@vger.kernel.org +Signed-off-by: Gustavo A. R. Silva +Reviewed-by: Ian Abbott +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/staging/comedi/drivers/ni_660x.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/staging/comedi/drivers/ni_660x.c ++++ b/drivers/staging/comedi/drivers/ni_660x.c +@@ -606,6 +606,7 @@ static int ni_660x_set_pfi_routing(struc + case NI_660X_PFI_OUTPUT_DIO: + if (chan > 31) + return -EINVAL; ++ break; + default: + return -EINVAL; + } diff --git a/queue-4.9/staging-wilc1000-fix-to-set-correct-value-for-vif_num.patch b/queue-4.9/staging-wilc1000-fix-to-set-correct-value-for-vif_num.patch new file mode 100644 index 00000000000..9c8adb7c55e --- /dev/null +++ b/queue-4.9/staging-wilc1000-fix-to-set-correct-value-for-vif_num.patch @@ -0,0 +1,37 @@ +From dda037057a572f5c82ac2499eb4e6fb17600ba3e Mon Sep 17 00:00:00 2001 +From: Ajay Singh +Date: Thu, 7 Feb 2019 11:28:58 +0000 +Subject: staging: wilc1000: fix to set correct value for 'vif_num' + +From: Ajay Singh + +commit dda037057a572f5c82ac2499eb4e6fb17600ba3e upstream. + +Set correct value in '->vif_num' for the total number of interfaces and +set '->idx' value using 'i'. + +Fixes: 735bb39ca3be ("staging: wilc1000: simplify vif[i]->ndev accesses") +Fixes: 0e490657c721 ("staging: wilc1000: Fix problem with wrong vif index") +Cc: +Suggested-by: Dan Carpenter +Reviewed-by: Dan Carpenter +Signed-off-by: Greg Kroah-Hartman +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/staging/wilc1000/linux_wlan.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +--- a/drivers/staging/wilc1000/linux_wlan.c ++++ b/drivers/staging/wilc1000/linux_wlan.c +@@ -1263,8 +1263,8 @@ int wilc_netdev_init(struct wilc **wilc, + vif->wilc = *wilc; + vif->ndev = ndev; + wl->vif[i] = vif; +- wl->vif_num = i; +- vif->idx = wl->vif_num; ++ wl->vif_num = i + 1; ++ vif->idx = i; + + ndev->netdev_ops = &wilc_netdev_ops; +