All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: "Saleem, Shiraz" <shiraz.saleem@intel.com>
Cc: "dledford@redhat.com" <dledford@redhat.com>,
	"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>,
	Dan Carpenter <dan.carpenter@oracle.com>
Subject: Re: [PATCH rdma-next v1] irdma: Use list_last_entry/list_first_entry
Date: Tue, 8 Jun 2021 20:25:23 -0300	[thread overview]
Message-ID: <20210608232523.GU1002214@nvidia.com> (raw)
In-Reply-To: <8d892696e01c47998b104579f489da25@intel.com>

On Tue, Jun 08, 2021 at 11:19:58PM +0000, Saleem, Shiraz wrote:
> > Subject: Re: [PATCH rdma-next v1] irdma: Use list_last_entry/list_first_entry
> > 
> > On Tue, Jun 08, 2021 at 04:14:16PM -0500, Shiraz Saleem wrote:
> > > Use list_last_entry and list_first_entry instead of using prev and
> > > next pointers.
> > >
> > > Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
> > > Signed-off-by: Shiraz Saleem <shiraz.saleem@intel.com>
> > > v0->v1: create patch on more recent git version
> > >
> > >  drivers/infiniband/hw/irdma/puda.c  | 2 +-
> > > drivers/infiniband/hw/irdma/utils.c | 4 ++--
> > >  2 files changed, 3 insertions(+), 3 deletions(-)
> > 
> > This still doesn't apply to the rdma tree.. You need to use the exact rdma tree, not
> > wherever this came from.
> > 
> > Anyhow I fixed it up by hand.
> > 
> 
> I am not really sure what is going on. This applies cleanly for me
> to the tip of for-next.

It is git magic because you have the right blobs and I don't

> diff --git a/drivers/infiniband/hw/irdma/utils.c b/drivers/infiniband/hw/irdma/utils.c
> index 8f04347be52c..b4b91cb81cca 100644
        ^^^^^^^^^^^^

This is the right blob, but the v1 from before had this:

index 8ce3535cdc21..81e590fb77b1 100644

And I don't have 8ce3535cdc21 at all. So git gives up if things aren't
a perfect match.

You have 8ce3535cdc21 so when you tried to apply your own patch it
would have done a 3 way merge and fixed it.

This is why it is important to actually generate diffs against common
commits that other people have because it allows git magic to work
properly. Even if the diffs are nearly identical having the blob be
correct covers alot of sins.

What I tell other people to do is publish everything they send in a
branch in a git repo and I then just keep a local copy of it up to
date and get the needed stuff from there.

Jason

  reply	other threads:[~2021-06-08 23:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-08 21:14 [PATCH rdma-next v1] irdma: Use list_last_entry/list_first_entry Shiraz Saleem
2021-06-08 23:04 ` Jason Gunthorpe
2021-06-08 23:19   ` Saleem, Shiraz
2021-06-08 23:25     ` Jason Gunthorpe [this message]
2021-06-09  6:45 ` Dan Carpenter

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=20210608232523.GU1002214@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=dan.carpenter@oracle.com \
    --cc=dledford@redhat.com \
    --cc=linux-rdma@vger.kernel.org \
    --cc=shiraz.saleem@intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.