| To: | David Daney <ddaney@caviumnetworks.com> |
|---|---|
| Subject: | Re: [PATCH] MIPS: Rewrite cpu_to_name so it has one statement per line (version 2). |
| From: | Geert Uytterhoeven <geert@linux-m68k.org> |
| Date: | Wed, 15 Oct 2008 09:10:33 +0200 (CEST) |
| Cc: | linux-mips@linux-mips.org, dvomlehn@cisco.com, "Paoletti, Tomaso" <Tomaso.Paoletti@caviumnetworks.com> |
| In-reply-to: | <48F51BF7.2040906@caviumnetworks.com> |
| Original-recipient: | rfc822;linux-mips@linux-mips.org |
| References: | <48F51BF7.2040906@caviumnetworks.com> |
| Sender: | linux-mips-bounce@linux-mips.org |
On Tue, 14 Oct 2008, David Daney wrote:
> +static const char *mips_cpu_names[] = {
[...]
> + [CPU_LAST] = NULL
> +};
> + if (c->cputype >= CPU_LAST)
^^
Either you can use `>' here, or remove the [CPU_LAST] entry in
mips_cpu_names[].
> + BUG();
> + name = mips_cpu_names[c->cputype];
> + if (!name)
> BUG();
> - }
> -
> return name;
> }
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [PATCH] MIPS: Rewrite cpu_to_name so it has one statement per line (version 2)., David VomLehn |
|---|---|
| Next by Date: | [PATCH] 8250: Don't clobber spinlocks in 8250., David Daney |
| Previous by Thread: | Re: [PATCH] MIPS: Rewrite cpu_to_name so it has one statement per line (version 2)., David VomLehn |
| Next by Thread: | [PATCH] 8250: Don't clobber spinlocks in 8250., David Daney |
| Indexes: | [Date] [Thread] [Top] [All Lists] |