From: Greg Kroah-Hartman Date: Thu, 3 Aug 2017 19:39:06 +0000 (-0700) Subject: 4.4-stable patches X-Git-Tag: v4.12.5~38 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d8a1d97e552961b77d6edb48544c8508a95503c5;p=thirdparty%2Fkernel%2Fstable-queue.git 4.4-stable patches added patches: staging-comedi-comedi_fops-avoid-orphaned-proc-entry.patch --- diff --git a/queue-4.4/series b/queue-4.4/series index 5f8b05b2f98..af4684d0f28 100644 --- a/queue-4.4/series +++ b/queue-4.4/series @@ -11,3 +11,4 @@ kvm-ppc-book3s-hv-restore-critical-sprs-to-host-values-on-guest-exit.patch kvm-ppc-book3s-hv-reload-htm-registers-explicitly.patch kvm-ppc-book3s-hv-save-restore-host-values-of-debug-registers.patch revert-powerpc-numa-fix-percpu-allocations-to-be-numa-aware.patch +staging-comedi-comedi_fops-avoid-orphaned-proc-entry.patch diff --git a/queue-4.4/staging-comedi-comedi_fops-avoid-orphaned-proc-entry.patch b/queue-4.4/staging-comedi-comedi_fops-avoid-orphaned-proc-entry.patch new file mode 100644 index 00000000000..eadf24636c1 --- /dev/null +++ b/queue-4.4/staging-comedi-comedi_fops-avoid-orphaned-proc-entry.patch @@ -0,0 +1,42 @@ +From bf279ece37d2a3eaaa9813fcd7a1d8a81eb29c20 Mon Sep 17 00:00:00 2001 +From: Cheah Kok Cheong +Date: Fri, 30 Dec 2016 19:25:52 +0800 +Subject: Staging: comedi: comedi_fops: Avoid orphaned proc entry + +From: Cheah Kok Cheong + +commit bf279ece37d2a3eaaa9813fcd7a1d8a81eb29c20 upstream. + +Move comedi_proc_init to the end to avoid orphaned proc entry +if module loading failed. + +Signed-off-by: Cheah Kok Cheong +Reviewed-by: Ian Abbott +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/staging/comedi/comedi_fops.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +--- a/drivers/staging/comedi/comedi_fops.c ++++ b/drivers/staging/comedi/comedi_fops.c +@@ -2901,9 +2901,6 @@ static int __init comedi_init(void) + + comedi_class->dev_groups = comedi_dev_groups; + +- /* XXX requires /proc interface */ +- comedi_proc_init(); +- + /* create devices files for legacy/manual use */ + for (i = 0; i < comedi_num_legacy_minors; i++) { + struct comedi_device *dev; +@@ -2921,6 +2918,9 @@ static int __init comedi_init(void) + mutex_unlock(&dev->mutex); + } + ++ /* XXX requires /proc interface */ ++ comedi_proc_init(); ++ + return 0; + } + module_init(comedi_init);