Message ID | 20180731060237.5045-3-kamalheib1@gmail.com (mailing list archive) |
---|---|
State | Accepted |
Headers | show |
Series | RDMA: Fix modify_cq return value | expand |
On Tue, Jul 31, 2018 at 09:02:37AM +0300, Kamal Heib wrote: > Make sure to check for "-EOPNOTSUPP" instead of "-ENOSYS" which is the > return code from rdma_set_cq_moderation() in case that it not supported. > > Signed-off-by: Kamal Heib <kamalheib1@gmail.com> > --- > drivers/infiniband/ulp/ipoib/ipoib_ethtool.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > This patch should be squashed into first patch, otherwise you are breaking git bisect. Thanks
On Tue, Jul 31, 2018 at 04:25:08PM +0300, Leon Romanovsky wrote: > On Tue, Jul 31, 2018 at 09:02:37AM +0300, Kamal Heib wrote: > > Make sure to check for "-EOPNOTSUPP" instead of "-ENOSYS" which is the > > return code from rdma_set_cq_moderation() in case that it not supported. > > > > Signed-off-by: Kamal Heib <kamalheib1@gmail.com> > > --- > > drivers/infiniband/ulp/ipoib/ipoib_ethtool.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > This patch should be squashed into first patch, otherwise you are > breaking git bisect. > > Thanks I don't think so, unless you are seeing this from mlx5_ib point of view only ... Thanks, Kamal -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c b/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c index 2706bf26cbac..83429925dfc6 100644 --- a/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c +++ b/drivers/infiniband/ulp/ipoib/ipoib_ethtool.c @@ -102,7 +102,7 @@ static int ipoib_set_coalesce(struct net_device *dev, ret = rdma_set_cq_moderation(priv->recv_cq, coal->rx_max_coalesced_frames, coal->rx_coalesce_usecs); - if (ret && ret != -ENOSYS) { + if (ret && ret != -EOPNOTSUPP) { ipoib_warn(priv, "failed modifying CQ (%d)\n", ret); return ret; }
Make sure to check for "-EOPNOTSUPP" instead of "-ENOSYS" which is the return code from rdma_set_cq_moderation() in case that it not supported. Signed-off-by: Kamal Heib <kamalheib1@gmail.com> --- drivers/infiniband/ulp/ipoib/ipoib_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)