diff options
author | Harvey Harrison <harvey.harrison@gmail.com> | 2008-04-17 00:01:10 -0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2008-04-17 00:01:10 -0400 |
commit | 3371836383d63b627b228875f5ac63023cbf11d2 (patch) | |
tree | b997894d9774bdc07f7df76ceca48e6a848760c8 /drivers/infiniband/hw/cxgb3/iwch_provider.c | |
parent | e8e91f6b4dc1179a70b0d21241b769c0ebfaa129 (diff) |
IB: Replace remaining __FUNCTION__ occurrences with __func__
__FUNCTION__ is gcc-specific, use __func__ instead.
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/cxgb3/iwch_provider.c')
-rw-r--r-- | drivers/infiniband/hw/cxgb3/iwch_provider.c | 76 |
1 files changed, 38 insertions, 38 deletions
diff --git a/drivers/infiniband/hw/cxgb3/iwch_provider.c b/drivers/infiniband/hw/cxgb3/iwch_provider.c index b2ea9210467f..50e1f2a16e0c 100644 --- a/drivers/infiniband/hw/cxgb3/iwch_provider.c +++ b/drivers/infiniband/hw/cxgb3/iwch_provider.c | |||
@@ -101,7 +101,7 @@ static int iwch_dealloc_ucontext(struct ib_ucontext *context) | |||
101 | struct iwch_ucontext *ucontext = to_iwch_ucontext(context); | 101 | struct iwch_ucontext *ucontext = to_iwch_ucontext(context); |
102 | struct iwch_mm_entry *mm, *tmp; | 102 | struct iwch_mm_entry *mm, *tmp; |
103 | 103 | ||
104 | PDBG("%s context %p\n", __FUNCTION__, context); | 104 | PDBG("%s context %p\n", __func__, context); |
105 | list_for_each_entry_safe(mm, tmp, &ucontext->mmaps, entry) | 105 | list_for_each_entry_safe(mm, tmp, &ucontext->mmaps, entry) |
106 | kfree(mm); | 106 | kfree(mm); |
107 | cxio_release_ucontext(&rhp->rdev, &ucontext->uctx); | 107 | cxio_release_ucontext(&rhp->rdev, &ucontext->uctx); |
@@ -115,7 +115,7 @@ static struct ib_ucontext *iwch_alloc_ucontext(struct ib_device *ibdev, | |||
115 | struct iwch_ucontext *context; | 115 | struct iwch_ucontext *context; |
116 | struct iwch_dev *rhp = to_iwch_dev(ibdev); | 116 | struct iwch_dev *rhp = to_iwch_dev(ibdev); |
117 | 117 | ||
118 | PDBG("%s ibdev %p\n", __FUNCTION__, ibdev); | 118 | PDBG("%s ibdev %p\n", __func__, ibdev); |
119 | context = kzalloc(sizeof(*context), GFP_KERNEL); | 119 | context = kzalloc(sizeof(*context), GFP_KERNEL); |
120 | if (!context) | 120 | if (!context) |
121 | return ERR_PTR(-ENOMEM); | 121 | return ERR_PTR(-ENOMEM); |
@@ -129,7 +129,7 @@ static int iwch_destroy_cq(struct ib_cq *ib_cq) | |||
129 | { | 129 | { |
130 | struct iwch_cq *chp; | 130 | struct iwch_cq *chp; |
131 | 131 | ||
132 | PDBG("%s ib_cq %p\n", __FUNCTION__, ib_cq); | 132 | PDBG("%s ib_cq %p\n", __func__, ib_cq); |
133 | chp = to_iwch_cq(ib_cq); | 133 | chp = to_iwch_cq(ib_cq); |
134 | 134 | ||
135 | remove_handle(chp->rhp, &chp->rhp->cqidr, chp->cq.cqid); | 135 | remove_handle(chp->rhp, &chp->rhp->cqidr, chp->cq.cqid); |
@@ -151,7 +151,7 @@ static struct ib_cq *iwch_create_cq(struct ib_device *ibdev, int entries, int ve | |||
151 | struct iwch_create_cq_req ureq; | 151 | struct iwch_create_cq_req ureq; |
152 | struct iwch_ucontext *ucontext = NULL; | 152 | struct iwch_ucontext *ucontext = NULL; |
153 | 153 | ||
154 | PDBG("%s ib_dev %p entries %d\n", __FUNCTION__, ibdev, entries); | 154 | PDBG("%s ib_dev %p entries %d\n", __func__, ibdev, entries); |
155 | rhp = to_iwch_dev(ibdev); | 155 | rhp = to_iwch_dev(ibdev); |
156 | chp = kzalloc(sizeof(*chp), GFP_KERNEL); | 156 | chp = kzalloc(sizeof(*chp), GFP_KERNEL); |
157 | if (!chp) | 157 | if (!chp) |
@@ -233,7 +233,7 @@ static int iwch_resize_cq(struct ib_cq *cq, int cqe, struct ib_udata *udata) | |||
233 | struct t3_cq oldcq, newcq; | 233 | struct t3_cq oldcq, newcq; |
234 | int ret; | 234 | int ret; |
235 | 235 | ||
236 | PDBG("%s ib_cq %p cqe %d\n", __FUNCTION__, cq, cqe); | 236 | PDBG("%s ib_cq %p cqe %d\n", __func__, cq, cqe); |
237 | 237 | ||
238 | /* We don't downsize... */ | 238 | /* We don't downsize... */ |
239 | if (cqe <= cq->cqe) | 239 | if (cqe <= cq->cqe) |
@@ -281,7 +281,7 @@ static int iwch_resize_cq(struct ib_cq *cq, int cqe, struct ib_udata *udata) | |||
281 | ret = cxio_destroy_cq(&chp->rhp->rdev, &oldcq); | 281 | ret = cxio_destroy_cq(&chp->rhp->rdev, &oldcq); |
282 | if (ret) { | 282 | if (ret) { |
283 | printk(KERN_ERR MOD "%s - cxio_destroy_cq failed %d\n", | 283 | printk(KERN_ERR MOD "%s - cxio_destroy_cq failed %d\n", |
284 | __FUNCTION__, ret); | 284 | __func__, ret); |
285 | } | 285 | } |
286 | 286 | ||
287 | /* add user hooks here */ | 287 | /* add user hooks here */ |
@@ -316,7 +316,7 @@ static int iwch_arm_cq(struct ib_cq *ibcq, enum ib_cq_notify_flags flags) | |||
316 | chp->cq.rptr = rptr; | 316 | chp->cq.rptr = rptr; |
317 | } else | 317 | } else |
318 | spin_lock_irqsave(&chp->lock, flag); | 318 | spin_lock_irqsave(&chp->lock, flag); |
319 | PDBG("%s rptr 0x%x\n", __FUNCTION__, chp->cq.rptr); | 319 | PDBG("%s rptr 0x%x\n", __func__, chp->cq.rptr); |
320 | err = cxio_hal_cq_op(&rhp->rdev, &chp->cq, cq_op, 0); | 320 | err = cxio_hal_cq_op(&rhp->rdev, &chp->cq, cq_op, 0); |
321 | spin_unlock_irqrestore(&chp->lock, flag); | 321 | spin_unlock_irqrestore(&chp->lock, flag); |
322 | if (err < 0) | 322 | if (err < 0) |
@@ -337,7 +337,7 @@ static int iwch_mmap(struct ib_ucontext *context, struct vm_area_struct *vma) | |||
337 | struct iwch_ucontext *ucontext; | 337 | struct iwch_ucontext *ucontext; |
338 | u64 addr; | 338 | u64 addr; |
339 | 339 | ||
340 | PDBG("%s pgoff 0x%lx key 0x%x len %d\n", __FUNCTION__, vma->vm_pgoff, | 340 | PDBG("%s pgoff 0x%lx key 0x%x len %d\n", __func__, vma->vm_pgoff, |
341 | key, len); | 341 | key, len); |
342 | 342 | ||
343 | if (vma->vm_start & (PAGE_SIZE-1)) { | 343 | if (vma->vm_start & (PAGE_SIZE-1)) { |
@@ -390,7 +390,7 @@ static int iwch_deallocate_pd(struct ib_pd *pd) | |||
390 | 390 | ||
391 | php = to_iwch_pd(pd); | 391 | php = to_iwch_pd(pd); |
392 | rhp = php->rhp; | 392 | rhp = php->rhp; |
393 | PDBG("%s ibpd %p pdid 0x%x\n", __FUNCTION__, pd, php->pdid); | 393 | PDBG("%s ibpd %p pdid 0x%x\n", __func__, pd, php->pdid); |
394 | cxio_hal_put_pdid(rhp->rdev.rscp, php->pdid); | 394 | cxio_hal_put_pdid(rhp->rdev.rscp, php->pdid); |
395 | kfree(php); | 395 | kfree(php); |
396 | return 0; | 396 | return 0; |
@@ -404,7 +404,7 @@ static struct ib_pd *iwch_allocate_pd(struct ib_device *ibdev, | |||
404 | u32 pdid; | 404 | u32 pdid; |
405 | struct iwch_dev *rhp; | 405 | struct iwch_dev *rhp; |
406 | 406 | ||
407 | PDBG("%s ibdev %p\n", __FUNCTION__, ibdev); | 407 | PDBG("%s ibdev %p\n", __func__, ibdev); |
408 | rhp = (struct iwch_dev *) ibdev; | 408 | rhp = (struct iwch_dev *) ibdev; |
409 | pdid = cxio_hal_get_pdid(rhp->rdev.rscp); | 409 | pdid = cxio_hal_get_pdid(rhp->rdev.rscp); |
410 | if (!pdid) | 410 | if (!pdid) |
@@ -422,7 +422,7 @@ static struct ib_pd *iwch_allocate_pd(struct ib_device *ibdev, | |||
422 | return ERR_PTR(-EFAULT); | 422 | return ERR_PTR(-EFAULT); |
423 | } | 423 | } |
424 | } | 424 | } |
425 | PDBG("%s pdid 0x%0x ptr 0x%p\n", __FUNCTION__, pdid, php); | 425 | PDBG("%s pdid 0x%0x ptr 0x%p\n", __func__, pdid, php); |
426 | return &php->ibpd; | 426 | return &php->ibpd; |
427 | } | 427 | } |
428 | 428 | ||
@@ -432,7 +432,7 @@ static int iwch_dereg_mr(struct ib_mr *ib_mr) | |||
432 | struct iwch_mr *mhp; | 432 | struct iwch_mr *mhp; |
433 | u32 mmid; | 433 | u32 mmid; |
434 | 434 | ||
435 | PDBG("%s ib_mr %p\n", __FUNCTION__, ib_mr); | 435 | PDBG("%s ib_mr %p\n", __func__, ib_mr); |
436 | /* There can be no memory windows */ | 436 | /* There can be no memory windows */ |
437 | if (atomic_read(&ib_mr->usecnt)) | 437 | if (atomic_read(&ib_mr->usecnt)) |
438 | return -EINVAL; | 438 | return -EINVAL; |
@@ -447,7 +447,7 @@ static int iwch_dereg_mr(struct ib_mr *ib_mr) | |||
447 | kfree((void *) (unsigned long) mhp->kva); | 447 | kfree((void *) (unsigned long) mhp->kva); |
448 | if (mhp->umem) | 448 | if (mhp->umem) |
449 | ib_umem_release(mhp->umem); | 449 | ib_umem_release(mhp->umem); |
450 | PDBG("%s mmid 0x%x ptr %p\n", __FUNCTION__, mmid, mhp); | 450 | PDBG("%s mmid 0x%x ptr %p\n", __func__, mmid, mhp); |
451 | kfree(mhp); | 451 | kfree(mhp); |
452 | return 0; | 452 | return 0; |
453 | } | 453 | } |
@@ -467,7 +467,7 @@ static struct ib_mr *iwch_register_phys_mem(struct ib_pd *pd, | |||
467 | struct iwch_mr *mhp; | 467 | struct iwch_mr *mhp; |
468 | int ret; | 468 | int ret; |
469 | 469 | ||
470 | PDBG("%s ib_pd %p\n", __FUNCTION__, pd); | 470 | PDBG("%s ib_pd %p\n", __func__, pd); |
471 | php = to_iwch_pd(pd); | 471 | php = to_iwch_pd(pd); |
472 | rhp = php->rhp; | 472 | rhp = php->rhp; |
473 | 473 | ||
@@ -531,7 +531,7 @@ static int iwch_reregister_phys_mem(struct ib_mr *mr, | |||
531 | int npages; | 531 | int npages; |
532 | int ret; | 532 | int ret; |
533 | 533 | ||
534 | PDBG("%s ib_mr %p ib_pd %p\n", __FUNCTION__, mr, pd); | 534 | PDBG("%s ib_mr %p ib_pd %p\n", __func__, mr, pd); |
535 | 535 | ||
536 | /* There can be no memory windows */ | 536 | /* There can be no memory windows */ |
537 | if (atomic_read(&mr->usecnt)) | 537 | if (atomic_read(&mr->usecnt)) |
@@ -594,7 +594,7 @@ static struct ib_mr *iwch_reg_user_mr(struct ib_pd *pd, u64 start, u64 length, | |||
594 | struct iwch_mr *mhp; | 594 | struct iwch_mr *mhp; |
595 | struct iwch_reg_user_mr_resp uresp; | 595 | struct iwch_reg_user_mr_resp uresp; |
596 | 596 | ||
597 | PDBG("%s ib_pd %p\n", __FUNCTION__, pd); | 597 | PDBG("%s ib_pd %p\n", __func__, pd); |
598 | 598 | ||
599 | php = to_iwch_pd(pd); | 599 | php = to_iwch_pd(pd); |
600 | rhp = php->rhp; | 600 | rhp = php->rhp; |
@@ -649,7 +649,7 @@ static struct ib_mr *iwch_reg_user_mr(struct ib_pd *pd, u64 start, u64 length, | |||
649 | if (udata && !t3a_device(rhp)) { | 649 | if (udata && !t3a_device(rhp)) { |
650 | uresp.pbl_addr = (mhp->attr.pbl_addr - | 650 | uresp.pbl_addr = (mhp->attr.pbl_addr - |
651 | rhp->rdev.rnic_info.pbl_base) >> 3; | 651 | rhp->rdev.rnic_info.pbl_base) >> 3; |
652 | PDBG("%s user resp pbl_addr 0x%x\n", __FUNCTION__, | 652 | PDBG("%s user resp pbl_addr 0x%x\n", __func__, |
653 | uresp.pbl_addr); | 653 | uresp.pbl_addr); |
654 | 654 | ||
655 | if (ib_copy_to_udata(udata, &uresp, sizeof (uresp))) { | 655 | if (ib_copy_to_udata(udata, &uresp, sizeof (uresp))) { |
@@ -673,7 +673,7 @@ static struct ib_mr *iwch_get_dma_mr(struct ib_pd *pd, int acc) | |||
673 | u64 kva; | 673 | u64 kva; |
674 | struct ib_mr *ibmr; | 674 | struct ib_mr *ibmr; |
675 | 675 | ||
676 | PDBG("%s ib_pd %p\n", __FUNCTION__, pd); | 676 | PDBG("%s ib_pd %p\n", __func__, pd); |
677 | 677 | ||
678 | /* | 678 | /* |
679 | * T3 only supports 32 bits of size. | 679 | * T3 only supports 32 bits of size. |
@@ -710,7 +710,7 @@ static struct ib_mw *iwch_alloc_mw(struct ib_pd *pd) | |||
710 | mhp->attr.stag = stag; | 710 | mhp->attr.stag = stag; |
711 | mmid = (stag) >> 8; | 711 | mmid = (stag) >> 8; |
712 | insert_handle(rhp, &rhp->mmidr, mhp, mmid); | 712 | insert_handle(rhp, &rhp->mmidr, mhp, mmid); |
713 | PDBG("%s mmid 0x%x mhp %p stag 0x%x\n", __FUNCTION__, mmid, mhp, stag); | 713 | PDBG("%s mmid 0x%x mhp %p stag 0x%x\n", __func__, mmid, mhp, stag); |
714 | return &(mhp->ibmw); | 714 | return &(mhp->ibmw); |
715 | } | 715 | } |
716 | 716 | ||
@@ -726,7 +726,7 @@ static int iwch_dealloc_mw(struct ib_mw *mw) | |||
726 | cxio_deallocate_window(&rhp->rdev, mhp->attr.stag); | 726 | cxio_deallocate_window(&rhp->rdev, mhp->attr.stag); |
727 | remove_handle(rhp, &rhp->mmidr, mmid); | 727 | remove_handle(rhp, &rhp->mmidr, mmid); |
728 | kfree(mhp); | 728 | kfree(mhp); |
729 | PDBG("%s ib_mw %p mmid 0x%x ptr %p\n", __FUNCTION__, mw, mmid, mhp); | 729 | PDBG("%s ib_mw %p mmid 0x%x ptr %p\n", __func__, mw, mmid, mhp); |
730 | return 0; | 730 | return 0; |
731 | } | 731 | } |
732 | 732 | ||
@@ -754,7 +754,7 @@ static int iwch_destroy_qp(struct ib_qp *ib_qp) | |||
754 | cxio_destroy_qp(&rhp->rdev, &qhp->wq, | 754 | cxio_destroy_qp(&rhp->rdev, &qhp->wq, |
755 | ucontext ? &ucontext->uctx : &rhp->rdev.uctx); | 755 | ucontext ? &ucontext->uctx : &rhp->rdev.uctx); |
756 | 756 | ||
757 | PDBG("%s ib_qp %p qpid 0x%0x qhp %p\n", __FUNCTION__, | 757 | PDBG("%s ib_qp %p qpid 0x%0x qhp %p\n", __func__, |
758 | ib_qp, qhp->wq.qpid, qhp); | 758 | ib_qp, qhp->wq.qpid, qhp); |
759 | kfree(qhp); | 759 | kfree(qhp); |
760 | return 0; | 760 | return 0; |
@@ -773,7 +773,7 @@ static struct ib_qp *iwch_create_qp(struct ib_pd *pd, | |||
773 | int wqsize, sqsize, rqsize; | 773 | int wqsize, sqsize, rqsize; |
774 | struct iwch_ucontext *ucontext; | 774 | struct iwch_ucontext *ucontext; |
775 | 775 | ||
776 | PDBG("%s ib_pd %p\n", __FUNCTION__, pd); | 776 | PDBG("%s ib_pd %p\n", __func__, pd); |
777 | if (attrs->qp_type != IB_QPT_RC) | 777 | if (attrs->qp_type != IB_QPT_RC) |
778 | return ERR_PTR(-EINVAL); | 778 | return ERR_PTR(-EINVAL); |
779 | php = to_iwch_pd(pd); | 779 | php = to_iwch_pd(pd); |
@@ -805,7 +805,7 @@ static struct ib_qp *iwch_create_qp(struct ib_pd *pd, | |||
805 | */ | 805 | */ |
806 | sqsize = roundup_pow_of_two(attrs->cap.max_send_wr); | 806 | sqsize = roundup_pow_of_two(attrs->cap.max_send_wr); |
807 | wqsize = roundup_pow_of_two(rqsize + sqsize); | 807 | wqsize = roundup_pow_of_two(rqsize + sqsize); |
808 | PDBG("%s wqsize %d sqsize %d rqsize %d\n", __FUNCTION__, | 808 | PDBG("%s wqsize %d sqsize %d rqsize %d\n", __func__, |
809 | wqsize, sqsize, rqsize); | 809 | wqsize, sqsize, rqsize); |
810 | qhp = kzalloc(sizeof(*qhp), GFP_KERNEL); | 810 | qhp = kzalloc(sizeof(*qhp), GFP_KERNEL); |
811 | if (!qhp) | 811 | if (!qhp) |
@@ -898,7 +898,7 @@ static struct ib_qp *iwch_create_qp(struct ib_pd *pd, | |||
898 | init_timer(&(qhp->timer)); | 898 | init_timer(&(qhp->timer)); |
899 | PDBG("%s sq_num_entries %d, rq_num_entries %d " | 899 | PDBG("%s sq_num_entries %d, rq_num_entries %d " |
900 | "qpid 0x%0x qhp %p dma_addr 0x%llx size %d\n", | 900 | "qpid 0x%0x qhp %p dma_addr 0x%llx size %d\n", |
901 | __FUNCTION__, qhp->attr.sq_num_entries, qhp->attr.rq_num_entries, | 901 | __func__, qhp->attr.sq_num_entries, qhp->attr.rq_num_entries, |
902 | qhp->wq.qpid, qhp, (unsigned long long) qhp->wq.dma_addr, | 902 | qhp->wq.qpid, qhp, (unsigned long long) qhp->wq.dma_addr, |
903 | 1 << qhp->wq.size_log2); | 903 | 1 << qhp->wq.size_log2); |
904 | return &qhp->ibqp; | 904 | return &qhp->ibqp; |
@@ -912,7 +912,7 @@ static int iwch_ib_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, | |||
912 | enum iwch_qp_attr_mask mask = 0; | 912 | enum iwch_qp_attr_mask mask = 0; |
913 | struct iwch_qp_attributes attrs; | 913 | struct iwch_qp_attributes attrs; |
914 | 914 | ||
915 | PDBG("%s ib_qp %p\n", __FUNCTION__, ibqp); | 915 | PDBG("%s ib_qp %p\n", __func__, ibqp); |
916 | 916 | ||
917 | /* iwarp does not support the RTR state */ | 917 | /* iwarp does not support the RTR state */ |
918 | if ((attr_mask & IB_QP_STATE) && (attr->qp_state == IB_QPS_RTR)) | 918 | if ((attr_mask & IB_QP_STATE) && (attr->qp_state == IB_QPS_RTR)) |
@@ -945,20 +945,20 @@ static int iwch_ib_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, | |||
945 | 945 | ||
946 | void iwch_qp_add_ref(struct ib_qp *qp) | 946 | void iwch_qp_add_ref(struct ib_qp *qp) |
947 | { | 947 | { |
948 | PDBG("%s ib_qp %p\n", __FUNCTION__, qp); | 948 | PDBG("%s ib_qp %p\n", __func__, qp); |
949 | atomic_inc(&(to_iwch_qp(qp)->refcnt)); | 949 | atomic_inc(&(to_iwch_qp(qp)->refcnt)); |
950 | } | 950 | } |
951 | 951 | ||
952 | void iwch_qp_rem_ref(struct ib_qp *qp) | 952 | void iwch_qp_rem_ref(struct ib_qp *qp) |
953 | { | 953 | { |
954 | PDBG("%s ib_qp %p\n", __FUNCTION__, qp); | 954 | PDBG("%s ib_qp %p\n", __func__, qp); |
955 | if (atomic_dec_and_test(&(to_iwch_qp(qp)->refcnt))) | 955 | if (atomic_dec_and_test(&(to_iwch_qp(qp)->refcnt))) |
956 | wake_up(&(to_iwch_qp(qp)->wait)); | 956 | wake_up(&(to_iwch_qp(qp)->wait)); |
957 | } | 957 | } |
958 | 958 | ||
959 | static struct ib_qp *iwch_get_qp(struct ib_device *dev, int qpn) | 959 | static struct ib_qp *iwch_get_qp(struct ib_device *dev, int qpn) |
960 | { | 960 | { |
961 | PDBG("%s ib_dev %p qpn 0x%x\n", __FUNCTION__, dev, qpn); | 961 | PDBG("%s ib_dev %p qpn 0x%x\n", __func__, dev, qpn); |
962 | return (struct ib_qp *)get_qhp(to_iwch_dev(dev), qpn); | 962 | return (struct ib_qp *)get_qhp(to_iwch_dev(dev), qpn); |
963 | } | 963 | } |
964 | 964 | ||
@@ -966,7 +966,7 @@ static struct ib_qp *iwch_get_qp(struct ib_device *dev, int qpn) | |||
966 | static int iwch_query_pkey(struct ib_device *ibdev, | 966 | static int iwch_query_pkey(struct ib_device *ibdev, |
967 | u8 port, u16 index, u16 * pkey) | 967 | u8 port, u16 index, u16 * pkey) |
968 | { | 968 | { |
969 | PDBG("%s ibdev %p\n", __FUNCTION__, ibdev); | 969 | PDBG("%s ibdev %p\n", __func__, ibdev); |
970 | *pkey = 0; | 970 | *pkey = 0; |
971 | return 0; | 971 | return 0; |
972 | } | 972 | } |
@@ -977,7 +977,7 @@ static int iwch_query_gid(struct ib_device *ibdev, u8 port, | |||
977 | struct iwch_dev *dev; | 977 | struct iwch_dev *dev; |
978 | 978 | ||
979 | PDBG("%s ibdev %p, port %d, index %d, gid %p\n", | 979 | PDBG("%s ibdev %p, port %d, index %d, gid %p\n", |
980 | __FUNCTION__, ibdev, port, index, gid); | 980 | __func__, ibdev, port, index, gid); |
981 | dev = to_iwch_dev(ibdev); | 981 | dev = to_iwch_dev(ibdev); |
982 | BUG_ON(port == 0 || port > 2); | 982 | BUG_ON(port == 0 || port > 2); |
983 | memset(&(gid->raw[0]), 0, sizeof(gid->raw)); | 983 | memset(&(gid->raw[0]), 0, sizeof(gid->raw)); |
@@ -990,7 +990,7 @@ static int iwch_query_device(struct ib_device *ibdev, | |||
990 | { | 990 | { |
991 | 991 | ||
992 | struct iwch_dev *dev; | 992 | struct iwch_dev *dev; |
993 | PDBG("%s ibdev %p\n", __FUNCTION__, ibdev); | 993 | PDBG("%s ibdev %p\n", __func__, ibdev); |
994 | 994 | ||
995 | dev = to_iwch_dev(ibdev); | 995 | dev = to_iwch_dev(ibdev); |
996 | memset(props, 0, sizeof *props); | 996 | memset(props, 0, sizeof *props); |
@@ -1017,7 +1017,7 @@ static int iwch_query_device(struct ib_device *ibdev, | |||
1017 | static int iwch_query_port(struct ib_device *ibdev, | 1017 | static int iwch_query_port(struct ib_device *ibdev, |
1018 | u8 port, struct ib_port_attr *props) | 1018 | u8 port, struct ib_port_attr *props) |
1019 | { | 1019 | { |
1020 | PDBG("%s ibdev %p\n", __FUNCTION__, ibdev); | 1020 | PDBG("%s ibdev %p\n", __func__, ibdev); |
1021 | props->max_mtu = IB_MTU_4096; | 1021 | props->max_mtu = IB_MTU_4096; |
1022 | props->lid = 0; | 1022 | props->lid = 0; |
1023 | props->lmc = 0; | 1023 | props->lmc = 0; |
@@ -1045,7 +1045,7 @@ static ssize_t show_rev(struct class_device *cdev, char *buf) | |||
1045 | { | 1045 | { |
1046 | struct iwch_dev *dev = container_of(cdev, struct iwch_dev, | 1046 | struct iwch_dev *dev = container_of(cdev, struct iwch_dev, |
1047 | ibdev.class_dev); | 1047 | ibdev.class_dev); |
1048 | PDBG("%s class dev 0x%p\n", __FUNCTION__, cdev); | 1048 | PDBG("%s class dev 0x%p\n", __func__, cdev); |
1049 | return sprintf(buf, "%d\n", dev->rdev.t3cdev_p->type); | 1049 | return sprintf(buf, "%d\n", dev->rdev.t3cdev_p->type); |
1050 | } | 1050 | } |
1051 | 1051 | ||
@@ -1056,7 +1056,7 @@ static ssize_t show_fw_ver(struct class_device *cdev, char *buf) | |||
1056 | struct ethtool_drvinfo info; | 1056 | struct ethtool_drvinfo info; |
1057 | struct net_device *lldev = dev->rdev.t3cdev_p->lldev; | 1057 | struct net_device *lldev = dev->rdev.t3cdev_p->lldev; |
1058 | 1058 | ||
1059 | PDBG("%s class dev 0x%p\n", __FUNCTION__, cdev); | 1059 | PDBG("%s class dev 0x%p\n", __func__, cdev); |
1060 | rtnl_lock(); | 1060 | rtnl_lock(); |
1061 | lldev->ethtool_ops->get_drvinfo(lldev, &info); | 1061 | lldev->ethtool_ops->get_drvinfo(lldev, &info); |
1062 | rtnl_unlock(); | 1062 | rtnl_unlock(); |
@@ -1070,7 +1070,7 @@ static ssize_t show_hca(struct class_device *cdev, char *buf) | |||
1070 | struct ethtool_drvinfo info; | 1070 | struct ethtool_drvinfo info; |
1071 | struct net_device *lldev = dev->rdev.t3cdev_p->lldev; | 1071 | struct net_device *lldev = dev->rdev.t3cdev_p->lldev; |
1072 | 1072 | ||
1073 | PDBG("%s class dev 0x%p\n", __FUNCTION__, cdev); | 1073 | PDBG("%s class dev 0x%p\n", __func__, cdev); |
1074 | rtnl_lock(); | 1074 | rtnl_lock(); |
1075 | lldev->ethtool_ops->get_drvinfo(lldev, &info); | 1075 | lldev->ethtool_ops->get_drvinfo(lldev, &info); |
1076 | rtnl_unlock(); | 1076 | rtnl_unlock(); |
@@ -1081,7 +1081,7 @@ static ssize_t show_board(struct class_device *cdev, char *buf) | |||
1081 | { | 1081 | { |
1082 | struct iwch_dev *dev = container_of(cdev, struct iwch_dev, | 1082 | struct iwch_dev *dev = container_of(cdev, struct iwch_dev, |
1083 | ibdev.class_dev); | 1083 | ibdev.class_dev); |
1084 | PDBG("%s class dev 0x%p\n", __FUNCTION__, dev); | 1084 | PDBG("%s class dev 0x%p\n", __func__, dev); |
1085 | return sprintf(buf, "%x.%x\n", dev->rdev.rnic_info.pdev->vendor, | 1085 | return sprintf(buf, "%x.%x\n", dev->rdev.rnic_info.pdev->vendor, |
1086 | dev->rdev.rnic_info.pdev->device); | 1086 | dev->rdev.rnic_info.pdev->device); |
1087 | } | 1087 | } |
@@ -1103,7 +1103,7 @@ int iwch_register_device(struct iwch_dev *dev) | |||
1103 | int ret; | 1103 | int ret; |
1104 | int i; | 1104 | int i; |
1105 | 1105 | ||
1106 | PDBG("%s iwch_dev %p\n", __FUNCTION__, dev); | 1106 | PDBG("%s iwch_dev %p\n", __func__, dev); |
1107 | strlcpy(dev->ibdev.name, "cxgb3_%d", IB_DEVICE_NAME_MAX); | 1107 | strlcpy(dev->ibdev.name, "cxgb3_%d", IB_DEVICE_NAME_MAX); |
1108 | memset(&dev->ibdev.node_guid, 0, sizeof(dev->ibdev.node_guid)); | 1108 | memset(&dev->ibdev.node_guid, 0, sizeof(dev->ibdev.node_guid)); |
1109 | memcpy(&dev->ibdev.node_guid, dev->rdev.t3cdev_p->lldev->dev_addr, 6); | 1109 | memcpy(&dev->ibdev.node_guid, dev->rdev.t3cdev_p->lldev->dev_addr, 6); |
@@ -1207,7 +1207,7 @@ void iwch_unregister_device(struct iwch_dev *dev) | |||
1207 | { | 1207 | { |
1208 | int i; | 1208 | int i; |
1209 | 1209 | ||
1210 | PDBG("%s iwch_dev %p\n", __FUNCTION__, dev); | 1210 | PDBG("%s iwch_dev %p\n", __func__, dev); |
1211 | for (i = 0; i < ARRAY_SIZE(iwch_class_attributes); ++i) | 1211 | for (i = 0; i < ARRAY_SIZE(iwch_class_attributes); ++i) |
1212 | class_device_remove_file(&dev->ibdev.class_dev, | 1212 | class_device_remove_file(&dev->ibdev.class_dev, |
1213 | iwch_class_attributes[i]); | 1213 | iwch_class_attributes[i]); |