summaryrefslogtreecommitdiff
path: root/drivers/infiniband/core/sysfs.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-19 02:52:40 +0300
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-19 02:52:40 +0300
commitf702c5815696bfca095cc1173fff6995c4d39844 (patch)
treef96bd0c4de6e12d06891bbd9760fe7bb213a3a60 /drivers/infiniband/core/sysfs.c
parent0165d7f476b99eb637027c2f69c365f00260f188 (diff)
parent51af33e8e45b845d8ee85446f58e31bc4c118048 (diff)
downloadlinux-f702c5815696bfca095cc1173fff6995c4d39844.tar.xz
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: RDMA/nes: Fix possible array overrun RDMA/nes: Fix VLAN support RDMA/nes: Fix MAC interrupt erroneously masked on ifdown IB: Fix return value in ib_device_register_sysfs()
Diffstat (limited to 'drivers/infiniband/core/sysfs.c')
-rw-r--r--drivers/infiniband/core/sysfs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/infiniband/core/sysfs.c b/drivers/infiniband/core/sysfs.c
index c864ef70fdf9..5a4b2e65534b 100644
--- a/drivers/infiniband/core/sysfs.c
+++ b/drivers/infiniband/core/sysfs.c
@@ -686,8 +686,10 @@ int ib_device_register_sysfs(struct ib_device *device)
device->ports_parent = kobject_create_and_add("ports",
kobject_get(&class_dev->kobj));
- if (!device->ports_parent)
+ if (!device->ports_parent) {
+ ret = -ENOMEM;
goto err_put;
+ }
if (device->node_type == RDMA_NODE_IB_SWITCH) {
ret = add_port(device, 0);