On Wed, Nov 15, 2017 at 09:01:07AM +0200, Erez Shitrit wrote: > >> if (!IS_ERR_OR_NULL(ah)) { > >> + /* check there is no mismatch from the request */ > >> + if (memcmp(pathrec->dgid.raw, path->pathrec.dgid.raw, > >> + sizeof(union ib_gid))) { > >> + pr_warn("%s got PathRec for gid %pI6 while asked for %pI6\n", > >> + dev->name, pathrec->dgid.raw, path->pathrec.dgid.raw); > >> + /* overwrite the response from the sm before copy to the db */ > >> + memcpy(pathrec->dgid.raw, path->pathrec.dgid.raw, > >> + sizeof(union ib_gid)); > > > > This doesn't seem like it should be a warning, and replacing the > > good DGID from the SA with local garbage seems really wrong. > > IPoIB is L2 driver and should act as a pipe and cannot add its opinion > about what is a good or a garbage GID. Which is why ipoib should not override the result from the SA. It needs to work in a way where it looks up a DGID from the LLADDR and gets back a wire GRH and LRH which come from SA. > If the host is asking for specific mac address, IPoIB should return > the response for the original request/mac and should not decide what > is good for the host. No, it is up to the SA to return the GRH to put in the packets, it should never be changed in any way by a ULP. Jason -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html