Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753129AbcKNKBY (ORCPT ); Mon, 14 Nov 2016 05:01:24 -0500 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:39837 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932310AbcKNKBV (ORCPT ); Mon, 14 Nov 2016 05:01:21 -0500 From: Nayna Jain To: tpmdd-devel@lists.sourceforge.net Cc: peterhuewe@gmx.de, tpmdd@selhorst.net, jarkko.sakkinen@linux.intel.com, jgunthorpe@obsidianresearch.com, linux-kernel@vger.kernel.org, linux-security-module@vger.kernel.org, Nayna Jain Subject: [PATCH v6 2/9] tpm: replace symbolic permission with octal for securityfs files Date: Mon, 14 Nov 2016 05:00:49 -0500 X-Mailer: git-send-email 2.5.0 In-Reply-To: <1479117656-12403-1-git-send-email-nayna@linux.vnet.ibm.com> References: <1479117656-12403-1-git-send-email-nayna@linux.vnet.ibm.com> X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16111410-0040-0000-0000-000002C5941D X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 16111410-0041-0000-0000-00000BAD7ACF Message-Id: <1479117656-12403-3-git-send-email-nayna@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-11-14_03:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=1 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609300000 definitions=main-1611140206 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1170 Lines: 35 checkpatch.pl flags warning for symbolic permissions and suggests to replace with octal value. This patch changes securityfs pseudo files permission to octal values in tpm_bios_log_setup(). Signed-off-by: Nayna Jain --- drivers/char/tpm/tpm_eventlog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/char/tpm/tpm_eventlog.c b/drivers/char/tpm/tpm_eventlog.c index 42b49c4..9467e31 100644 --- a/drivers/char/tpm/tpm_eventlog.c +++ b/drivers/char/tpm/tpm_eventlog.c @@ -378,7 +378,7 @@ struct dentry **tpm_bios_log_setup(const char *name) bin_file = securityfs_create_file("binary_bios_measurements", - S_IRUSR | S_IRGRP, tpm_dir, + 0440, tpm_dir, (void *)&tpm_binary_b_measurements_seqops, &tpm_bios_measurements_ops); if (is_bad(bin_file)) @@ -386,7 +386,7 @@ struct dentry **tpm_bios_log_setup(const char *name) ascii_file = securityfs_create_file("ascii_bios_measurements", - S_IRUSR | S_IRGRP, tpm_dir, + 0440, tpm_dir, (void *)&tpm_ascii_b_measurements_seqops, &tpm_bios_measurements_ops); if (is_bad(ascii_file)) -- 2.5.0