intel_fb: set default brightness of connector

which is unconfigured to 70%

Issue #4820
This commit is contained in:
Alexander Boettcher 2023-04-20 20:19:11 +02:00 committed by Christian Helmuth
parent 83f78e7fe6
commit 38f4b15df1
2 changed files with 5 additions and 2 deletions

View File

@ -221,8 +221,7 @@ static bool reconfigure(void * data)
unsigned mode_id = 0;
struct drm_connector *connector = NULL;
struct genode_mode conf_mode = { .enabled = 1,
.brightness = INVALID_BRIGHTNESS };
struct genode_mode conf_mode = { };
if (!mode_set->connectors || !*mode_set->connectors)
continue;

View File

@ -197,6 +197,10 @@ void Framebuffer::Driver::generate_report(void *lx_data)
void Framebuffer::Driver::lookup_config(char const * const name,
struct genode_mode &mode)
{
/* default settings, possibly overridden by explicit configuration below */
mode.enabled = true;
mode.brightness = 70 /* percent */;
if (!config.valid())
return;