Config.in.riscv 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. # RISC-V CPU ISA extensions.
  2. choice
  3. prompt "Target Architecture Variant"
  4. default BR2_riscv_g
  5. config BR2_riscv_g
  6. bool "General purpose (G)"
  7. select BR2_RISCV_ISA_RVI
  8. select BR2_RISCV_ISA_RVM
  9. select BR2_RISCV_ISA_RVA
  10. select BR2_RISCV_ISA_RVF
  11. select BR2_RISCV_ISA_RVD
  12. help
  13. General purpose (G) is equivalent to IMAFD.
  14. config BR2_riscv_custom
  15. bool "Custom architecture"
  16. select BR2_RISCV_ISA_RVI
  17. endchoice
  18. comment "Instruction Set Extensions"
  19. config BR2_RISCV_ISA_RVI
  20. bool "Base Integer (I)"
  21. config BR2_RISCV_ISA_RVM
  22. bool "Integer Multiplication and Division (M)"
  23. config BR2_RISCV_ISA_RVA
  24. bool "Atomic Instructions (A)"
  25. config BR2_RISCV_ISA_RVF
  26. bool "Single-precision Floating-point (F)"
  27. config BR2_RISCV_ISA_RVD
  28. bool "Double-precision Floating-point (D)"
  29. depends on BR2_RISCV_ISA_RVF
  30. config BR2_RISCV_ISA_RVC
  31. bool "Compressed Instructions (C)"
  32. config BR2_RISCV_ISA_RVV
  33. bool "Vector Instructions (V)"
  34. select BR2_ARCH_NEEDS_GCC_AT_LEAST_12
  35. choice
  36. prompt "Target Architecture Size"
  37. default BR2_RISCV_64
  38. config BR2_RISCV_32
  39. bool "32-bit"
  40. config BR2_RISCV_64
  41. bool "64-bit"
  42. select BR2_ARCH_IS_64
  43. endchoice
  44. config BR2_RISCV_USE_MMU
  45. bool "MMU support"
  46. default y
  47. select BR2_USE_MMU
  48. help
  49. Enable this option if your RISC-V core has a MMU (Memory
  50. Management Unit).
  51. choice
  52. prompt "Target ABI"
  53. default BR2_RISCV_ABI_ILP32D if !BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVD
  54. default BR2_RISCV_ABI_ILP32F if !BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVF
  55. default BR2_RISCV_ABI_ILP32 if !BR2_ARCH_IS_64
  56. default BR2_RISCV_ABI_LP64D if BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVD
  57. default BR2_RISCV_ABI_LP64F if BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVF
  58. default BR2_RISCV_ABI_LP64 if BR2_ARCH_IS_64
  59. config BR2_RISCV_ABI_ILP32
  60. bool "ilp32"
  61. depends on !BR2_ARCH_IS_64
  62. config BR2_RISCV_ABI_ILP32F
  63. bool "ilp32f"
  64. depends on !BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVF
  65. config BR2_RISCV_ABI_ILP32D
  66. bool "ilp32d"
  67. depends on !BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVD
  68. config BR2_RISCV_ABI_LP64
  69. bool "lp64"
  70. depends on BR2_ARCH_IS_64
  71. config BR2_RISCV_ABI_LP64F
  72. bool "lp64f"
  73. depends on BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVF
  74. depends on BR2_USE_MMU
  75. config BR2_RISCV_ABI_LP64D
  76. bool "lp64d"
  77. depends on BR2_ARCH_IS_64 && BR2_RISCV_ISA_RVD
  78. endchoice
  79. config BR2_ARCH
  80. default "riscv32" if !BR2_ARCH_IS_64
  81. default "riscv64" if BR2_ARCH_IS_64
  82. config BR2_NORMALIZED_ARCH
  83. default "riscv"
  84. config BR2_ENDIAN
  85. default "LITTLE"
  86. config BR2_GCC_TARGET_ABI
  87. default "ilp32" if BR2_RISCV_ABI_ILP32
  88. default "ilp32f" if BR2_RISCV_ABI_ILP32F
  89. default "ilp32d" if BR2_RISCV_ABI_ILP32D
  90. default "lp64" if BR2_RISCV_ABI_LP64
  91. default "lp64f" if BR2_RISCV_ABI_LP64F
  92. default "lp64d" if BR2_RISCV_ABI_LP64D
  93. config BR2_READELF_ARCH_NAME
  94. default "RISC-V"
  95. # vim: ft=kconfig
  96. # -*- mode:kconfig; -*-