public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: David Henningsson <david.henningsson@canonical.com>
Cc: vinod.koul@intel.com, daniel.vetter@intel.com,
	intel-gfx@lists.freedesktop.org, alsa-devel@alsa-project.org
Subject: Re: [PATCH v3 0/4] i915 to call hda driver on HDMI plug/unplug
Date: Fri, 24 Jul 2015 18:38:52 +0200	[thread overview]
Message-ID: <s5hegjxv7c3.wl-tiwai@suse.de> (raw)
In-Reply-To: <1437665179-9786-1-git-send-email-david.henningsson@canonical.com>

On Thu, 23 Jul 2015 17:26:15 +0200,
David Henningsson wrote:
> 
> Changes since v2 is that the patch set has diminished to not transfer
> connector/eld information, since it might be better that such information
> to be transferred by a separate call in the ordinary direction. That
> could be added in a later patch set.
> 
> The audio_ptr is now a void* (instead of a hdac_bus*) so that the audio
> side can easily refactor the ptr to point to the codec instead of the bus
> if we would find that beneficial.

OK, that leaves some room if we want to change in future.

I still consider whether it's better to register from the codec driver
or from the bus driver.  The codec driver might be a bit cleaner, but
then it'd be a call like
	snd_hda_i915_register_notifier()
instead of adding a callback in the codec ops.

What I see a bit ugly in the current patchset is the addition of
i915 specific callback to a generic hda codec ops.  If the codec
registers the callback dynamically like above, the pointer will be
stored in component directly, so we don't need it in codec ops.
(But we'd need to unregister at codec removal, too.)

Or, if we keep it as a codec ops callback, as already mentioned, it
might make more sense to define it as a generic notifier, i.e. drop
i915 prefix and pass some event type to identify the event.


thanks,

Takashi

> David Henningsson (4):
>   drm/i915: Add audio hotplug info callback
>   drm/i915: Call audio hotplug notify function
>   ALSA: hda - Dispatch incoming HDMI hotplug i915 callback
>   ALSA: hda - Wake the codec up on hotplug notify events
> 
>  drivers/gpu/drm/i915/i915_drv.h    |    1 +
>  drivers/gpu/drm/i915/intel_audio.c |   23 ++++++++++++++++++++---
>  include/drm/i915_component.h       |    5 +++++
>  include/sound/hdaudio.h            |    4 ++++
>  sound/hda/hdac_i915.c              |   23 +++++++++++++++++++++++
>  sound/pci/hda/patch_hdmi.c         |   13 ++++++++++++-
>  6 files changed, 65 insertions(+), 4 deletions(-)
> 
> -- 
> 1.7.9.5
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

      parent reply	other threads:[~2015-07-24 16:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-23 15:26 [PATCH v3 0/4] i915 to call hda driver on HDMI plug/unplug David Henningsson
2015-07-23 15:26 ` [PATCH 1/4] drm/i915: Add audio hotplug info callback David Henningsson
2015-07-27  8:14   ` Jani Nikula
2015-07-23 15:26 ` [PATCH 2/4] drm/i915: Call audio hotplug notify function David Henningsson
2015-07-23 15:26 ` [PATCH 3/4] ALSA: hda - Dispatch incoming HDMI hotplug i915 callback David Henningsson
2015-07-23 15:26 ` [PATCH 4/4] ALSA: hda - Wake the codec up on hotplug notify events David Henningsson
2015-07-27  2:24   ` Yang, Libin
2015-07-24 16:38 ` Takashi Iwai [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=s5hegjxv7c3.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=daniel.vetter@intel.com \
    --cc=david.henningsson@canonical.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=vinod.koul@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox