diff options
author | Maxime Ripard <mripard@kernel.org> | 2024-04-23 08:48:56 +0200 |
---|---|---|
committer | Maxime Ripard <mripard@kernel.org> | 2024-04-23 08:48:56 +0200 |
commit | c058e7a8f8af355e4a441c89400a6e95a16320e5 (patch) | |
tree | ed96dcd06e69f508a3f8a112a29fd228289429a6 /drivers/gpu/drm/i915/display/intel_backlight.c | |
parent | 6221deb716b9d5397c09ba6567f7ae61d8cbeb98 (diff) | |
parent | 0208ca55aa9c9b997da1f5bc45c4e98916323f08 (diff) |
Merge drm/drm-next into drm-misc-next
MaĆra needs a backmerge to apply v3d patches, and Danilo for some
nouveau patches.
Signed-off-by: Maxime Ripard <mripard@kernel.org>
Diffstat (limited to 'drivers/gpu/drm/i915/display/intel_backlight.c')
-rw-r--r-- | drivers/gpu/drm/i915/display/intel_backlight.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_backlight.c b/drivers/gpu/drm/i915/display/intel_backlight.c index 1946d7fb3c2e..4d4330410b4d 100644 --- a/drivers/gpu/drm/i915/display/intel_backlight.c +++ b/drivers/gpu/drm/i915/display/intel_backlight.c @@ -761,8 +761,8 @@ static void __intel_backlight_enable(const struct intel_crtc_state *crtc_state, WARN_ON(panel->backlight.max == 0); - if (panel->backlight.level <= panel->backlight.min) { - panel->backlight.level = panel->backlight.max; + if (panel->backlight.level < panel->backlight.min) { + panel->backlight.level = panel->backlight.min; if (panel->backlight.device) panel->backlight.device->props.brightness = scale_hw_to_user(connector, @@ -949,7 +949,7 @@ int intel_backlight_device_register(struct intel_connector *connector) else props.power = FB_BLANK_POWERDOWN; - name = kstrdup("intel_backlight", GFP_KERNEL); + name = kstrdup_const("intel_backlight", GFP_KERNEL); if (!name) return -ENOMEM; @@ -963,7 +963,7 @@ int intel_backlight_device_register(struct intel_connector *connector) * compatibility. Use unique names for subsequent backlight devices as a * fallback when the default name already exists. */ - kfree(name); + kfree_const(name); name = kasprintf(GFP_KERNEL, "card%d-%s-backlight", i915->drm.primary->index, connector->base.name); if (!name) @@ -987,7 +987,7 @@ int intel_backlight_device_register(struct intel_connector *connector) connector->base.base.id, connector->base.name, name); out: - kfree(name); + kfree_const(name); return ret; } |