From: Julia Lawall Date: Sat, 29 Oct 2016 19:37:02 +0000 (+0200) Subject: powerpc/iommu: Use permission-specific DEVICE_ATTR variants X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8a7aef2cb3dafd2e8560750f4e5ad2cc2d9b1d17;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git powerpc/iommu: Use permission-specific DEVICE_ATTR variants Use DEVICE_ATTR_RW for read-write attributes. This simplifies the source code, improves readbility, and reduces the chance of inconsistencies. Signed-off-by: Julia Lawall Acked-by: Michael Ellerman (powerpc) Signed-off-by: Michael Ellerman --- diff --git a/arch/powerpc/kernel/iommu.c b/arch/powerpc/kernel/iommu.c index e0af6cd7ba4f..af7a20dc6e09 100644 --- a/arch/powerpc/kernel/iommu.c +++ b/arch/powerpc/kernel/iommu.c @@ -127,8 +127,7 @@ static ssize_t fail_iommu_store(struct device *dev, return count; } -static DEVICE_ATTR(fail_iommu, S_IRUGO|S_IWUSR, fail_iommu_show, - fail_iommu_store); +static DEVICE_ATTR_RW(fail_iommu); static int fail_iommu_bus_notify(struct notifier_block *nb, unsigned long action, void *data)