Re: [Mesa-dev] [PATCH v1 3/7] gallium: os_process fixes for Android
On 16 June 2017 at 04:38, Chih-Wei Huangwrote: > 2017-06-16 4:47 GMT+08:00 Robert Foss : >> From: Rob Herring >> >> Signed-off-by: Rob Herring >> --- >> src/gallium/auxiliary/os/os_process.c | 5 +++-- >> 1 file changed, 3 insertions(+), 2 deletions(-) >> >> diff --git a/src/gallium/auxiliary/os/os_process.c >> b/src/gallium/auxiliary/os/os_process.c >> index 6622b9b2bc..af5d22bf84 100644 >> --- a/src/gallium/auxiliary/os/os_process.c >> +++ b/src/gallium/auxiliary/os/os_process.c >> @@ -34,7 +34,7 @@ >> # include >> #elif defined(__GLIBC__) || defined(__CYGWIN__) >> # include >> -#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) >> +#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) || >> defined(PIPE_OS_ANDROID) >> # include >> #elif defined(PIPE_OS_HAIKU) >> # include >> @@ -59,6 +59,7 @@ os_get_process_name(char *procname, size_t size) >> { >> const char *name; >> >> + Unrelated whitespace change. >> /* First, check if the GALLIUM_PROCESS_NAME env var is set to >> * override the normal process name query. >> */ >> @@ -86,7 +87,7 @@ os_get_process_name(char *procname, size_t size) >> >> #elif defined(__GLIBC__) || defined(__CYGWIN__) >>name = program_invocation_short_name; >> -#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) >> +#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) || >> defined(PIPE_OS_ANDROID) >>/* *BSD and OS X */ >>name = getprogname(); >> #elif defined(PIPE_OS_HAIKU) >> -- > > I have submitted another patch to fix > the same issue about 2 weeks ago. > My suggestion is just define PIPE_OS_BSD > for Android. This allows Android to share features > inherited from (Open)BSD and avoid further changes > like this one. > > Please see: > https://lists.freedesktop.org/archives/mesa-dev/2017-June/157754.html > And as mentioned in the thread - assuming both BSD and Linux does not sound like a good idea. Let's go ahead with this, but Rob please apply some polish on the commit message. Some example follows: "gallium: android: use BSD code path for os_get_process_name The function getprogname() is available on Android, since it reuses various BSD solutions C runtime." With the above Reviewed-by: Emil Velikov -Emil ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev
Re: [Mesa-dev] [PATCH v1 3/7] gallium: os_process fixes for Android
2017-06-16 4:47 GMT+08:00 Robert Foss: > From: Rob Herring > > Signed-off-by: Rob Herring > --- > src/gallium/auxiliary/os/os_process.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/src/gallium/auxiliary/os/os_process.c > b/src/gallium/auxiliary/os/os_process.c > index 6622b9b2bc..af5d22bf84 100644 > --- a/src/gallium/auxiliary/os/os_process.c > +++ b/src/gallium/auxiliary/os/os_process.c > @@ -34,7 +34,7 @@ > # include > #elif defined(__GLIBC__) || defined(__CYGWIN__) > # include > -#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) > +#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) || > defined(PIPE_OS_ANDROID) > # include > #elif defined(PIPE_OS_HAIKU) > # include > @@ -59,6 +59,7 @@ os_get_process_name(char *procname, size_t size) > { > const char *name; > > + > /* First, check if the GALLIUM_PROCESS_NAME env var is set to > * override the normal process name query. > */ > @@ -86,7 +87,7 @@ os_get_process_name(char *procname, size_t size) > > #elif defined(__GLIBC__) || defined(__CYGWIN__) >name = program_invocation_short_name; > -#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) > +#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) || > defined(PIPE_OS_ANDROID) >/* *BSD and OS X */ >name = getprogname(); > #elif defined(PIPE_OS_HAIKU) > -- I have submitted another patch to fix the same issue about 2 weeks ago. My suggestion is just define PIPE_OS_BSD for Android. This allows Android to share features inherited from (Open)BSD and avoid further changes like this one. Please see: https://lists.freedesktop.org/archives/mesa-dev/2017-June/157754.html -- Chih-Wei Android-x86 project http://www.android-x86.org ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev
[Mesa-dev] [PATCH v1 3/7] gallium: os_process fixes for Android
From: Rob HerringSigned-off-by: Rob Herring --- src/gallium/auxiliary/os/os_process.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/os/os_process.c b/src/gallium/auxiliary/os/os_process.c index 6622b9b2bc..af5d22bf84 100644 --- a/src/gallium/auxiliary/os/os_process.c +++ b/src/gallium/auxiliary/os/os_process.c @@ -34,7 +34,7 @@ # include #elif defined(__GLIBC__) || defined(__CYGWIN__) # include -#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) +#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) || defined(PIPE_OS_ANDROID) # include #elif defined(PIPE_OS_HAIKU) # include @@ -59,6 +59,7 @@ os_get_process_name(char *procname, size_t size) { const char *name; + /* First, check if the GALLIUM_PROCESS_NAME env var is set to * override the normal process name query. */ @@ -86,7 +87,7 @@ os_get_process_name(char *procname, size_t size) #elif defined(__GLIBC__) || defined(__CYGWIN__) name = program_invocation_short_name; -#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) +#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE) || defined(PIPE_OS_ANDROID) /* *BSD and OS X */ name = getprogname(); #elif defined(PIPE_OS_HAIKU) -- 2.11.0 ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev