diff options
author | Ira Weiny <ira.weiny@intel.com> | 2015-12-02 00:43:31 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-12-21 13:53:37 -0800 |
commit | 9d2b75f696d9a3988e0aab00fca8f931ece35d9c (patch) | |
tree | 598fb7d3fb88aaa011aa2ca5cc9088ed9dc5d731 /drivers/staging | |
parent | 47bc16971939367a8e6b5c38637ba8afb3b8908d (diff) |
staging/rdma/hfi1: diag.c add missing braces
Else statements should continue using braces even if there is only 1 line in
the block. Found by checkpatch --strict
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/rdma/hfi1/diag.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/staging/rdma/hfi1/diag.c b/drivers/staging/rdma/hfi1/diag.c index f687ddfe264d..ed9cfccc860b 100644 --- a/drivers/staging/rdma/hfi1/diag.c +++ b/drivers/staging/rdma/hfi1/diag.c @@ -954,12 +954,14 @@ static ssize_t hfi1_snoop_read(struct file *fp, char __user *data, ret = -EFAULT; else ret = packet->total_len; - } else + } else { ret = -EINVAL; + } kfree(packet); - } else + } else { spin_unlock_irqrestore(&dd->hfi1_snoop.snoop_lock, flags); + } return ret; } |