diff options
author | Aaro Koskinen <aaro.koskinen@nsn.com> | 2014-09-08 11:25:42 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2014-11-24 01:45:32 -0500 |
commit | 653e0528810280106b0ceb4c6988e6263ede852b (patch) | |
tree | 7692052f30d5ed2a4bf5658ec33bdeacd3a64605 /arch/mips | |
parent | 4aa16510bffcbd5a1d0c3aa16b05137ac90f58cb (diff) |
MIPS: Octeon: Move code to avoid forward declaration
Move code to avoid forward declarations.
Signed-off-by: Aaro Koskinen <aaro.koskinen@nsn.com>
Cc: David Daney <david.daney@cavium.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/7667/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips')
-rw-r--r-- | arch/mips/cavium-octeon/executive/octeon-model.c | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/arch/mips/cavium-octeon/executive/octeon-model.c b/arch/mips/cavium-octeon/executive/octeon-model.c index e1878723efd8..5105d0d57154 100644 --- a/arch/mips/cavium-octeon/executive/octeon-model.c +++ b/arch/mips/cavium-octeon/executive/octeon-model.c | |||
@@ -47,25 +47,6 @@ uint8_t cvmx_fuse_read_byte(int byte_addr) | |||
47 | return read_cmd.s.dat; | 47 | return read_cmd.s.dat; |
48 | } | 48 | } |
49 | 49 | ||
50 | /** | ||
51 | * Given the chip processor ID from COP0, this function returns a | ||
52 | * string representing the chip model number. The string is of the | ||
53 | * form CNXXXXpX.X-FREQ-SUFFIX. | ||
54 | * - XXXX = The chip model number | ||
55 | * - X.X = Chip pass number | ||
56 | * - FREQ = Current frequency in Mhz | ||
57 | * - SUFFIX = NSP, EXP, SCP, SSP, or CP | ||
58 | * | ||
59 | * @chip_id: Chip ID | ||
60 | * | ||
61 | * Returns Model string | ||
62 | */ | ||
63 | const char *octeon_model_get_string(uint32_t chip_id) | ||
64 | { | ||
65 | static char buffer[32]; | ||
66 | return octeon_model_get_string_buffer(chip_id, buffer); | ||
67 | } | ||
68 | |||
69 | /* | 50 | /* |
70 | * Version of octeon_model_get_string() that takes buffer as argument, | 51 | * Version of octeon_model_get_string() that takes buffer as argument, |
71 | * as running early in u-boot static/global variables don't work when | 52 | * as running early in u-boot static/global variables don't work when |
@@ -427,3 +408,22 @@ const char *octeon_model_get_string_buffer(uint32_t chip_id, char *buffer) | |||
427 | sprintf(buffer, "CN%s%sp%s-%d-%s", family, core_model, pass, clock_mhz, suffix); | 408 | sprintf(buffer, "CN%s%sp%s-%d-%s", family, core_model, pass, clock_mhz, suffix); |
428 | return buffer; | 409 | return buffer; |
429 | } | 410 | } |
411 | |||
412 | /** | ||
413 | * Given the chip processor ID from COP0, this function returns a | ||
414 | * string representing the chip model number. The string is of the | ||
415 | * form CNXXXXpX.X-FREQ-SUFFIX. | ||
416 | * - XXXX = The chip model number | ||
417 | * - X.X = Chip pass number | ||
418 | * - FREQ = Current frequency in Mhz | ||
419 | * - SUFFIX = NSP, EXP, SCP, SSP, or CP | ||
420 | * | ||
421 | * @chip_id: Chip ID | ||
422 | * | ||
423 | * Returns Model string | ||
424 | */ | ||
425 | const char *octeon_model_get_string(uint32_t chip_id) | ||
426 | { | ||
427 | static char buffer[32]; | ||
428 | return octeon_model_get_string_buffer(chip_id, buffer); | ||
429 | } | ||