public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@suse.de>
To: jack_wang <jack_wang@usish.com>
Cc: linux-scsi <linux-scsi@vger.kernel.org>
Subject: Re: [PATCH Resend 2/3] pm8001:enhance IOMB process modules
Date: Wed, 04 Nov 2009 11:32:40 -0600	[thread overview]
Message-ID: <1257355960.10416.5.camel@mulgrave.site> (raw)
In-Reply-To: <200910302152552653057@usish.com>

Just for future reference, git doesn't like patches in this format.
What it's expecting is the change log in the actual email and the patch
as an attachment.

On Fri, 2009-10-30 at 21:53 +0800, jack_wang wrote:
> @@ -1342,34 +1360,43 @@ static u32 mpi_msg_consume(struct pm8001_hba_info *pm8001_ha,
>                                         *pBC = (u8)((msgHeader_tmp >> 24) &
>                                                 0x1f);
>                                         PM8001_IO_DBG(pm8001_ha,
> -                                               pm8001_printk("mpi_msg_consume"
> -                                               ": CI=%d PI=%d msgHeader=%x\n",
> +                                               pm8001_printk(": CI=%d PI=%d "
> +                                               "msgHeader=%x\n",
>                                                 circularQ->consumer_idx,
>                                                 circularQ->producer_index,
>                                                 msgHeader_tmp));
>                                         return MPI_IO_STATUS_SUCCESS;
>                                 } else {
> -                                       u32 producer_index;
> -                                       void *pi_virt = circularQ->pi_virt;
> -                                       /* free the circular queue buffer
> -                                       elements associated with the message*/
>                                         circularQ->consumer_idx =
>                                                 (circularQ->consumer_idx +
> -                                               ((msgHeader_tmp >> 24) & 0x1f))
> -                                               % 256;
> +                                               ((msgHeader_tmp >> 24) & 0x1f))
> +                                               % 256;
> +                                       msgHeader_tmp = 0;
> +                                       pm8001_write_32(msgHeader, 0, 0);
>                                         /* update the CI of outbound queue */
>                                         pm8001_cw32(pm8001_ha,
>                                                 circularQ->ci_pci_bar,
>                                                 circularQ->ci_offset,
>                                                 circularQ->consumer_idx);
> -                                       /* Update the producer index from SPC */
> -                                       producer_index =
> -                                               pm8001_read_32(pi_virt);
> -                                       circularQ->producer_index =
> -                                               cpu_to_le32(producer_index);
> +
>                                 }
> -                       } else
> +                       } else {
> +                               circularQ->consumer_idx =
> +                                       (circularQ->consumer_idx +
> +                                       ((msgHeader_tmp >> 24) & 0x1f)) % 256;
> +                               msgHeader_tmp = 0;
> +                               pm8001_write_32(msgHeader, 0, 0);
> +                               /* update the CI of outbound queue */
> +                               pm8001_cw32(pm8001_ha, circularQ->ci_pci_bar,
> +                                       circularQ->ci_offset,
> +                                       circularQ->consumer_idx);
>                                 return MPI_IO_STATUS_FAIL;
> +                       }
> +               } else {
> +                       u32 producer_index;
> +                       void *pi_virt = circularQ->pi_virt;
> +                       /* Update the producer index from SPC */
> +                       producer_index = pm8001_read_32(pi_virt);
> +                       circularQ->producer_index = cpu_to_le32(producer_index);
>                 }
>         } while (circularQ->producer_index != circularQ->consumer_idx);
>         /* while we don't have any more not-yet-delivered message */

This hunk is refusing to apply:

patching file drivers/scsi/pm8001/pm8001_hwi.c
patch: **** malformed patch at line 164:        /* while we don't have
any more not-yet-delivered message */

The problem seems to be that the header promises there will be 43 lines
after patching and there are actually 44 ... did you edit this patch
after generating the diff?

James



  reply	other threads:[~2009-11-04 17:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200910281755.n9SHtGrV004494@hera.kernel.org>
     [not found] ` <200910302144286878481@usish.com>
2009-10-30 13:51   ` [PATCH Resend 1/3] pm8001:add reinitialize SPC parameters before phy start jack_wang
     [not found] ` <200910302144471408205@usish.com>
2009-10-30 13:53   ` [PATCH Resend 2/3] pm8001:enhance IOMB process modules jack_wang
2009-11-04 17:32     ` James Bottomley [this message]
2009-11-05  1:03       ` jack wang
2009-11-05 14:32     ` [PATCH v2 1/3] pm8001:add reinitialize SPC parameters before phy start jack_wang
2009-11-05 14:33     ` [PATCH V2 2/3] pm8001:enhance IOMB process modules jack_wang
2009-11-05 14:33     ` [PATCH v2 3/3] pm8001:Fixes for tag alloc, error goto and code cleanup jack_wang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1257355960.10416.5.camel@mulgrave.site \
    --to=james.bottomley@suse.de \
    --cc=jack_wang@usish.com \
    --cc=linux-scsi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox