sparc64: Use unsigned long long for u64.

Andrew Morton wrote:

    People keep on doing

            printk("%llu", some_u64);

    testing it only on x86_64 and this generates a warning storm on
    powerpc, sparc64, etc.  Because they use `long', not `long long'.

    Quite a few 64-bit architectures are using `long' for their
    s64/u64 types.  We should convert them all to `long long'.

Update types.h so we use unsigned long long for u64 and
fix all warnings in sparc64 code.
Tested with an allnoconfig, defconfig and allmodconfig builds.

This patch introduces additional warnings in several drivers.
These will be dealt with in separate patches.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Sam Ravnborg
2009-01-06 13:19:28 -08:00
committed by David S. Miller
parent 0157141ae2
commit 9018113649
19 changed files with 71 additions and 71 deletions

View File

@@ -779,8 +779,8 @@ static int find_node(unsigned long addr)
return -1;
}
static unsigned long nid_range(unsigned long start, unsigned long end,
int *nid)
static unsigned long long nid_range(unsigned long long start,
unsigned long long end, int *nid)
{
*nid = find_node(start);
start += PAGE_SIZE;
@@ -798,8 +798,8 @@ static unsigned long nid_range(unsigned long start, unsigned long end,
return start;
}
#else
static unsigned long nid_range(unsigned long start, unsigned long end,
int *nid)
static unsigned long long nid_range(unsigned long long start,
unsigned long long end, int *nid)
{
*nid = 0;
return end;
@@ -1026,8 +1026,8 @@ static int __init grab_mlgroups(struct mdesc_handle *md)
val = mdesc_get_property(md, node, "address-mask", NULL);
m->mask = *val;
numadbg("MLGROUP[%d]: node[%lx] latency[%lx] "
"match[%lx] mask[%lx]\n",
numadbg("MLGROUP[%d]: node[%llx] latency[%llx] "
"match[%llx] mask[%llx]\n",
count - 1, m->node, m->latency, m->match, m->mask);
}
@@ -1066,7 +1066,7 @@ static int __init grab_mblocks(struct mdesc_handle *md)
"address-congruence-offset", NULL);
m->offset = *val;
numadbg("MBLOCK[%d]: base[%lx] size[%lx] offset[%lx]\n",
numadbg("MBLOCK[%d]: base[%llx] size[%llx] offset[%llx]\n",
count - 1, m->base, m->size, m->offset);
}
@@ -1137,7 +1137,7 @@ static int __init numa_attach_mlgroup(struct mdesc_handle *md, u64 grp,
n->mask = candidate->mask;
n->val = candidate->match;
numadbg("NUMA NODE[%d]: mask[%lx] val[%lx] (latency[%lx])\n",
numadbg("NUMA NODE[%d]: mask[%lx] val[%lx] (latency[%llx])\n",
index, n->mask, n->val, candidate->latency);
return 0;