[Intel-gfx] [PATCH 4/4] drm/i915/audio: move intel_audio_funcs internal to intel_audio.c
Ville Syrjälä
ville.syrjala at linux.intel.com
Fri Oct 22 16:48:29 UTC 2021
On Fri, Oct 22, 2021 at 07:27:58PM +0300, Jani Nikula wrote:
> It's all internal to intel_audio.c.
>
> Cc: Dave Airlie <airlied at redhat.com>
> Signed-off-by: Jani Nikula <jani.nikula at intel.com>
I've toyed around with similar stuff myself before
(moving bunch of .av_foo/.audio_foo to .audio.foo) just
never bothered sending it out. So very much like the idea.
Series is
Reviewed-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_audio.c | 9 +++++++++
> drivers/gpu/drm/i915/i915_drv.h | 10 +---------
> 2 files changed, 10 insertions(+), 9 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_audio.c b/drivers/gpu/drm/i915/display/intel_audio.c
> index b46f6539b9ab..39246f64fb39 100644
> --- a/drivers/gpu/drm/i915/display/intel_audio.c
> +++ b/drivers/gpu/drm/i915/display/intel_audio.c
> @@ -62,6 +62,15 @@
> * struct &i915_audio_component_audio_ops @audio_ops is called from i915 driver.
> */
>
> +struct intel_audio_funcs {
> + void (*audio_codec_enable)(struct intel_encoder *encoder,
> + const struct intel_crtc_state *crtc_state,
> + const struct drm_connector_state *conn_state);
> + void (*audio_codec_disable)(struct intel_encoder *encoder,
> + const struct intel_crtc_state *old_crtc_state,
> + const struct drm_connector_state *old_conn_state);
> +};
> +
> /* DP N/M table */
> #define LC_810M 810000
> #define LC_540M 540000
> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
> index ed86633a587b..bb023b909e86 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -364,15 +364,6 @@ struct intel_color_funcs {
> void (*read_luts)(struct intel_crtc_state *crtc_state);
> };
>
> -struct intel_audio_funcs {
> - void (*audio_codec_enable)(struct intel_encoder *encoder,
> - const struct intel_crtc_state *crtc_state,
> - const struct drm_connector_state *conn_state);
> - void (*audio_codec_disable)(struct intel_encoder *encoder,
> - const struct intel_crtc_state *old_crtc_state,
> - const struct drm_connector_state *old_conn_state);
> -};
> -
> struct intel_cdclk_funcs {
> void (*get_cdclk)(struct drm_i915_private *dev_priv,
> struct intel_cdclk_config *cdclk_config);
> @@ -829,6 +820,7 @@ struct i915_selftest_stash {
> };
>
> /* intel_audio.c private */
> +struct intel_audio_funcs;
> struct intel_audio_private {
> /* Display internal audio functions */
> const struct intel_audio_funcs *funcs;
> --
> 2.30.2
--
Ville Syrjälä
Intel
More information about the Intel-gfx
mailing list