From d100e7268dc869ede6c06ba0a4af0a1408dd96ae Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Sat, 16 Apr 2016 21:05:48 +0000 Subject: kernel: update kernel 4.4 to version 4.4.7 Signed-off-by: Hauke Mehrtens git-svn-id: svn://svn.openwrt.org/openwrt/trunk@49176 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- ...-add-hash-state-import-and-export-support.patch | 114 --------------------- .../patches-4.4/210-darwin_scripts_include.patch | 2 +- ...rc-enable-unaligned-access-in-kernel-mode.patch | 7 +- .../patches-4.4/773-bgmac-add-srab-switch.patch | 4 +- 4 files changed, 4 insertions(+), 123 deletions(-) delete mode 100644 target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch (limited to 'target/linux/generic') diff --git a/target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch b/target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch deleted file mode 100644 index 986ac5d253..0000000000 --- a/target/linux/generic/patches-4.4/150-crypto-ccp-add-hash-state-import-and-export-support.patch +++ /dev/null @@ -1,114 +0,0 @@ -From: Tom Lendacky -Subject: [PATCH v1] crypto: ccp - Add hash state import and export support -Date: Tue, 12 Jan 2016 11:17:38 -0600 -Message-ID: <20160112171738.23496.44254.stgit@tlendack-t1.amdoffice.net> -Mime-Version: 1.0 -Content-Type: text/plain; charset="utf-8" -Content-Transfer-Encoding: 7bit -Cc: Herbert Xu , , - "David Miller" -To: - -Commit 8996eafdcbad ("crypto: ahash - ensure statesize is non-zero") -added a check to prevent ahash algorithms from successfully registering -if the import and export functions were not implemented. This prevents -an oops in the hash_accept function of algif_hash. This commit causes -the ccp-crypto module SHA support and AES CMAC support from successfully -registering and causing the ccp-crypto module load to fail because the -ahash import and export functions are not implemented. - -Update the CCP Crypto API support to provide import and export support -for ahash algorithms. - -Cc: # 3.14.x- -Signed-off-by: Tom Lendacky ---- - drivers/crypto/ccp/ccp-crypto-aes-cmac.c | 23 +++++++++++++++++++++++ - drivers/crypto/ccp/ccp-crypto-sha.c | 23 +++++++++++++++++++++++ - 2 files changed, 46 insertions(+) - ---- a/drivers/crypto/ccp/ccp-crypto-aes-cmac.c -+++ b/drivers/crypto/ccp/ccp-crypto-aes-cmac.c -@@ -220,6 +220,26 @@ static int ccp_aes_cmac_digest(struct ah - return ccp_aes_cmac_finup(req); - } - -+static int ccp_aes_cmac_export(struct ahash_request *req, void *out) -+{ -+ struct ccp_aes_cmac_req_ctx *rctx = ahash_request_ctx(req); -+ struct ccp_aes_cmac_req_ctx *state = out; -+ -+ *state = *rctx; -+ -+ return 0; -+} -+ -+static int ccp_aes_cmac_import(struct ahash_request *req, const void *in) -+{ -+ struct ccp_aes_cmac_req_ctx *rctx = ahash_request_ctx(req); -+ const struct ccp_aes_cmac_req_ctx *state = in; -+ -+ *rctx = *state; -+ -+ return 0; -+} -+ - static int ccp_aes_cmac_setkey(struct crypto_ahash *tfm, const u8 *key, - unsigned int key_len) - { -@@ -352,10 +372,13 @@ int ccp_register_aes_cmac_algs(struct li - alg->final = ccp_aes_cmac_final; - alg->finup = ccp_aes_cmac_finup; - alg->digest = ccp_aes_cmac_digest; -+ alg->export = ccp_aes_cmac_export; -+ alg->import = ccp_aes_cmac_import; - alg->setkey = ccp_aes_cmac_setkey; - - halg = &alg->halg; - halg->digestsize = AES_BLOCK_SIZE; -+ halg->statesize = sizeof(struct ccp_aes_cmac_req_ctx); - - base = &halg->base; - snprintf(base->cra_name, CRYPTO_MAX_ALG_NAME, "cmac(aes)"); ---- a/drivers/crypto/ccp/ccp-crypto-sha.c -+++ b/drivers/crypto/ccp/ccp-crypto-sha.c -@@ -207,6 +207,26 @@ static int ccp_sha_digest(struct ahash_r - return ccp_sha_finup(req); - } - -+static int ccp_sha_export(struct ahash_request *req, void *out) -+{ -+ struct ccp_sha_req_ctx *rctx = ahash_request_ctx(req); -+ struct ccp_sha_req_ctx *state = out; -+ -+ *state = *rctx; -+ -+ return 0; -+} -+ -+static int ccp_sha_import(struct ahash_request *req, const void *in) -+{ -+ struct ccp_sha_req_ctx *rctx = ahash_request_ctx(req); -+ const struct ccp_sha_req_ctx *state = in; -+ -+ *rctx = *state; -+ -+ return 0; -+} -+ - static int ccp_sha_setkey(struct crypto_ahash *tfm, const u8 *key, - unsigned int key_len) - { -@@ -403,9 +423,12 @@ static int ccp_register_sha_alg(struct l - alg->final = ccp_sha_final; - alg->finup = ccp_sha_finup; - alg->digest = ccp_sha_digest; -+ alg->export = ccp_sha_export; -+ alg->import = ccp_sha_import; - - halg = &alg->halg; - halg->digestsize = def->digest_size; -+ halg->statesize = sizeof(struct ccp_sha_req_ctx); - - base = &halg->base; - snprintf(base->cra_name, CRYPTO_MAX_ALG_NAME, "%s", def->name); diff --git a/target/linux/generic/patches-4.4/210-darwin_scripts_include.patch b/target/linux/generic/patches-4.4/210-darwin_scripts_include.patch index 59ab5ad00f..2afeb23b52 100644 --- a/target/linux/generic/patches-4.4/210-darwin_scripts_include.patch +++ b/target/linux/generic/patches-4.4/210-darwin_scripts_include.patch @@ -38,7 +38,7 @@ #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof(arr[0])) --- a/scripts/kconfig/Makefile +++ b/scripts/kconfig/Makefile -@@ -159,6 +159,9 @@ check-lxdialog := $(srctree)/$(src)/lxd +@@ -161,6 +161,9 @@ check-lxdialog := $(srctree)/$(src)/lxd # we really need to do so. (Do not call gcc as part of make mrproper) HOST_EXTRACFLAGS += $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) \ -DLOCALE diff --git a/target/linux/generic/patches-4.4/333-arc-enable-unaligned-access-in-kernel-mode.patch b/target/linux/generic/patches-4.4/333-arc-enable-unaligned-access-in-kernel-mode.patch index 76a9ce8968..082f525f1b 100644 --- a/target/linux/generic/patches-4.4/333-arc-enable-unaligned-access-in-kernel-mode.patch +++ b/target/linux/generic/patches-4.4/333-arc-enable-unaligned-access-in-kernel-mode.patch @@ -13,11 +13,9 @@ Signed-off-by: Alexey Brodkin arch/arc/kernel/unaligned.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -diff --git a/arch/arc/kernel/unaligned.c b/arch/arc/kernel/unaligned.c -index abd961f..0b0cc97 100644 --- a/arch/arc/kernel/unaligned.c +++ b/arch/arc/kernel/unaligned.c -@@ -206,7 +206,7 @@ int misaligned_fixup(unsigned long address, struct pt_regs *regs, +@@ -206,7 +206,7 @@ int misaligned_fixup(unsigned long addre char buf[TASK_COMM_LEN]; /* handle user mode only and only if enabled by sysadmin */ @@ -26,6 +24,3 @@ index abd961f..0b0cc97 100644 return 1; if (no_unaligned_warning) { --- -2.5.0 - diff --git a/target/linux/generic/patches-4.4/773-bgmac-add-srab-switch.patch b/target/linux/generic/patches-4.4/773-bgmac-add-srab-switch.patch index 46f01d03a8..8a68e7e401 100644 --- a/target/linux/generic/patches-4.4/773-bgmac-add-srab-switch.patch +++ b/target/linux/generic/patches-4.4/773-bgmac-add-srab-switch.patch @@ -30,7 +30,7 @@ Signed-off-by: Hauke Mehrtens /************************************************** * BCMA bus ops **************************************************/ -@@ -1686,6 +1698,14 @@ static int bgmac_probe(struct bcma_devic +@@ -1688,6 +1700,14 @@ static int bgmac_probe(struct bcma_devic net_dev->hw_features = net_dev->features; net_dev->vlan_features = net_dev->features; @@ -45,7 +45,7 @@ Signed-off-by: Hauke Mehrtens err = register_netdev(bgmac->net_dev); if (err) { bgmac_err(bgmac, "Cannot register net device\n"); -@@ -1712,6 +1732,10 @@ static void bgmac_remove(struct bcma_dev +@@ -1714,6 +1734,10 @@ static void bgmac_remove(struct bcma_dev { struct bgmac *bgmac = bcma_get_drvdata(core); -- cgit v1.2.3