Makefile 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. #
  2. # Makefile for Kernel-based Virtual Machine module
  3. #
  4. subdir-ccflags-$(CONFIG_PPC_WERROR) := -Werror
  5. ccflags-y := -Ivirt/kvm -Iarch/powerpc/kvm
  6. KVM := ../../../virt/kvm
  7. common-objs-y = $(KVM)/kvm_main.o $(KVM)/eventfd.o
  8. common-objs-$(CONFIG_KVM_VFIO) += $(KVM)/vfio.o
  9. common-objs-$(CONFIG_KVM_MMIO) += $(KVM)/coalesced_mmio.o
  10. CFLAGS_e500_mmu.o := -I.
  11. CFLAGS_e500_mmu_host.o := -I.
  12. CFLAGS_emulate.o := -I.
  13. CFLAGS_emulate_loadstore.o := -I.
  14. common-objs-y += powerpc.o emulate_loadstore.o
  15. obj-$(CONFIG_KVM_EXIT_TIMING) += timing.o
  16. obj-$(CONFIG_KVM_BOOK3S_HANDLER) += book3s_exports.o
  17. AFLAGS_booke_interrupts.o := -I$(objtree)/$(obj)
  18. kvm-e500-objs := \
  19. $(common-objs-y) \
  20. emulate.o \
  21. booke.o \
  22. booke_emulate.o \
  23. booke_interrupts.o \
  24. e500.o \
  25. e500_mmu.o \
  26. e500_mmu_host.o \
  27. e500_emulate.o
  28. kvm-objs-$(CONFIG_KVM_E500V2) := $(kvm-e500-objs)
  29. kvm-e500mc-objs := \
  30. $(common-objs-y) \
  31. emulate.o \
  32. booke.o \
  33. booke_emulate.o \
  34. bookehv_interrupts.o \
  35. e500mc.o \
  36. e500_mmu.o \
  37. e500_mmu_host.o \
  38. e500_emulate.o
  39. kvm-objs-$(CONFIG_KVM_E500MC) := $(kvm-e500mc-objs)
  40. kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HANDLER) := \
  41. book3s_64_vio_hv.o
  42. kvm-pr-y := \
  43. fpu.o \
  44. emulate.o \
  45. book3s_paired_singles.o \
  46. book3s_pr.o \
  47. book3s_pr_papr.o \
  48. book3s_emulate.o \
  49. book3s_interrupts.o \
  50. book3s_mmu_hpte.o \
  51. book3s_64_mmu_host.o \
  52. book3s_64_mmu.o \
  53. book3s_32_mmu.o
  54. ifdef CONFIG_KVM_BOOK3S_PR_POSSIBLE
  55. kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HANDLER) += \
  56. book3s_rmhandlers.o
  57. endif
  58. kvm-hv-y += \
  59. book3s_hv.o \
  60. book3s_hv_interrupts.o \
  61. book3s_64_mmu_hv.o
  62. kvm-book3s_64-builtin-xics-objs-$(CONFIG_KVM_XICS) := \
  63. book3s_hv_rm_xics.o
  64. ifdef CONFIG_KVM_BOOK3S_HV_POSSIBLE
  65. kvm-book3s_64-builtin-objs-$(CONFIG_KVM_BOOK3S_64_HANDLER) += \
  66. book3s_hv_hmi.o \
  67. book3s_hv_rmhandlers.o \
  68. book3s_hv_rm_mmu.o \
  69. book3s_hv_ras.o \
  70. book3s_hv_builtin.o \
  71. $(kvm-book3s_64-builtin-xics-objs-y)
  72. endif
  73. kvm-book3s_64-objs-$(CONFIG_KVM_XICS) += \
  74. book3s_xics.o
  75. kvm-book3s_64-module-objs := \
  76. $(common-objs-y) \
  77. book3s.o \
  78. book3s_64_vio.o \
  79. book3s_rtas.o \
  80. $(kvm-book3s_64-objs-y)
  81. kvm-objs-$(CONFIG_KVM_BOOK3S_64) := $(kvm-book3s_64-module-objs)
  82. kvm-book3s_32-objs := \
  83. $(common-objs-y) \
  84. emulate.o \
  85. fpu.o \
  86. book3s_paired_singles.o \
  87. book3s.o \
  88. book3s_pr.o \
  89. book3s_emulate.o \
  90. book3s_interrupts.o \
  91. book3s_mmu_hpte.o \
  92. book3s_32_mmu_host.o \
  93. book3s_32_mmu.o
  94. kvm-objs-$(CONFIG_KVM_BOOK3S_32) := $(kvm-book3s_32-objs)
  95. kvm-objs-$(CONFIG_KVM_MPIC) += mpic.o
  96. kvm-objs-$(CONFIG_HAVE_KVM_IRQ_ROUTING) += $(KVM)/irqchip.o
  97. kvm-objs := $(kvm-objs-m) $(kvm-objs-y)
  98. obj-$(CONFIG_KVM_E500V2) += kvm.o
  99. obj-$(CONFIG_KVM_E500MC) += kvm.o
  100. obj-$(CONFIG_KVM_BOOK3S_64) += kvm.o
  101. obj-$(CONFIG_KVM_BOOK3S_32) += kvm.o
  102. obj-$(CONFIG_KVM_BOOK3S_64_PR) += kvm-pr.o
  103. obj-$(CONFIG_KVM_BOOK3S_64_HV) += kvm-hv.o
  104. obj-y += $(kvm-book3s_64-builtin-objs-y)