提交 e7b18ede 编写于 作者: M Mike Miller 提交者: Linus Torvalds

cciss: set max scatter gather entries to 32 on P600

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: NMike Miller <mike.miller@hp.com>
Signed-off-by: NDwight (Bud) Brown <bubrown@redhat.com>
Signed-off-by: NTomas Henzl <thenzl@redhat.com>
Acked-by: NStephen M. Cameron <steve.cameron@hp.com>
Cc: Jens Axboe <axboe@kernel.dk>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 c86db975
......@@ -4257,6 +4257,13 @@ static void cciss_find_board_params(ctlr_info_t *h)
cciss_get_max_perf_mode_cmds(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
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册