2 * Copyright (C) 2013-2015 Masahiro Yamada <yamada.masahiro@socionext.com>
4 * SPDX-License-Identifier: GPL-2.0+
12 int print_cpuinfo(void)
14 u32 revision, type, model, rev, required_model = 1, required_rev = 1;
16 revision = readl(SG_REVISION);
17 type = (revision & SG_REVISION_TYPE_MASK) >> SG_REVISION_TYPE_SHIFT;
18 model = (revision & SG_REVISION_MODEL_MASK) >> SG_REVISION_MODEL_SHIFT;
19 rev = (revision & SG_REVISION_REV_MASK) >> SG_REVISION_REV_SHIFT;
25 puts("PH1-sLD3 (MN2WS0220)");
29 puts("PH1-LD4 (MN2WS0250)");
33 puts("PH1-Pro4 (MN2WS0230)");
36 puts("PH1-sLD8 (MN2WS0270)");
39 puts("PH1-Pro5 (MN2WS0300)");
42 puts("ProXstream2 (MN2WS0310)");
45 puts("PH1-LD6b (MN2WS0320)");
54 printf("Unknown Processor ID (0x%x)\n", revision);
58 printf(" model %d", model);
60 printf(" (rev. %d)\n", rev);
62 if (model < required_model) {
63 printf("Sorry, this model is not supported.\n");
64 printf("Required model is %d.", required_model);
66 } else if (rev < required_rev) {
67 printf("Sorry, this revision is not supported.\n");
68 printf("Required revision is %d.", required_rev);