Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp6394191ybv; Tue, 18 Feb 2020 16:08:21 -0800 (PST) X-Google-Smtp-Source: APXvYqwhNcN/f4NF6JlsbV7IxSSgZMw/4twh0NDJ6cPz3Jws9nDxwwgDCjFUe9kNaDYj5ik+JlG5 X-Received: by 2002:a54:458d:: with SMTP id z13mr3043969oib.32.1582070901205; Tue, 18 Feb 2020 16:08:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582070901; cv=none; d=google.com; s=arc-20160816; b=EkMxHYhaUJfzSN3JvWGgQpMxrH/q5xxk4VVsVo2XwVGt7doUatQCEeJwM4aOZ6qxZN nsd5w+Qirx459YahS264IF+XBSuaiig+wT3B+oLH6canoIB9BsrrD63XcKtgA43oWxKQ XPzwkkPvOzScePmzskHaE5qikCOgNAfE79sRg8rIvp5tNIFUjDlSE/B8NGg+1BxMxMCQ +GeRPOHHyG6rz15c/Ihs7BgnWtujnv2ar8yeW4sbj9K/qNLYY/PaoEc2xbPx1jOIn79S WSuQ4DMlPhrfx49vIQsmT1s5bJoYS467m6ojw1BU6WMV7DJ21sY6LsO+BI+AE7QJ+b8g FVaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=lmmv8BwguvSfd0HKerD1hdGZVZFucntvwM9yetms1ek=; b=bTovUCDS6feg5GbZVIZVa6ZC46wSA3XksLxoLJLLVXtqCK26lHH4EHVUPuAay5NvGa nflQ4oYOD0/EftPPY5OZ1jwvytZbUBPj8sh0p9eBlNoezPV7M8hi4grknhgzwEJIINyO VmcwXEilGgNfr8hlWebkgs0MrJDfSL3B8UF1JrCyRgWbVF6yTAuZngBK4Wuof8oSdPKP N+ajcYOWANpY9hHLQIwS+q6meZPT3sxwDHDGy1zK5gZpnS/Itsl5dhV9SZQ2K1lOcDrY H+hGaV0eqcz0cvI2TTHBWX/bRXxOsY1SISrfk9F6HU7ijuNhI0NXb+gbjsvaFOayzEJ1 yZsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=eQZWim38; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y8si168400otg.309.2020.02.18.16.08.09; Tue, 18 Feb 2020 16:08:21 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=eQZWim38; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727935AbgBSAGX (ORCPT + 99 others); Tue, 18 Feb 2020 19:06:23 -0500 Received: from linux.microsoft.com ([13.77.154.182]:44388 "EHLO linux.microsoft.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727797AbgBSAGW (ORCPT ); Tue, 18 Feb 2020 19:06:22 -0500 Received: from tusharsu-Ubuntu.corp.microsoft.com (unknown [131.107.147.225]) by linux.microsoft.com (Postfix) with ESMTPSA id BB6D52007690; Tue, 18 Feb 2020 16:06:21 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com BB6D52007690 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1582070781; bh=lmmv8BwguvSfd0HKerD1hdGZVZFucntvwM9yetms1ek=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=eQZWim380eXo4NGuZOz5xcVFNBCtgOG5SBnQ7kkqq7jr9BmaenystKjJ8e6SZsADz NCzHkUmp1pSAQ+pTZWxfu9SFTrFatNytjLy5XKiovOb3r1xMELl+635YsioXacjhYD UIgb5lGIlffDMKATy0s2PgtTjK/YVdisvmACWWwk= From: Tushar Sugandhi To: zohar@linux.ibm.com, joe@perches.com, skhan@linuxfoundation.org, linux-integrity@vger.kernel.org Cc: sashal@kernel.org, nramas@linux.microsoft.com, linux-kernel@vger.kernel.org Subject: [PATCH v5 2/3] IMA: Add log statements for failure conditions Date: Tue, 18 Feb 2020 16:06:10 -0800 Message-Id: <20200219000611.28141-3-tusharsu@linux.microsoft.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200219000611.28141-1-tusharsu@linux.microsoft.com> References: <20200219000611.28141-1-tusharsu@linux.microsoft.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org process_buffer_measurement() does not have log messages for failure conditions. This change adds a log statement in the above function. Signed-off-by: Tushar Sugandhi Reviewed-by: Lakshmi Ramasubramanian Suggested-by: Joe Perches Reviewed-by: Mimi Zohar --- security/integrity/ima/ima_main.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/security/integrity/ima/ima_main.c b/security/integrity/ima/ima_main.c index 9fe949c6a530..aac1c44fb11b 100644 --- a/security/integrity/ima/ima_main.c +++ b/security/integrity/ima/ima_main.c @@ -757,6 +757,9 @@ void process_buffer_measurement(const void *buf, int size, ima_free_template_entry(entry); out: + if (ret < 0) + pr_devel("%s: failed, result: %d\n", __func__, ret); + return; } -- 2.17.1