Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
4e953a21
K
Kernel
项目概览
openeuler
/
Kernel
1 年多 前同步成功
通知
8
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
4e953a21
编写于
9月 27, 2007
作者:
J
Jeff Garzik
提交者:
Jens Axboe
10月 10, 2007
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
drivers/block/umem: trim trailing whitespace
Signed-off-by:
N
Jeff Garzik
<
jeff@garzik.org
>
上级
ee4a7b68
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
18 addition
and
18 deletion
+18
-18
drivers/block/umem.c
drivers/block/umem.c
+11
-11
drivers/block/umem.h
drivers/block/umem.h
+7
-7
未找到文件。
drivers/block/umem.c
浏览文件 @
4e953a21
...
...
@@ -293,7 +293,7 @@ static void mm_start_io(struct cardinfo *card)
desc
->
control_bits
&=
~
cpu_to_le32
(
DMASCR_CHAIN_EN
);
desc
->
sem_control_bits
=
desc
->
control_bits
;
if
(
debug
&
DEBUG_LED_ON_TRANSFER
)
set_led
(
card
,
LED_REMOVE
,
LED_ON
);
...
...
@@ -327,7 +327,7 @@ static int add_bio(struct cardinfo *card);
static
void
activate
(
struct
cardinfo
*
card
)
{
/* if No page is Active, and Ready is
/* if No page is Active, and Ready is
* not empty, then switch Ready page
* to active and start IO.
* Then add any bh's that are available to Ready
...
...
@@ -366,7 +366,7 @@ static void mm_unplug_device(struct request_queue *q)
spin_unlock_irqrestore
(
&
card
->
lock
,
flags
);
}
/*
/*
* If there is room on Ready page, take
* one bh off list and add it.
* return 1 if there was room, else 0.
...
...
@@ -467,7 +467,7 @@ static void process_page(unsigned long data)
if
(
card
->
Active
<
0
)
goto
out_unlock
;
page
=
&
card
->
mm_pages
[
card
->
Active
];
while
(
page
->
headcnt
<
page
->
cnt
)
{
struct
bio
*
bio
=
page
->
bio
;
struct
mm_dma_desc
*
desc
=
&
page
->
desc
[
page
->
headcnt
];
...
...
@@ -477,7 +477,7 @@ static void process_page(unsigned long data)
if
(
!
(
control
&
DMASCR_DMA_COMPLETE
))
{
control
=
dma_status
;
last
=
1
;
last
=
1
;
}
page
->
headcnt
++
;
idx
=
page
->
idx
;
...
...
@@ -487,7 +487,7 @@ static void process_page(unsigned long data)
page
->
idx
=
page
->
bio
->
bi_idx
;
}
pci_unmap_page
(
card
->
dev
,
desc
->
data_dma_handle
,
pci_unmap_page
(
card
->
dev
,
desc
->
data_dma_handle
,
bio_iovec_idx
(
bio
,
idx
)
->
bv_len
,
(
control
&
DMASCR_TRANSFER_READ
)
?
PCI_DMA_TODEVICE
:
PCI_DMA_FROMDEVICE
);
...
...
@@ -592,7 +592,7 @@ HW_TRACE(0x30);
else
writeb
((
DMASCR_DMA_COMPLETE
|
DMASCR_CHAIN_COMPLETE
)
>>
16
,
card
->
csr_remap
+
DMA_STATUS_CTRL
+
2
);
/* log errors and clear interrupt status */
if
(
dma_status
&
DMASCR_ANY_ERR
)
{
unsigned
int
data_log1
,
data_log2
;
...
...
@@ -668,7 +668,7 @@ HW_TRACE(0x30);
HW_TRACE
(
0x36
);
return
IRQ_HANDLED
;
return
IRQ_HANDLED
;
}
/*
-----------------------------------------------------------------------------------
...
...
@@ -761,7 +761,7 @@ static void check_all_batteries(unsigned long ptr)
{
int
i
;
for
(
i
=
0
;
i
<
num_cards
;
i
++
)
for
(
i
=
0
;
i
<
num_cards
;
i
++
)
if
(
!
(
cards
[
i
].
flags
&
UM_FLAG_NO_BATT
))
{
struct
cardinfo
*
card
=
&
cards
[
i
];
spin_lock_bh
(
&
card
->
lock
);
...
...
@@ -972,7 +972,7 @@ static int __devinit mm_pci_probe(struct pci_dev *dev, const struct pci_device_i
tasklet_init
(
&
card
->
tasklet
,
process_page
,
(
unsigned
long
)
card
);
card
->
check_batteries
=
0
;
mem_present
=
readb
(
card
->
csr_remap
+
MEMCTRLSTATUS_MEMORY
);
switch
(
mem_present
)
{
case
MEM_128_MB
:
...
...
@@ -1005,7 +1005,7 @@ static int __devinit mm_pci_probe(struct pci_dev *dev, const struct pci_device_i
card
->
battery
[
1
].
good
=
!
(
batt_status
&
BATTERY_2_FAILURE
);
card
->
battery
[
0
].
last_change
=
card
->
battery
[
1
].
last_change
=
jiffies
;
if
(
card
->
flags
&
UM_FLAG_NO_BATT
)
if
(
card
->
flags
&
UM_FLAG_NO_BATT
)
dev_printk
(
KERN_INFO
,
&
card
->
dev
->
dev
,
"Size %d KB
\n
"
,
card
->
mm_size
);
else
{
...
...
drivers/block/umem.h
浏览文件 @
4e953a21
...
...
@@ -87,13 +87,13 @@
#define DMASCR_DMA_COMPLETE 0x40000
#define DMASCR_CHAIN_COMPLETE 0x80000
/*
3.SOME PCs HAVE HOST BRIDGES WHICH APPARENTLY DO NOT CORRECTLY HANDLE
READ-LINE (0xE) OR READ-MULTIPLE (0xC) PCI COMMAND CODES DURING DMA
TRANSFERS. IN OTHER SYSTEMS THESE COMMAND CODES WILL CAUSE THE HOST BRIDGE
TO ALLOW LONGER BURSTS DURING DMA READ OPERATIONS. THE UPPER FOUR BITS
(31..28) OF THE DMA CSR HAVE BEEN MADE PROGRAMMABLE, SO THAT EITHER A 0x6,
AN 0xE OR A 0xC CAN BE WRITTEN TO THEM TO SET THE COMMAND CODE USED DURING
/*
3.SOME PCs HAVE HOST BRIDGES WHICH APPARENTLY DO NOT CORRECTLY HANDLE
READ-LINE (0xE) OR READ-MULTIPLE (0xC) PCI COMMAND CODES DURING DMA
TRANSFERS. IN OTHER SYSTEMS THESE COMMAND CODES WILL CAUSE THE HOST BRIDGE
TO ALLOW LONGER BURSTS DURING DMA READ OPERATIONS. THE UPPER FOUR BITS
(31..28) OF THE DMA CSR HAVE BEEN MADE PROGRAMMABLE, SO THAT EITHER A 0x6,
AN 0xE OR A 0xC CAN BE WRITTEN TO THEM TO SET THE COMMAND CODE USED DURING
DMA READ OPERATIONS.
*/
#define DMASCR_READ 0x60000000
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录