[v3,7/8] libcamera: egl: Drop dmabuf_import_failed_
diff mbox series

Message ID 20260626113325.3218045-8-bryan.odonoghue@linaro.org
State New
Headers show
Series
  • libcamera: software_isp: gpu: Add go faster stripes
Related show

Commit Message

Bryan O'Donoghue June 26, 2026, 11:33 a.m. UTC
Drop per eGLImage flag dmabuf_import_failed_. We use a per-session import
flag use_dmabuf_ so there's no need to mark failure per image anymore.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
 include/libcamera/internal/egl.h | 1 -
 src/libcamera/egl.cpp            | 1 -
 2 files changed, 2 deletions(-)

Comments

Robert Mader June 26, 2026, 12:04 p.m. UTC | #1
Would prefer this commit to get squashed into the one where we stop 
using these values. Still:

Reviewed-by: Robert Mader <robert.mader@collabora.com>

On 26.06.26 13:33, Bryan O'Donoghue wrote:
> Drop per eGLImage flag dmabuf_import_failed_. We use a per-session import
> flag use_dmabuf_ so there's no need to mark failure per image anymore.
>
> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
> ---
>   include/libcamera/internal/egl.h | 1 -
>   src/libcamera/egl.cpp            | 1 -
>   2 files changed, 2 deletions(-)
>
> diff --git a/include/libcamera/internal/egl.h b/include/libcamera/internal/egl.h
> index e4d366abd..d2c4d1a7b 100644
> --- a/include/libcamera/internal/egl.h
> +++ b/include/libcamera/internal/egl.h
> @@ -90,7 +90,6 @@ public:
>   	GLenum texture_unit_; /**< Texture unit associated with this image eg (GL_TEXTURE0) */
>   	GLuint texture_; /**< OpenGL texture object ID */
>   	GLuint fbo_; /**< OpenGL frame buffer object ID */
> -	bool dmabuf_import_failed_ = false; /**< Previous image import failed */
>   
>   private:
>   	LIBCAMERA_DISABLE_COPY_AND_MOVE(eGLImage)
> diff --git a/src/libcamera/egl.cpp b/src/libcamera/egl.cpp
> index 4eabddcc7..ce451d521 100644
> --- a/src/libcamera/egl.cpp
> +++ b/src/libcamera/egl.cpp
> @@ -210,7 +210,6 @@ int eGL::createDMABufTexture2D(eGLImage &eglImage, int fd, bool output)
>   
>   	if (image == EGL_NO_IMAGE_KHR) {
>   		LOG(eGL, Debug) << "eglCreateImageKHR fail";
> -		eglImage.dmabuf_import_failed_ = true;
>   		return -ENODEV;
>   	}
>
Milan Zamazal June 26, 2026, 12:39 p.m. UTC | #2
Robert Mader <robert.mader@collabora.com> writes:

> Would prefer this commit to get squashed into the one where we stop
> using these values.

+1

> Still:
>
> Reviewed-by: Robert Mader <robert.mader@collabora.com>
>
> On 26.06.26 13:33, Bryan O'Donoghue wrote:
>> Drop per eGLImage flag dmabuf_import_failed_. We use a per-session import
>> flag use_dmabuf_ so there's no need to mark failure per image anymore.
>>
>> Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
>> ---
>>   include/libcamera/internal/egl.h | 1 -
>>   src/libcamera/egl.cpp            | 1 -
>>   2 files changed, 2 deletions(-)
>>
>> diff --git a/include/libcamera/internal/egl.h b/include/libcamera/internal/egl.h
>> index e4d366abd..d2c4d1a7b 100644
>> --- a/include/libcamera/internal/egl.h
>> +++ b/include/libcamera/internal/egl.h
>> @@ -90,7 +90,6 @@ public:
>>   	GLenum texture_unit_; /**< Texture unit associated with this image eg (GL_TEXTURE0) */
>>   	GLuint texture_; /**< OpenGL texture object ID */
>>   	GLuint fbo_; /**< OpenGL frame buffer object ID */
>> -	bool dmabuf_import_failed_ = false; /**< Previous image import failed */
>>     private:
>>   	LIBCAMERA_DISABLE_COPY_AND_MOVE(eGLImage)
>> diff --git a/src/libcamera/egl.cpp b/src/libcamera/egl.cpp
>> index 4eabddcc7..ce451d521 100644
>> --- a/src/libcamera/egl.cpp
>> +++ b/src/libcamera/egl.cpp
>> @@ -210,7 +210,6 @@ int eGL::createDMABufTexture2D(eGLImage &eglImage, int fd, bool output)
>>     	if (image == EGL_NO_IMAGE_KHR) {
>>   		LOG(eGL, Debug) << "eglCreateImageKHR fail";
>> -		eglImage.dmabuf_import_failed_ = true;
>>   		return -ENODEV;
>>   	}
>>

Patch
diff mbox series

diff --git a/include/libcamera/internal/egl.h b/include/libcamera/internal/egl.h
index e4d366abd..d2c4d1a7b 100644
--- a/include/libcamera/internal/egl.h
+++ b/include/libcamera/internal/egl.h
@@ -90,7 +90,6 @@  public:
 	GLenum texture_unit_; /**< Texture unit associated with this image eg (GL_TEXTURE0) */
 	GLuint texture_; /**< OpenGL texture object ID */
 	GLuint fbo_; /**< OpenGL frame buffer object ID */
-	bool dmabuf_import_failed_ = false; /**< Previous image import failed */
 
 private:
 	LIBCAMERA_DISABLE_COPY_AND_MOVE(eGLImage)
diff --git a/src/libcamera/egl.cpp b/src/libcamera/egl.cpp
index 4eabddcc7..ce451d521 100644
--- a/src/libcamera/egl.cpp
+++ b/src/libcamera/egl.cpp
@@ -210,7 +210,6 @@  int eGL::createDMABufTexture2D(eGLImage &eglImage, int fd, bool output)
 
 	if (image == EGL_NO_IMAGE_KHR) {
 		LOG(eGL, Debug) << "eglCreateImageKHR fail";
-		eglImage.dmabuf_import_failed_ = true;
 		return -ENODEV;
 	}