Message ID | 20170130142843.8459.53690.stgit@taos (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | Herbert Xu |
Headers | show
Return-Path: <linux-crypto-owner@kernel.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B5128604A8 for <patchwork-linux-crypto@patchwork.kernel.org>; Mon, 30 Jan 2017 14:29:04 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A8DDA2022B for <patchwork-linux-crypto@patchwork.kernel.org>; Mon, 30 Jan 2017 14:29:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9D9F32811D; Mon, 30 Jan 2017 14:29:04 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 460282022B for <patchwork-linux-crypto@patchwork.kernel.org>; Mon, 30 Jan 2017 14:29:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932137AbdA3O3D (ORCPT <rfc822;patchwork-linux-crypto@patchwork.kernel.org>); Mon, 30 Jan 2017 09:29:03 -0500 Received: from mail-sn1nam02on0081.outbound.protection.outlook.com ([104.47.36.81]:35664 "EHLO NAM02-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752959AbdA3O3C (ORCPT <rfc822;linux-crypto@vger.kernel.org>); Mon, 30 Jan 2017 09:29:02 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=3ru+bWMEP1L9IDUcEuTnSYvyQG/GcnmleoDVzQgKMKw=; b=N23R/hWB018jAXaHgcWWrtQEv9AJYmv9+Vh1GEz9OyUAUX3ckp0+Cq4GDlCIKsLQGZ8zDqiZ+H930c4OTKv34BrVZBm2kzkEZTLFA0ddx8hm8sssOth7caAEGuTXHhOwyE1jlMZxUC7brbj2mT7BPr1EMnR1U3OWxYjA27H0k4M= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Gary.Hook@amd.com; Received: from [10.236.19.42] (165.204.77.1) by CY4PR12MB1398.namprd12.prod.outlook.com (10.168.169.19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.845.12; Mon, 30 Jan 2017 14:28:54 +0000 Subject: [PATCH 3/4] crypto: ccp - Update the command queue on errors From: Gary R Hook <gary.hook@amd.com> To: <linux-crypto@vger.kernel.org> CC: <thomas.lendacky@amd.com>, <herbert@gondor.apana.org.au>, <davem@davemloft.net> Date: Mon, 30 Jan 2017 08:28:43 -0600 Message-ID: <20170130142843.8459.53690.stgit@taos> In-Reply-To: <20170130142414.8459.71539.stgit@taos> References: <20170130142414.8459.71539.stgit@taos> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [165.204.77.1] X-ClientProxiedBy: SN1PR12CA0024.namprd12.prod.outlook.com (10.162.96.162) To CY4PR12MB1398.namprd12.prod.outlook.com (10.168.169.19) X-MS-Office365-Filtering-Correlation-Id: 73d6ebf3-79c9-4a77-7d2e-08d4491c5221 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(48565401076); SRVR:CY4PR12MB1398; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1398; 3:uZR0U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agnostics: 1; CY4PR12MB1398; 31:bgl45p4HxzgLJWUVZVUvyNPj/TtmU/u8aMQdXgpqPxYtGSIobt9AzmKLEuAdHCuTj3SZt3elTIpUhqguSnbHEAL5JsTiPHLhNapXvSYjQX3+T2XwPViHu84UCV4jVaTVcHh3zaKv6Gn4E0e1iW642i9LnOxAKomStkGfL8MTMJRNVmRqdPpJEhFWI0LAGeg6R15LrfZTYhY5ZvjljguVxvM/KjF569dMsAXJqoKtvgkKk0VEH0k69iQv3ZlYvdKW6T3spD7X8mFYiJclg1A48Q==; 20:oQYWN/0Dpbv48kdCOXjaUK+Yr4GSs31CaXSwj/67a9SnUePVN2fXCHD2vykkbkCmlDFtGVG7HuX+w47LrM+bhgiM0GAfh1/mV2hd1W7xakgglcHu0Jsde4YIxzUbeOtJlrwuelW3OhZRYAWbPYD8pRS1lboBVwEKmIGjYJUrpjizuDS0COUkjS0e7qFwBKVyr1Dizdwo4AyYCDOa6NkXYA/o9AaK7CpduEAjFZv94HEgKJgRE9gBdIXLnE4kapru5vpdX46PQ//y8TyQRFenVGORzU7dT8/4ztnYOuJpmGuWHES1Jup+o4xW9KsC0IqPCQ6c32xURwEFW1JtVQGXLfS+OgF33xxHXkNLv44V1dApslb6Eld0pQBwaqFc9Xv9fgoD2Cmdn4VKTrK2j9s+sJjRfjBBOw1ezErj5PK+jS/uWr55skJ5xU/S/WEBGtAOXnnl0AWWXyVnu+2MckuUXoxv8hDrDoLppsal7Ye5Tj/6QYtqrf9sovZTaSg4C+bm X-Microsoft-Antispam-PRVS: <CY4PR12MB1398933BDA3191CF14644228FD4B0@CY4PR12MB1398.namprd12.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001)(6055026)(6041248)(20161123562025)(20161123564025)(20161123555025)(20161123560025)(20161123558021)(6072148); SRVR:CY4PR12MB1398; BCL:0; PCL:0; RULEID:; SRVR:CY4PR12MB1398; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1398; 4:E0DsqTYaYBP75AlCWOOeCeEwJbs9UeH26ISJf+b1rHgGzLEAMGO962rYR2cgt1q+GFRhM+/r4GHPZ2XMMqvddi7RcXt+HuwSfym1dK3uAfhOwp9fsTJToS1bx7ndQ0Au8ZuzeX01BFmRIxxXC/guKKo0areob3UXI+Udgis7W0WlTStEL70Iv9nRJ40G/lKC+2PDVfnqMncUJHWXEZi6WdmWhK6UiLy6wPGw+NtPZTNj0T/F8fWBWknExWyeMUlEu2F4tsh0BL9gCfuGVadYVQ7GZvSF4eaF0NE7O+lIkKqtNS7cB4a9Mmj5247PjLzvZEF5Dbbx42tALON3dgZyCDpZkxLG4sRIEydZzjFeSrpqyKUKzda+MieUwg+rXTzrVpQS4KNZoAU03jLwNjRyxLOcocs9NTNRlZh5Ze+wYabqbl704s6Nmt8yq5G7uKglHvPUotm2rOf/VjgisUJPIT4ZjVMHHtZ3gcZNFttZwPG120uCtIZ5A4Ij/p0dJ/5y44sqdDykkwbfkRCBHSa/dmlps1y5m+tcyWHQbVPQIo+y+YHhT4hVS6kqtqvdmWtjsvaq4k8uZxm/qUy6Oo7Cj56xJgIkanlKd2UW78VleNfffZ9LmIa88d+XC8B7yLQvRCDBehmZTM554rGtKXYyGLC+rCVvYNoJcnYfty1//0E= X-Forefront-PRVS: 0203C93D51 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(6049001)(7916002)(39840400002)(39450400003)(39860400002)(39850400002)(39410400002)(199003)(189002)(7736002)(110136003)(6116002)(305945005)(1076002)(2950100002)(101416001)(6916009)(33646002)(2351001)(68736007)(53936002)(8676002)(105586002)(230700001)(81156014)(86362001)(106356001)(83506001)(6666003)(3846002)(5660300001)(81166006)(97746001)(103116003)(47776003)(9686003)(25786008)(90366009)(97736004)(66066001)(4001350100001)(54906002)(23676002)(50466002)(2906002)(33716001)(54356999)(50986999)(76176999)(38730400001)(189998001)(92566002)(6486002)(77096006)(4326007)(42186005); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR12MB1398; H:[10.236.19.42]; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtDWTRQUjEyTUIxMzk4OzIzOjRHZjZDSDJzdndWY1hGZjRqak15aUUxenVX?= =?utf-8?B?S3FzUVZHQmh6YlFReFRTL1lEUFQ4Ti9VcEpDbDE4ZDNPSDJOSWFpWHVvQXA4?= =?utf-8?B?SUpwZmlMK2dVaHVkZ1JTb1BrZTNmZDdXM0w2bjllRlN5STRrWEg5MEJ3Y211?= =?utf-8?B?ME9OYTY0UlBzdWR4WlVVSlNzUUQyeFYybjBISXBqNnZPWUNBWlY2cGk1WnMv?= =?utf-8?B?dEZoSjQ2OGhqeDl6VS93STFKVUFaUW02bUxlSjh4ZG1zSmhicXgvMG1GZlk5?= =?utf-8?B?Tnd0Rm5yNmpzUUxPVG15dllZMDlpM2hKRHh0MWRVME1GWmJxeXdMQ1AzaU5G?= =?utf-8?B?MWtnazY3L3o3aFZsM1RGbXFEeW5HTFZkVGI5YnBKVGhkUVVMWSt5d0VTK085?= =?utf-8?B?TlFEK3lCRlR5MFBvUjl4REhYVlY3ZXlmL3dEZGgya3dpSU8zL29VdnhhZ1NL?= =?utf-8?B?cncxNlZoVnYxeGI5eGcvTUtaNnNZaXRDSXpsZWZUMktMSFNHcm9qK2UyWVps?= =?utf-8?B?QzVjelJkeS84WWNuazdSbEY1MGFuVmdIQWNqMlp1TEVJQk5BWlVvdmJmSFZB?= =?utf-8?B?dXhFeldoZmhUV2xvYzhTVkN6V00wSHNFenRjcnVBeTh4OEE1b0JXeHBBeTNx?= =?utf-8?B?VDNmNkdjR1F6WDdhY3ZlTVRWWkY0c1N3VDQrejFXbTdWNW0rSHdtaWJqemUz?= =?utf-8?B?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gJ2upPxX9uGZVudTx+nhmtnpEAlIK9Q= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1398; 7:VsEiinF95OqsY2FLGcJ/jAi8J4/6M0/AOnn2PBASi8qN4ltge/7dmhR04+kIlvnPg6WsNqklw260+K6lYdl1JYm1XI4f3zqYAfEubV6WHCpnFdPL6V+q3JfrWM9JCnauRJvdGAGOYYP1ekLIxcnOcnrR10SeraB247nks6VsbhsHk6I2XijFWscw3yXg/Sx9/GN01TpVgSKgjoGyKtGNb//pXXG6c4ey+Yjdu8+E7PeJxnb+Iao3/raeLdpyupDMMJ8PnDUF7bM0+iZQL7/ASXMlUnIqwXDybd7MW0FtSukeIu0WCoVJE4QvIcn7K6l2aO40RZiE6ViuS2/DIJF0ccR/ZFmOfC00cITFlIj2vJy4PtuGsZt9xVqURhTU6zNsrt6+LjPbMYjh1Zhs2nlgd6rKiOa1DQyizIhKeirNJdEm6eG7oKncgIvZTJy6y7cN2D86R/jERat755Jer8bfWA==; 20:Chup6dBkUM2Ad7YCrRpNDFXJLcUkIcfECbanvsaVUDGmqYnBdnJuffUDors/GalhXWMe2nVXRW0agjT+ckhtWmDLNWJyIcOWUfbzzlf2zPNkze/bUFf7rOqrokuqotmlaXXa7M+XvEgZIbCMANLEU0Xsgi3TpfMK650H7m+h4KU5j4lhXzrKNZo+Ofwb1RvAf9g8qOUjAjS2rDjsyKvPw1b1RSVm368fMWYlF1NuuBtVjwZcmAzdwVYz6ZyoGVAf X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Jan 2017 14:28:54.9518 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR12MB1398 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: <linux-crypto.vger.kernel.org> X-Mailing-List: linux-crypto@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/drivers/crypto/ccp/ccp-dev-v5.c b/drivers/crypto/ccp/ccp-dev-v5.c index 5fb6c8c..d9e1876 100644 --- a/drivers/crypto/ccp/ccp-dev-v5.c +++ b/drivers/crypto/ccp/ccp-dev-v5.c @@ -250,17 +250,20 @@ static int ccp5_do_cmd(struct ccp5_desc *desc, ret = wait_event_interruptible(cmd_q->int_queue, cmd_q->int_rcvd); if (ret || cmd_q->cmd_error) { + /* Log the error and flush the queue by + * moving the head pointer + */ if (cmd_q->cmd_error) ccp_log_error(cmd_q->ccp, cmd_q->cmd_error); - /* A version 5 device doesn't use Job IDs... */ + iowrite32(tail, cmd_q->reg_head_lo); if (!ret) ret = -EIO; } cmd_q->int_rcvd = 0; } - return 0; + return ret; } static int ccp5_perform_aes(struct ccp_op *op)
Move the command queue tail pointer when an error is detected. Always return the error. Signed-off-by: Gary R Hook <gary.hook@amd.com> --- drivers/crypto/ccp/ccp-dev-v5.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-crypto" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html