Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933245Ab3HNUwp (ORCPT ); Wed, 14 Aug 2013 16:52:45 -0400 Received: from g1t0028.austin.hp.com ([15.216.28.35]:17985 "EHLO g1t0028.austin.hp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932987Ab3HNUwo (ORCPT ); Wed, 14 Aug 2013 16:52:44 -0400 Date: Wed, 14 Aug 2013 15:52:36 -0500 From: Mike Miller To: Andrew Morton , Jens Axboe Cc: LKML-scsi , LKML , thenzl@redhat.com, bubrown@redhat.com, scameron@beardog.cce.hp.com Subject: [PATCH 1/1] cciss: set max scatter gather entries to 32 on P600 Message-ID: <20130814205236.GB23042@beardog.cce.hp.com> Reply-To: mike.miller@hp.com, mikem@thumper.usa.hp.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.2i Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1852 Lines: 46 Patch 1/1 From: Mike Miller At one time we used to set the maximum number of scatter gather elements on all Smart Array controllers to 32. At some point in time the firmware began to write the "appropriate" value for each controller into the config table. The cciss driver would then read that and set h->maxsgentries. h->maxsgentries = readl(&(h->cfgtable->MaxSGElements); On the P600 that value is 544. Under some workloads a significant performance reduction may result. This patch forces the P600 to use only 32 scatter gather elements. Other controllers are not affected. Signed-off-by: Mike Miller Signed-off-by: Dwight (Bud) Brown Signed-off-by: Tomas Henzl Acked-by: Stephen M. Cameron --- drivers/block/cciss.c | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c index 62b6c2c..d2d95ff 100644 --- a/drivers/block/cciss.c +++ b/drivers/block/cciss.c @@ -4258,6 +4258,13 @@ static void cciss_find_board_params(ctlr_info_t *h) h->nr_cmds = h->max_commands - 4 - cciss_tape_cmds; h->maxsgentries = readl(&(h->cfgtable->MaxSGElements)); /* + * The P600 may exhibit poor performnace under some workloads + * if we use the value in the configuration table. Limit this + * controller to MAXSGENTRIES (32) instead. + */ + if (h->board_id == 0x3225103C) + h->maxsgentries = MAXSGENTRIES; + /* * Limit in-command s/g elements to 32 save dma'able memory. * Howvever spec says if 0, use 31 */ -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/