0051-kernel-remove-packaging-of-kmod-crypto-core-and-kmod-crypto-arc4.patch 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. From: Matthias Schiffer <mschiffer@universe-factory.net>
  2. Date: Thu, 16 Jun 2016 03:42:03 +0200
  3. Subject: kernel: remove packaging of kmod-crypto-core and kmod-crypto-arc4
  4. Everything except for blkcipher was already built-in, so make blkcipher
  5. built-in as well.
  6. Signed-off-by: Felix Fietkau <nbd@openwrt.org>
  7. Backport of OpenWrt r46820
  8. The packages kmod-crypto-{core,arc4} are added to kernel PROVIDES to
  9. satisfy dependencies of CC packages.
  10. diff --git a/package/kernel/linux/Makefile b/package/kernel/linux/Makefile
  11. index b06c49a92fd396e8edcb0ca7a7a94b74b05a87e0..19bcbd582ba06cb8cdb9ee869c50a67dbfd470bb 100644
  12. --- a/package/kernel/linux/Makefile
  13. +++ b/package/kernel/linux/Makefile
  14. @@ -49,7 +49,7 @@ define Package/kernel
  15. TITLE:=Virtual kernel package
  16. VERSION:=$(LINUX_VERSION)-$(LINUX_RELEASE)-$(LINUX_VERMAGIC)
  17. URL:=http://www.kernel.org/
  18. - PROVIDES:=$(if $(CONFIG_IPV6),kmod-ipv6)
  19. + PROVIDES:=kmod-crypto-core kmod-crypto-arc4 $(if $(CONFIG_IPV6),kmod-ipv6)
  20. endef
  21. define Package/kernel/install
  22. diff --git a/package/kernel/linux/modules/crypto.mk b/package/kernel/linux/modules/crypto.mk
  23. index c8e0fbb04397c9b1fa7ebde3579f663b5d756e1b..926dab0e3379efbc92aeac865b02673928c18644 100644
  24. --- a/package/kernel/linux/modules/crypto.mk
  25. +++ b/package/kernel/linux/modules/crypto.mk
  26. @@ -15,24 +15,9 @@ crypto_confvar=CONFIG_CRYPTO_$(word 1,$(subst =,$(space),$(1)))
  27. crypto_file=$(LINUX_DIR)/crypto/$(word 2,$(subst =,$(space),$(1))).ko
  28. crypto_name=$(if $(findstring y,$($(call crypto_confvar,$(1)))),,$(word 2,$(subst =,$(space),$(1))))
  29. -define KernelPackage/crypto-core
  30. - SUBMENU:=$(CRYPTO_MENU)
  31. - TITLE:=Core CryptoAPI modules
  32. - KCONFIG:= \
  33. - CONFIG_CRYPTO=y \
  34. - CONFIG_CRYPTO_HW=y \
  35. - CONFIG_CRYPTO_BLKCIPHER \
  36. - CONFIG_CRYPTO_ALGAPI \
  37. - $(foreach mod,$(CRYPTO_MODULES),$(call crypto_confvar,$(mod)))
  38. - FILES:=$(foreach mod,$(CRYPTO_MODULES),$(call crypto_file,$(mod)))
  39. -endef
  40. -
  41. -$(eval $(call KernelPackage,crypto-core))
  42. -
  43. -
  44. define AddDepends/crypto
  45. SUBMENU:=$(CRYPTO_MENU)
  46. - DEPENDS+=+kmod-crypto-core $(1)
  47. + DEPENDS+= $(1)
  48. endef
  49. define KernelPackage/crypto-aead
  50. @@ -272,17 +257,6 @@ endif
  51. $(eval $(call KernelPackage,crypto-aes))
  52. -define KernelPackage/crypto-arc4
  53. - TITLE:=ARC4 (RC4) cipher CryptoAPI module
  54. - KCONFIG:=CONFIG_CRYPTO_ARC4
  55. - FILES:=$(LINUX_DIR)/crypto/arc4.ko
  56. - AUTOLOAD:=$(call AutoLoad,09,arc4)
  57. - $(call AddDepends/crypto)
  58. -endef
  59. -
  60. -$(eval $(call KernelPackage,crypto-arc4))
  61. -
  62. -
  63. define KernelPackage/crypto-authenc
  64. TITLE:=Combined mode wrapper for IPsec
  65. DEPENDS:=+kmod-crypto-manager
  66. diff --git a/package/kernel/linux/modules/fs.mk b/package/kernel/linux/modules/fs.mk
  67. index fa182375ea8b0224753141620bd168328194ddf4..cc87a45961d04d93badce575530495f994deee86 100644
  68. --- a/package/kernel/linux/modules/fs.mk
  69. +++ b/package/kernel/linux/modules/fs.mk
  70. @@ -91,7 +91,6 @@ define KernelPackage/fs-cifs
  71. AUTOLOAD:=$(call AutoLoad,30,cifs)
  72. $(call AddDepends/nls)
  73. DEPENDS+= \
  74. - +kmod-crypto-arc4 \
  75. +kmod-crypto-hmac \
  76. +kmod-crypto-md5 \
  77. +kmod-crypto-md4 \
  78. diff --git a/package/kernel/linux/modules/netsupport.mk b/package/kernel/linux/modules/netsupport.mk
  79. index 8a2760d8a4a429f206eba41a8c83432e5b6ddab7..ab76946d2ab30e748ea5bc69c24051dbfc411036 100644
  80. --- a/package/kernel/linux/modules/netsupport.mk
  81. +++ b/package/kernel/linux/modules/netsupport.mk
  82. @@ -714,7 +714,7 @@ $(eval $(call KernelPackage,ipoa))
  83. define KernelPackage/mppe
  84. SUBMENU:=$(NETWORK_SUPPORT_MENU)
  85. TITLE:=Microsoft PPP compression/encryption
  86. - DEPENDS:=kmod-ppp +kmod-crypto-core +kmod-crypto-arc4 +kmod-crypto-sha1 +kmod-crypto-ecb
  87. + DEPENDS:=kmod-ppp +kmod-crypto-sha1 +kmod-crypto-ecb
  88. KCONFIG:= \
  89. CONFIG_PPP_MPPE_MPPC \
  90. CONFIG_PPP_MPPE
  91. @@ -998,7 +998,7 @@ define KernelPackage/rxrpc
  92. $(LINUX_DIR)/net/rxrpc/af-rxrpc.ko \
  93. $(LINUX_DIR)/net/rxrpc/rxkad.ko
  94. AUTOLOAD:=$(call AutoLoad,30,rxkad af-rxrpc)
  95. - DEPENDS:=+kmod-crypto-core +kmod-crypto-manager +kmod-crypto-pcbc +kmod-crypto-fcrypt
  96. + DEPENDS:= +kmod-crypto-manager +kmod-crypto-pcbc +kmod-crypto-fcrypt
  97. endef
  98. define KernelPackage/rxrpc/description
  99. diff --git a/target/linux/generic/config-3.18 b/target/linux/generic/config-3.18
  100. index 6038692b7e81334e4864d30453f734f4fe829aa0..a0dc3c9b607abe32c1ca021b7fad293a8f742ec1 100644
  101. --- a/target/linux/generic/config-3.18
  102. +++ b/target/linux/generic/config-3.18
  103. @@ -700,9 +700,10 @@ CONFIG_CRYPTO_ALGAPI=y
  104. CONFIG_CRYPTO_ALGAPI2=y
  105. # CONFIG_CRYPTO_ANSI_CPRNG is not set
  106. # CONFIG_CRYPTO_ANUBIS is not set
  107. -# CONFIG_CRYPTO_ARC4 is not set
  108. +CONFIG_CRYPTO_ARC4=y
  109. # CONFIG_CRYPTO_AUTHENC is not set
  110. -# CONFIG_CRYPTO_BLKCIPHER is not set
  111. +CONFIG_CRYPTO_BLKCIPHER=y
  112. +CONFIG_CRYPTO_BLKCIPHER2=y
  113. # CONFIG_CRYPTO_BLOWFISH is not set
  114. # CONFIG_CRYPTO_CAMELLIA is not set
  115. # CONFIG_CRYPTO_CAST5 is not set
  116. diff --git a/target/linux/omap/config-3.18 b/target/linux/omap/config-3.18
  117. index a06a350a37c035c66ec8d6242f28379e7992685e..d5003c275b2b2a167d4614f5e33269941a02173e 100644
  118. --- a/target/linux/omap/config-3.18
  119. +++ b/target/linux/omap/config-3.18
  120. @@ -114,9 +114,6 @@ CONFIG_CPU_V7=y
  121. CONFIG_CRC16=y
  122. CONFIG_CRYPTO_AEAD=m
  123. CONFIG_CRYPTO_AEAD2=m
  124. -CONFIG_CRYPTO_ARC4=m
  125. -CONFIG_CRYPTO_BLKCIPHER=m
  126. -CONFIG_CRYPTO_BLKCIPHER2=m
  127. CONFIG_CRYPTO_CCM=m
  128. CONFIG_CRYPTO_CRC32C=y
  129. CONFIG_CRYPTO_CTR=m
  130. diff --git a/target/linux/sunxi/config-3.18 b/target/linux/sunxi/config-3.18
  131. index ddc3f7acb82064fb3be16f5111b0c4344b01c362..57651bbd65ebc61b14d45aefaaf20e5b8d59e27a 100644
  132. --- a/target/linux/sunxi/config-3.18
  133. +++ b/target/linux/sunxi/config-3.18
  134. @@ -110,9 +110,6 @@ CONFIG_CPU_TLB_V7=y
  135. CONFIG_CPU_V7=y
  136. CONFIG_CRC16=y
  137. CONFIG_CRC_T10DIF=y
  138. -CONFIG_CRYPTO_ARC4=y
  139. -CONFIG_CRYPTO_BLKCIPHER=y
  140. -CONFIG_CRYPTO_BLKCIPHER2=y
  141. CONFIG_CRYPTO_CRC32C=y
  142. CONFIG_CRYPTO_CRCT10DIF=y
  143. CONFIG_CRYPTO_DES=y