All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Frédéric Danis" <frederic.danis@collabora.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH BlueZ 3/3] audio/hfp-hf: Add in-band ringtone flag support
Date: Wed, 17 Dec 2025 17:48:20 +0100	[thread overview]
Message-ID: <20251217164820.277845-3-frederic.danis@collabora.com> (raw)
In-Reply-To: <20251217164820.277845-1-frederic.danis@collabora.com>

This flags is set by remote phone when it wants to play the ringtone
through the audio channel.
---
 profiles/audio/hfp-hf.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/profiles/audio/hfp-hf.c b/profiles/audio/hfp-hf.c
index 81d5f4437..3c4218da3 100644
--- a/profiles/audio/hfp-hf.c
+++ b/profiles/audio/hfp-hf.c
@@ -137,6 +137,13 @@ static void hfp_hf_update_indicator(enum hfp_indicator indicator, uint32_t val,
 	}
 }
 
+static void hfp_hf_update_inband_ring(bool enabled, void *user_data)
+{
+	struct hfp_device *dev = user_data;
+
+	telephony_set_inband_ringtone(dev->telephony, enabled);
+}
+
 static void hfp_hf_update_operator(const char *operator_name, void *user_data)
 {
 	struct hfp_device *dev = user_data;
@@ -235,6 +242,7 @@ static struct hfp_hf_callbacks hf_session_callbacks = {
 	.session_ready = hfp_hf_session_ready_cb,
 	.update_indicator = hfp_hf_update_indicator,
 	.update_operator = hfp_hf_update_operator,
+	.update_inband_ring = hfp_hf_update_inband_ring,
 	.call_added = hfp_hf_call_added,
 	.call_removed = hfp_hf_call_removed,
 	.call_status_updated = hfp_hf_call_status_updated,
-- 
2.43.0


  parent reply	other threads:[~2025-12-17 16:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-17 16:48 [PATCH BlueZ 1/3] audio/hfp-hf: Add Operator name support Frédéric Danis
2025-12-17 16:48 ` [PATCH BlueZ 2/3] audio/hfp-hf: Add simple call support Frédéric Danis
2025-12-18 19:07   ` Luiz Augusto von Dentz
2025-12-17 16:48 ` Frédéric Danis [this message]
2025-12-17 18:24 ` [BlueZ,1/3] audio/hfp-hf: Add Operator name support bluez.test.bot

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=20251217164820.277845-3-frederic.danis@collabora.com \
    --to=frederic.danis@collabora.com \
    --cc=linux-bluetooth@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.