From: Joe Perches <joe@perches.com>
To: Vinay Simha BN <simhavcs@gmail.com>
Cc: Sudip Mukherjee <sudipm.mukherjee@gmail.com>,
Teddy Wang <teddy.wang@siliconmotion.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
"open list:STAGING - SILICON MOTION SM750 FRAME BUFFER DRIVER"
<linux-fbdev@vger.kernel.org>,
"open list:STAGING SUBSYSTEM" <devel@driverdev.osuosl.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] sm750fb: coding style fixes lines over 80 chars
Date: Fri, 17 Jul 2015 07:38:41 +0000 [thread overview]
Message-ID: <1437118721.2495.54.camel@perches.com> (raw)
In-Reply-To: <1437118085-8432-1-git-send-email-simhavcs@gmail.com>
On Fri, 2015-07-17 at 12:58 +0530, Vinay Simha BN wrote:
> scripts/checkpatch.pl kernel coding style fixes of WARNING
Please use checkpatch's --strict option until you know
kernel style much better.
> diff --git a/drivers/staging/sm750fb/sm750_accel.h b/drivers/staging/sm750fb/sm750_accel.h
[]
> @@ -259,17 +259,22 @@ unsigned int height, /* width and height of rectangle in pixel value */
> unsigned int rop2);
>
> int hw_imageblit(struct lynx_accel *accel,
> - const char *pSrcbuf, /* pointer to start of source buffer in system memory */
> - u32 srcDelta, /* Pitch value (in bytes) of the source buffer, +ive means top down and -ive mean button up */
> - u32 startBit, /* Mono data can start at any bit in a byte, this value should be 0 to 7 */
> - u32 dBase, /* Address of destination: offset in frame buffer */
> + const char *pSrcbuf, /* pointer to start of source
> + buffer in system memory */
If you change these lines, please use normal kernel comment style.
/*
* comment block
*/
> diff --git a/drivers/staging/sm750fb/sm750_help.h b/drivers/staging/sm750fb/sm750_help.h
[]
> @@ -49,17 +49,23 @@
> /* Field Macros */
> #define FIELD_START(field) (0 ? field)
> #define FIELD_END(field) (1 ? field)
Odd statements.
> -#define FIELD_SIZE(field) (1 + FIELD_END(field) - FIELD_START(field))
> -#define FIELD_MASK(field) (((1 << (FIELD_SIZE(field)-1)) | ((1 << (FIELD_SIZE(field)-1)) - 1)) << FIELD_START(field))
> -#define FIELD_NORMALIZE(reg, field) (((reg) & FIELD_MASK(field)) >> FIELD_START(field))
> -#define FIELD_DENORMALIZE(field, value) (((value) << FIELD_START(field)) & FIELD_MASK(field))
> +#define FIELD_SIZE(field) (1 + FIELD_END(field) - \
> + FIELD_START(field))
> +#define FIELD_MASK(field) (((1 << (FIELD_SIZE(field)-1)) \
> + | ((1 << (FIELD_SIZE(field)-1)) - 1)) \
> + << FIELD_START(field))
> +#define FIELD_NORMALIZE(reg, field) (((reg) & FIELD_MASK(field)) >> \
> + FIELD_START(field))
> +#define FIELD_DENORMALIZE(field, value) (((value) << FIELD_START(field)) & \
> + FIELD_MASK(field))
>
> #define FIELD_INIT(reg, field, value) FIELD_DENORMALIZE(reg ## _ ## field, \
> - reg ## _ ## field ## _ ## value)
> + reg ## _ ## field ## _ ## value)
> #define FIELD_INIT_VAL(reg, field, value) \
> (FIELD_DENORMALIZE(reg ## _ ## field, value))
> #define FIELD_VAL_SET(x, r, f, v) x = x & ~FIELD_MASK(r ## _ ## f) \
> - | FIELD_DENORMALIZE(r ## _ ## f, r ## _ ## f ## _ ## v)
> + | FIELD_DENORMALIZE(r ## _ ## f, \
> + r ## _ ## f ## _ ## v)
I think _none_ of these are actually used so it'd
be better to delete them instead.
WARNING: multiple messages have this Message-ID (diff)
From: Joe Perches <joe@perches.com>
To: Vinay Simha BN <simhavcs@gmail.com>
Cc: Sudip Mukherjee <sudipm.mukherjee@gmail.com>,
Teddy Wang <teddy.wang@siliconmotion.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
"open list:STAGING - SILICON MOTION SM750 FRAME BUFFER DRIVER"
<linux-fbdev@vger.kernel.org>,
"open list:STAGING SUBSYSTEM" <devel@driverdev.osuosl.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] sm750fb: coding style fixes lines over 80 chars
Date: Fri, 17 Jul 2015 00:38:41 -0700 [thread overview]
Message-ID: <1437118721.2495.54.camel@perches.com> (raw)
In-Reply-To: <1437118085-8432-1-git-send-email-simhavcs@gmail.com>
On Fri, 2015-07-17 at 12:58 +0530, Vinay Simha BN wrote:
> scripts/checkpatch.pl kernel coding style fixes of WARNING
Please use checkpatch's --strict option until you know
kernel style much better.
> diff --git a/drivers/staging/sm750fb/sm750_accel.h b/drivers/staging/sm750fb/sm750_accel.h
[]
> @@ -259,17 +259,22 @@ unsigned int height, /* width and height of rectangle in pixel value */
> unsigned int rop2);
>
> int hw_imageblit(struct lynx_accel *accel,
> - const char *pSrcbuf, /* pointer to start of source buffer in system memory */
> - u32 srcDelta, /* Pitch value (in bytes) of the source buffer, +ive means top down and -ive mean button up */
> - u32 startBit, /* Mono data can start at any bit in a byte, this value should be 0 to 7 */
> - u32 dBase, /* Address of destination: offset in frame buffer */
> + const char *pSrcbuf, /* pointer to start of source
> + buffer in system memory */
If you change these lines, please use normal kernel comment style.
/*
* comment block
*/
> diff --git a/drivers/staging/sm750fb/sm750_help.h b/drivers/staging/sm750fb/sm750_help.h
[]
> @@ -49,17 +49,23 @@
> /* Field Macros */
> #define FIELD_START(field) (0 ? field)
> #define FIELD_END(field) (1 ? field)
Odd statements.
> -#define FIELD_SIZE(field) (1 + FIELD_END(field) - FIELD_START(field))
> -#define FIELD_MASK(field) (((1 << (FIELD_SIZE(field)-1)) | ((1 << (FIELD_SIZE(field)-1)) - 1)) << FIELD_START(field))
> -#define FIELD_NORMALIZE(reg, field) (((reg) & FIELD_MASK(field)) >> FIELD_START(field))
> -#define FIELD_DENORMALIZE(field, value) (((value) << FIELD_START(field)) & FIELD_MASK(field))
> +#define FIELD_SIZE(field) (1 + FIELD_END(field) - \
> + FIELD_START(field))
> +#define FIELD_MASK(field) (((1 << (FIELD_SIZE(field)-1)) \
> + | ((1 << (FIELD_SIZE(field)-1)) - 1)) \
> + << FIELD_START(field))
> +#define FIELD_NORMALIZE(reg, field) (((reg) & FIELD_MASK(field)) >> \
> + FIELD_START(field))
> +#define FIELD_DENORMALIZE(field, value) (((value) << FIELD_START(field)) & \
> + FIELD_MASK(field))
>
> #define FIELD_INIT(reg, field, value) FIELD_DENORMALIZE(reg ## _ ## field, \
> - reg ## _ ## field ## _ ## value)
> + reg ## _ ## field ## _ ## value)
> #define FIELD_INIT_VAL(reg, field, value) \
> (FIELD_DENORMALIZE(reg ## _ ## field, value))
> #define FIELD_VAL_SET(x, r, f, v) x = x & ~FIELD_MASK(r ## _ ## f) \
> - | FIELD_DENORMALIZE(r ## _ ## f, r ## _ ## f ## _ ## v)
> + | FIELD_DENORMALIZE(r ## _ ## f, \
> + r ## _ ## f ## _ ## v)
I think _none_ of these are actually used so it'd
be better to delete them instead.
next prev parent reply other threads:[~2015-07-17 7:38 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-17 7:28 [PATCH] sm750fb: coding style fixes lines over 80 chars Vinay Simha BN
2015-07-17 7:40 ` Vinay Simha BN
2015-07-17 7:38 ` Joe Perches [this message]
2015-07-17 7:38 ` Joe Perches
2015-07-21 6:44 ` [PATCH] sm750fb: coding style fixes in _accel.h,__help.h Vinay Simha BN
2015-07-21 6:56 ` Vinay Simha BN
2015-07-21 7:17 ` Sudip Mukherjee
2015-07-21 7:29 ` Sudip Mukherjee
[not found] ` <CAGWqDJ5AkG5PwQOkboZfiC1PzXw0j+x5zwaYn0SWWtiks+OP2A@mail.gmail.com>
2015-07-21 7:31 ` Sudip Mukherjee
2015-07-21 7:43 ` Sudip Mukherjee
2015-07-21 7:40 ` [PATCH 1/2] sm750fb: coding style fixes lines over 80 chars Vinay Simha BN
2015-07-21 7:52 ` Vinay Simha BN
2015-07-21 7:40 ` [PATCH 2/2] sm750fb: coding style fixes lines over 80 chars - v2 Vinay Simha BN
2015-07-21 7:52 ` Vinay Simha BN
2015-07-21 8:39 ` Dan Carpenter
2015-07-21 8:39 ` Dan Carpenter
2015-07-21 8:14 ` [PATCH 1/2] sm750fb: coding style fixes lines over 80 chars Joe Perches
2015-07-21 8:14 ` Joe Perches
2015-07-21 8:35 ` Dan Carpenter
2015-07-21 8:35 ` Dan Carpenter
[not found] ` <CAGWqDJ4dgrsYAiWXMKi2j1-kGoFhQ_rZGxuDuqpbfTG2P7bnsw@mail.gmail.com>
2015-07-27 5:24 ` [PATCH] " Sudip Mukherjee
2015-07-27 5:36 ` Sudip Mukherjee
-- strict thread matches above, loose matches on Subject: below --
2015-07-15 18:46 Vinay Simha BN
2015-07-15 18:58 ` Vinay Simha BN
2015-07-16 3:57 ` Joe Perches
2015-07-16 3:57 ` Joe Perches
2015-07-17 7:16 ` Vinay Simha
2015-07-17 7:28 ` Vinay Simha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1437118721.2495.54.camel@perches.com \
--to=joe@perches.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-fbdev@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=simhavcs@gmail.com \
--cc=sudipm.mukherjee@gmail.com \
--cc=teddy.wang@siliconmotion.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.