summaryrefslogtreecommitdiff
path: root/net-wireless/bluez
diff options
context:
space:
mode:
Diffstat (limited to 'net-wireless/bluez')
-rw-r--r--net-wireless/bluez/Manifest9
-rw-r--r--net-wireless/bluez/bluez-5.62-r2.ebuild (renamed from net-wireless/bluez/bluez-5.62.ebuild)18
-rw-r--r--net-wireless/bluez/bluez-5.62-r3.ebuild (renamed from net-wireless/bluez/bluez-5.61.ebuild)30
-rw-r--r--net-wireless/bluez/files/0001-Revert-attrib-Make-use-of-bt_att_resend.patch188
-rw-r--r--net-wireless/bluez/files/bluez-5.62-fix-disconnecting.patch54
-rw-r--r--net-wireless/bluez/metadata.xml1
6 files changed, 270 insertions, 30 deletions
diff --git a/net-wireless/bluez/Manifest b/net-wireless/bluez/Manifest
index 7b86553b89e8..12dfdef79005 100644
--- a/net-wireless/bluez/Manifest
+++ b/net-wireless/bluez/Manifest
@@ -1,11 +1,12 @@
AUX 0001-Allow-using-obexd-without-systemd-in-the-user-session-r2.patch 1912 BLAKE2B c7226ccbf1b794b5f3d6504dcb6950bc7e7bd69995243d0e4cf30dfb161f95e15c18c96724f82916e8c83cac6ff255ed957b60c9ee9ad53e108c69eb509074d5 SHA512 65a970fa82ded9f6e97ef2f0d856010f96468cbd375447e1c47d6073be5a364f747b7b5ea93a0bc3b7dba0470dc8dccd9b5d1f6567f18b38042e424d3e06171b
+AUX 0001-Revert-attrib-Make-use-of-bt_att_resend.patch 4975 BLAKE2B 4e2e8a7bb9f5ef7913fbe69b76261ceeb061a10893c3f20c3eab2a155e18fd3bef58788798503f27afc7c97c46fad2014b91bb2c70c9ba11931ae5eb717fdad2 SHA512 f3d26fcb79d5448d12bb9495c24b99b13821b8672ed6d3568b01126baf4e439bd31bcdb9d295530a876db2f3d5b9369e033e2e9d7cc49771fa8579063074c1f0
AUX 0001-obex-Use-GLib-helper-function-to-manipulate-paths.patch 1252 BLAKE2B ce6d00ea244d91e76b696e60ddb9096aa48572b68474f321f05b0e3e9525932e6fdaeacc3b141dc4b118d5fa305b7a0510e9c57c935e489a9c159dcd826ad870 SHA512 774f1d9cd49dd3fc0e9f02ad93876c59d78f88f149591f384cf5d2e3541d237ce390552c8bc2cb4d4ad7e5dcc295df49220565f0b0e686a2f8b3404f68323d32
AUX bluetooth-conf.d 21 BLAKE2B 7c94e499438f441fc18f0b50178e707982ac91871a74b2e7a35c9930d32441a89f742993e993e3003f9bcb5e3ee9adde2ab1cbe33b27245b1b1e91e7c3dc1a0b SHA512 45befd3fb42ea3462fa6e1ee9f3ee9591e197d4925a4c9df6733bacfe44cf44f54ed3aad6fd7a6a2953da54b93460a1cf0ea1cadf0d7e47f811e4c3182af74d5
AUX bluetooth-init.d-r5 313 BLAKE2B 6bad1b9a75de5927ab22a229d6ce18247b32a79b994078338eff33df7f74a7dc4a5266212f6d0150101600e3a864a9b64ce6a576208218750bfbe88bc5911baa SHA512 95aff192be6207047fc01b42754bcd34d5cd7f82c16486fdd81bb1d14be040e4f3e9bafd8dc2f4e8b87bf1eb50f6634f526feaf2b38c0c6807f40784d84dac96
AUX bluez-5.60-glibc-2.34.patch 1511 BLAKE2B 59035b078414358bf3ab66f92884dcef1d3795780d3ecad2d036dbfe7ee78dab027c9eb34185013ab89f5cbe2a6a0006e4d9420217f3231e27aafd2c5b92a9ec SHA512 ea78ae3771be72b269626c0c119d8d8f8d9b0874379bfd3ada58c9087aac3c55a7ab52a08503964aa397c03791beb918362bc35d0e87e74f5feca0c30bac0e0b
+AUX bluez-5.62-fix-disconnecting.patch 2244 BLAKE2B fe2d3b975adda9422ac8bfd41c1cedc70cafd363982e4a415b057498e83feaf989fff7fe78fcbfa9b4fcdb1c1629347bd6380259ef71bf8c5ac78386b7990231 SHA512 2cf7b4929ab2f8f7e68546ba15ab7f74bcb748f741d6d6cc189ead14becd3403d0d6393b0645fccd215da3aee90360db28cd327802cf2ff3212f0487edaa3e95
AUX bluez-udevadm-path-r1.patch 564 BLAKE2B 0b4dc12f55ab60d254aa3365baf35186a5913026dbfcbc3da41c113b3c423c81189b87016dabcb2c505b684cad376d10d10df9aa17558b8fd022928995931e0e SHA512 d9b0dd452258e425802cf5ad4980a77796be79e94bf6ce641927c5ab7ea1117ce6589063f3a0b96bf25e81303234279a09d58484fec49cfc6aa1db46f245f9c6
-DIST bluez-5.61.tar.xz 2137412 BLAKE2B 2fc1b44f726d48b4a0e8bbecc664077db1db69bbc87c66e9d7ac85d7b2e066de8b349c18597a5ba140c5fcb1ef867ee3980ebdd839ded69ae30491fb7b836940 SHA512 a2318637258f9db0bf05fecbfbea2c3ca5e21867378e28ab4c77f658fe42f10c8c607939f2b437ec40d1ceb00b99f7916c0275faaedd9edd247f7dc91329937a
DIST bluez-5.62.tar.xz 2149348 BLAKE2B db99b36a230fc0be15275d2eda9864b686326ba50648f66b19087ea4309a76d234ab4f1dcb6975f1513a898978b1d5b9332542f5dcee22efd898b79658434a70 SHA512 8fb0b81e1d929d3eee3d70f457ce75dbcff4c2a8a728247fc950bbe11e84d83582345bfd433d2e2df7b5588eb0e42f286658a83c7332be84819d9df49a5707e8
-EBUILD bluez-5.61.ebuild 9385 BLAKE2B 8ae4bf939cffe5d42440ae677aff36f98777f3e7f154c62c68fb2b53e13a6df305d4f47b4e86f25be250bf2325084549dab6075d9642b69086efa8cf3c9c845a SHA512 b9a5944f27d19aa5e8a0e34058946e1432e706f9c94be99337aca9d478ebd7edd2a016ad2da64cf9042ab43cb3b7ba486ab9aef88536c4925f5fe1950d5d416f
-EBUILD bluez-5.62.ebuild 9285 BLAKE2B bdf223d01048d569bc030f1cec1502e5ced6dc348b102e1413831e3d1fed69c90beb23d7648739d8bb176d292b8927ea035a8a83d2b1100e365d86c9a9fc071e SHA512 a71ef65fdfd3caa163dec8be0d33eb6b51a9cb6f5217c61a08b30d0a8c6c135be71fc4a96daccfabbc7b36aea05a365831fbd8b2faebd245989b20b44f22120a
-MISC metadata.xml 1212 BLAKE2B 0b5305cc11d8a158397c71913b66be82b72db0e08cecdc98a2e24d2b77882a39752a2415a75758425fdfe4c06bfb98ab6526e55c2af2da2ddd697bab0d383b39 SHA512 f8fccab91d82cf6eced451e7f6d20ee721ba8199aa36f8771b79ef1707f5fb9239e9b7034cff4798c8ace0f209cca7c4d7d5f2f5744728f18c4c1e398c09dcd3
+EBUILD bluez-5.62-r2.ebuild 9103 BLAKE2B cf83b34b46fcbaecb4d1a2d2e583b34d67534d18bf7ceeacbee589fda4d2d3bb9be4aa6bde8cbbce3311106c55e14d3eb7136c1c86cf4943dc3b8b8e9d161963 SHA512 750e391d3dc10225288037537624bd53aea605581a3a0124979d846e7e54147b72913e2c182a4e571699c33246473a42f5e56e6af578db38e256248954a9ee66
+EBUILD bluez-5.62-r3.ebuild 9484 BLAKE2B 6bec6be42a51b9d3ce5b02851700231465fe6e5c24e64533b43081317f3159daf9456e4a2061d2578d9e71765c7e93cc593d89b3d4e2ef6e1671607065546560 SHA512 f31bafe6f0ea6edc73621318e7bb03332823084196f4dfb89f9ab4f6c38282e2b142da0b585fa0732417119d7659b8835b94b8eb35230fae357ef33ee242cb1b
+MISC metadata.xml 1099 BLAKE2B 75b6db1d43b75f9b22ce5fb6ec640e2e06b2f2575ff75441318a2076b8486ed7d81a62714540c61ab3a35198113538546b9aa71d05ef4cd7106c8a7f09c13029 SHA512 6e4a7bba7102b4850a938ba0f6feec9cd12488d4b440b19982751c2a742b33a565933fae3967080c060e5b5eb51d90268abc87a2c0a2efb7f4c773020c29462a
diff --git a/net-wireless/bluez/bluez-5.62.ebuild b/net-wireless/bluez/bluez-5.62-r2.ebuild
index 1cf0b131ea8d..70c9a7547c55 100644
--- a/net-wireless/bluez/bluez-5.62.ebuild
+++ b/net-wireless/bluez/bluez-5.62-r2.ebuild
@@ -12,8 +12,8 @@ SRC_URI="https://www.kernel.org/pub/linux/bluetooth/${P}.tar.xz"
LICENSE="GPL-2+ LGPL-2.1+"
SLOT="0/3"
-KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~riscv ~x86"
-IUSE="btpclient cups doc debug deprecated extra-tools experimental +mesh midi +obex +readline selinux systemd test test-programs +udev user-session"
+KEYWORDS="amd64 arm arm64 ~hppa ~mips ppc ppc64 ~riscv x86"
+IUSE="btpclient cups doc debug deprecated extra-tools experimental +mesh midi +obex +readline selinux systemd test test-programs +udev"
# Since this release all remaining extra-tools need readline support, but this could
# change in the future, hence, this REQUIRED_USE constraint could be dropped
@@ -37,7 +37,6 @@ BDEPEND="
"
DEPEND="
>=dev-libs/glib-2.28:2[${MULTILIB_USEDEP}]
- >=sys-apps/hwids-20121202.2
btpclient? ( >=dev-libs/ell-0.39 )
cups? ( net-print/cups:= )
mesh? (
@@ -48,11 +47,8 @@ DEPEND="
midi? ( media-libs/alsa-lib )
obex? ( dev-libs/libical:= )
readline? ( sys-libs/readline:0= )
- systemd? (
- >=sys-apps/dbus-1.6:=[user-session=]
- sys-apps/systemd
- )
- !systemd? ( >=sys-apps/dbus-1.6:= )
+ systemd? ( sys-apps/systemd )
+ >=sys-apps/dbus-1.6:=
udev? ( >=virtual/udev-172 )
"
RDEPEND="${DEPEND}
@@ -104,7 +100,7 @@ src_prepare() {
default
# http://www.spinics.net/lists/linux-bluetooth/msg38490.html
- if ! use user-session || ! use systemd; then
+ if ! use systemd; then
eapply "${FILESDIR}"/0001-Allow-using-obexd-without-systemd-in-the-user-session-r2.patch
fi
@@ -245,8 +241,8 @@ multilib_src_install_all() {
# https://bugs.archlinux.org/task/45816
# https://bugzilla.redhat.com/show_bug.cgi?id=1318441
# https://bugzilla.redhat.com/show_bug.cgi?id=1389347
- if use user-session && use systemd; then
- ln -s "${ED}"/usr/lib/systemd/user/obex.service "${ED}"/usr/lib/systemd/user/dbus-org.bluez.obex.service
+ if use systemd; then
+ dosym obex.service /usr/lib/systemd/user/dbus-org.bluez.obex.service
fi
find "${D}" -name '*.la' -type f -delete || die
diff --git a/net-wireless/bluez/bluez-5.61.ebuild b/net-wireless/bluez/bluez-5.62-r3.ebuild
index 95941e34b204..0068b5bad6aa 100644
--- a/net-wireless/bluez/bluez-5.61.ebuild
+++ b/net-wireless/bluez/bluez-5.62-r3.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
PYTHON_COMPAT=( python3_{8..10} )
inherit autotools linux-info python-single-r1 readme.gentoo-r1 systemd udev multilib-minimal
@@ -12,8 +12,8 @@ SRC_URI="https://www.kernel.org/pub/linux/bluetooth/${P}.tar.xz"
LICENSE="GPL-2+ LGPL-2.1+"
SLOT="0/3"
-KEYWORDS="amd64 arm arm64 ~hppa ~mips ppc ppc64 ~riscv x86"
-IUSE="btpclient cups doc debug deprecated extra-tools experimental +mesh midi +obex +readline selinux systemd test test-programs +udev user-session"
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~riscv ~x86"
+IUSE="btpclient cups doc debug deprecated extra-tools experimental +mesh midi +obex +readline selinux systemd test test-programs +udev"
# Since this release all remaining extra-tools need readline support, but this could
# change in the future, hence, this REQUIRED_USE constraint could be dropped
@@ -37,7 +37,6 @@ BDEPEND="
"
DEPEND="
>=dev-libs/glib-2.28:2[${MULTILIB_USEDEP}]
- >=sys-apps/hwids-20121202.2
btpclient? ( >=dev-libs/ell-0.39 )
cups? ( net-print/cups:= )
mesh? (
@@ -48,11 +47,8 @@ DEPEND="
midi? ( media-libs/alsa-lib )
obex? ( dev-libs/libical:= )
readline? ( sys-libs/readline:0= )
- systemd? (
- >=sys-apps/dbus-1.6:=[user-session=]
- sys-apps/systemd
- )
- !systemd? ( >=sys-apps/dbus-1.6:= )
+ systemd? ( sys-apps/systemd )
+ >=sys-apps/dbus-1.6:=
udev? ( >=virtual/udev-172 )
"
RDEPEND="${DEPEND}
@@ -72,8 +68,14 @@ PATCHES=(
# http://www.spinics.net/lists/linux-bluetooth/msg40136.html
"${FILESDIR}"/0001-obex-Use-GLib-helper-function-to-manipulate-paths.patch
- # https://marc.info/?l=linux-bluetooth&m=161498090629584&w=2
- "${FILESDIR}"/${PN}-5.60-glibc-2.34.patch
+ # This reverts commit ac2c2e10b3adb432a572b618c6f53cabb6b3c80b. It
+ # causes problems with Logitech MX wireless input devices (see
+ # https://github.com/bluez/bluez/issues/220 )
+ "${FILESDIR}"/0001-Revert-attrib-Make-use-of-bt_att_resend.patch
+
+ # gatt-client: Fix disconnecting due to GattCharacteristic1.MTU
+ # (from 'master')
+ "${FILESDIR}"/${P}-fix-disconnecting.patch
)
pkg_setup() {
@@ -107,7 +109,7 @@ src_prepare() {
default
# http://www.spinics.net/lists/linux-bluetooth/msg38490.html
- if ! use user-session || ! use systemd; then
+ if ! use systemd; then
eapply "${FILESDIR}"/0001-Allow-using-obexd-without-systemd-in-the-user-session-r2.patch
fi
@@ -248,8 +250,8 @@ multilib_src_install_all() {
# https://bugs.archlinux.org/task/45816
# https://bugzilla.redhat.com/show_bug.cgi?id=1318441
# https://bugzilla.redhat.com/show_bug.cgi?id=1389347
- if use user-session && use systemd; then
- ln -s "${ED}"/usr/lib/systemd/user/obex.service "${ED}"/usr/lib/systemd/user/dbus-org.bluez.obex.service
+ if use systemd; then
+ dosym obex.service /usr/lib/systemd/user/dbus-org.bluez.obex.service
fi
find "${D}" -name '*.la' -type f -delete || die
diff --git a/net-wireless/bluez/files/0001-Revert-attrib-Make-use-of-bt_att_resend.patch b/net-wireless/bluez/files/0001-Revert-attrib-Make-use-of-bt_att_resend.patch
new file mode 100644
index 000000000000..a8475b0c4273
--- /dev/null
+++ b/net-wireless/bluez/files/0001-Revert-attrib-Make-use-of-bt_att_resend.patch
@@ -0,0 +1,188 @@
+From 697866e210e4e2dce14c95f7a7243e9b9128d01f Mon Sep 17 00:00:00 2001
+From: Adam Williamson <awilliam@redhat.com>
+Date: Sun, 7 Nov 2021 15:10:53 -0800
+Subject: [PATCH] Revert "attrib: Make use of bt_att_resend"
+
+This reverts commit ac2c2e10b3adb432a572b618c6f53cabb6b3c80b. It
+causes problems with Logitech MX wireless input devices (see
+https://github.com/bluez/bluez/issues/220 and
+https://bugzilla.redhat.com/show_bug.cgi?id=2019970 ).
+---
+ attrib/gattrib.c | 95 +++++++++++++++++++++++++++++++++++++-----------
+ 1 file changed, 73 insertions(+), 22 deletions(-)
+
+diff --git a/attrib/gattrib.c b/attrib/gattrib.c
+index 270a37ebe..bc7d4f22c 100644
+--- a/attrib/gattrib.c
++++ b/attrib/gattrib.c
+@@ -41,8 +41,13 @@ struct _GAttrib {
+ struct queue *track_ids;
+ };
+
++struct id_pair {
++ unsigned int org_id;
++ unsigned int pend_id;
++};
++
+ struct attrib_callbacks {
+- unsigned int id;
++ struct id_pair *id;
+ GAttribResultFunc result_func;
+ GAttribNotifyFunc notify_func;
+ GDestroyNotify destroy_func;
+@@ -51,6 +56,32 @@ struct attrib_callbacks {
+ uint16_t notify_handle;
+ };
+
++static bool find_with_org_id(const void *data, const void *user_data)
++{
++ const struct id_pair *p = data;
++ unsigned int orig_id = PTR_TO_UINT(user_data);
++
++ return (p->org_id == orig_id);
++}
++
++static struct id_pair *store_id(GAttrib *attrib, unsigned int org_id,
++ unsigned int pend_id)
++{
++ struct id_pair *t;
++
++ t = new0(struct id_pair, 1);
++ if (!t)
++ return NULL;
++
++ t->org_id = org_id;
++ t->pend_id = pend_id;
++
++ if (queue_push_tail(attrib->track_ids, t))
++ return t;
++
++ return NULL;
++}
++
+ GAttrib *g_attrib_new(GIOChannel *io, guint16 mtu, bool ext_signed)
+ {
+ gint fd;
+@@ -119,6 +150,9 @@ static void attrib_callbacks_destroy(void *data)
+ if (cb->destroy_func)
+ cb->destroy_func(cb->user_data);
+
++ if (queue_remove(cb->parent->track_ids, cb->id))
++ free(cb->id);
++
+ free(data);
+ }
+
+@@ -148,7 +182,7 @@ void g_attrib_unref(GAttrib *attrib)
+ bt_att_unref(attrib->att);
+
+ queue_destroy(attrib->callbacks, attrib_callbacks_destroy);
+- queue_destroy(attrib->track_ids, NULL);
++ queue_destroy(attrib->track_ids, free);
+
+ free(attrib->buf);
+
+@@ -261,6 +295,7 @@ guint g_attrib_send(GAttrib *attrib, guint id, const guint8 *pdu, guint16 len,
+ struct attrib_callbacks *cb = NULL;
+ bt_att_response_func_t response_cb = NULL;
+ bt_att_destroy_func_t destroy_cb = NULL;
++ unsigned int pend_id;
+
+ if (!attrib)
+ return 0;
+@@ -282,47 +317,62 @@ guint g_attrib_send(GAttrib *attrib, guint id, const guint8 *pdu, guint16 len,
+
+ }
+
+- if (id == 0)
+- id = bt_att_send(attrib->att, pdu[0], (void *) pdu + 1,
+- len - 1, response_cb, cb, destroy_cb);
+- else {
+- int err;
+-
+- err = bt_att_resend(attrib->att, id, pdu[0], (void *) pdu + 1,
+- len - 1, response_cb, cb, destroy_cb);
+- if (err)
+- return 0;
+- }
++ pend_id = bt_att_send(attrib->att, pdu[0], (void *) pdu + 1, len - 1,
++ response_cb, cb, destroy_cb);
+
+- if (!id)
+- return id;
++ /*
++ * We store here pair as it is easier to handle it in response and in
++ * case where user request us to use specific id request - see below.
++ */
++ if (id == 0)
++ id = pend_id;
+
+ /*
+ * If user what us to use given id, lets keep track on that so we give
+ * user a possibility to cancel ongoing request.
+ */
+- if (cb) {
+- cb->id = id;
+- queue_push_tail(attrib->track_ids, UINT_TO_PTR(id));
+- }
++ if (cb)
++ cb->id = store_id(attrib, id, pend_id);
+
+ return id;
+ }
+
+ gboolean g_attrib_cancel(GAttrib *attrib, guint id)
+ {
++ struct id_pair *p;
++
+ if (!attrib)
+ return FALSE;
+
++ /*
++ * If request belongs to gattrib and is not yet done it has to be on
++ * the tracking id queue
++ *
++ * FIXME: It can happen that on the queue there is id_pair with
++ * given id which was provided by the user. In the same time it might
++ * happen that other attrib user got dynamic allocated req_id with same
++ * value as the one provided by the other user.
++ * In such case there are two clients having same request id and in
++ * this point of time we don't know which one calls cancel. For
++ * now we cancel request in which id was specified by the user.
++ */
++ p = queue_remove_if(attrib->track_ids, find_with_org_id,
++ UINT_TO_PTR(id));
++ if (!p)
++ return FALSE;
++
++ id = p->pend_id;
++ free(p);
++
+ return bt_att_cancel(attrib->att, id);
+ }
+
+ static void cancel_request(void *data, void *user_data)
+ {
+- unsigned int id = PTR_TO_UINT(data);
++ struct id_pair *p = data;
+ GAttrib *attrib = user_data;
+
+- bt_att_cancel(attrib->att, id);
++ bt_att_cancel(attrib->att, p->pend_id);
+ }
+
+ gboolean g_attrib_cancel_all(GAttrib *attrib)
+@@ -330,8 +380,9 @@ gboolean g_attrib_cancel_all(GAttrib *attrib)
+ if (!attrib)
+ return FALSE;
+
++ /* Cancel only request which belongs to gattrib */
+ queue_foreach(attrib->track_ids, cancel_request, attrib);
+- queue_remove_all(attrib->track_ids, NULL, NULL, NULL);
++ queue_remove_all(attrib->track_ids, NULL, NULL, free);
+
+ return TRUE;
+ }
+--
+2.33.1
+
diff --git a/net-wireless/bluez/files/bluez-5.62-fix-disconnecting.patch b/net-wireless/bluez/files/bluez-5.62-fix-disconnecting.patch
new file mode 100644
index 000000000000..8eff9dc006dd
--- /dev/null
+++ b/net-wireless/bluez/files/bluez-5.62-fix-disconnecting.patch
@@ -0,0 +1,54 @@
+From ebf2d7935690c00c7fd12768177e2023fc63c9fe Mon Sep 17 00:00:00 2001
+From: Javier de San Pedro <dev.git@javispedro.com>
+Date: Sat, 27 Nov 2021 23:21:36 +0100
+Subject: gatt-client: Fix disconnecting due to GattCharacteristic1.MTU
+
+After the MTU dbus property patches in 5.62 we are seeing bluetoothd
+terminate frequently with "Disconnected from D-Bus. Exiting." msgs.
+Apparently this is because bluetoothd sent an invalid reply to a D-Bus
+Property Get (for GattCharacteristic1's MTU).
+Multiple issues in bluez Github.com project reported similar behavior;
+at least #235 (see Fixes:), #219, and likely #238.
+
+When the Characteristic1 object is still cached/alive, but the
+underlying att connection is not (e.g. someone just called Disconnect),
+the property getter (characteristic_get_mtu) right now returns false.
+However, gdbus seems to ignore the return value and sends the empty reply
+message anyway (rather than a dbus error?), and this seems to cause
+the dbus connection to be terminated (due to the ill-formed reply?).
+bluetoothd then aborts.
+
+This patch makes the property value BT_ATT_DEFAULT_LE_MTU if the
+underlying att object does not exist, rather than returning an invalid
+message. This is consistent with the existing PropertyChanged signal
+behavior (we will emit a PropertyChange only if a larger MTU is
+exchanged), and fixes the issue on my machines.
+An alternative could be to change gdbus behavior, but I'm not sure if we
+are allowed to return an error here anyway without causing problems in
+other dbus libraries/wrappers.
+
+Fixes: aaa0c4996ae9 ("gatt: Add implementation of GattCharacteristic1.MTU")
+Fixes: https://github.com/bluez/bluez/issues/235
+---
+ src/gatt-client.c | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/src/gatt-client.c b/src/gatt-client.c
+index de18bea97..6ee984db9 100644
+--- a/src/gatt-client.c
++++ b/src/gatt-client.c
+@@ -883,10 +883,7 @@ static gboolean characteristic_get_mtu(const GDBusPropertyTable *property,
+ uint16_t mtu;
+
+ att = bt_gatt_client_get_att(gatt);
+- if (!att)
+- return FALSE;
+-
+- mtu = bt_att_get_mtu(att);
++ mtu = att ? bt_att_get_mtu(att) : BT_ATT_DEFAULT_LE_MTU;
+
+ dbus_message_iter_append_basic(iter, DBUS_TYPE_UINT16, &mtu);
+
+--
+cgit 1.2.3-1.el7
+
diff --git a/net-wireless/bluez/metadata.xml b/net-wireless/bluez/metadata.xml
index 60e3ee745e9e..410dfc0f6323 100644
--- a/net-wireless/bluez/metadata.xml
+++ b/net-wireless/bluez/metadata.xml
@@ -17,7 +17,6 @@
<flag name="midi">Enable MIDI support</flag>
<flag name="obex">Enable OBEX transfer support</flag>
<flag name="test-programs">Install tools for testing of various Bluetooth functions</flag>
- <flag name="user-session">Allow compatibility with user-session semantics for session bus under systemd</flag>
</use>
<upstream>
<remote-id type="cpe">cpe:/a:bluez:bluez</remote-id>