Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OS
U-Boot.Mirror
提交
ba9b42c8
U
U-Boot.Mirror
项目概览
OS
/
U-Boot.Mirror
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
U-Boot.Mirror
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
ba9b42c8
编写于
6月 24, 2014
作者:
T
Tom Rini
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'sandbox' of
git://git.denx.de/u-boot-x86
上级
19198f8b
1638d980
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
39 addition
and
18 deletion
+39
-18
arch/sandbox/cpu/os.c
arch/sandbox/cpu/os.c
+1
-0
arch/sandbox/include/asm/bitops.h
arch/sandbox/include/asm/bitops.h
+3
-2
arch/sandbox/include/asm/system.h
arch/sandbox/include/asm/system.h
+1
-4
arch/x86/config.mk
arch/x86/config.mk
+3
-2
arch/x86/cpu/config.mk
arch/x86/cpu/config.mk
+1
-1
common/cmd_sandbox.c
common/cmd_sandbox.c
+6
-4
disk/part.c
disk/part.c
+19
-0
test/command_ut.c
test/command_ut.c
+4
-4
test/vboot/vboot_test.sh
test/vboot/vboot_test.sh
+1
-1
未找到文件。
arch/sandbox/cpu/os.c
浏览文件 @
ba9b42c8
...
...
@@ -341,6 +341,7 @@ int os_dirent_ls(const char *dirname, struct os_dirent_node **headp)
ret
=
-
ENOMEM
;
goto
done
;
}
next
->
next
=
NULL
;
strcpy
(
next
->
name
,
entry
.
d_name
);
switch
(
entry
.
d_type
)
{
case
DT_REG
:
...
...
arch/sandbox/include/asm/bitops.h
浏览文件 @
ba9b42c8
...
...
@@ -17,6 +17,7 @@
#ifndef __ASM_SANDBOX_BITOPS_H
#define __ASM_SANDBOX_BITOPS_H
#include <linux/compiler.h>
#include <asm/system.h>
#ifdef __KERNEL__
...
...
@@ -53,7 +54,7 @@ static inline int __test_and_set_bit(int nr, void *addr)
static
inline
int
test_and_set_bit
(
int
nr
,
void
*
addr
)
{
unsigned
long
flags
;
unsigned
long
__always_unused
flags
;
int
out
;
local_irq_save
(
flags
);
...
...
@@ -75,7 +76,7 @@ static inline int __test_and_clear_bit(int nr, void *addr)
static
inline
int
test_and_clear_bit
(
int
nr
,
void
*
addr
)
{
unsigned
long
flags
;
unsigned
long
__always_unused
flags
;
int
out
;
local_irq_save
(
flags
);
...
...
arch/sandbox/include/asm/system.h
浏览文件 @
ba9b42c8
...
...
@@ -8,10 +8,7 @@
#define __ASM_SANDBOX_SYSTEM_H
/* Define this as nops for sandbox architecture */
static
inline
void
local_irq_save
(
unsigned
flags
__attribute__
((
unused
)))
{
}
#define local_irq_save(x)
#define local_irq_enable()
#define local_irq_disable()
#define local_save_flags(x)
...
...
arch/x86/config.mk
浏览文件 @
ba9b42c8
...
...
@@ -16,17 +16,18 @@ PF_CPPFLAGS_X86 := $(call cc-option, -fno-toplevel-reorder, \
PLATFORM_CPPFLAGS
+=
$(PF_CPPFLAGS_X86)
PLATFORM_CPPFLAGS
+=
-fno-dwarf2-cfi-asm
PLATFORM_CPPFLAGS
+=
-DREALMODE_BASE
=
0x7c0
PLATFORM_CPPFLAGS
+=
-march
=
i386
-m32
# Support generic board on x86
__HAVE_ARCH_GENERIC_BOARD
:=
y
PLATFORM_RELFLAGS
+=
-ffunction-sections
-fvisibility
=
hidden
PLATFORM_LDFLAGS
+=
--emit-relocs
-Bsymbolic
-Bsymbolic-functions
PLATFORM_LDFLAGS
+=
--emit-relocs
-Bsymbolic
-Bsymbolic-functions
-m
elf_i386
LDFLAGS_FINAL
+=
--gc-sections
-pie
LDFLAGS_FINAL
+=
--wrap
=
__divdi3
--wrap
=
__udivdi3
LDFLAGS_FINAL
+=
--wrap
=
__moddi3
--wrap
=
__umoddi3
export
NORMAL_LIBGCC
=
$(
shell
$(CC)
$(
C
FLAGS)
-print-libgcc-file-name
)
export
NORMAL_LIBGCC
=
$(
shell
$(CC)
$(
PLATFORM_CPP
FLAGS)
-print-libgcc-file-name
)
CONFIG_USE_PRIVATE_LIBGCC
:=
arch
/x86/lib
arch/x86/cpu/config.mk
浏览文件 @
ba9b42c8
...
...
@@ -7,7 +7,7 @@
CROSS_COMPILE
?=
i386-linux-
PLATFORM_CPPFLAGS
+=
-DCONFIG_X86
-D__I386__
-
march
=
i386
-
Werror
PLATFORM_CPPFLAGS
+=
-DCONFIG_X86
-D__I386__
-Werror
# DO NOT MODIFY THE FOLLOWING UNLESS YOU REALLY KNOW WHAT YOU ARE DOING!
LDPPFLAGS
+=
-DRESET_SEG_START
=
0xffff0000
...
...
common/cmd_sandbox.c
浏览文件 @
ba9b42c8
...
...
@@ -114,11 +114,13 @@ static int do_sandbox(cmd_tbl_t *cmdtp, int flag, int argc,
U_BOOT_CMD
(
sb
,
8
,
1
,
do_sandbox
,
"Miscellaneous sandbox commands"
,
"load host
<dev>
<addr> <filename> [<bytes> <offset>] - "
"load host
fs -
<addr> <filename> [<bytes> <offset>] - "
"load a file from host
\n
"
"sb ls host
<filename>
- list files on host
\n
"
"sb save host
<dev>
<filename> <addr> <bytes> [<offset>] - "
"sb ls host
fs - <filename>
- list files on host
\n
"
"sb save host
fs -
<filename> <addr> <bytes> [<offset>] - "
"save a file to host
\n
"
"sb bind <dev> [<filename>] - bind
\"
host
\"
device to file
\n
"
"sb info [<dev>] - show device binding & info"
"sb info [<dev>] - show device binding & info
\n
"
"sb commands use the
\"
hostfs
\"
device. The
\"
host
\"
device is used
\n
"
"with standard IO commands such as fatls or ext2load"
);
disk/part.c
浏览文件 @
ba9b42c8
...
...
@@ -510,6 +510,25 @@ int get_device_and_partition(const char *ifname, const char *dev_part_str,
int
part
;
disk_partition_t
tmpinfo
;
/*
* Special-case a psuedo block device "hostfs", to allow access to the
* host's own filesystem.
*/
if
(
0
==
strcmp
(
ifname
,
"hostfs"
))
{
*
dev_desc
=
NULL
;
info
->
start
=
0
;
info
->
size
=
0
;
info
->
blksz
=
0
;
info
->
bootable
=
0
;
strcpy
((
char
*
)
info
->
type
,
BOOT_PART_TYPE
);
strcpy
((
char
*
)
info
->
name
,
"Sandbox host"
);
#ifdef CONFIG_PARTITION_UUIDS
info
->
uuid
[
0
]
=
0
;
#endif
return
0
;
}
/* If no dev_part_str, use bootdevice environment variable */
if
(
!
dev_part_str
||
!
strlen
(
dev_part_str
)
||
!
strcmp
(
dev_part_str
,
"-"
))
...
...
test/command_ut.c
浏览文件 @
ba9b42c8
...
...
@@ -165,12 +165,12 @@ static int do_ut_cmd(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
#ifdef CONFIG_SANDBOX
/* File existence */
HUSH_TEST
(
e
,
"-e host - creating_this_file_breaks_uboot_unit_test"
,
n
);
run_command
(
"sb save host - creating_this_file_breaks_uboot_unit_test 0 1"
,
0
);
HUSH_TEST
(
e
,
"-e host - creating_this_file_breaks_uboot_unit_test"
,
y
);
HUSH_TEST
(
e
,
"-e host
fs
- creating_this_file_breaks_uboot_unit_test"
,
n
);
run_command
(
"sb save host
fs
- creating_this_file_breaks_uboot_unit_test 0 1"
,
0
);
HUSH_TEST
(
e
,
"-e host
fs
- creating_this_file_breaks_uboot_unit_test"
,
y
);
/* Perhaps this could be replaced by an "rm" shell command one day */
assert
(
!
os_unlink
(
"creating_this_file_breaks_uboot_unit_test"
));
HUSH_TEST
(
e
,
"-e host - creating_this_file_breaks_uboot_unit_test"
,
n
);
HUSH_TEST
(
e
,
"-e host
fs
- creating_this_file_breaks_uboot_unit_test"
,
n
);
#endif
#endif
...
...
test/vboot/vboot_test.sh
浏览文件 @
ba9b42c8
...
...
@@ -14,7 +14,7 @@ set -e
run_uboot
()
{
echo
-n
"Test Verified Boot Run:
$1
: "
${
uboot
}
-d
sandbox-u-boot.dtb
>
${
tmp
}
-c
'
sb load host
0
100 test.fit;
sb load host
fs -
100 test.fit;
fdt addr 100;
bootm 100;
reset'
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录