Commit e9c3815e authored by Vojtech Pavlik's avatar Vojtech Pavlik

Kernel command line [__setup()] parsing fixes in all the input

drivers that use it, except i8042.
parent 3b89dbbd
......@@ -373,21 +373,21 @@ static struct db9 __init *db9_probe(int *config)
}
#ifndef MODULE
int __init db9_setup(char *str)
static int __init db9_setup(char *str)
{
int i, ints[3];
get_options(str, ARRAY_SIZE(ints), ints);
for (i = 0; i <= ints[0] && i < 2; i++) db9[i] = ints[i + 1];
return 1;
}
int __init db9_setup_2(char *str)
static int __init db9_setup_2(char *str)
{
int i, ints[3];
get_options(str, ARRAY_SIZE(ints), ints);
for (i = 0; i <= ints[0] && i < 2; i++) db9_2[i] = ints[i + 1];
return 1;
}
int __init db9_setup_3(char *str)
static int __init db9_setup_3(char *str)
{
int i, ints[3];
get_options(str, ARRAY_SIZE(ints), ints);
......
......@@ -617,21 +617,21 @@ static struct gc __init *gc_probe(int *config)
}
#ifndef MODULE
int __init gc_setup(char *str)
static int __init gc_setup(char *str)
{
int i, ints[7];
get_options(str, ARRAY_SIZE(ints), ints);
for (i = 0; i <= ints[0] && i < 6; i++) gc[i] = ints[i + 1];
return 1;
}
int __init gc_setup_2(char *str)
static int __init gc_setup_2(char *str)
{
int i, ints[7];
get_options(str, ARRAY_SIZE(ints), ints);
for (i = 0; i <= ints[0] && i < 6; i++) gc_2[i] = ints[i + 1];
return 1;
}
int __init gc_setup_3(char *str)
static int __init gc_setup_3(char *str)
{
int i, ints[7];
get_options(str, ARRAY_SIZE(ints), ints);
......
......@@ -208,21 +208,21 @@ static struct tgfx __init *tgfx_probe(int *config)
}
#ifndef MODULE
int __init tgfx_setup(char *str)
static int __init tgfx_setup(char *str)
{
int i, ints[9];
get_options(str, ARRAY_SIZE(ints), ints);
for (i = 0; i <= ints[0] && i < 8; i++) tgfx[i] = ints[i + 1];
return 1;
}
int __init tgfx_setup_2(char *str)
static int __init tgfx_setup_2(char *str)
{
int i, ints[9];
get_options(str, ARRAY_SIZE(ints), ints);
for (i = 0; i <= ints[0] && i < 8; i++) tgfx_2[i] = ints[i + 1];
return 1;
}
int __init tgfx_setup_3(char *str)
static int __init tgfx_setup_3(char *str)
{
int i, ints[9];
get_options(str, ARRAY_SIZE(ints), ints);
......
......@@ -520,14 +520,16 @@ static struct serio_dev atkbd_dev = {
disconnect: atkbd_disconnect
};
/*
* Module init and exit.
*/
void __init atkbd_setup(char *str, int *ints)
#ifndef MODULE
static int __init atkbd_setup(char *str)
{
if (!ints[0]) atkbd_set = ints[1];
int ints[4];
str = get_options(str, ARRAY_SIZE(ints), ints);
if (ints[0] > 0) atkbd_set = ints[1];
return 1;
}
__setup("atkbd_set=", atkbd_setup);
#endif
int __init atkbd_init(void)
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment