From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from e23smtp08.au.ibm.com ([202.81.31.141]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aTdyw-0002FN-Vb for kexec@lists.infradead.org; Wed, 10 Feb 2016 23:15:35 +0000 Received: from localhost by e23smtp08.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 11 Feb 2016 09:15:09 +1000 Received: from d23relay09.au.ibm.com (d23relay09.au.ibm.com [9.185.63.181]) by d23dlp03.au.ibm.com (Postfix) with ESMTP id 2737C3578057 for ; Thu, 11 Feb 2016 10:15:04 +1100 (EST) Received: from d23av02.au.ibm.com (d23av02.au.ibm.com [9.190.235.138]) by d23relay09.au.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u1ANEtxm40829020 for ; Thu, 11 Feb 2016 10:15:03 +1100 Received: from d23av02.au.ibm.com (localhost [127.0.0.1]) by d23av02.au.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u1ANEV2O022119 for ; Thu, 11 Feb 2016 10:14:31 +1100 Message-ID: <1455146051.2538.230.camel@linux.vnet.ibm.com> Subject: Re: [PATCH v3 17/22] ima: remove firmware and module specific cached status info From: Mimi Zohar Date: Wed, 10 Feb 2016 18:14:11 -0500 In-Reply-To: References: <1454526390-19792-1-git-send-email-zohar@linux.vnet.ibm.com> <1454526390-19792-18-git-send-email-zohar@linux.vnet.ibm.com> Mime-Version: 1.0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "kexec" Errors-To: kexec-bounces+dwmw2=infradead.org@lists.infradead.org To: Dmitry Kasatkin Cc: Rusty Russell , Kees Cook , fsdevel@vger.kernel.org, "Luis R. Rodriguez" , Dmitry Torokhov , kexec@lists.infradead.org, David Howells , linux-security-module , Eric Biederman , David Woodhouse , linux-modules@vger.kernel.org On Wed, 2016-02-10 at 22:18 +0200, Dmitry Kasatkin wrote: > > diff --git a/security/integrity/ima/ima_appraise.c b/security/integrity/ima/ima_appraise.c > > index cb0d0ff..6b4694a 100644 > > --- a/security/integrity/ima/ima_appraise.c > > +++ b/security/integrity/ima/ima_appraise.c > > @@ -74,13 +74,12 @@ enum integrity_status ima_get_cache_status(struct integrity_iint_cache *iint, > > return iint->ima_mmap_status; > > case BPRM_CHECK: > > return iint->ima_bprm_status; > > - case MODULE_CHECK: > > - return iint->ima_module_status; > > - case FIRMWARE_CHECK: > > - return iint->ima_firmware_status; > > case FILE_CHECK: > > - default: > > + case POST_SETATTR: > > return iint->ima_file_status; > > + case MODULE_CHECK ... MAX_CHECK - 1: > > Will LLVM clang handles this range? > > Otherwise it can be just like: > > case MODULE_CHECK ... MAX_CHECK : Yes, my test program compiled fine with clang. Similar usage exists in the kernel (eg. fs/afs/callback.c). Mimi _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec