Makefile 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. #
  2. # Arch-specific CryptoAPI modules.
  3. #
  4. obj-$(CONFIG_CRYPTO_AES_ARM) += aes-arm.o
  5. obj-$(CONFIG_CRYPTO_AES_ARM_BS) += aes-arm-bs.o
  6. obj-$(CONFIG_CRYPTO_SHA1_ARM) += sha1-arm.o
  7. obj-$(CONFIG_CRYPTO_SHA1_ARM_NEON) += sha1-arm-neon.o
  8. obj-$(CONFIG_CRYPTO_SHA256_ARM) += sha256-arm.o
  9. obj-$(CONFIG_CRYPTO_SHA512_ARM) += sha512-arm.o
  10. ce-obj-$(CONFIG_CRYPTO_AES_ARM_CE) += aes-arm-ce.o
  11. ce-obj-$(CONFIG_CRYPTO_SHA1_ARM_CE) += sha1-arm-ce.o
  12. ce-obj-$(CONFIG_CRYPTO_SHA2_ARM_CE) += sha2-arm-ce.o
  13. ce-obj-$(CONFIG_CRYPTO_GHASH_ARM_CE) += ghash-arm-ce.o
  14. ifneq ($(ce-obj-y)$(ce-obj-m),)
  15. ifeq ($(call as-instr,.fpu crypto-neon-fp-armv8,y,n),y)
  16. obj-y += $(ce-obj-y)
  17. obj-m += $(ce-obj-m)
  18. else
  19. $(warning These ARMv8 Crypto Extensions modules need binutils 2.23 or higher)
  20. $(warning $(ce-obj-y) $(ce-obj-m))
  21. endif
  22. endif
  23. aes-arm-y := aes-armv4.o aes_glue.o
  24. aes-arm-bs-y := aesbs-core.o aesbs-glue.o
  25. sha1-arm-y := sha1-armv4-large.o sha1_glue.o
  26. sha1-arm-neon-y := sha1-armv7-neon.o sha1_neon_glue.o
  27. sha256-arm-neon-$(CONFIG_KERNEL_MODE_NEON) := sha256_neon_glue.o
  28. sha256-arm-y := sha256-core.o sha256_glue.o $(sha256-arm-neon-y)
  29. sha512-arm-neon-$(CONFIG_KERNEL_MODE_NEON) := sha512-neon-glue.o
  30. sha512-arm-y := sha512-core.o sha512-glue.o $(sha512-arm-neon-y)
  31. sha1-arm-ce-y := sha1-ce-core.o sha1-ce-glue.o
  32. sha2-arm-ce-y := sha2-ce-core.o sha2-ce-glue.o
  33. aes-arm-ce-y := aes-ce-core.o aes-ce-glue.o
  34. ghash-arm-ce-y := ghash-ce-core.o ghash-ce-glue.o
  35. quiet_cmd_perl = PERL $@
  36. cmd_perl = $(PERL) $(<) > $(@)
  37. $(src)/aesbs-core.S_shipped: $(src)/bsaes-armv7.pl
  38. $(call cmd,perl)
  39. $(src)/sha256-core.S_shipped: $(src)/sha256-armv4.pl
  40. $(call cmd,perl)
  41. $(src)/sha512-core.S_shipped: $(src)/sha512-armv4.pl
  42. $(call cmd,perl)
  43. .PRECIOUS: $(obj)/aesbs-core.S $(obj)/sha256-core.S $(obj)/sha512-core.S