* [PATCH] drm/plane: Fix a couple of checkpatch warnings
@ 2014-05-13 14:58 Thierry Reding
2014-05-13 15:32 ` Matt Roper
0 siblings, 1 reply; 3+ messages in thread
From: Thierry Reding @ 2014-05-13 14:58 UTC (permalink / raw)
To: dri-devel
From: Thierry Reding <treding@nvidia.com>
Code should be indented using tabs rather than spaces (see CodingStyle)
and the canonical form to declare a constant static variable is using
"static const" rather than "const static". Fixes the following warnings
from checkpatch:
$ scripts/checkpatch.pl -f drivers/gpu/drm/drm_plane_helper.c
WARNING: storage class should be at the beginning of the declaration
#40: FILE: drivers/gpu/drm/drm_plane_helper.c:40:
+const static uint32_t safe_modeset_formats[] = {
WARNING: please, no spaces at the start of a line
#41: FILE: drivers/gpu/drm/drm_plane_helper.c:41:
+ DRM_FORMAT_XRGB8888,$
WARNING: please, no spaces at the start of a line
#42: FILE: drivers/gpu/drm/drm_plane_helper.c:42:
+ DRM_FORMAT_ARGB8888,$
Signed-off-by: Thierry Reding <treding@nvidia.com>
---
drivers/gpu/drm/drm_plane_helper.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/drm_plane_helper.c b/drivers/gpu/drm/drm_plane_helper.c
index 0b58dbc86707..97e5518ca15b 100644
--- a/drivers/gpu/drm/drm_plane_helper.c
+++ b/drivers/gpu/drm/drm_plane_helper.c
@@ -37,9 +37,9 @@
* creating the primary plane. However drivers that still call
* drm_plane_init() will use this minimal format list as the default.
*/
-const static uint32_t safe_modeset_formats[] = {
- DRM_FORMAT_XRGB8888,
- DRM_FORMAT_ARGB8888,
+static const uint32_t safe_modeset_formats[] = {
+ DRM_FORMAT_XRGB8888,
+ DRM_FORMAT_ARGB8888,
};
/*
--
1.9.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/plane: Fix a couple of checkpatch warnings
2014-05-13 14:58 [PATCH] drm/plane: Fix a couple of checkpatch warnings Thierry Reding
@ 2014-05-13 15:32 ` Matt Roper
2014-05-13 17:48 ` Daniel Vetter
0 siblings, 1 reply; 3+ messages in thread
From: Matt Roper @ 2014-05-13 15:32 UTC (permalink / raw)
To: Thierry Reding; +Cc: dri-devel
On Tue, May 13, 2014 at 04:58:35PM +0200, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
>
> Code should be indented using tabs rather than spaces (see CodingStyle)
> and the canonical form to declare a constant static variable is using
> "static const" rather than "const static". Fixes the following warnings
> from checkpatch:
>
> $ scripts/checkpatch.pl -f drivers/gpu/drm/drm_plane_helper.c
> WARNING: storage class should be at the beginning of the declaration
> #40: FILE: drivers/gpu/drm/drm_plane_helper.c:40:
> +const static uint32_t safe_modeset_formats[] = {
>
> WARNING: please, no spaces at the start of a line
> #41: FILE: drivers/gpu/drm/drm_plane_helper.c:41:
> + DRM_FORMAT_XRGB8888,$
>
> WARNING: please, no spaces at the start of a line
> #42: FILE: drivers/gpu/drm/drm_plane_helper.c:42:
> + DRM_FORMAT_ARGB8888,$
>
> Signed-off-by: Thierry Reding <treding@nvidia.com>
Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
> ---
> drivers/gpu/drm/drm_plane_helper.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_plane_helper.c b/drivers/gpu/drm/drm_plane_helper.c
> index 0b58dbc86707..97e5518ca15b 100644
> --- a/drivers/gpu/drm/drm_plane_helper.c
> +++ b/drivers/gpu/drm/drm_plane_helper.c
> @@ -37,9 +37,9 @@
> * creating the primary plane. However drivers that still call
> * drm_plane_init() will use this minimal format list as the default.
> */
> -const static uint32_t safe_modeset_formats[] = {
> - DRM_FORMAT_XRGB8888,
> - DRM_FORMAT_ARGB8888,
> +static const uint32_t safe_modeset_formats[] = {
> + DRM_FORMAT_XRGB8888,
> + DRM_FORMAT_ARGB8888,
> };
>
> /*
> --
> 1.9.2
>
--
Matt Roper
Graphics Software Engineer
IoTG Platform Enabling & Development
Intel Corporation
(916) 356-2795
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/plane: Fix a couple of checkpatch warnings
2014-05-13 15:32 ` Matt Roper
@ 2014-05-13 17:48 ` Daniel Vetter
0 siblings, 0 replies; 3+ messages in thread
From: Daniel Vetter @ 2014-05-13 17:48 UTC (permalink / raw)
To: Matt Roper; +Cc: dri-devel
On Tue, May 13, 2014 at 08:32:31AM -0700, Matt Roper wrote:
> On Tue, May 13, 2014 at 04:58:35PM +0200, Thierry Reding wrote:
> > From: Thierry Reding <treding@nvidia.com>
> >
> > Code should be indented using tabs rather than spaces (see CodingStyle)
> > and the canonical form to declare a constant static variable is using
> > "static const" rather than "const static". Fixes the following warnings
> > from checkpatch:
> >
> > $ scripts/checkpatch.pl -f drivers/gpu/drm/drm_plane_helper.c
> > WARNING: storage class should be at the beginning of the declaration
> > #40: FILE: drivers/gpu/drm/drm_plane_helper.c:40:
> > +const static uint32_t safe_modeset_formats[] = {
> >
> > WARNING: please, no spaces at the start of a line
> > #41: FILE: drivers/gpu/drm/drm_plane_helper.c:41:
> > + DRM_FORMAT_XRGB8888,$
> >
> > WARNING: please, no spaces at the start of a line
> > #42: FILE: drivers/gpu/drm/drm_plane_helper.c:42:
> > + DRM_FORMAT_ARGB8888,$
> >
> > Signed-off-by: Thierry Reding <treding@nvidia.com>
>
> Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
Both pulled into my topic/core-stuff branch to make sure they don't get
lost.
-Daniel
>
> > ---
> > drivers/gpu/drm/drm_plane_helper.c | 6 +++---
> > 1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/drm_plane_helper.c b/drivers/gpu/drm/drm_plane_helper.c
> > index 0b58dbc86707..97e5518ca15b 100644
> > --- a/drivers/gpu/drm/drm_plane_helper.c
> > +++ b/drivers/gpu/drm/drm_plane_helper.c
> > @@ -37,9 +37,9 @@
> > * creating the primary plane. However drivers that still call
> > * drm_plane_init() will use this minimal format list as the default.
> > */
> > -const static uint32_t safe_modeset_formats[] = {
> > - DRM_FORMAT_XRGB8888,
> > - DRM_FORMAT_ARGB8888,
> > +static const uint32_t safe_modeset_formats[] = {
> > + DRM_FORMAT_XRGB8888,
> > + DRM_FORMAT_ARGB8888,
> > };
> >
> > /*
> > --
> > 1.9.2
> >
>
> --
> Matt Roper
> Graphics Software Engineer
> IoTG Platform Enabling & Development
> Intel Corporation
> (916) 356-2795
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-05-13 17:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-13 14:58 [PATCH] drm/plane: Fix a couple of checkpatch warnings Thierry Reding
2014-05-13 15:32 ` Matt Roper
2014-05-13 17:48 ` Daniel Vetter
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.