From patchwork Mon May 2 15:54:02 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jon Derrick X-Patchwork-Id: 8993631 Return-Path: X-Original-To: patchwork-linux-block@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id C28AE9F1D3 for ; Mon, 2 May 2016 15:55:18 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id EE8AD20222 for ; Mon, 2 May 2016 15:55:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E1BE920219 for ; Mon, 2 May 2016 15:55:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754096AbcEBPzQ (ORCPT ); Mon, 2 May 2016 11:55:16 -0400 Received: from mga14.intel.com ([192.55.52.115]:47778 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754077AbcEBPzP (ORCPT ); Mon, 2 May 2016 11:55:15 -0400 Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP; 02 May 2016 08:55:14 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,568,1455004800"; d="scan'208";a="944522125" Received: from eremita.lm.intel.com ([10.232.112.217]) by orsmga001.jf.intel.com with ESMTP; 02 May 2016 08:55:14 -0700 From: Jon Derrick To: axboe@fb.com Cc: Jon Derrick , linux-nvme@lists.infradead.org, linux-block@vger.kernel.org, keith.busch@intel.com, hch@infradead.org, stephen.bates@microsemi.com Subject: [PATCHv2] nvme: Make CMB module parameter read-only Date: Mon, 2 May 2016 09:54:02 -0600 Message-Id: <1462204442-3368-1-git-send-email-jonathan.derrick@intel.com> X-Mailer: git-send-email 1.8.3.1 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Spam-Status: No, score=-7.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 This patch changes the use_cmb_sqes module parameter to read-only. This parameter allows the driver to place IO submission queues within the Controller Memory Buffer. The parameter is currently writable through sysfs at /sys/module/nvme/parameters/use_cmb_sqes. Memory allocations for queues aren't dynamically reallocated between resets. For this reason, allowing the use_cmb_sqes module parameter to be written while the drive is loaded may be confusing because we have no mechanism to dynamically remap the queues. Signed-off-by: Jon Derrick Reviewed-by: Christoph Hellwig --- v2: More thorough log message drivers/nvme/host/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c index 4fd733f..83de5569 100644 --- a/drivers/nvme/host/pci.c +++ b/drivers/nvme/host/pci.c @@ -61,7 +61,7 @@ static int use_threaded_interrupts; module_param(use_threaded_interrupts, int, 0); static bool use_cmb_sqes = true; -module_param(use_cmb_sqes, bool, 0644); +module_param(use_cmb_sqes, bool, 0444); MODULE_PARM_DESC(use_cmb_sqes, "use controller's memory buffer for I/O SQes"); static struct workqueue_struct *nvme_workq;