patch-2.3.14 linux/drivers/char/ftape/lowlevel/ftape-setup.c

Next file: linux/drivers/char/lp_intern.c
Previous file: linux/drivers/char/defkeymap.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.13/linux/drivers/char/ftape/lowlevel/ftape-setup.c linux/drivers/char/ftape/lowlevel/ftape-setup.c
@@ -60,12 +60,15 @@
 	{ "mach2",     &ft_mach2,          CONFIG_FT_MACH2,          0,     1}
 };
 
-void __init ftape_setup(char *str, int *ints)
+static int __init ftape_setup(char *str)
 {
 	int i;
 	int param;
+	int ints[2];
+
 	TRACE_FUN(ft_t_flow);
 
+	str = get_options(str, ARRAY_SIZE(ints), ints);
 	if (str) {
 		for (i=0; i < NR_ITEMS(config_params); i++) {
 			if (strcmp(str,config_params[i].name) == 0){
@@ -81,13 +84,13 @@
 					      config_params[i].name,
 					      config_params[i].min,
 					      config_params[i].max);
-					TRACE_EXIT;
+					goto out;
 				}
 				if(config_params[i].var) {
 					TRACE(ft_t_info, "%s=%d", str, param);
 					*config_params[i].var = param;
 				}
-				TRACE_EXIT;
+				goto out;
 			}
 		}
 	}
@@ -101,5 +104,8 @@
 	} else {
 		TRACE(ft_t_err, "botched ftape option");
 	}
-	TRACE_EXIT;
+ out:
+	TRACE_EXIT 1;
 }
+
+__setup("ftape=", ftape_setup);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)