Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Staging: comedi: clean up sparse issues in proc.c

The whole file should be converted to use seqfile, if it's even
still needed. Or move to debugfs.

Anyway, I fixed up the minor issues here.

Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: Frank Mori Hess <fmhess@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

+7 -7
+7 -7
drivers/staging/comedi/proc.c
··· 32 32 #include "comedidev.h" 33 33 #include "comedi_fops.h" 34 34 #include <linux/proc_fs.h> 35 - /* #include <linux/string.h> */ 35 + #include <linux/string.h> 36 36 37 - int comedi_read_procmem(char *buf, char **start, off_t offset, int len, 38 - int *eof, void *data) 37 + #ifdef CONFIG_PROC_FS 38 + static int comedi_read(char *buf, char **start, off_t offset, int len, 39 + int *eof, void *data) 39 40 { 40 41 int i; 41 42 int devices_q = 0; ··· 83 82 return l; 84 83 } 85 84 86 - #ifdef CONFIG_PROC_FS 87 85 void comedi_proc_init(void) 88 86 { 89 87 struct proc_dir_entry *comedi_proc; 90 88 91 - comedi_proc = create_proc_entry("comedi", S_IFREG | S_IRUGO, 0); 89 + comedi_proc = create_proc_entry("comedi", S_IFREG | S_IRUGO, NULL); 92 90 if (comedi_proc) 93 - comedi_proc->read_proc = comedi_read_procmem; 91 + comedi_proc->read_proc = comedi_read; 94 92 } 95 93 96 94 void comedi_proc_cleanup(void) 97 95 { 98 - remove_proc_entry("comedi", 0); 96 + remove_proc_entry("comedi", NULL); 99 97 } 100 98 #endif