Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
34cc234f
Commit
34cc234f
authored
Jun 04, 2018
by
Vinod Koul
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'topic/dmatest' into for-linus
parents
535f2960
72ef08bf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
3 deletions
+13
-3
drivers/dma/dmatest.c
drivers/dma/dmatest.c
+13
-3
No files found.
drivers/dma/dmatest.c
View file @
34cc234f
...
...
@@ -468,6 +468,8 @@ static int dmatest_func(void *data)
unsigned
long
long
total_len
=
0
;
u8
align
=
0
;
bool
is_memset
=
false
;
dma_addr_t
*
srcs
;
dma_addr_t
*
dma_pq
;
set_freezable
();
...
...
@@ -551,6 +553,14 @@ static int dmatest_func(void *data)
set_user_nice
(
current
,
10
);
srcs
=
kcalloc
(
src_cnt
,
sizeof
(
dma_addr_t
),
GFP_KERNEL
);
if
(
!
srcs
)
goto
err_dstbuf
;
dma_pq
=
kcalloc
(
dst_cnt
,
sizeof
(
dma_addr_t
),
GFP_KERNEL
);
if
(
!
dma_pq
)
goto
err_srcs_array
;
/*
* src and dst buffers are freed by ourselves below
*/
...
...
@@ -561,7 +571,6 @@ static int dmatest_func(void *data)
&&
!
(
params
->
iterations
&&
total_tests
>=
params
->
iterations
))
{
struct
dma_async_tx_descriptor
*
tx
=
NULL
;
struct
dmaengine_unmap_data
*
um
;
dma_addr_t
srcs
[
src_cnt
];
dma_addr_t
*
dsts
;
unsigned
int
src_off
,
dst_off
,
len
;
...
...
@@ -676,8 +685,6 @@ static int dmatest_func(void *data)
srcs
,
src_cnt
,
len
,
flags
);
else
if
(
thread
->
type
==
DMA_PQ
)
{
dma_addr_t
dma_pq
[
dst_cnt
];
for
(
i
=
0
;
i
<
dst_cnt
;
i
++
)
dma_pq
[
i
]
=
dsts
[
i
]
+
dst_off
;
tx
=
dev
->
device_prep_dma_pq
(
chan
,
dma_pq
,
srcs
,
...
...
@@ -779,6 +786,9 @@ static int dmatest_func(void *data)
runtime
=
ktime_to_us
(
ktime
);
ret
=
0
;
kfree
(
dma_pq
);
err_srcs_array:
kfree
(
srcs
);
err_dstbuf:
for
(
i
=
0
;
thread
->
udsts
[
i
];
i
++
)
kfree
(
thread
->
udsts
[
i
]);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment