lkml.org 
[lkml]   [2014]   [Oct]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] char: misc: add missing blank line after declarations
Date
Signed-off-by: Rahul Bedarkar <rahulbedarkar89@gmail.com>
---
drivers/char/misc.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/drivers/char/misc.c b/drivers/char/misc.c
index cb32ea9..3111e86 100644
--- a/drivers/char/misc.c
+++ b/drivers/char/misc.c
@@ -186,6 +186,7 @@ int misc_register(struct miscdevice *misc)

if (misc->minor == MISC_DYNAMIC_MINOR) {
int i = find_first_zero_bit(misc_minors, DYNAMIC_MINORS);
+
if (i >= DYNAMIC_MINORS) {
err = -EBUSY;
goto out;
@@ -209,6 +210,7 @@ int misc_register(struct miscdevice *misc)
misc, "%s", misc->name);
if (IS_ERR(misc->this_device)) {
int i = DYNAMIC_MINORS - misc->minor - 1;
+
if (i < DYNAMIC_MINORS && i >= 0)
clear_bit(i, misc_minors);
err = PTR_ERR(misc->this_device);
--
1.8.3.2


\
 
 \ /
  Last update: 2014-10-11 21:01    [W:0.387 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site