]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
iommu/arm-smmu: Make force_stage module param read-only in sysfs
authorWill Deacon <will.deacon@arm.com>
Wed, 27 May 2015 16:09:35 +0000 (17:09 +0100)
committerJoerg Roedel <jroedel@suse.de>
Fri, 29 May 2015 09:12:01 +0000 (11:12 +0200)
Changing force_stage dynamically isn't supported by the driver and it
also doesn't make a whole lot of sense to change it once the SMMU is up
and running.

This patch makes the sysfs entry for the parameter read-only.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/arm-smmu.c

index e2a788eea5ed810607476aa9b8097d8f4d012e34..dce041b1c1394be7057528a5b6fd23dcbbbf6253 100644 (file)
 #define FSYNR0_WNR                     (1 << 4)
 
 static int force_stage;
-module_param_named(force_stage, force_stage, int, S_IRUGO | S_IWUSR);
+module_param_named(force_stage, force_stage, int, S_IRUGO);
 MODULE_PARM_DESC(force_stage,
        "Force SMMU mappings to be installed at a particular stage of translation. A value of '1' or '2' forces the corresponding stage. All other values are ignored (i.e. no stage is forced). Note that selecting a specific stage will disable support for nested translation.");