Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Output management on the gbm-kms platform is racy #3751

Open
mattkae opened this issue Feb 10, 2025 · 1 comment
Open

Output management on the gbm-kms platform is racy #3751

mattkae opened this issue Feb 10, 2025 · 1 comment
Labels

Comments

@mattkae
Copy link
Contributor

mattkae commented Feb 10, 2025

This issue was uncovered while investigating #3729.

Issue

The crux of the issue is in src/platforms/gbm-kms/server/kms/display.cpp.

Display::configure_locked (called by Display::configure) is responsible for associating incoming outptus with their DisplaySink. A DisplaySink is only created for an output when the output meets a number of conditions, one of which is being connected. Each DisplaySink has a shared_ptr reference to a RealKMSOutput.

When the configuration is requested by Display::configuration(), we update the properties of RealKMSOutputs to reflect its current status (e.g. the output may now be disconnected). The problem is, however, that an output that currently has a display sink may have been updated such that it should no longer have a display sink. However, the renderer thread is still running and submitting buffers to this sink which is associated with an invalid output.

Expected

A DisplaySink cannot be submitted for an output that does not deserve a sink. Or - perhaps even better! - the DisplaySink should be invalidated such that it will not be used by the renderer while the output is in an invalid state.

@mattkae
Copy link
Contributor Author

mattkae commented Feb 11, 2025

GBMSurfaceImpl constructor is created with a zero width and height.

mattkae added a commit that referenced this issue Feb 11, 2025
mattkae added a commit that referenced this issue Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant