Re: [Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-16 Thread Tapani Pälli

thanks, pushed!

On 11/17/2016 12:29 AM, Eric Engestrom wrote:

I introduced this code last month, but didn't follow the naming
convention. Fix this.

Fixes: 0a606a400fe382a9bc72 ("egl: add eglSwapBuffersWithDamageKHR")
Reviewed-by: Tapani Pälli 
Signed-off-by: Eric Engestrom 
---
 src/egl/main/eglapi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
index 53340bf..934d585 100644
--- a/src/egl/main/eglapi.c
+++ b/src/egl/main/eglapi.c
@@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)


 static EGLBoolean
-eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
-   EGLint *rects, EGLint n_rects)
+_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
+EGLint *rects, EGLint n_rects)
 {
_EGLContext *ctx = _eglGetCurrentContext();
@@ -1224,7 +1224,7 @@ eglSwapBuffersWithDamageEXT(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }

 static EGLBoolean EGLAPIENTRY
@@ -1234,7 +1234,7 @@ eglSwapBuffersWithDamageKHR(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }

 EGLBoolean EGLAPIENTRY


___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


[Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-16 Thread Eric Engestrom
I introduced this code last month, but didn't follow the naming
convention. Fix this.

Fixes: 0a606a400fe382a9bc72 ("egl: add eglSwapBuffersWithDamageKHR")
Reviewed-by: Tapani Pälli 
Signed-off-by: Eric Engestrom 
---
 src/egl/main/eglapi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
index 53340bf..934d585 100644
--- a/src/egl/main/eglapi.c
+++ b/src/egl/main/eglapi.c
@@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)
 
 
 static EGLBoolean
-eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
-   EGLint *rects, EGLint n_rects)
+_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
+EGLint *rects, EGLint n_rects)
 {
_EGLContext *ctx = _eglGetCurrentContext();
@@ -1224,7 +1224,7 @@ eglSwapBuffersWithDamageEXT(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }
 
 static EGLBoolean EGLAPIENTRY
@@ -1234,7 +1234,7 @@ eglSwapBuffersWithDamageKHR(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }
 
 EGLBoolean EGLAPIENTRY
-- 
Cheers,
  Eric

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-16 Thread Eric Engestrom
On Tuesday, 2016-11-15 22:49:52 -0800, Matt Turner wrote:
> On Tue, Nov 15, 2016 at 3:43 PM, Eric Engestrom  wrote:
> > Signed-off-by: Eric Engestrom 
> > ---
> >  src/egl/main/eglapi.c | 6 +++---
> >  1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
> > index 53340bf..934d585 100644
> > --- a/src/egl/main/eglapi.c
> > +++ b/src/egl/main/eglapi.c
> > @@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)
> >
> >
> >  static EGLBoolean
> > -eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
> > +_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
> > EGLint *rects, EGLint n_rects)
> 
> Should indent the wrapped parameters one space as well

Good eye!
I'll send a v2 tonight.

Cheers,
  Eric
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-16 Thread Eric Engestrom
On Wednesday, 2016-11-16 08:29:27 +0200, Tapani Pälli wrote:
> why not ..
> 
> Reviewed-by: Tapani Pälli 
> 
> (note that there are other static functions that don't have '_' in them in
> this file, also there is _eglConvertIntsToAttribs which looks like it could
> be static (only one caller in same file) but it is not)

Reason I did this and didn't look at the rest was that I introduced
these functions a month ago, and just realized I didn't follow the
naming convention for them.

Note to self: have a look at the rest EGL, and fix names and add
`static` where appropriate.

