]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - drivers/infiniband/hw/ipath/ipath_cq.c
IB/ipath: Fix error returned from ib_resize_cq if new size smaller than # entries
[net-next-2.6.git] / drivers / infiniband / hw / ipath / ipath_cq.c
index d1380c7a1703bf463776699f366fa3c490a6e9af..a03bd28d9b487e1f21f81ce0ff3e826a31412bb6 100644 (file)
@@ -421,7 +421,7 @@ int ipath_resize_cq(struct ib_cq *ibcq, int cqe, struct ib_udata *udata)
        else
                n = head - tail;
        if (unlikely((u32)cqe < n)) {
-               ret = -EOVERFLOW;
+               ret = -EINVAL;
                goto bail_unlock;
        }
        for (n = 0; tail != head; n++) {