mirror of
https://github.com/torvalds/linux.git
synced 2026-05-24 15:12:13 +02:00
drm/i915/atomic: convert intel_atomic.c to struct intel_display
Going forward, struct intel_display is the main display device data pointer. Convert intel_atomic.c to struct intel_display. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://lore.kernel.org/r/7ef6fe795e4e5c26ae0d546e57f64f494aaf56fc.1742554320.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
parent
744edb461b
commit
0a9231901e
|
|
@ -33,16 +33,17 @@
|
|||
#include <drm/drm_atomic.h>
|
||||
#include <drm/drm_atomic_helper.h>
|
||||
#include <drm/drm_fourcc.h>
|
||||
#include <drm/drm_print.h>
|
||||
|
||||
#include "i915_drv.h"
|
||||
#include "intel_atomic.h"
|
||||
#include "intel_cdclk.h"
|
||||
#include "intel_display_core.h"
|
||||
#include "intel_display_types.h"
|
||||
#include "intel_dp_tunnel.h"
|
||||
#include "intel_fb.h"
|
||||
#include "intel_global_state.h"
|
||||
#include "intel_hdcp.h"
|
||||
#include "intel_psr.h"
|
||||
#include "intel_fb.h"
|
||||
#include "skl_universal_plane.h"
|
||||
|
||||
/**
|
||||
|
|
@ -59,17 +60,16 @@ int intel_digital_connector_atomic_get_property(struct drm_connector *connector,
|
|||
struct drm_property *property,
|
||||
u64 *val)
|
||||
{
|
||||
struct drm_device *dev = connector->dev;
|
||||
struct drm_i915_private *dev_priv = to_i915(dev);
|
||||
struct intel_display *display = to_intel_display(connector->dev);
|
||||
const struct intel_digital_connector_state *intel_conn_state =
|
||||
to_intel_digital_connector_state(state);
|
||||
|
||||
if (property == dev_priv->display.properties.force_audio)
|
||||
if (property == display->properties.force_audio)
|
||||
*val = intel_conn_state->force_audio;
|
||||
else if (property == dev_priv->display.properties.broadcast_rgb)
|
||||
else if (property == display->properties.broadcast_rgb)
|
||||
*val = intel_conn_state->broadcast_rgb;
|
||||
else {
|
||||
drm_dbg_atomic(&dev_priv->drm,
|
||||
drm_dbg_atomic(display->drm,
|
||||
"Unknown property [PROP:%d:%s]\n",
|
||||
property->base.id, property->name);
|
||||
return -EINVAL;
|
||||
|
|
@ -92,22 +92,21 @@ int intel_digital_connector_atomic_set_property(struct drm_connector *connector,
|
|||
struct drm_property *property,
|
||||
u64 val)
|
||||
{
|
||||
struct drm_device *dev = connector->dev;
|
||||
struct drm_i915_private *dev_priv = to_i915(dev);
|
||||
struct intel_display *display = to_intel_display(connector->dev);
|
||||
struct intel_digital_connector_state *intel_conn_state =
|
||||
to_intel_digital_connector_state(state);
|
||||
|
||||
if (property == dev_priv->display.properties.force_audio) {
|
||||
if (property == display->properties.force_audio) {
|
||||
intel_conn_state->force_audio = val;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (property == dev_priv->display.properties.broadcast_rgb) {
|
||||
if (property == display->properties.broadcast_rgb) {
|
||||
intel_conn_state->broadcast_rgb = val;
|
||||
return 0;
|
||||
}
|
||||
|
||||
drm_dbg_atomic(&dev_priv->drm, "Unknown property [PROP:%d:%s]\n",
|
||||
drm_dbg_atomic(display->drm, "Unknown property [PROP:%d:%s]\n",
|
||||
property->base.id, property->name);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user