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
ecb509ec
Commit
ecb509ec
authored
Mar 09, 2014
by
David Woodhouse
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
iommu/vt-d: Remove pdev from iommu_no_mapping()
Signed-off-by:
David Woodhouse
<
David.Woodhouse@intel.com
>
parent
5913c9bf
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
7 deletions
+5
-7
drivers/iommu/intel-iommu.c
drivers/iommu/intel-iommu.c
+5
-7
No files found.
drivers/iommu/intel-iommu.c
View file @
ecb509ec
...
...
@@ -2902,10 +2902,9 @@ static int iommu_dummy(struct device *dev)
return
dev
->
archdata
.
iommu
==
DUMMY_DEVICE_DOMAIN_INFO
;
}
/* Check if the
p
dev needs to go through non-identity map and unmap process.*/
/* Check if the dev needs to go through non-identity map and unmap process.*/
static
int
iommu_no_mapping
(
struct
device
*
dev
)
{
struct
pci_dev
*
pdev
;
int
found
;
if
(
unlikely
(
!
dev_is_pci
(
dev
)))
...
...
@@ -2917,10 +2916,9 @@ static int iommu_no_mapping(struct device *dev)
if
(
!
iommu_identity_mapping
)
return
0
;
pdev
=
to_pci_dev
(
dev
);
found
=
identity_mapping
(
dev
);
if
(
found
)
{
if
(
iommu_should_identity_map
(
&
pdev
->
dev
,
0
))
if
(
iommu_should_identity_map
(
dev
,
0
))
return
1
;
else
{
/*
...
...
@@ -2929,7 +2927,7 @@ static int iommu_no_mapping(struct device *dev)
*/
domain_remove_one_dev_info
(
si_domain
,
dev
);
printk
(
KERN_INFO
"32bit %s uses non-identity mapping
\n
"
,
pci_name
(
p
dev
));
dev_name
(
dev
));
return
0
;
}
}
else
{
...
...
@@ -2937,7 +2935,7 @@ static int iommu_no_mapping(struct device *dev)
* In case of a detached 64 bit DMA device from vm, the device
* is put into si_domain for identity mapping.
*/
if
(
iommu_should_identity_map
(
&
pdev
->
dev
,
0
))
{
if
(
iommu_should_identity_map
(
dev
,
0
))
{
int
ret
;
ret
=
domain_add_dev_info
(
si_domain
,
dev
,
hw_pass_through
?
...
...
@@ -2945,7 +2943,7 @@ static int iommu_no_mapping(struct device *dev)
CONTEXT_TT_MULTI_LEVEL
);
if
(
!
ret
)
{
printk
(
KERN_INFO
"64bit %s uses identity mapping
\n
"
,
pci_name
(
p
dev
));
dev_name
(
dev
));
return
1
;
}
}
...
...
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