From patchwork Mon Jan 19 13:54:24 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cristian Stoica X-Patchwork-Id: 5659131 X-Patchwork-Delegate: herbert@gondor.apana.org.au Return-Path: X-Original-To: patchwork-linux-crypto@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id C4497C058D for ; Mon, 19 Jan 2015 15:25:54 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DAA9220351 for ; Mon, 19 Jan 2015 15:25:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A24532034F for ; Mon, 19 Jan 2015 15:25:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751671AbbASPZv (ORCPT ); Mon, 19 Jan 2015 10:25:51 -0500 Received: from mail-bn1bon0133.outbound.protection.outlook.com ([157.56.111.133]:64288 "EHLO na01-bn1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751403AbbASPZu (ORCPT ); Mon, 19 Jan 2015 10:25:50 -0500 X-Greylist: delayed 5469 seconds by postgrey-1.27 at vger.kernel.org; Mon, 19 Jan 2015 10:25:50 EST Received: from BN3PR0301CA0077.namprd03.prod.outlook.com (25.160.152.173) by BLUPR03MB389.namprd03.prod.outlook.com (10.141.78.11) with Microsoft SMTP Server (TLS) id 15.1.59.20; Mon, 19 Jan 2015 13:54:34 +0000 Received: from BY2FFO11FD019.protection.gbl (2a01:111:f400:7c0c::164) by BN3PR0301CA0077.outlook.office365.com (2a01:111:e400:401e::45) with Microsoft SMTP Server (TLS) id 15.1.59.20 via Frontend Transport; Mon, 19 Jan 2015 13:54:33 +0000 Received: from az84smr01.freescale.net (192.88.158.2) by BY2FFO11FD019.mail.protection.outlook.com (10.1.14.107) with Microsoft SMTP Server (TLS) id 15.1.59.14 via Frontend Transport; Mon, 19 Jan 2015 13:54:33 +0000 Received: from enigma.ea.freescale.net (enigma.ea.freescale.net [10.171.77.120]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id t0JDsUXQ007837; Mon, 19 Jan 2015 06:54:31 -0700 From: Cristian Stoica To: , , CC: , , "Cristian Stoica" Subject: [PATCH] crypto: testmgr: notify expected failures on aead tests Date: Mon, 19 Jan 2015 15:54:24 +0200 Message-ID: <1421675664-26107-1-git-send-email-cristian.stoica@freescale.com> X-Mailer: git-send-email 2.2.0 X-EOPAttributedMessage: 0 Received-SPF: Fail (protection.outlook.com: domain of freescale.com does not designate 192.88.158.2 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.158.2; helo=az84smr01.freescale.net; Authentication-Results: spf=fail (sender IP is 192.88.158.2) smtp.mailfrom=B18196@freescale.com; X-Forefront-Antispam-Report: CIP:192.88.158.2; CTRY:US; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(339900001)(189002)(199003)(64706001)(69596002)(48376002)(105606002)(81156004)(87936001)(2201001)(77096005)(19580395003)(106466001)(229853001)(19580405001)(50466002)(85426001)(104016003)(33646002)(6806004)(36756003)(50226001)(77156002)(62966003)(92566002)(47776003)(46102003)(50986999); DIR:OUT; SFP:1102; SCL:1; SRVR:BLUPR03MB389; H:az84smr01.freescale.net; FPR:; SPF:Fail; MLV:sfv; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; MIME-Version: 1.0 X-DmarcAction-Test: None X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(3005004);SRVR:BLUPR03MB389; X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004); SRVR:BLUPR03MB389; X-Forefront-PRVS: 046164D5C4 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:;SRVR:BLUPR03MB389; X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Jan 2015 13:54:33.4597 (UTC) X-MS-Exchange-CrossTenant-Id: 710a03f5-10f6-4d38-9ff4-a80b81da590d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=710a03f5-10f6-4d38-9ff4-a80b81da590d; Ip=[192.88.158.2] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR03MB389 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Some hardware drivers (e.g. caamalg) log failed operations reported by hw to assist in debugging. However, these messages are confusing when they are the result of a testmgr test that is expected to fail. This patch puts the driver messages in their testing context and helps the user classify them as harmless. Signed-off-by: Cristian Stoica --- crypto/testmgr.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/crypto/testmgr.c b/crypto/testmgr.c index 235b1ff..ec19e98 100644 --- a/crypto/testmgr.c +++ b/crypto/testmgr.c @@ -573,9 +573,11 @@ static int __test_aead(struct crypto_aead *tfm, int enc, if (!ret) break; case -EBADMSG: - if (template[i].novrfy) - /* verification failure was expected */ + if (template[i].novrfy) { + pr_info("aead%s: expected %s failure on test %d for %s: ret=-EBADMSG\n", + d, e, j, algo); continue; + } /* fall through */ default: pr_err("alg: aead%s: %s failed on test %d for %s: ret=%d\n", @@ -723,9 +725,11 @@ static int __test_aead(struct crypto_aead *tfm, int enc, if (!ret) break; case -EBADMSG: - if (template[i].novrfy) - /* verification failure was expected */ + if (template[i].novrfy) { + pr_info("aead%s: expected %s failure on test %d for %s: ret=-EBADMSG\n", + d, e, j, algo); continue; + } /* fall through */ default: pr_err("alg: aead%s: %s failed on chunk test %d for %s: ret=%d\n",