* [PATCH] include/linux/amd-iommu.h: Move to arch/x86/include/asm
@ 2015-12-26 13:26 chengang
2015-12-28 15:51 ` Joerg Roedel
0 siblings, 1 reply; 3+ messages in thread
From: chengang @ 2015-12-26 13:26 UTC (permalink / raw)
To: akpm, oded.gabbay, airlied, joro, joe, jslaby
Cc: gregkh, davem, mchehab, linux-kernel, dri-devel, Chen Gang,
Chen Gang
From: Chen Gang <chengang@emindsoft.com.cn>
It is architecture specific mechanism header, not generic header, so
move it to arch/x86/include/asm.
ALso change all related contents for it.
Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>
---
MAINTAINERS | 2 +-
{include/linux => arch/x86/include/asm}/amd-iommu.h | 0
drivers/gpu/drm/amd/amdkfd/kfd_device.c | 2 +-
drivers/gpu/drm/amd/amdkfd/kfd_process.c | 2 +-
drivers/iommu/amd_iommu.c | 2 +-
drivers/iommu/amd_iommu_init.c | 2 +-
drivers/iommu/amd_iommu_v2.c | 2 +-
7 files changed, 6 insertions(+), 6 deletions(-)
rename {include/linux => arch/x86/include/asm}/amd-iommu.h (100%)
diff --git a/MAINTAINERS b/MAINTAINERS
index 44666b1..893cf07 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -656,7 +656,7 @@ L: iommu@lists.linux-foundation.org
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
S: Maintained
F: drivers/iommu/amd_iommu*.[ch]
-F: include/linux/amd-iommu.h
+F: arch/x86/include/asm/amd-iommu.h
AMD KFD
M: Oded Gabbay <oded.gabbay@gmail.com>
diff --git a/include/linux/amd-iommu.h b/arch/x86/include/asm/amd-iommu.h
similarity index 100%
rename from include/linux/amd-iommu.h
rename to arch/x86/include/asm/amd-iommu.h
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_device.c b/drivers/gpu/drm/amd/amdkfd/kfd_device.c
index 3f95f7c..bcbbabd 100644
--- a/drivers/gpu/drm/amd/amdkfd/kfd_device.c
+++ b/drivers/gpu/drm/amd/amdkfd/kfd_device.c
@@ -20,7 +20,7 @@
* OTHER DEALINGS IN THE SOFTWARE.
*/
-#include <linux/amd-iommu.h>
+#include <asm/amd-iommu.h>
#include <linux/bsearch.h>
#include <linux/pci.h>
#include <linux/slab.h>
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_process.c b/drivers/gpu/drm/amd/amdkfd/kfd_process.c
index 9be0070..a268799 100644
--- a/drivers/gpu/drm/amd/amdkfd/kfd_process.c
+++ b/drivers/gpu/drm/amd/amdkfd/kfd_process.c
@@ -24,7 +24,7 @@
#include <linux/log2.h>
#include <linux/sched.h>
#include <linux/slab.h>
-#include <linux/amd-iommu.h>
+#include <asm/amd-iommu.h>
#include <linux/notifier.h>
#include <linux/compat.h>
diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c
index 8b2be1e..fea3056 100644
--- a/drivers/iommu/amd_iommu.c
+++ b/drivers/iommu/amd_iommu.c
@@ -28,7 +28,7 @@
#include <linux/iommu-helper.h>
#include <linux/iommu.h>
#include <linux/delay.h>
-#include <linux/amd-iommu.h>
+#include <asm/amd-iommu.h>
#include <linux/notifier.h>
#include <linux/export.h>
#include <linux/irq.h>
diff --git a/drivers/iommu/amd_iommu_init.c b/drivers/iommu/amd_iommu_init.c
index 013bdff..f7eee70 100644
--- a/drivers/iommu/amd_iommu_init.c
+++ b/drivers/iommu/amd_iommu_init.c
@@ -24,7 +24,7 @@
#include <linux/syscore_ops.h>
#include <linux/interrupt.h>
#include <linux/msi.h>
-#include <linux/amd-iommu.h>
+#include <asm/amd-iommu.h>
#include <linux/export.h>
#include <linux/iommu.h>
#include <asm/pci-direct.h>
diff --git a/drivers/iommu/amd_iommu_v2.c b/drivers/iommu/amd_iommu_v2.c
index c865737..e6584fe 100644
--- a/drivers/iommu/amd_iommu_v2.c
+++ b/drivers/iommu/amd_iommu_v2.c
@@ -17,7 +17,7 @@
*/
#include <linux/mmu_notifier.h>
-#include <linux/amd-iommu.h>
+#include <asm/amd-iommu.h>
#include <linux/mm_types.h>
#include <linux/profile.h>
#include <linux/module.h>
--
1.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] include/linux/amd-iommu.h: Move to arch/x86/include/asm
2015-12-26 13:26 [PATCH] include/linux/amd-iommu.h: Move to arch/x86/include/asm chengang
@ 2015-12-28 15:51 ` Joerg Roedel
2015-12-28 20:40 ` Chen Gang
0 siblings, 1 reply; 3+ messages in thread
From: Joerg Roedel @ 2015-12-28 15:51 UTC (permalink / raw)
To: chengang
Cc: akpm, oded.gabbay, airlied, joe, jslaby, gregkh, davem, mchehab,
linux-kernel, dri-devel, Chen Gang
On Sat, Dec 26, 2015 at 09:26:32PM +0800, chengang@emindsoft.com.cn wrote:
> From: Chen Gang <chengang@emindsoft.com.cn>
>
> It is architecture specific mechanism header, not generic header, so
> move it to arch/x86/include/asm.
There might be future non-x86 hardware which also has an amd iommu, so
the header file should stay where it is for now.
Joerg
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] include/linux/amd-iommu.h: Move to arch/x86/include/asm
2015-12-28 15:51 ` Joerg Roedel
@ 2015-12-28 20:40 ` Chen Gang
0 siblings, 0 replies; 3+ messages in thread
From: Chen Gang @ 2015-12-28 20:40 UTC (permalink / raw)
To: Joerg Roedel
Cc: akpm, oded.gabbay, airlied, joe, jslaby, gregkh, davem, mchehab,
linux-kernel, dri-devel
On 12/28/15 23:51, Joerg Roedel wrote:
> On Sat, Dec 26, 2015 at 09:26:32PM +0800, chengang@emindsoft.com.cn wrote:
>>
>> It is architecture specific mechanism header, not generic header, so
>> move it to arch/x86/include/asm.
>
> There might be future non-x86 hardware which also has an amd iommu, so
> the header file should stay where it is for now.
>
For me, amd-iommu.h is architecture specific, for this kind of headers,
if it is used by most of archs, it will be in "include/asm-generic". If
it is used by several archs, it will be in "arch/*/include/asm/".
So for me, at present, it is only used by x86, so is move to "arch/x86/
include/asm/"; if another archs want it, they can copy one. If quite a
few archs (e.g. > 3 archs) need it, move it to "include/asm-generic".
Thanks.
--
Chen Gang (陈刚)
Open, share, and attitude like air, water, and life which God blessed
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-12-28 20:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-12-26 13:26 [PATCH] include/linux/amd-iommu.h: Move to arch/x86/include/asm chengang
2015-12-28 15:51 ` Joerg Roedel
2015-12-28 20:40 ` Chen Gang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox