Commit d87731f
iommu/vt-d: debugfs: Create/remove debugfs file per {device, pasid}
Add a debugfs directory per pair of {device, pasid} if the mappings of
its page table are created and destroyed by the iommu_map/unmap()
interfaces. i.e. /sys/kernel/debug/iommu/intel/<device source id>/<pasid>.
Create a debugfs file in the directory for users to dump the page
table corresponding to {device, pasid}. e.g.
/sys/kernel/debug/iommu/intel/0000:00:02.0/1/domain_translation_struct.
For the default domain without pasid, it creates a debugfs file in the
debugfs device directory for users to dump its page table. e.g.
/sys/kernel/debug/iommu/intel/0000:00:02.0/domain_translation_struct.
When setting a domain to a PASID of device, create a debugfs file in
the pasid debugfs directory for users to dump the page table of the
specified pasid. Remove the debugfs device directory of the device
when releasing a device. e.g.
/sys/kernel/debug/iommu/intel/0000:00:01.0
Signed-off-by: Jingqi Liu <Jingqi.liu@intel.com>
Link: https://lore.kernel.org/r/20231013135811.73953-3-Jingqi.liu@intel.com
Signed-off-by: Lu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>1 parent e8aa45f commit d87731f
3 files changed
+69
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
| 114 | + | |
| 115 | + | |
114 | 116 | | |
115 | 117 | | |
116 | 118 | | |
| |||
671 | 673 | | |
672 | 674 | | |
673 | 675 | | |
674 | | - | |
675 | | - | |
| 676 | + | |
676 | 677 | | |
677 | 678 | | |
678 | 679 | | |
679 | 680 | | |
680 | 681 | | |
681 | | - | |
682 | | - | |
683 | | - | |
684 | 682 | | |
685 | 683 | | |
686 | 684 | | |
| |||
690 | 688 | | |
691 | 689 | | |
692 | 690 | | |
| 691 | + | |
| 692 | + | |
| 693 | + | |
| 694 | + | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
| 717 | + | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
| 723 | + | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
| 727 | + | |
| 728 | + | |
| 729 | + | |
| 730 | + | |
| 731 | + | |
| 732 | + | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4425 | 4425 | | |
4426 | 4426 | | |
4427 | 4427 | | |
| 4428 | + | |
| 4429 | + | |
4428 | 4430 | | |
4429 | 4431 | | |
4430 | 4432 | | |
| |||
4434 | 4436 | | |
4435 | 4437 | | |
4436 | 4438 | | |
| 4439 | + | |
4437 | 4440 | | |
4438 | 4441 | | |
4439 | 4442 | | |
| |||
4726 | 4729 | | |
4727 | 4730 | | |
4728 | 4731 | | |
| 4732 | + | |
4729 | 4733 | | |
4730 | 4734 | | |
4731 | 4735 | | |
| |||
4778 | 4782 | | |
4779 | 4783 | | |
4780 | 4784 | | |
| 4785 | + | |
| 4786 | + | |
| 4787 | + | |
4781 | 4788 | | |
4782 | 4789 | | |
4783 | 4790 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
716 | 716 | | |
717 | 717 | | |
718 | 718 | | |
| 719 | + | |
| 720 | + | |
| 721 | + | |
719 | 722 | | |
720 | 723 | | |
721 | 724 | | |
722 | 725 | | |
723 | 726 | | |
724 | 727 | | |
| 728 | + | |
| 729 | + | |
| 730 | + | |
725 | 731 | | |
726 | 732 | | |
727 | 733 | | |
| |||
883 | 889 | | |
884 | 890 | | |
885 | 891 | | |
| 892 | + | |
| 893 | + | |
| 894 | + | |
| 895 | + | |
886 | 896 | | |
887 | 897 | | |
| 898 | + | |
| 899 | + | |
| 900 | + | |
| 901 | + | |
888 | 902 | | |
889 | 903 | | |
890 | 904 | | |
| |||
0 commit comments