Re: [PATCH v3 5/5] firmware: add an extensible system data helpers
Hi Luis, [auto build test WARNING on v4.4-rc6] [also build test WARNING on next-20151223] url: https://github.com/0day-ci/linux/commits/Luis-R-Rodriguez/firmware_class-extensible-firmware-API/20151224-053852 reproduce: make htmldocs All warnings (new ones prefixed by >>): include/linux/init.h:1: warning: no structured comments found kernel/sys.c:1: warning: no structured comments found >> drivers/base/firmware_class.c:1336: warning: No description found for >> parameter 'sysdata' >> drivers/base/firmware_class.c:1336: warning: Excess function parameter >> 'sysdata_file' description in 'release_sysdata_file' drivers/dma-buf/seqno-fence.c:1: warning: no structured comments found drivers/dma-buf/reservation.c:1: warning: no structured comments found include/linux/reservation.h:1: warning: no structured comments found include/linux/hsi/hsi.h:150: warning: Excess struct/union/enum/typedef member 'e_handler' description in 'hsi_client' include/linux/hsi/hsi.h:150: warning: Excess struct/union/enum/typedef member 'pclaimed' description in 'hsi_client' include/linux/hsi/hsi.h:150: warning: Excess struct/union/enum/typedef member 'nb' description in 'hsi_client' vim +/sysdata +1336 drivers/base/firmware_class.c 1320 __func__); 1321 return -ENOMEM; 1322 } 1323 1324 ret = _request_firmware_prepare(, name, device); 1325 if (ret >= 0) 1326 sysdata->priv = fw; 1327 1328 return ret; 1329 } 1330 1331 /** 1332 * release_sysdata_file: - release the resource associated with the sysdata file 1333 * @sysdata_file: sysdata resource to release 1334 **/ 1335 void release_sysdata_file(const struct sysdata_file *sysdata) > 1336 { 1337 struct firmware *fw; 1338 1339 if (sysdata) { 1340 if (sysdata->priv) { 1341 fw = sysdata->priv; 1342 release_firmware(fw); 1343 } 1344 } --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: Binary data
Re: [PATCH v3 1/2] crypto: KEYS: convert public key to the akcipher api
Hi Tadeusz, [auto build test ERROR on cryptodev/master] [also build test ERROR on v4.4-rc6 next-20151223] url: https://github.com/0day-ci/linux/commits/Tadeusz-Struk/crypto-KEYS-convert-public-key-to-akcipher-api/20151223-132001 base: https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git master config: xtensa-allyesconfig (attached as .config) reproduce: wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree make.cross ARCH=xtensa Note: the linux-review/Tadeusz-Struk/crypto-KEYS-convert-public-key-to-akcipher-api/20151223-132001 HEAD 06fa55a0feec438fdc649cdac682af7ab99f8099 builds fine. It only hurts bisectibility. All errors (new ones prefixed by >>): security/integrity/digsig_asymmetric.c: In function 'asymmetric_verify': >> security/integrity/digsig_asymmetric.c:95:5: error: 'struct >> public_key_signature' has no member named 'nr_mpi' pks.nr_mpi = 1; ^ >> security/integrity/digsig_asymmetric.c:96:5: error: 'struct >> public_key_signature' has no member named 'rsa' pks.rsa.s = mpi_read_raw_data(hdr->sig, siglen); ^ >> security/integrity/digsig_asymmetric.c:96:2: error: implicit declaration of >> function 'mpi_read_raw_data' [-Werror=implicit-function-declaration] pks.rsa.s = mpi_read_raw_data(hdr->sig, siglen); ^ security/integrity/digsig_asymmetric.c:98:9: error: 'struct public_key_signature' has no member named 'rsa' if (pks.rsa.s) ^ >> security/integrity/digsig_asymmetric.c:101:2: error: implicit declaration of >> function 'mpi_free' [-Werror=implicit-function-declaration] mpi_free(pks.rsa.s); ^ security/integrity/digsig_asymmetric.c:101:14: error: 'struct public_key_signature' has no member named 'rsa' mpi_free(pks.rsa.s); ^ cc1: some warnings being treated as errors vim +95 security/integrity/digsig_asymmetric.c e0751257 Dmitry Kasatkin 2013-02-07 89 e0751257 Dmitry Kasatkin 2013-02-07 90memset(, 0, sizeof(pks)); e0751257 Dmitry Kasatkin 2013-02-07 91 e0751257 Dmitry Kasatkin 2013-02-07 92pks.pkey_hash_algo = hdr->hash_algo; e0751257 Dmitry Kasatkin 2013-02-07 93pks.digest = (u8 *)data; e0751257 Dmitry Kasatkin 2013-02-07 94pks.digest_size = datalen; e0751257 Dmitry Kasatkin 2013-02-07 @95pks.nr_mpi = 1; e0751257 Dmitry Kasatkin 2013-02-07 @96pks.rsa.s = mpi_read_raw_data(hdr->sig, siglen); e0751257 Dmitry Kasatkin 2013-02-07 97 e0751257 Dmitry Kasatkin 2013-02-07 98if (pks.rsa.s) e0751257 Dmitry Kasatkin 2013-02-07 99ret = verify_signature(key, ); e0751257 Dmitry Kasatkin 2013-02-07 100 e0751257 Dmitry Kasatkin 2013-02-07 @101mpi_free(pks.rsa.s); e0751257 Dmitry Kasatkin 2013-02-07 102key_put(key); e0751257 Dmitry Kasatkin 2013-02-07 103pr_debug("%s() = %d\n", __func__, ret); e0751257 Dmitry Kasatkin 2013-02-07 104return ret; :: The code at line 95 was first introduced by commit :: e0751257a64ea10cca96ccb06522bfb10e36cb5b ima: digital signature verification using asymmetric keys :: TO: Dmitry Kasatkin:: CC: Mimi Zohar --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: Binary data
Re: [PATCH v2 1/2] crypto: KEYS: convert public key to the akcipher api
Hi Tadeusz, [auto build test ERROR on crypto/master] [also build test ERROR on v4.4-rc5 next-20151218] url: https://github.com/0day-ci/linux/commits/Tadeusz-Struk/crypto-KEYS-convert-public-key-to-akcipher-api/20151213-103429 base: https://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6.git master config: x86_64-randconfig-s4-12200710 (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): In file included from include/crypto/public_key.h:17:0, from include/linux/verify_pefile.h:15, from arch/x86/kernel/kexec-bzimage64.c:22: include/keys/asymmetric-type.h: In function 'asymmetric_key_ids': >> include/keys/asymmetric-type.h:74:12: error: dereferencing pointer to >> incomplete type 'const struct key' return key->payload.data[asym_key_ids]; ^ vim +74 include/keys/asymmetric-type.h 7901c1a8 David Howells 2014-09-16 68 size_t len_1, 7901c1a8 David Howells 2014-09-16 69 const void *val_2, 7901c1a8 David Howells 2014-09-16 70 size_t len_2); 146aa8b1 David Howells 2015-10-21 71 static inline 146aa8b1 David Howells 2015-10-21 72 const struct asymmetric_key_ids *asymmetric_key_ids(const struct key *key) 146aa8b1 David Howells 2015-10-21 73 { 146aa8b1 David Howells 2015-10-21 @74 return key->payload.data[asym_key_ids]; 146aa8b1 David Howells 2015-10-21 75 } 7901c1a8 David Howells 2014-09-16 76 7901c1a8 David Howells 2014-09-16 77 /* :: The code at line 74 was first introduced by commit :: 146aa8b1453bd8f1ff2304ffb71b4ee0eb9acdcc KEYS: Merge the type-specific data with the payload data :: TO: David Howells:: CC: David Howells --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: Binary data
Re: [PATCH v3] keys, trusted: select hash algorithm for TPM2 chips
Hi Jarkko, [auto build test ERROR on: security/next] [also build test ERROR on: next-20151105] [cannot apply to: v4.3] url: https://github.com/0day-ci/linux/commits/Jarkko-Sakkinen/keys-trusted-select-hash-algorithm-for-TPM2-chips/20151106-010236 base: https://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security.git next config: x86_64-randconfig-s4-11060055 (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): >> ERROR: "hash_algo_name" [drivers/char/tpm/tpm.ko] undefined! --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: Binary data
Re: [PATCH v3] keys, trusted: select hash algorithm for TPM2 chips
Hi Jarkko, [auto build test ERROR on: security/next] [also build test ERROR on: next-20151105] [cannot apply to: v4.3] url: https://github.com/0day-ci/linux/commits/Jarkko-Sakkinen/keys-trusted-select-hash-algorithm-for-TPM2-chips/20151106-010236 base: https://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security.git next config: i386-randconfig-h0-11060637 (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=i386 All errors (new ones prefixed by >>): drivers/built-in.o: In function `tpm2_seal_trusted': >> (.text+0xe3617): undefined reference to `hash_algo_name' --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: Binary data
Re: [PATCH v1 3/4] keys, trusted: select the hash algorithm
Hi Jarkko, [auto build test ERROR on next-20151022 -- if it's inappropriate base, please suggest rules for selecting the more suitable base] url: https://github.com/0day-ci/linux/commits/Jarkko-Sakkinen/TPM2-select-hash-algorithm-for-a-trusted-key/20151030-000439 config: x86_64-acpi-redef (attached as .config) reproduce: # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): security/built-in.o: In function `getoptions.isra.0': >> trusted.c:(.text+0x6678): undefined reference to `hash_algo_name' --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: Binary data
Re: [PATCH v4 1/2] create SMAF module
Hi Benjamin, [auto build test ERROR on v4.3-rc4 -- if it's inappropriate base, please ignore] config: s390-allmodconfig (attached as .config) reproduce: wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree make.cross ARCH=s390 All error/warnings (new ones prefixed by >>): In file included from arch/s390/include/asm/elf.h:130:0, from include/linux/elf.h:4, from include/linux/module.h:15, from drivers/smaf/smaf-core.c:16: drivers/smaf/smaf-core.c: In function 'smaf_unsecure_handle': >> arch/s390/include/asm/mmu_context.h:33:41: error: expected identifier before >> 'do' #define destroy_context(mm) do { } while (0) ^ >> drivers/smaf/smaf-core.c:136:23: note: in expansion of macro >> 'destroy_context' if (smaf_dev.secure->destroy_context(handle->secure_ctx)) ^ vim +/destroy_context +136 drivers/smaf/smaf-core.c 10 #include 11 #include 12 #include 13 #include 14 #include 15 #include > 16 #include 17 #include 18 #include 19 #include 20 #include 21 #include 22 23 struct smaf_handle { 24 struct dma_buf *dmabuf; 25 struct smaf_allocator *allocator; 26 struct dma_buf *db_alloc; 27 size_t length; 28 unsigned int flags; 29 int fd; 30 bool is_secure; 31 void *secure_ctx; 32 }; 33 34 /** 35 * struct smaf_device - smaf device node private data 36 * @misc_dev: the misc device 37 * @head: list of allocator 38 * @lock: list and secure pointer mutex 39 * @secure: pointer to secure functions helpers 40 */ 41 struct smaf_device { 42 struct miscdevice misc_dev; 43 struct list_head head; 44 /* list and secure pointer lock*/ 45 struct mutex lock; 46 struct smaf_secure *secure; 47 }; 48 49 static struct smaf_device smaf_dev; 50 51 /** 52 * smaf_allow_cpu_access return true if CPU can access to memory 53 * if their is no secure module associated to SMAF assume that CPU can get 54 * access to the memory. 55 */ 56 static bool smaf_allow_cpu_access(struct smaf_handle *handle, 57unsigned long flags) 58 { 59 if (!handle->is_secure) 60 return true; 61 62 if (!smaf_dev.secure) 63 return true; 64 65 if (!smaf_dev.secure->allow_cpu_access) 66 return true; 67 68 return smaf_dev.secure->allow_cpu_access(handle->secure_ctx, flags); 69 } 70 71 static int smaf_grant_access(struct smaf_handle *handle, struct device *dev, 72 dma_addr_t addr, size_t size, 73 enum dma_data_direction dir) 74 { 75 if (!handle->is_secure) 76 return 0; 77 78 if (!smaf_dev.secure) 79 return -EINVAL; 80 81 if (!smaf_dev.secure->grant_access) 82 return -EINVAL; 83 84 return smaf_dev.secure->grant_access(handle->secure_ctx, 85 dev, addr, size, dir); 86 } 87 88 static void smaf_revoke_access(struct smaf_handle *handle, struct device *dev, 89 dma_addr_t addr, size_t size, 90 enum dma_data_direction dir) 91 { 92 if (!handle->is_secure) 93 return; 94 95 if (!smaf_dev.secure) 96 return; 97 98 if (!smaf_dev.secure->revoke_access) 99 return; 100 101 smaf_dev.secure->revoke_access(handle->secure_ctx, 102 dev, addr, size, dir); 103 } 104 105 static int smaf_secure_handle(struct smaf_handle *handle) 106 { 107 if (handle->is_secure) 108 return 0; 109 110 if (!smaf_dev.secure) 111 return -EINVAL; 112 113 if (!smaf_dev.secure->create_context) 114 return -EINVAL; 115 116 handle->secure_ctx = smaf_dev.secure->create_context(); 117 118 if (!handle->secure_ctx) 119 return -EINVAL; 120 121 handle->is_secure = true; 122 return 0; 123 } 124 125 static int
Re: [PATCH v4 2/2] SMAF: add CMA allocator
Hi Benjamin, [auto build test WARNING on v4.3-rc4 -- if it's inappropriate base, please ignore] reproduce: # apt-get install sparse make ARCH=x86_64 allmodconfig make C=1 CF=-D__CHECK_ENDIAN__ sparse warnings: (new ones prefixed by >>) >> drivers/smaf/smaf-cma.c:178:23: sparse: symbol 'smaf_cma' was not declared. >> Should it be static? Please review and possibly fold the followup patch. --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation -- To unsubscribe from this list: send the line "unsubscribe linux-security-module" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[RFC PATCH] SMAF: smaf_cma can be static
Signed-off-by: Fengguang Wu--- smaf-cma.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/smaf/smaf-cma.c b/drivers/smaf/smaf-cma.c index ab38717..9fbd9b7 100644 --- a/drivers/smaf/smaf-cma.c +++ b/drivers/smaf/smaf-cma.c @@ -175,7 +175,7 @@ error: return NULL; } -struct smaf_allocator smaf_cma = { +static struct smaf_allocator smaf_cma = { .match = smaf_cma_match, .allocate = smaf_cma_allocate, .name = "smaf-cma", -- To unsubscribe from this list: send the line "unsubscribe linux-security-module" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html