path: root/src/lib/ecore_drm2/ecore_drm2_outputs.c (unfollow)
AgeCommit message (Collapse)Author
2019-04-18ecore-drm2: Fix API function parameters for background color setChristopher Michael
Passing int as parameters here is too small for left shifting the colors so make these parameters uint64_t
2019-04-18ecore-drm2: Add API function to set crtc background colorChristopher Michael
This patch adds a new API function we can be called in order to set the crtc background color of a given output. @feature
2019-04-18ecore-drm2: Fill in crtc background color (if supported) during atomicChristopher Michael
commits Small patch to add the crtc background_color property (if supported) to any atomic tests/commits @feature
2019-03-22ecore-drm2: Factor in output rotation when getting output infoChristopher Michael
Summary: Enlightenment uses this function to get information about a given output, so we should be accounting for output rotation when returning width/height values. ref T7690 @fix Depends on D8114 Reviewers: raster, cedric, zmike Reviewed By: cedric Subscribers: cedric Tags: #efl, #do_not_merge Maniphest Tasks: T7690 Differential Revision:
2019-03-22ecore-drm2: Add API function to return output rotationChristopher Michael
Summary: Small patch to add an API function which can be used to return a given output's rotation value ref T7690 @feature Depends on D8113 Reviewers: raster, cedric, zmike, stefan_schmidt, bu5hm4n Reviewed By: cedric Subscribers: cedric Tags: #efl, #do_not_merge Maniphest Tasks: T7690 Differential Revision:
2019-03-22ecore-drm2: Set output rotation valueChristopher Michael
Summary: When we call ecore_drm2_output_rotation_set we need to store that value in the Output structure so that it can be checked later when needed. ref T7690 Depends on D8112 Reviewers: raster, cedric, zmike Reviewed By: cedric Subscribers: cedric Tags: #efl, #do_not_merge Maniphest Tasks: T7690 Differential Revision:
2019-03-22ecore-drm2: Disable hardware rotation for outputsChristopher Michael
Summary: Setting output primary plane rotation is broken at the moment, so this commit will disable that for now until this can be investigated ref T7690 Depends on D8111 Reviewers: raster, cedric, zmike Subscribers: cedric Tags: #efl, #do_not_merge Maniphest Tasks: T7690 Differential Revision:
2019-02-21ecore drm2 - work around kms/drm bug seemingly when no flip event comesCarsten Haitzler (Rasterman)
so we request a flip so we can do vsync events. the flip event never comes. i am not sure why it never comes, but we ask and nothing arrives, and this basically halts all rendering in wayland compositor mode as we are syncing rendering to vsync (of course). put in a timeout of 0.05s (50ms) to try ask again if the event never comes and log the error. this is a pretty useful workaround becauswe having your entire display freeze is a ... bad thing. @fix
2019-02-06ecore-drm2: Minor formatting fixes.Christopher Michael
NB: No functional changes
2019-02-06ecore-drm2: Reduce duplicated codeChristopher Michael
No need for this line to be there twice as it is going to be called in either case. NB: No functional changes
2019-02-06ecore-drm2: Remove useless if checkChristopher Michael
_ecore_drm2_use_atomic is already checked just above this, so there is no need for this if statement
2019-01-28ecore-drm2: Support multiple gpus during vblankChristopher Michael
Summary: When we try to calculate a drm vblank type, we should take into account the output's pipe value which is used to determine if we are using multiple gpus (if so, we need to use the high_crtc_mask. Reviewers: ManMower Reviewed By: ManMower Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision:
2019-01-17ecore-drm2: Fix formattingChristopher Michael
NB: No functional changes
2019-01-17ecore-drm2: Pass output as data to drmModePageFlip and drmModeAtomicCommitChristopher Michael
In order to support per-output ticking, the drmModePageFlip and drmModeAtomicCommit functions need to pass the actual Output as data to the pageflip callback so that the pageflip callback function can pass the proper rectangle to ecore_evas_animator_tick Differential Revision:
2018-02-27ecore-drm2: Add API function to retrieve output user dataChris Michael
With the rework of Ecore_Evas drm engine, we need to get the ecore_evas itself in the pageflip callback so we have to reassign output->user_data to the ecore_evas which we can then use to retrieve via this function This is needed as the pageflip callback will pass us the output on which the pageflip completed. @feature Signed-off-by: Chris Michael <>
2018-02-27ecore-drm2: Free stringshare for relative output during output_freeChris Michael
When we destroy a given output, we should be freeing the eina_stringshare for Signed-off-by: Chris Michael <>
2018-02-27ecore-drm2: Add API to get/set which output is relative to anotherChris Michael
In order to know which output we should clone, we need a way to store/retrieve the output which should be cloned. This patch adds a small api we can use in randr config dialog to get/set that value. @feature Signed-off-by: Chris Michael <>
2018-02-20ecore-drm2: Fix typo when comparing output relative modeChris Michael
Signed-off-by: Chris Michael <>
2018-02-20ecore-drm2: Account for output relative mode when getting cloned valueChris Michael
As an output may have it's relative mode set to clone from the E randr dialog, we should account for that also when returning output cloned mode. Signed-off-by: Chris Michael <>
2018-02-13ecore-drm2: Add API functions to get/set output relative modeChris Michael
These API functions will be used inside Enlightenment in order to determine the proper extended screen size based on outputs relative position. @feature Signed-off-by: Chris Michael <>
2018-02-06ecore-drm2: Ensure output changed event is sent for removed outputsChris Michael
If an output gets disconnected, we would still like to be notified of that. In the _outputs_update function, we mark an output as disconnected by setting output->connected and output->enabled to FALSE. With this line in place (in the output_event_send function) we would never get notified if an output was disconnected. @fix Signed-off-by: Chris Michael <>
2018-01-09ecore-drm2: return supported rotations if not using hardwareChris Michael
If we are Not using Atomic/Hardware support for output rotations, we should return all available rotations as these will still work in software mode. @fix Signed-off-by: Chris Michael <>
2018-01-09ecore-drm2: Fix enabling outputsChris Michael
Commit 9d583b3fdbed686642dbc0d96d1e417485ca0077 broke ecore_drm2_output_enabled_set function due changing order of setting output->enabled value. This patch fixes both issues by checking the 'enabled' variable being passed in. @fix Signed-off-by: Chris Michael <>
2017-11-01ecore-drm2: Fix issue of not being able to set output modeChris Michael
If we pass in screen geometry here when trying to set an output mode, we can encounter "out of memory" errors from libdrm with outputs that have a high resolution. As it turns out, we should be passing 0, 0 for the x/y values when trying to set an output mode. @fix Signed-off-by: Chris Michael <>
2017-09-19ecore-drm2: Minor formatting fixChris Michael
NB: No functional changes Signed-off-by: Chris Michael <>
2017-09-05ecore_drm2: Better handling of blank time checksDerek Foreman
On some systems we'll successfully complete the vblank ioctl but get a reply of 0. When that happens we can't use that time for ticking as it will break all of the entire world. Fixes immediate screen blank on rpi3. @ref T5977
2017-08-11ecore_drm2: Add query for pending pageflipDerek Foreman
We've been tracking this in ecore_evas, but ecore_evas isn't the only caller, and it doesn't know about flips initiated by the evas engines.
2017-08-09ecore_drm2: Remove ecore_drm2_output_resolution_get()Derek Foreman
No local callers. Superseded by ecore_drm2_output_info_get()
2017-08-09ecore_drm2: Remove ecore_drm2_output_crtc_size_get()Derek Foreman
Replaced with ecore_drm2_output_info_get()
2017-08-09ecore_drm2: Remove ecore_drm2_output_geometry_get()Derek Foreman
Replaced with ecore_drm2_output_info_get()
2017-08-09ecore_drm2: Add ecore_drm2_output_info_getDerek Foreman
We've got too many ways to query output information, so let's add more. (this will soon replace all of them)
2017-08-09ecore_drm2: Remove connector bitfieldDerek Foreman
This is unreliable - there's no reason to expect these connector ids will be low enough to sensibly store in a bit field.
2017-08-09ecore_drm2: remove unused crtc bitfieldDerek Foreman
We'll need something like this when multi-head works, but it can't be implemented this way anyway. There's no guarantee that crtc ids will be low enough to fit sensibly in a bitfield.
2017-07-31ecore_drm2: Remove dead code in blank time getDerek Foreman
When I added the fallback block I left an if statement that could never evaluate to true. Remove it.
2017-07-30ecore_drm2 - fix startup if edid blob is null.. assume all 0'sCarsten Haitzler (Rasterman)
this causes a crash when no edid is available. survive and dont crash. this causes e wayland to not work at all on my baytrail laptop. @fix
2017-07-28ecore_drm2: Add a fallback method for vblank waitingDerek Foreman
We can't depend on vblank waits being implemented by the driver, but we can count on page flips functioning, so add a fallback that does a page flip and waits for it.
2017-07-28ecore_drm2: Allow picking a sequence number for blanktime_getDerek Foreman
This lets us do a blocking wait for a vsync. Something we should try to do as infrequently as possible, but in some cases we need it one time at startup to catch graphics driver bugs.
2017-07-13ecore_drm2: Add a query for the next vblank timeDerek Foreman
I guess this is a feature, and we're deep in freeze, but: a) this is critical for fixing T5462 properly without any side effects. b) ecore_drm2 is all beta api c) this should only affect wayland users ref T5462
2017-06-23ecore_drm2: Remove obsolete per output fb callback apiDerek Foreman
It's all beta API so I can throw this away now that there are no in-tree users anymore.
2017-06-16ecore-drm2: add ecore_drm2_output_subpixel_get()Mike Blumenkrantz
2017-06-09ecore-drm2: Remove #ifdef HAVE_ATOMIC_DRMChris Michael
As we now use static_libs/libdrm for compiling ecore-drm2, we can remove the atomic #ifdefs as we can run-time check this now. Signed-off-by: Chris Michael <>
2017-06-08ecore-drm2: Fix potential SIGFPE when adding output modeChris Michael
If we receive bad crtc info from libdrm, then we could end up with a SIGFPE here due to division by zero if info h/v total are not set. @fix Signed-off-by: Chris Michael <>
2017-06-06ecore-drm2: Don't use Atomic functions to set DPMS levelsChris Michael
This was initially an experiment in trying to use Atomic properties to set dpms on/off, however it does not turn off backlight support when triggered so it is useless. Fixes T5462 @fix Signed-off-by: Chris Michael <>
2017-06-06ecore-drm2: Add internal functions to get backlight valuesChris Michael
Small patch to add an internal function which can be used to retrieve backlight values on output creation. Signed-off-by: Chris Michael <>
2017-06-05ecore_drm2: Fix error handling in _output_dpms_atomic_setDerek Foreman
This was skipping the error path on failure and setting some state as if it was successful. Then the next attempt at a page flip was actually setting this state. So _output_dpms_atomic_set (which has always been broken) wasn't actually the function that successfully disabled dpms. This is confounding attempts to debug why dpms isn't coming back on properly. Now it won't turn *off* either, because it really never should have. Ref T5462
2017-06-02ecore_drm2: Fix dpms shutdown while disabling outputsDerek Foreman
We need to set output->enabled to disabled *after* dpms takes place or set it to enabled *before* dpms takes place. We can't just set it at the start of the function or one of enable/disable will hit the dpms path with a disabled display.
2017-06-02ecore_drm2: Properly release buffers on output disableDerek Foreman
Give back all buffers, and do it through the release mechanism that can fire a callback into the engine. Previously we just leaked one and left the rest.
2017-05-30ecore-drm2: Don't free output plane states if not using atomicChris Michael
If atomic support is not enabled (kernel or env var), then we will not be filling output plane_states, so no need to free them (if non-atomic). @fix Signed-off-by: Chris Michael <>
2017-05-30ecore-drm2: Don't fill output atomic states if not using atomicChris Michael
If atomic support is not enabled (kernel or env var), then we should not be filling in output atomic state @fix Signed-off-by: Chris Michael <>
2017-05-19ecore-drm2: Don't call fb_flip until output is enabledChris Michael
When calling ecore_drm2_output_enabled_set, we cannot initiate a pageflip until the output has been enabled, so remove call to fb_flip here. The dpms_set function will handle issueing the pageflip anyway. @fix Signed-off-by: Chris Michael <>