@@ -134,8 +134,8 @@ static void __iommu_group_set_domain_nofail(struct iommu_group *group,
134134
135135static int iommu_setup_default_domain (struct iommu_group * group ,
136136 int target_type );
137- static int iommu_create_device_direct_mappings (struct iommu_domain * domain ,
138- struct device * dev );
137+ static int iommu_create_device_fw_mappings (struct iommu_domain * domain ,
138+ struct device * dev );
139139static ssize_t iommu_group_store_type (struct iommu_group * group ,
140140 const char * buf , size_t count );
141141static struct group_device * iommu_group_alloc_device (struct iommu_group * group ,
@@ -641,7 +641,7 @@ static int __iommu_probe_device(struct device *dev, struct list_head *group_list
641641 list_add_tail (& gdev -> list , & group -> devices );
642642 WARN_ON (group -> default_domain && !group -> domain );
643643 if (group -> default_domain )
644- iommu_create_device_direct_mappings (group -> default_domain , dev );
644+ iommu_create_device_fw_mappings (group -> default_domain , dev );
645645 if (group -> domain ) {
646646 ret = __iommu_device_set_domain (group , dev , group -> domain , NULL ,
647647 0 );
@@ -1170,8 +1170,8 @@ int iommu_group_set_name(struct iommu_group *group, const char *name)
11701170}
11711171EXPORT_SYMBOL_GPL (iommu_group_set_name );
11721172
1173- static int iommu_create_device_direct_mappings (struct iommu_domain * domain ,
1174- struct device * dev )
1173+ static int iommu_create_device_fw_mappings (struct iommu_domain * domain ,
1174+ struct device * dev )
11751175{
11761176 struct iommu_resv_region * entry ;
11771177 struct list_head mappings ;
@@ -3021,7 +3021,7 @@ static int iommu_setup_default_domain(struct iommu_group *group,
30213021 struct iommu_domain * old_dom = group -> default_domain ;
30223022 struct group_device * gdev ;
30233023 struct iommu_domain * dom ;
3024- bool direct_failed ;
3024+ bool fw_failed ;
30253025 int req_type ;
30263026 int ret ;
30273027
@@ -3051,10 +3051,10 @@ static int iommu_setup_default_domain(struct iommu_group *group,
30513051 * mapped before their device is attached, in order to guarantee
30523052 * continuity with any FW activity
30533053 */
3054- direct_failed = false;
3054+ fw_failed = false;
30553055 for_each_group_device (group , gdev ) {
3056- if (iommu_create_device_direct_mappings (dom , gdev -> dev )) {
3057- direct_failed = true;
3056+ if (iommu_create_device_fw_mappings (dom , gdev -> dev )) {
3057+ fw_failed = true;
30583058 dev_warn_once (
30593059 gdev -> dev -> iommu -> iommu_dev -> dev ,
30603060 "IOMMU driver was not able to establish FW requested direct mapping." );
@@ -3086,9 +3086,9 @@ static int iommu_setup_default_domain(struct iommu_group *group,
30863086 * trying again after attaching. If this happens it means the device
30873087 * will not continuously have the IOMMU_RESV_DIRECT map.
30883088 */
3089- if (direct_failed ) {
3089+ if (fw_failed ) {
30903090 for_each_group_device (group , gdev ) {
3091- ret = iommu_create_device_direct_mappings (dom , gdev -> dev );
3091+ ret = iommu_create_device_fw_mappings (dom , gdev -> dev );
30923092 if (ret )
30933093 goto err_restore_domain ;
30943094 }
0 commit comments