diff options
Diffstat (limited to 'drivers/infiniband/core/user_mad.c')
-rw-r--r-- | drivers/infiniband/core/user_mad.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/infiniband/core/user_mad.c b/drivers/infiniband/core/user_mad.c index 6be596dc360a..ea90a3ebb9c2 100644 --- a/drivers/infiniband/core/user_mad.c +++ b/drivers/infiniband/core/user_mad.c | |||
@@ -616,6 +616,8 @@ static int ib_umad_reg_agent(struct ib_umad_file *file, void __user *arg, | |||
616 | mutex_lock(&file->mutex); | 616 | mutex_lock(&file->mutex); |
617 | 617 | ||
618 | if (!file->port->ib_dev) { | 618 | if (!file->port->ib_dev) { |
619 | dev_notice(file->port->dev, | ||
620 | "ib_umad_reg_agent: invalid device\n"); | ||
619 | ret = -EPIPE; | 621 | ret = -EPIPE; |
620 | goto out; | 622 | goto out; |
621 | } | 623 | } |
@@ -626,6 +628,9 @@ static int ib_umad_reg_agent(struct ib_umad_file *file, void __user *arg, | |||
626 | } | 628 | } |
627 | 629 | ||
628 | if (ureq.qpn != 0 && ureq.qpn != 1) { | 630 | if (ureq.qpn != 0 && ureq.qpn != 1) { |
631 | dev_notice(file->port->dev, | ||
632 | "ib_umad_reg_agent: invalid QPN %d specified\n", | ||
633 | ureq.qpn); | ||
629 | ret = -EINVAL; | 634 | ret = -EINVAL; |
630 | goto out; | 635 | goto out; |
631 | } | 636 | } |
@@ -634,6 +639,9 @@ static int ib_umad_reg_agent(struct ib_umad_file *file, void __user *arg, | |||
634 | if (!__get_agent(file, agent_id)) | 639 | if (!__get_agent(file, agent_id)) |
635 | goto found; | 640 | goto found; |
636 | 641 | ||
642 | dev_notice(file->port->dev, | ||
643 | "ib_umad_reg_agent: Max Agents (%u) reached\n", | ||
644 | IB_UMAD_MAX_AGENTS); | ||
637 | ret = -ENOMEM; | 645 | ret = -ENOMEM; |
638 | goto out; | 646 | goto out; |
639 | 647 | ||