cpu-probe.c 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598
  1. /*
  2. * Processor capabilities determination functions.
  3. *
  4. * Copyright (C) xxxx the Anonymous
  5. * Copyright (C) 2003 Maciej W. Rozycki
  6. * Copyright (C) 1994 - 2003 Ralf Baechle
  7. * Copyright (C) 2001 MIPS Inc.
  8. *
  9. * This program is free software; you can redistribute it and/or
  10. * modify it under the terms of the GNU General Public License
  11. * as published by the Free Software Foundation; either version
  12. * 2 of the License, or (at your option) any later version.
  13. */
  14. #include <linux/config.h>
  15. #include <linux/init.h>
  16. #include <linux/kernel.h>
  17. #include <linux/ptrace.h>
  18. #include <linux/stddef.h>
  19. #include <asm/bugs.h>
  20. #include <asm/cpu.h>
  21. #include <asm/fpu.h>
  22. #include <asm/mipsregs.h>
  23. #include <asm/system.h>
  24. /*
  25. * Not all of the MIPS CPUs have the "wait" instruction available. Moreover,
  26. * the implementation of the "wait" feature differs between CPU families. This
  27. * points to the function that implements CPU specific wait.
  28. * The wait instruction stops the pipeline and reduces the power consumption of
  29. * the CPU very much.
  30. */
  31. void (*cpu_wait)(void) = NULL;
  32. static void r3081_wait(void)
  33. {
  34. unsigned long cfg = read_c0_conf();
  35. write_c0_conf(cfg | R30XX_CONF_HALT);
  36. }
  37. static void r39xx_wait(void)
  38. {
  39. unsigned long cfg = read_c0_conf();
  40. write_c0_conf(cfg | TX39_CONF_HALT);
  41. }
  42. static void r4k_wait(void)
  43. {
  44. __asm__(".set\tmips3\n\t"
  45. "wait\n\t"
  46. ".set\tmips0");
  47. }
  48. /*
  49. * The Au1xxx wait is available only if we run CONFIG_PM and
  50. * the timer setup found we had a 32KHz counter available.
  51. * There are still problems with functions that may call au1k_wait
  52. * directly, but that will be discovered pretty quickly.
  53. */
  54. extern void (*au1k_wait_ptr)(void);
  55. void au1k_wait(void)
  56. {
  57. #ifdef CONFIG_PM
  58. /* using the wait instruction makes CP0 counter unusable */
  59. __asm__(".set\tmips3\n\t"
  60. "wait\n\t"
  61. "nop\n\t"
  62. "nop\n\t"
  63. "nop\n\t"
  64. "nop\n\t"
  65. ".set\tmips0");
  66. #else
  67. __asm__("nop\n\t"
  68. "nop");
  69. #endif
  70. }
  71. static inline void check_wait(void)
  72. {
  73. struct cpuinfo_mips *c = &current_cpu_data;
  74. printk("Checking for 'wait' instruction... ");
  75. switch (c->cputype) {
  76. case CPU_R3081:
  77. case CPU_R3081E:
  78. cpu_wait = r3081_wait;
  79. printk(" available.\n");
  80. break;
  81. case CPU_TX3927:
  82. cpu_wait = r39xx_wait;
  83. printk(" available.\n");
  84. break;
  85. case CPU_R4200:
  86. /* case CPU_R4300: */
  87. case CPU_R4600:
  88. case CPU_R4640:
  89. case CPU_R4650:
  90. case CPU_R4700:
  91. case CPU_R5000:
  92. case CPU_NEVADA:
  93. case CPU_RM7000:
  94. case CPU_RM9000:
  95. case CPU_TX49XX:
  96. case CPU_4KC:
  97. case CPU_4KEC:
  98. case CPU_4KSC:
  99. case CPU_5KC:
  100. /* case CPU_20KC:*/
  101. case CPU_24K:
  102. case CPU_25KF:
  103. cpu_wait = r4k_wait;
  104. printk(" available.\n");
  105. break;
  106. #ifdef CONFIG_PM
  107. case CPU_AU1000:
  108. case CPU_AU1100:
  109. case CPU_AU1500:
  110. if (au1k_wait_ptr != NULL) {
  111. cpu_wait = au1k_wait_ptr;
  112. printk(" available.\n");
  113. }
  114. else {
  115. printk(" unavailable.\n");
  116. }
  117. break;
  118. #endif
  119. default:
  120. printk(" unavailable.\n");
  121. break;
  122. }
  123. }
  124. void __init check_bugs32(void)
  125. {
  126. check_wait();
  127. }
  128. /*
  129. * Probe whether cpu has config register by trying to play with
  130. * alternate cache bit and see whether it matters.
  131. * It's used by cpu_probe to distinguish between R3000A and R3081.
  132. */
  133. static inline int cpu_has_confreg(void)
  134. {
  135. #ifdef CONFIG_CPU_R3000
  136. extern unsigned long r3k_cache_size(unsigned long);
  137. unsigned long size1, size2;
  138. unsigned long cfg = read_c0_conf();
  139. size1 = r3k_cache_size(ST0_ISC);
  140. write_c0_conf(cfg ^ R30XX_CONF_AC);
  141. size2 = r3k_cache_size(ST0_ISC);
  142. write_c0_conf(cfg);
  143. return size1 != size2;
  144. #else
  145. return 0;
  146. #endif
  147. }
  148. /*
  149. * Get the FPU Implementation/Revision.
  150. */
  151. static inline unsigned long cpu_get_fpu_id(void)
  152. {
  153. unsigned long tmp, fpu_id;
  154. tmp = read_c0_status();
  155. __enable_fpu();
  156. fpu_id = read_32bit_cp1_register(CP1_REVISION);
  157. write_c0_status(tmp);
  158. return fpu_id;
  159. }
  160. /*
  161. * Check the CPU has an FPU the official way.
  162. */
  163. static inline int __cpu_has_fpu(void)
  164. {
  165. return ((cpu_get_fpu_id() & 0xff00) != FPIR_IMP_NONE);
  166. }
  167. #define R4K_OPTS (MIPS_CPU_TLB | MIPS_CPU_4KEX | MIPS_CPU_4KTLB \
  168. | MIPS_CPU_COUNTER)
  169. static inline void cpu_probe_legacy(struct cpuinfo_mips *c)
  170. {
  171. switch (c->processor_id & 0xff00) {
  172. case PRID_IMP_R2000:
  173. c->cputype = CPU_R2000;
  174. c->isa_level = MIPS_CPU_ISA_I;
  175. c->options = MIPS_CPU_TLB | MIPS_CPU_NOFPUEX;
  176. if (__cpu_has_fpu())
  177. c->options |= MIPS_CPU_FPU;
  178. c->tlbsize = 64;
  179. break;
  180. case PRID_IMP_R3000:
  181. if ((c->processor_id & 0xff) == PRID_REV_R3000A)
  182. if (cpu_has_confreg())
  183. c->cputype = CPU_R3081E;
  184. else
  185. c->cputype = CPU_R3000A;
  186. else
  187. c->cputype = CPU_R3000;
  188. c->isa_level = MIPS_CPU_ISA_I;
  189. c->options = MIPS_CPU_TLB | MIPS_CPU_NOFPUEX;
  190. if (__cpu_has_fpu())
  191. c->options |= MIPS_CPU_FPU;
  192. c->tlbsize = 64;
  193. break;
  194. case PRID_IMP_R4000:
  195. if (read_c0_config() & CONF_SC) {
  196. if ((c->processor_id & 0xff) >= PRID_REV_R4400)
  197. c->cputype = CPU_R4400PC;
  198. else
  199. c->cputype = CPU_R4000PC;
  200. } else {
  201. if ((c->processor_id & 0xff) >= PRID_REV_R4400)
  202. c->cputype = CPU_R4400SC;
  203. else
  204. c->cputype = CPU_R4000SC;
  205. }
  206. c->isa_level = MIPS_CPU_ISA_III;
  207. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  208. MIPS_CPU_WATCH | MIPS_CPU_VCE |
  209. MIPS_CPU_LLSC;
  210. c->tlbsize = 48;
  211. break;
  212. case PRID_IMP_VR41XX:
  213. switch (c->processor_id & 0xf0) {
  214. #ifndef CONFIG_VR4181
  215. case PRID_REV_VR4111:
  216. c->cputype = CPU_VR4111;
  217. break;
  218. #else
  219. case PRID_REV_VR4181:
  220. c->cputype = CPU_VR4181;
  221. break;
  222. #endif
  223. case PRID_REV_VR4121:
  224. c->cputype = CPU_VR4121;
  225. break;
  226. case PRID_REV_VR4122:
  227. if ((c->processor_id & 0xf) < 0x3)
  228. c->cputype = CPU_VR4122;
  229. else
  230. c->cputype = CPU_VR4181A;
  231. break;
  232. case PRID_REV_VR4130:
  233. if ((c->processor_id & 0xf) < 0x4)
  234. c->cputype = CPU_VR4131;
  235. else
  236. c->cputype = CPU_VR4133;
  237. break;
  238. default:
  239. printk(KERN_INFO "Unexpected CPU of NEC VR4100 series\n");
  240. c->cputype = CPU_VR41XX;
  241. break;
  242. }
  243. c->isa_level = MIPS_CPU_ISA_III;
  244. c->options = R4K_OPTS;
  245. c->tlbsize = 32;
  246. break;
  247. case PRID_IMP_R4300:
  248. c->cputype = CPU_R4300;
  249. c->isa_level = MIPS_CPU_ISA_III;
  250. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  251. MIPS_CPU_LLSC;
  252. c->tlbsize = 32;
  253. break;
  254. case PRID_IMP_R4600:
  255. c->cputype = CPU_R4600;
  256. c->isa_level = MIPS_CPU_ISA_III;
  257. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_LLSC;
  258. c->tlbsize = 48;
  259. break;
  260. #if 0
  261. case PRID_IMP_R4650:
  262. /*
  263. * This processor doesn't have an MMU, so it's not
  264. * "real easy" to run Linux on it. It is left purely
  265. * for documentation. Commented out because it shares
  266. * it's c0_prid id number with the TX3900.
  267. */
  268. c->cputype = CPU_R4650;
  269. c->isa_level = MIPS_CPU_ISA_III;
  270. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_LLSC;
  271. c->tlbsize = 48;
  272. break;
  273. #endif
  274. case PRID_IMP_TX39:
  275. c->isa_level = MIPS_CPU_ISA_I;
  276. c->options = MIPS_CPU_TLB;
  277. if ((c->processor_id & 0xf0) == (PRID_REV_TX3927 & 0xf0)) {
  278. c->cputype = CPU_TX3927;
  279. c->tlbsize = 64;
  280. } else {
  281. switch (c->processor_id & 0xff) {
  282. case PRID_REV_TX3912:
  283. c->cputype = CPU_TX3912;
  284. c->tlbsize = 32;
  285. break;
  286. case PRID_REV_TX3922:
  287. c->cputype = CPU_TX3922;
  288. c->tlbsize = 64;
  289. break;
  290. default:
  291. c->cputype = CPU_UNKNOWN;
  292. break;
  293. }
  294. }
  295. break;
  296. case PRID_IMP_R4700:
  297. c->cputype = CPU_R4700;
  298. c->isa_level = MIPS_CPU_ISA_III;
  299. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  300. MIPS_CPU_LLSC;
  301. c->tlbsize = 48;
  302. break;
  303. case PRID_IMP_TX49:
  304. c->cputype = CPU_TX49XX;
  305. c->isa_level = MIPS_CPU_ISA_III;
  306. c->options = R4K_OPTS | MIPS_CPU_LLSC;
  307. if (!(c->processor_id & 0x08))
  308. c->options |= MIPS_CPU_FPU | MIPS_CPU_32FPR;
  309. c->tlbsize = 48;
  310. break;
  311. case PRID_IMP_R5000:
  312. c->cputype = CPU_R5000;
  313. c->isa_level = MIPS_CPU_ISA_IV;
  314. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  315. MIPS_CPU_LLSC;
  316. c->tlbsize = 48;
  317. break;
  318. case PRID_IMP_R5432:
  319. c->cputype = CPU_R5432;
  320. c->isa_level = MIPS_CPU_ISA_IV;
  321. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  322. MIPS_CPU_WATCH | MIPS_CPU_LLSC;
  323. c->tlbsize = 48;
  324. break;
  325. case PRID_IMP_R5500:
  326. c->cputype = CPU_R5500;
  327. c->isa_level = MIPS_CPU_ISA_IV;
  328. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  329. MIPS_CPU_WATCH | MIPS_CPU_LLSC;
  330. c->tlbsize = 48;
  331. break;
  332. case PRID_IMP_NEVADA:
  333. c->cputype = CPU_NEVADA;
  334. c->isa_level = MIPS_CPU_ISA_IV;
  335. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  336. MIPS_CPU_DIVEC | MIPS_CPU_LLSC;
  337. c->tlbsize = 48;
  338. break;
  339. case PRID_IMP_R6000:
  340. c->cputype = CPU_R6000;
  341. c->isa_level = MIPS_CPU_ISA_II;
  342. c->options = MIPS_CPU_TLB | MIPS_CPU_FPU |
  343. MIPS_CPU_LLSC;
  344. c->tlbsize = 32;
  345. break;
  346. case PRID_IMP_R6000A:
  347. c->cputype = CPU_R6000A;
  348. c->isa_level = MIPS_CPU_ISA_II;
  349. c->options = MIPS_CPU_TLB | MIPS_CPU_FPU |
  350. MIPS_CPU_LLSC;
  351. c->tlbsize = 32;
  352. break;
  353. case PRID_IMP_RM7000:
  354. c->cputype = CPU_RM7000;
  355. c->isa_level = MIPS_CPU_ISA_IV;
  356. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  357. MIPS_CPU_LLSC;
  358. /*
  359. * Undocumented RM7000: Bit 29 in the info register of
  360. * the RM7000 v2.0 indicates if the TLB has 48 or 64
  361. * entries.
  362. *
  363. * 29 1 => 64 entry JTLB
  364. * 0 => 48 entry JTLB
  365. */
  366. c->tlbsize = (read_c0_info() & (1 << 29)) ? 64 : 48;
  367. break;
  368. case PRID_IMP_RM9000:
  369. c->cputype = CPU_RM9000;
  370. c->isa_level = MIPS_CPU_ISA_IV;
  371. c->options = R4K_OPTS | MIPS_CPU_FPU | MIPS_CPU_32FPR |
  372. MIPS_CPU_LLSC;
  373. /*
  374. * Bit 29 in the info register of the RM9000
  375. * indicates if the TLB has 48 or 64 entries.
  376. *
  377. * 29 1 => 64 entry JTLB
  378. * 0 => 48 entry JTLB
  379. */
  380. c->tlbsize = (read_c0_info() & (1 << 29)) ? 64 : 48;
  381. break;
  382. case PRID_IMP_R8000:
  383. c->cputype = CPU_R8000;
  384. c->isa_level = MIPS_CPU_ISA_IV;
  385. c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
  386. MIPS_CPU_FPU | MIPS_CPU_32FPR |
  387. MIPS_CPU_LLSC;
  388. c->tlbsize = 384; /* has weird TLB: 3-way x 128 */
  389. break;
  390. case PRID_IMP_R10000:
  391. c->cputype = CPU_R10000;
  392. c->isa_level = MIPS_CPU_ISA_IV;
  393. c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
  394. MIPS_CPU_FPU | MIPS_CPU_32FPR |
  395. MIPS_CPU_COUNTER | MIPS_CPU_WATCH |
  396. MIPS_CPU_LLSC;
  397. c->tlbsize = 64;
  398. break;
  399. case PRID_IMP_R12000:
  400. c->cputype = CPU_R12000;
  401. c->isa_level = MIPS_CPU_ISA_IV;
  402. c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
  403. MIPS_CPU_FPU | MIPS_CPU_32FPR |
  404. MIPS_CPU_COUNTER | MIPS_CPU_WATCH |
  405. MIPS_CPU_LLSC;
  406. c->tlbsize = 64;
  407. break;
  408. }
  409. }
  410. static inline void decode_config1(struct cpuinfo_mips *c)
  411. {
  412. unsigned long config0 = read_c0_config();
  413. unsigned long config1;
  414. if ((config0 & (1 << 31)) == 0)
  415. return; /* actually wort a panic() */
  416. /* MIPS32 or MIPS64 compliant CPU. Read Config 1 register. */
  417. c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
  418. MIPS_CPU_4KTLB | MIPS_CPU_COUNTER | MIPS_CPU_DIVEC |
  419. MIPS_CPU_LLSC | MIPS_CPU_MCHECK;
  420. config1 = read_c0_config1();
  421. if (config1 & (1 << 3))
  422. c->options |= MIPS_CPU_WATCH;
  423. if (config1 & (1 << 2))
  424. c->options |= MIPS_CPU_MIPS16;
  425. if (config1 & (1 << 1))
  426. c->options |= MIPS_CPU_EJTAG;
  427. if (config1 & 1) {
  428. c->options |= MIPS_CPU_FPU;
  429. c->options |= MIPS_CPU_32FPR;
  430. }
  431. c->scache.flags = MIPS_CACHE_NOT_PRESENT;
  432. c->tlbsize = ((config1 >> 25) & 0x3f) + 1;
  433. }
  434. static inline void cpu_probe_mips(struct cpuinfo_mips *c)
  435. {
  436. decode_config1(c);
  437. switch (c->processor_id & 0xff00) {
  438. case PRID_IMP_4KC:
  439. c->cputype = CPU_4KC;
  440. c->isa_level = MIPS_CPU_ISA_M32;
  441. break;
  442. case PRID_IMP_4KEC:
  443. c->cputype = CPU_4KEC;
  444. c->isa_level = MIPS_CPU_ISA_M32;
  445. break;
  446. case PRID_IMP_4KSC:
  447. c->cputype = CPU_4KSC;
  448. c->isa_level = MIPS_CPU_ISA_M32;
  449. break;
  450. case PRID_IMP_5KC:
  451. c->cputype = CPU_5KC;
  452. c->isa_level = MIPS_CPU_ISA_M64;
  453. break;
  454. case PRID_IMP_20KC:
  455. c->cputype = CPU_20KC;
  456. c->isa_level = MIPS_CPU_ISA_M64;
  457. break;
  458. case PRID_IMP_24K:
  459. c->cputype = CPU_24K;
  460. c->isa_level = MIPS_CPU_ISA_M32;
  461. break;
  462. case PRID_IMP_25KF:
  463. c->cputype = CPU_25KF;
  464. c->isa_level = MIPS_CPU_ISA_M64;
  465. /* Probe for L2 cache */
  466. c->scache.flags &= ~MIPS_CACHE_NOT_PRESENT;
  467. break;
  468. }
  469. }
  470. static inline void cpu_probe_alchemy(struct cpuinfo_mips *c)
  471. {
  472. decode_config1(c);
  473. switch (c->processor_id & 0xff00) {
  474. case PRID_IMP_AU1_REV1:
  475. case PRID_IMP_AU1_REV2:
  476. switch ((c->processor_id >> 24) & 0xff) {
  477. case 0:
  478. c->cputype = CPU_AU1000;
  479. break;
  480. case 1:
  481. c->cputype = CPU_AU1500;
  482. break;
  483. case 2:
  484. c->cputype = CPU_AU1100;
  485. break;
  486. case 3:
  487. c->cputype = CPU_AU1550;
  488. break;
  489. default:
  490. panic("Unknown Au Core!");
  491. break;
  492. }
  493. c->isa_level = MIPS_CPU_ISA_M32;
  494. break;
  495. }
  496. }
  497. static inline void cpu_probe_sibyte(struct cpuinfo_mips *c)
  498. {
  499. decode_config1(c);
  500. switch (c->processor_id & 0xff00) {
  501. case PRID_IMP_SB1:
  502. c->cputype = CPU_SB1;
  503. c->isa_level = MIPS_CPU_ISA_M64;
  504. c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
  505. MIPS_CPU_COUNTER | MIPS_CPU_DIVEC |
  506. MIPS_CPU_MCHECK | MIPS_CPU_EJTAG |
  507. MIPS_CPU_WATCH | MIPS_CPU_LLSC;
  508. #ifndef CONFIG_SB1_PASS_1_WORKAROUNDS
  509. /* FPU in pass1 is known to have issues. */
  510. c->options |= MIPS_CPU_FPU | MIPS_CPU_32FPR;
  511. #endif
  512. break;
  513. }
  514. }
  515. static inline void cpu_probe_sandcraft(struct cpuinfo_mips *c)
  516. {
  517. decode_config1(c);
  518. switch (c->processor_id & 0xff00) {
  519. case PRID_IMP_SR71000:
  520. c->cputype = CPU_SR71000;
  521. c->isa_level = MIPS_CPU_ISA_M64;
  522. c->options = MIPS_CPU_TLB | MIPS_CPU_4KEX |
  523. MIPS_CPU_4KTLB | MIPS_CPU_FPU |
  524. MIPS_CPU_COUNTER | MIPS_CPU_MCHECK;
  525. c->scache.ways = 8;
  526. c->tlbsize = 64;
  527. break;
  528. }
  529. }
  530. __init void cpu_probe(void)
  531. {
  532. struct cpuinfo_mips *c = &current_cpu_data;
  533. c->processor_id = PRID_IMP_UNKNOWN;
  534. c->fpu_id = FPIR_IMP_NONE;
  535. c->cputype = CPU_UNKNOWN;
  536. c->processor_id = read_c0_prid();
  537. switch (c->processor_id & 0xff0000) {
  538. case PRID_COMP_LEGACY:
  539. cpu_probe_legacy(c);
  540. break;
  541. case PRID_COMP_MIPS:
  542. cpu_probe_mips(c);
  543. break;
  544. case PRID_COMP_ALCHEMY:
  545. cpu_probe_alchemy(c);
  546. break;
  547. case PRID_COMP_SIBYTE:
  548. cpu_probe_sibyte(c);
  549. break;
  550. case PRID_COMP_SANDCRAFT:
  551. cpu_probe_sandcraft(c);
  552. break;
  553. default:
  554. c->cputype = CPU_UNKNOWN;
  555. }
  556. if (c->options & MIPS_CPU_FPU)
  557. c->fpu_id = cpu_get_fpu_id();
  558. }
  559. __init void cpu_report(void)
  560. {
  561. struct cpuinfo_mips *c = &current_cpu_data;
  562. printk("CPU revision is: %08x\n", c->processor_id);
  563. if (c->options & MIPS_CPU_FPU)
  564. printk("FPU revision is: %08x\n", c->fpu_id);
  565. }