> 
> On 11/16/2016 01:43 AM, Eric Engestrom wrote:
> > Signed-off-by: Eric Engestrom 
> > ---
> >  src/egl/main/eglapi.c | 6 +++---
> >  1 file changed, 3 insertions(+), 3 deletions(-)
> > 
> > diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
> > index 53340bf..934d585 100644
> > --- a/src/egl/main/eglapi.c
> > +++ b/src/egl/main/eglapi.c
> > @@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)
> > 
> > 
> >  static EGLBoolean
> > -eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
> > +_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
> > EGLint *rects, EGLint n_rects)
> >  {
> > _EGLContext *ctx = _eglGetCurrentContext();
> > @@ -1224,7 +1224,7 @@ eglSwapBuffersWithDamageEXT(EGLDisplay dpy, 
> > EGLSurface surface,
> > _EGLDisplay *disp = _eglLockDisplay(dpy);
> > _EGLSurface *surf = _eglLookupSurface(surface, disp);
> > _EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
> > -   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
> > +   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
> >  }
> > 
> >  static EGLBoolean EGLAPIENTRY
> > @@ -1234,7 +1234,7 @@ eglSwapBuffersWithDamageKHR(EGLDisplay dpy, 
> > EGLSurface surface,
> > _EGLDisplay *disp = _eglLockDisplay(dpy);
> > _EGLSurface *surf = _eglLookupSurface(surface, disp);
> > _EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
> > -   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
> > +   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
> >  }
> > 
> >  EGLBoolean EGLAPIENTRY
> > 
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-15 Thread Matt Turner
On Tue, Nov 15, 2016 at 3:43 PM, Eric Engestrom  wrote:
> Signed-off-by: Eric Engestrom 
> ---
>  src/egl/main/eglapi.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
> index 53340bf..934d585 100644
> --- a/src/egl/main/eglapi.c
> +++ b/src/egl/main/eglapi.c
> @@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)
>
>
>  static EGLBoolean
> -eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
> +_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
> EGLint *rects, EGLint n_rects)

Should indent the wrapped parameters one space as well
___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


Re: [Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-15 Thread Tapani Pälli

why not ..

Reviewed-by: Tapani Pälli 

(note that there are other static functions that don't have '_' in them 
in this file, also there is _eglConvertIntsToAttribs which looks like it 
could be static (only one caller in same file) but it is not)


On 11/16/2016 01:43 AM, Eric Engestrom wrote:

Signed-off-by: Eric Engestrom 
---
 src/egl/main/eglapi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
index 53340bf..934d585 100644
--- a/src/egl/main/eglapi.c
+++ b/src/egl/main/eglapi.c
@@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)


 static EGLBoolean
-eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
+_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
EGLint *rects, EGLint n_rects)
 {
_EGLContext *ctx = _eglGetCurrentContext();
@@ -1224,7 +1224,7 @@ eglSwapBuffersWithDamageEXT(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }

 static EGLBoolean EGLAPIENTRY
@@ -1234,7 +1234,7 @@ eglSwapBuffersWithDamageKHR(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }

 EGLBoolean EGLAPIENTRY


___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev


[Mesa-dev] [PATCH mesa] egl: fix helper function name

2016-11-15 Thread Eric Engestrom
Signed-off-by: Eric Engestrom 
---
 src/egl/main/eglapi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/egl/main/eglapi.c b/src/egl/main/eglapi.c
index 53340bf..934d585 100644
--- a/src/egl/main/eglapi.c
+++ b/src/egl/main/eglapi.c
@@ -1195,7 +1195,7 @@ eglSwapBuffers(EGLDisplay dpy, EGLSurface surface)
 
 
 static EGLBoolean
-eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
+_eglSwapBuffersWithDamageCommon(_EGLDisplay *disp, _EGLSurface *surf,
EGLint *rects, EGLint n_rects)
 {
_EGLContext *ctx = _eglGetCurrentContext();
@@ -1224,7 +1224,7 @@ eglSwapBuffersWithDamageEXT(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }
 
 static EGLBoolean EGLAPIENTRY
@@ -1234,7 +1234,7 @@ eglSwapBuffersWithDamageKHR(EGLDisplay dpy, EGLSurface 
surface,
_EGLDisplay *disp = _eglLockDisplay(dpy);
_EGLSurface *surf = _eglLookupSurface(surface, disp);
_EGL_FUNC_START(disp, EGL_OBJECT_SURFACE_KHR, surf, EGL_FALSE);
-   return eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
+   return _eglSwapBuffersWithDamageCommon(disp, surf, rects, n_rects);
 }
 
 EGLBoolean EGLAPIENTRY
-- 
Cheers,
  Eric

___
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev