On Tue, Nov 05, 2019 at 07:08:01PM +0800, Weihang Li wrote: > From: Yixian Liu <liuyixian@xxxxxxxxxx> > > It is better to return a linux error code than define a private constant. > > Signed-off-by: Yixian Liu <liuyixian@xxxxxxxxxx> > Signed-off-by: Wenpeng Liang <liangwenpeng@xxxxxxxxxx> > Signed-off-by: Weihang Li <liweihang@xxxxxxxxxxxxx> > --- > drivers/infiniband/hw/hns/hns_roce_alloc.c | 4 ++-- > drivers/infiniband/hw/hns/hns_roce_cq.c | 4 ++-- > drivers/infiniband/hw/hns/hns_roce_mr.c | 15 ++++++++------- > drivers/infiniband/hw/hns/hns_roce_pd.c | 2 +- > drivers/infiniband/hw/hns/hns_roce_srq.c | 2 +- > 5 files changed, 14 insertions(+), 13 deletions(-) > > diff --git a/drivers/infiniband/hw/hns/hns_roce_alloc.c b/drivers/infiniband/hw/hns/hns_roce_alloc.c > index 8c063c5..da574c2 100644 > --- a/drivers/infiniband/hw/hns/hns_roce_alloc.c > +++ b/drivers/infiniband/hw/hns/hns_roce_alloc.c > @@ -55,7 +55,7 @@ int hns_roce_bitmap_alloc(struct hns_roce_bitmap *bitmap, unsigned long *obj) Why do HNS driver have custom bitmap functions instead of include/linux/bitmap.h? Thanks