aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband
diff options
context:
space:
mode:
authorRoland Dreier <rolandd@cisco.com>2005-10-20 15:30:16 -0400
committerRoland Dreier <rolandd@cisco.com>2005-10-20 15:30:16 -0400
commit2e0c512aff978a7040464e81fc9c0dfdf4639c23 (patch)
tree0b278a811609e159bcaa134099af1692cdabd3ee /drivers/infiniband
parent3910f44d79a8a4a26fcfefbf16c5b8e1a7743175 (diff)
[IB] user_mad: trivial coding style fixes
Add spaces after "sizeof" operator to match the rest of file. Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r--drivers/infiniband/core/user_mad.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/infiniband/core/user_mad.c b/drivers/infiniband/core/user_mad.c
index a64d6b4dcc16..38f4bfbb7135 100644
--- a/drivers/infiniband/core/user_mad.c
+++ b/drivers/infiniband/core/user_mad.c
@@ -280,14 +280,14 @@ static ssize_t ib_umad_write(struct file *filp, const char __user *buf,
280 280
281 length = count - sizeof (struct ib_user_mad); 281 length = count - sizeof (struct ib_user_mad);
282 packet = kmalloc(sizeof *packet + sizeof(struct ib_mad_hdr) + 282 packet = kmalloc(sizeof *packet + sizeof(struct ib_mad_hdr) +
283 sizeof(struct ib_rmpp_hdr), GFP_KERNEL); 283 sizeof (struct ib_rmpp_hdr), GFP_KERNEL);
284 if (!packet) 284 if (!packet)
285 return -ENOMEM; 285 return -ENOMEM;
286 286
287 if (copy_from_user(&packet->mad, buf, 287 if (copy_from_user(&packet->mad, buf,
288 sizeof (struct ib_user_mad) + 288 sizeof (struct ib_user_mad) +
289 sizeof(struct ib_mad_hdr) + 289 sizeof (struct ib_mad_hdr) +
290 sizeof(struct ib_rmpp_hdr))) { 290 sizeof (struct ib_rmpp_hdr))) {
291 ret = -EFAULT; 291 ret = -EFAULT;
292 goto err; 292 goto err;
293 } 293 }
@@ -349,7 +349,7 @@ static ssize_t ib_umad_write(struct file *filp, const char __user *buf,
349 } 349 }
350 rmpp_active = 1; 350 rmpp_active = 1;
351 } else { 351 } else {
352 if (length > sizeof(struct ib_mad)) { 352 if (length > sizeof (struct ib_mad)) {
353 ret = -EINVAL; 353 ret = -EINVAL;
354 goto err_ah; 354 goto err_ah;
355 } 355 }
@@ -376,17 +376,17 @@ static ssize_t ib_umad_write(struct file *filp, const char __user *buf,
376 if (!rmpp_active) { 376 if (!rmpp_active) {
377 /* Copy message from user into send buffer */ 377 /* Copy message from user into send buffer */
378 if (copy_from_user(packet->msg->mad, 378 if (copy_from_user(packet->msg->mad,
379 buf + sizeof(struct ib_user_mad), length)) { 379 buf + sizeof (struct ib_user_mad), length)) {
380 ret = -EFAULT; 380 ret = -EFAULT;
381 goto err_msg; 381 goto err_msg;
382 } 382 }
383 } else { 383 } else {
384 rmpp_hdr_size = sizeof(struct ib_mad_hdr) + 384 rmpp_hdr_size = sizeof (struct ib_mad_hdr) +
385 sizeof(struct ib_rmpp_hdr); 385 sizeof (struct ib_rmpp_hdr);
386 386
387 /* Only copy MAD headers (RMPP header in place) */ 387 /* Only copy MAD headers (RMPP header in place) */
388 memcpy(packet->msg->mad, packet->mad.data, 388 memcpy(packet->msg->mad, packet->mad.data,
389 sizeof(struct ib_mad_hdr)); 389 sizeof (struct ib_mad_hdr));
390 390
391 /* Now, copy rest of message from user into send buffer */ 391 /* Now, copy rest of message from user into send buffer */
392 if (copy_from_user(((struct ib_rmpp_mad *) packet->msg->mad)->data, 392 if (copy_from_user(((struct ib_rmpp_mad *) packet->msg->mad)->data,