2014-12-01 12:36:59

by Athira Sharikkal

[permalink] [raw]
Subject: [PATCH v2] Drivers: input: mousedev.c: Fixed trailing statement on the next line

Fixed checkpatch error:
trailing statements should be on next line

Signed-off-by: Athira Sharikkal <[email protected]>
---
v2: corrected indentation
drivers/input/mousedev.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/input/mousedev.c b/drivers/input/mousedev.c
index b604564..28988f5 100644
--- a/drivers/input/mousedev.c
+++ b/drivers/input/mousedev.c
@@ -248,7 +248,8 @@ static void mousedev_key_event(struct mousedev *mousedev,
case BTN_4:
case BTN_EXTRA: index = 4; break;

- default: return;
+ default:
+ return;
}

if (value) {
--
1.9.1


2014-12-03 05:25:58

by Dmitry Torokhov

[permalink] [raw]
Subject: Re: [PATCH v2] Drivers: input: mousedev.c: Fixed trailing statement on the next line

Hi Athira,

On Mon, Dec 01, 2014 at 06:06:42PM +0530, Athira Sharikkal wrote:
> Fixed checkpatch error:
> trailing statements should be on next line
>
> Signed-off-by: Athira Sharikkal <[email protected]>
> ---
> v2: corrected indentation
> drivers/input/mousedev.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/input/mousedev.c b/drivers/input/mousedev.c
> index b604564..28988f5 100644
> --- a/drivers/input/mousedev.c
> +++ b/drivers/input/mousedev.c
> @@ -248,7 +248,8 @@ static void mousedev_key_event(struct mousedev *mousedev,
> case BTN_4:
> case BTN_EXTRA: index = 4; break;
>
> - default: return;
> + default:
> + return;

Changing one bit in a file while leaving the rest of it unchanged does not
make much sense. That said, I believe that in this particular case the
original style is fine and does not need changing.

Thanks.

--
Dmitry