Skip to content

Commit

Permalink
ARM: cache-l2x0.c: consistently use u32
Browse files Browse the repository at this point in the history
__u32 exists to avoid namespace clashes with userspace programs.  It
should not be used outside header files, so convert to use u32 instead.
Also, don't mix uint32_t and __u32 - use the same type throughout the
file for consistency.

Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King committed Jan 20, 2012
1 parent dcd6c92 commit 3e175ca
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
6 changes: 3 additions & 3 deletions arch/arm/include/asm/hardware/cache-l2x0.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,11 @@
#define L2X0_ADDR_FILTER_EN 1

#ifndef __ASSEMBLY__
extern void __init l2x0_init(void __iomem *base, __u32 aux_val, __u32 aux_mask);
extern void __init l2x0_init(void __iomem *base, u32 aux_val, u32 aux_mask);
#if defined(CONFIG_CACHE_L2X0) && defined(CONFIG_OF)
extern int l2x0_of_init(__u32 aux_val, __u32 aux_mask);
extern int l2x0_of_init(u32 aux_val, u32 aux_mask);
#else
static inline int l2x0_of_init(__u32 aux_val, __u32 aux_mask)
static inline int l2x0_of_init(u32 aux_val, u32 aux_mask)
{
return -ENODEV;
}
Expand Down
22 changes: 11 additions & 11 deletions arch/arm/mm/cache-l2x0.c
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@

static void __iomem *l2x0_base;
static DEFINE_RAW_SPINLOCK(l2x0_lock);
static uint32_t l2x0_way_mask; /* Bitmask of active ways */
static uint32_t l2x0_size;
static u32 l2x0_way_mask; /* Bitmask of active ways */
static u32 l2x0_size;

struct l2x0_regs l2x0_saved_regs;

struct l2x0_of_data {
void (*setup)(const struct device_node *, __u32 *, __u32 *);
void (*setup)(const struct device_node *, u32 *, u32 *);
void (*save)(void);
void (*resume)(void);
};
Expand Down Expand Up @@ -288,7 +288,7 @@ static void l2x0_disable(void)
raw_spin_unlock_irqrestore(&l2x0_lock, flags);
}

static void l2x0_unlock(__u32 cache_id)
static void l2x0_unlock(u32 cache_id)
{
int lockregs;
int i;
Expand All @@ -307,11 +307,11 @@ static void l2x0_unlock(__u32 cache_id)
}
}

void __init l2x0_init(void __iomem *base, __u32 aux_val, __u32 aux_mask)
void __init l2x0_init(void __iomem *base, u32 aux_val, u32 aux_mask)
{
__u32 aux;
__u32 cache_id;
__u32 way_size = 0;
u32 aux;
u32 cache_id;
u32 way_size = 0;
int ways;
const char *type;

Expand Down Expand Up @@ -388,7 +388,7 @@ void __init l2x0_init(void __iomem *base, __u32 aux_val, __u32 aux_mask)

#ifdef CONFIG_OF
static void __init l2x0_of_setup(const struct device_node *np,
__u32 *aux_val, __u32 *aux_mask)
u32 *aux_val, u32 *aux_mask)
{
u32 data[2] = { 0, 0 };
u32 tag = 0;
Expand Down Expand Up @@ -422,7 +422,7 @@ static void __init l2x0_of_setup(const struct device_node *np,
}

static void __init pl310_of_setup(const struct device_node *np,
__u32 *aux_val, __u32 *aux_mask)
u32 *aux_val, u32 *aux_mask)
{
u32 data[3] = { 0, 0, 0 };
u32 tag[3] = { 0, 0, 0 };
Expand Down Expand Up @@ -548,7 +548,7 @@ static const struct of_device_id l2x0_ids[] __initconst = {
{}
};

int __init l2x0_of_init(__u32 aux_val, __u32 aux_mask)
int __init l2x0_of_init(u32 aux_val, u32 aux_mask)
{
struct device_node *np;
struct l2x0_of_data *data;
Expand Down

0 comments on commit 3e175ca

Please sign in to comment.