Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
61f956f5
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
13
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
raspberrypi-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
61f956f5
编写于
5月 04, 2011
作者:
A
Arnaud Lacombe
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
kconfig: constify `kconf_id_lookup'
Signed-off-by:
N
Arnaud Lacombe
<
lacombar@gmail.com
>
上级
58ef81c5
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
8 addition
and
8 deletion
+8
-8
scripts/kconfig/Makefile
scripts/kconfig/Makefile
+1
-1
scripts/kconfig/zconf.gperf
scripts/kconfig/zconf.gperf
+1
-1
scripts/kconfig/zconf.l
scripts/kconfig/zconf.l
+2
-2
scripts/kconfig/zconf.y
scripts/kconfig/zconf.y
+4
-4
未找到文件。
scripts/kconfig/Makefile
浏览文件 @
61f956f5
...
@@ -356,7 +356,7 @@ lex.%.c: %.l
...
@@ -356,7 +356,7 @@ lex.%.c: %.l
cp
$@
$@
_shipped
cp
$@
$@
_shipped
%.hash.c
:
%.gperf
%.hash.c
:
%.gperf
gperf <
$<
>
$@
gperf
-C
<
$<
>
$@
cp
$@
$@
_shipped
cp
$@
$@
_shipped
endif
endif
scripts/kconfig/zconf.gperf
浏览文件 @
61f956f5
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
struct kconf_id;
struct kconf_id;
static struct kconf_id *kconf_id_lookup(register const char *str, register unsigned int len);
static
const
struct kconf_id *kconf_id_lookup(register const char *str, register unsigned int len);
%%
%%
mainmenu, T_MAINMENU, TF_COMMAND
mainmenu, T_MAINMENU, TF_COMMAND
...
...
scripts/kconfig/zconf.l
浏览文件 @
61f956f5
...
@@ -96,7 +96,7 @@ n [A-Za-z0-9_]
...
@@ -96,7 +96,7 @@ n [A-Za-z0-9_]
<COMMAND>{
<COMMAND>{
{n}+ {
{n}+ {
struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
const
struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
BEGIN(PARAM);
BEGIN(PARAM);
current_pos.file = current_file;
current_pos.file = current_file;
current_pos.lineno = current_file->lineno;
current_pos.lineno = current_file->lineno;
...
@@ -132,7 +132,7 @@ n [A-Za-z0-9_]
...
@@ -132,7 +132,7 @@ n [A-Za-z0-9_]
\n BEGIN(INITIAL); current_file->lineno++; return T_EOL;
\n BEGIN(INITIAL); current_file->lineno++; return T_EOL;
--- /* ignore */
--- /* ignore */
({n}|[-/.])+ {
({n}|[-/.])+ {
struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
const
struct kconf_id *id = kconf_id_lookup(yytext, yyleng);
if (id && id->flags & TF_PARAM) {
if (id && id->flags & TF_PARAM) {
zconflval.id = id;
zconflval.id = id;
return id->token;
return id->token;
...
...
scripts/kconfig/zconf.y
浏览文件 @
61f956f5
...
@@ -25,7 +25,7 @@ extern int zconflex(void);
...
@@ -25,7 +25,7 @@ extern int zconflex(void);
static void zconfprint(const char *err, ...);
static void zconfprint(const char *err, ...);
static void zconf_error(const char *err, ...);
static void zconf_error(const char *err, ...);
static void zconferror(const char *err);
static void zconferror(const char *err);
static bool zconf_endtoken(struct kconf_id *id, int starttoken, int endtoken);
static bool zconf_endtoken(
const
struct kconf_id *id, int starttoken, int endtoken);
struct symbol *symbol_hash[SYMBOL_HASHSIZE];
struct symbol *symbol_hash[SYMBOL_HASHSIZE];
...
@@ -45,7 +45,7 @@ static struct menu *current_menu, *current_entry;
...
@@ -45,7 +45,7 @@ static struct menu *current_menu, *current_entry;
struct symbol *symbol;
struct symbol *symbol;
struct expr *expr;
struct expr *expr;
struct menu *menu;
struct menu *menu;
struct kconf_id *id;
const
struct kconf_id *id;
}
}
%token <id>T_MAINMENU
%token <id>T_MAINMENU
...
@@ -229,7 +229,7 @@ symbol_option_list:
...
@@ -229,7 +229,7 @@ symbol_option_list:
/* empty */
/* empty */
| symbol_option_list T_WORD symbol_option_arg
| symbol_option_list T_WORD symbol_option_arg
{
{
struct kconf_id *id = kconf_id_lookup($2, strlen($2));
const
struct kconf_id *id = kconf_id_lookup($2, strlen($2));
if (id && id->flags & TF_OPTION)
if (id && id->flags & TF_OPTION)
menu_add_option(id->token, $3);
menu_add_option(id->token, $3);
else
else
...
@@ -545,7 +545,7 @@ static const char *zconf_tokenname(int token)
...
@@ -545,7 +545,7 @@ static const char *zconf_tokenname(int token)
return "<token>";
return "<token>";
}
}
static bool zconf_endtoken(struct kconf_id *id, int starttoken, int endtoken)
static bool zconf_endtoken(
const
struct kconf_id *id, int starttoken, int endtoken)
{
{
if (id->token != endtoken) {
if (id->token != endtoken) {
zconf_error("unexpected '%s' within %s block",
zconf_error("unexpected '%s' within %s block",
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录