From patchwork Tue Jul 9 15:07:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gary R Hook X-Patchwork-Id: 11037121 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4697813A4 for ; Tue, 9 Jul 2019 15:07:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 37C2127861 for ; Tue, 9 Jul 2019 15:07:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2C452286FF; Tue, 9 Jul 2019 15:07:21 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI 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 6CA9528516 for ; Tue, 9 Jul 2019 15:07:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726403AbfGIPHS (ORCPT ); Tue, 9 Jul 2019 11:07:18 -0400 Received: from mail-eopbgr780080.outbound.protection.outlook.com ([40.107.78.80]:30276 "EHLO NAM03-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726377AbfGIPHS (ORCPT ); Tue, 9 Jul 2019 11:07:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amdcloud-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zBHajjN1CsU8Nq1Mr4VawJD5ACXuxr3ux18EVRtRTTI=; b=P3LppQksDaqOlglLmFch/6nVOvxXZLXTz25Qn8ae8964o08G92Qp8CR0m/6elId4v7IiJiDttVtW4pdbTVuhVWi9Zpp36xWtPmIX9F+sNHKfY5XP4gMWv1d2yoGD2RlzeRhzqO56VXjsExweA0u9/nhUXV+EJWYCcE3ejhUfL9I= Received: from DM5PR12MB1449.namprd12.prod.outlook.com (10.172.40.14) by DM5PR12MB1420.namprd12.prod.outlook.com (10.168.239.12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2052.19; Tue, 9 Jul 2019 15:07:08 +0000 Received: from DM5PR12MB1449.namprd12.prod.outlook.com ([fe80::a894:b1d5:a126:adce]) by DM5PR12MB1449.namprd12.prod.outlook.com ([fe80::a894:b1d5:a126:adce%6]) with mapi id 15.20.2052.019; Tue, 9 Jul 2019 15:07:08 +0000 From: "Hook, Gary" To: "linux-crypto@vger.kernel.org" CC: "Lendacky, Thomas" , "herbert@gondor.apana.org.au" , "davem@davemloft.net" Subject: [PATCH v2 0/4] Add module parameters to control CCP activation Thread-Topic: [PATCH v2 0/4] Add module parameters to control CCP activation Thread-Index: AQHVNmf6IpyoPEcnbUeu6AGkbBKDqQ== Date: Tue, 9 Jul 2019 15:07:08 +0000 Message-ID: <156268468861.18577.13211913750250195885.stgit@sosrh3.amd.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: SN2PR01CA0002.prod.exchangelabs.com (2603:10b6:804:2::12) To DM5PR12MB1449.namprd12.prod.outlook.com (2603:10b6:4:10::14) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Gary.Hook@amd.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [165.204.78.2] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 3ee6d2dd-2812-414b-5853-08d7047f1c9b x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020);SRVR:DM5PR12MB1420; x-ms-traffictypediagnostic: DM5PR12MB1420: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1091; x-forefront-prvs: 0093C80C01 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(4636009)(366004)(39860400002)(136003)(376002)(396003)(346002)(199004)(189003)(71200400001)(66066001)(8936002)(102836004)(81156014)(26005)(8676002)(7736002)(71190400001)(256004)(81166006)(6512007)(186003)(72206003)(99286004)(305945005)(86362001)(386003)(52116002)(53936002)(6506007)(2351001)(6436002)(66476007)(66556008)(64756008)(66446008)(316002)(6916009)(25786009)(68736007)(478600001)(6486002)(6116002)(3846002)(5660300002)(4326008)(66946007)(5640700003)(2906002)(2501003)(103116003)(476003)(486006)(14444005)(14454004)(73956011)(54906003);DIR:OUT;SFP:1101;SCL:1;SRVR:DM5PR12MB1420;H:DM5PR12MB1449.namprd12.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: amd.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: SkBSPs/a3oMcLVLddbY/2ZT/87ni4dh10VUFMWki3i/63U/WXGNBw/OcBqhb+tqLm9+GJToj3TjNd742zCqS+NECzeSZSRgmTnyB1zLqKJ0iZ+4IgBIU7aFiHikN+8iGXcl+E4CwbGzjNiazZmPXDqoYqxWu38vbzACvO3FK0BH/rNDXoMV6Trf2H1aH2l5+oHVENw9AXOu3W6Ng6v4xHAfSha4iYezMvCCH4kaTsAA/Vn5RE1gHFVuKhnYrGWXBxsUleD4cb1qZUKf3LujijlkLXMWuko5dLk02MkkYeGZZlyuHeRd9/QRlBkOtFf25bb8w9QGkbIKx9mfMjlvUogeDJoLGNdQi4x5WcX952RTuKoKQ9hgDqBN6KAExnw6kg+0rFTrMUGCkFebiwYBjWCIHu6OkF/4h3GqHi7l2xAA= Content-ID: MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3ee6d2dd-2812-414b-5853-08d7047f1c9b X-MS-Exchange-CrossTenant-originalarrivaltime: 09 Jul 2019 15:07:08.5576 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: ghook@amd.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1420 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Firstly, add a switch to allow/disallow debugfs code to be built into the CCP driver. This rest of the patch series implements a set of module parameters that allows control over which CCPs on a system are enabled by the driver, and how many queues on each device are activated. A switch to enable/disable DMA engine registration is implemented. Details: nqueues - configure N queues per CCP (default: 0 - all queues enabled) max_devs - maximum number of devices to enable (default: 0 - all devices activated) dmaengine - Register services with the DMA subsystem (default: true) Only activated devices will have their DMA services registered, comprehensively controlled by the dmaengine parameter. Changes since v1: - Remove debugfs patches that duplicates sysfs function - Remove patches for filtering by pcibus and pci device ID - Utilize underscores for consistency in variable names - Correct commit message for nqueues regarding default value - Alter verbage of parameter description (dmaengine) - Help text in Kconfig: remove reference to parameters in debugfs --- Gary R Hook (4): crypto: ccp - Make CCP debugfs support optional crypto: ccp - Add a module parameter to specify a queue count crypto: ccp - module parameter to limit the number of enabled CCPs crypto: ccp - Add a module parameter to control registration for DMA drivers/crypto/ccp/Kconfig | 8 ++++++++ drivers/crypto/ccp/Makefile | 4 ++-- drivers/crypto/ccp/ccp-dev-v3.c | 2 +- drivers/crypto/ccp/ccp-dev-v5.c | 11 ++++++----- drivers/crypto/ccp/ccp-dev.c | 29 ++++++++++++++++++++++++++++- drivers/crypto/ccp/ccp-dev.h | 1 + drivers/crypto/ccp/ccp-dmaengine.c | 12 +++++++++++- 7 files changed, 57 insertions(+), 10 deletions(-) -- Signature