Config.in.riscv 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102
  1. # RISC-V CPU ISA extensions.
  2. config BR2_RISCV_ISA_RVI
  3. bool
  4. config BR2_RISCV_ISA_RVM
  5. bool
  6. config BR2_RISCV_ISA_RVA
  7. bool
  8. config BR2_RISCV_ISA_RVF
  9. bool
  10. config BR2_RISCV_ISA_RVD
  11. bool
  12. config BR2_RISCV_ISA_RVC
  13. bool
  14. choice
  15. prompt "Target Architecture Variant"
  16. default BR2_riscv_g
  17. config BR2_riscv_g
  18. bool "General purpose (G)"
  19. select BR2_RISCV_ISA_RVI
  20. select BR2_RISCV_ISA_RVM
  21. select BR2_RISCV_ISA_RVA
  22. select BR2_RISCV_ISA_RVF
  23. select BR2_RISCV_ISA_RVD
  24. help
  25. General purpose (G) is equivalent to IMAFD.
  26. config BR2_riscv_custom
  27. bool "Custom architecture"
  28. select BR2_RISCV_ISA_RVI
  29. select BR2_RISCV_ISA_CUSTOM_RVA
  30. endchoice
  31. if BR2_riscv_custom
  32. comment "Instruction Set Extensions"
  33. config BR2_RISCV_ISA_CUSTOM_RVM
  34. bool "Integer Multiplication and Division (M)"
  35. select BR2_RISCV_ISA_RVM
  36. config BR2_RISCV_ISA_CUSTOM_RVA
  37. bool "Atomic Instructions (A)"
  38. select BR2_RISCV_ISA_RVA
  39. config BR2_RISCV_ISA_CUSTOM_RVF
  40. bool "Single-precision Floating-point (F)"
  41. select BR2_RISCV_ISA_RVF
  42. config BR2_RISCV_ISA_CUSTOM_RVD
  43. bool "Double-precision Floating-point (D)"
  44. depends on BR2_RISCV_ISA_RVF
  45. select BR2_RISCV_ISA_RVD
  46. config BR2_RISCV_ISA_CUSTOM_RVC
  47. bool "Compressed Instructions (C)"
  48. select BR2_RISCV_ISA_RVC
  49. endif
  50. config BR2_RISCV_64
  51. bool
  52. default y
  53. select BR2_ARCH_IS_64
  54. choice
  55. prompt "Target ABI"
  56. default BR2_RISCV_ABI_LP64
  57. config BR2_RISCV_ABI_LP64
  58. bool "lp64"
  59. depends on BR2_ARCH_IS_64
  60. config BR2_RISCV_ABI_LP64F
  61. bool "lp64f"
  62. depends on BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVF
  63. config BR2_RISCV_ABI_LP64D
  64. bool "lp64d"
  65. depends on BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVD
  66. endchoice
  67. config BR2_ARCH
  68. default "riscv64" if BR2_ARCH_IS_64
  69. config BR2_ENDIAN
  70. default "LITTLE"
  71. config BR2_GCC_TARGET_ABI
  72. default "lp64" if BR2_RISCV_ABI_LP64
  73. default "lp64f" if BR2_RISCV_ABI_LP64F
  74. default "lp64d" if BR2_RISCV_ABI_LP64D
  75. config BR2_READELF_ARCH_NAME
  76. default "RISC-V"