Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
26cdb67c
cloud-kernel
项目概览
openanolis
/
cloud-kernel
大约 1 年 前同步成功
通知
158
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
26cdb67c
编写于
12月 10, 2008
作者:
D
David Woodhouse
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[MTD] Remove more strange u_intxx_t types
Signed-off-by:
N
David Woodhouse
<
David.Woodhouse@intel.com
>
上级
3854be77
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
15 addition
and
15 deletion
+15
-15
drivers/mtd/mtdconcat.c
drivers/mtd/mtdconcat.c
+1
-1
include/linux/mtd/mtd.h
include/linux/mtd/mtd.h
+13
-13
include/linux/mtd/partitions.h
include/linux/mtd/partitions.h
+1
-1
未找到文件。
drivers/mtd/mtdconcat.c
浏览文件 @
26cdb67c
...
...
@@ -696,7 +696,7 @@ struct mtd_info *mtd_concat_create(struct mtd_info *subdev[], /* subdevices to c
int
i
;
size_t
size
;
struct
mtd_concat
*
concat
;
u
_
int32_t
max_erasesize
,
curr_erasesize
;
uint32_t
max_erasesize
,
curr_erasesize
;
int
num_erase_region
;
printk
(
KERN_NOTICE
"Concatenating MTD devices:
\n
"
);
...
...
include/linux/mtd/mtd.h
浏览文件 @
26cdb67c
...
...
@@ -39,8 +39,8 @@ struct erase_info {
uint64_t
fail_addr
;
u_long
time
;
u_long
retries
;
u
_int
dev
;
u
_int
cell
;
u
nsigned
dev
;
u
nsigned
cell
;
void
(
*
callback
)
(
struct
erase_info
*
self
);
u_long
priv
;
u_char
state
;
...
...
@@ -49,8 +49,8 @@ struct erase_info {
struct
mtd_erase_region_info
{
uint64_t
offset
;
/* At which this region starts, from the beginning of the MTD */
u
_
int32_t
erasesize
;
/* For this region */
u
_
int32_t
numblocks
;
/* Number of blocks of erasesize in this region */
uint32_t
erasesize
;
/* For this region */
uint32_t
numblocks
;
/* Number of blocks of erasesize in this region */
unsigned
long
*
lockmap
;
/* If keeping bitmap of locks */
};
...
...
@@ -102,14 +102,14 @@ struct mtd_oob_ops {
struct
mtd_info
{
u_char
type
;
u
_
int32_t
flags
;
uint32_t
flags
;
uint64_t
size
;
// Total size of the MTD
/* "Major" erase size for the device. Naïve users may take this
* to be the only erase size available, or may use the more detailed
* information below if they desire
*/
u
_
int32_t
erasesize
;
uint32_t
erasesize
;
/* Minimal writable flash unit size. In case of NOR flash it is 1 (even
* though individual bits can be cleared), in case of NAND flash it is
* one NAND page (or half, or one-fourths of it), in case of ECC-ed NOR
...
...
@@ -117,10 +117,10 @@ struct mtd_info {
* Any driver registering a struct mtd_info must ensure a writesize of
* 1 or larger.
*/
u
_
int32_t
writesize
;
uint32_t
writesize
;
u
_
int32_t
oobsize
;
// Amount of OOB data per block (e.g. 16)
u
_
int32_t
oobavail
;
// Available OOB bytes per block
uint32_t
oobsize
;
// Amount of OOB data per block (e.g. 16)
uint32_t
oobavail
;
// Available OOB bytes per block
/*
* If erasesize is a power of 2 then the shift is stored in
...
...
@@ -233,7 +233,7 @@ struct mtd_info {
void
(
*
put_device
)
(
struct
mtd_info
*
mtd
);
};
static
inline
u
_
int32_t
mtd_div_by_eb
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
static
inline
uint32_t
mtd_div_by_eb
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
{
if
(
mtd
->
erasesize_shift
)
return
sz
>>
mtd
->
erasesize_shift
;
...
...
@@ -241,14 +241,14 @@ static inline u_int32_t mtd_div_by_eb(uint64_t sz, struct mtd_info *mtd)
return
sz
;
}
static
inline
u
_
int32_t
mtd_mod_by_eb
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
static
inline
uint32_t
mtd_mod_by_eb
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
{
if
(
mtd
->
erasesize_shift
)
return
sz
&
mtd
->
erasesize_mask
;
return
do_div
(
sz
,
mtd
->
erasesize
);
}
static
inline
u
_
int32_t
mtd_div_by_ws
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
static
inline
uint32_t
mtd_div_by_ws
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
{
if
(
mtd
->
writesize_shift
)
return
sz
>>
mtd
->
writesize_shift
;
...
...
@@ -256,7 +256,7 @@ static inline u_int32_t mtd_div_by_ws(uint64_t sz, struct mtd_info *mtd)
return
sz
;
}
static
inline
u
_
int32_t
mtd_mod_by_ws
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
static
inline
uint32_t
mtd_mod_by_ws
(
uint64_t
sz
,
struct
mtd_info
*
mtd
)
{
if
(
mtd
->
writesize_shift
)
return
sz
&
mtd
->
writesize_mask
;
...
...
include/linux/mtd/partitions.h
浏览文件 @
26cdb67c
...
...
@@ -38,7 +38,7 @@ struct mtd_partition {
char
*
name
;
/* identifier string */
uint64_t
size
;
/* partition size */
uint64_t
offset
;
/* offset within the master MTD space */
u
_
int32_t
mask_flags
;
/* master MTD flags to mask out for this partition */
uint32_t
mask_flags
;
/* master MTD flags to mask out for this partition */
struct
nand_ecclayout
*
ecclayout
;
/* out of band layout for this partition (NAND only)*/
struct
mtd_info
**
mtdp
;
/* pointer to store the MTD object */
};
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录