1
2
3
4
5
6
7
8
9
10#include <linux/pci.h>
11#include <linux/iommu.h>
12#include <linux/debugfs.h>
13
14struct dentry *iommu_debugfs_dir;
15EXPORT_SYMBOL_GPL(iommu_debugfs_dir);
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31void iommu_debugfs_setup(void)
32{
33 if (!iommu_debugfs_dir) {
34 iommu_debugfs_dir = debugfs_create_dir("iommu", NULL);
35 pr_warn("\n");
36 pr_warn("*************************************************************\n");
37 pr_warn("** NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE **\n");
38 pr_warn("** **\n");
39 pr_warn("** IOMMU DebugFS SUPPORT HAS BEEN ENABLED IN THIS KERNEL **\n");
40 pr_warn("** **\n");
41 pr_warn("** This means that this kernel is built to expose internal **\n");
42 pr_warn("** IOMMU data structures, which may compromise security on **\n");
43 pr_warn("** your system. **\n");
44 pr_warn("** **\n");
45 pr_warn("** If you see this message and you are not debugging the **\n");
46 pr_warn("** kernel, report this immediately to your vendor! **\n");
47 pr_warn("** **\n");
48 pr_warn("** NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE NOTICE **\n");
49 pr_warn("*************************************************************\n");
50 }
51}
52