]> err.no Git - linux-2.6/commitdiff
[POWERPC] tmp_atmel: Constify & voidify get_property()
authorJeremy Kerr <jk@ozlabs.org>
Wed, 12 Jul 2006 05:41:30 +0000 (15:41 +1000)
committerPaul Mackerras <paulus@samba.org>
Mon, 31 Jul 2006 05:55:06 +0000 (15:55 +1000)
Now that get_property() returns a void *, there's no need to cast its
return value. Also, treat the return value as const, so we can
constify get_property later.

tpm_atmel changes

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
drivers/char/tpm/tpm_atmel.h

index 2e68eeb8a2cdfa8397dfacf58f7ac85e37585619..aefd683c60b7e6a0304c6a9b410b5e22647f8a86 100644 (file)
@@ -37,7 +37,7 @@ static void __iomem * atmel_get_base_addr(unsigned long *base, int *region_size)
 {
        struct device_node *dn;
        unsigned long address, size;
-       unsigned int *reg;
+       const unsigned int *reg;
        int reglen;
        int naddrc;
        int nsizec;
@@ -52,7 +52,7 @@ static void __iomem * atmel_get_base_addr(unsigned long *base, int *region_size)
                return NULL;
        }
 
-       reg = (unsigned int *) get_property(dn, "reg", &reglen);
+       reg = get_property(dn, "reg", &reglen);
        naddrc = prom_n_addr_cells(dn);
        nsizec = prom_n_size_cells(dn);