lkml.org 
[lkml]   [2010]   [Oct]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 13/29] memstick: core: stop passing pointer to card->current_mrq


--- On Fri, 22/10/10, Maxim Levitsky <maximlevitsky@gmail.com> wrote:

> From: Maxim Levitsky <maximlevitsky@gmail.com>
> Subject: [PATCH 13/29] memstick: core: stop passing pointer to card->current_mrq
> To: "Alex Dubov" <oakad@yahoo.com>
> Cc: "Andrew Morton" <akpm@linux-foundation.org>, "LKML" <linux-kernel@vger.kernel.org>, "Maxim Levitsky" <maximlevitsky@gmail.com>
> Received: Friday, 22 October, 2010, 4:53 PM
> This cleans up a lot of code and
> makes the assumption
> (*mrq == &card->current_mrq) official.
>
> Signed-off-by: Maxim Levitsky <maximlevitsky@gmail.com>
> ---

Unfortunately, the description does not match the patch.
While the main optimization (merging req and card arguments for good) is
fully reasonable given the posterior knowledge of MSPro evolution, this
patch introduces some functional changes as well, which can not be
considered to be a pure cleanup. Some WARN_ONs also appear to be misplaced:

> if (msb->block_req) {
> - mspro_block_complete_req(card, (*mrq)->error);
> + mspro_block_complete_req(card, mrq->error);
> error = mspro_block_issue_req(card, false);
>
> - if (!msb->block_req) {
> + if (error) {
> + WARN_ON(msb->block_req);







\
 
 \ /
  Last update: 2010-10-25 17:43    [W:0.173 / U:9.920 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site