Received: by 2002:a05:6a10:d5a5:0:0:0:0 with SMTP id gn37csp4075520pxb; Mon, 4 Oct 2021 16:54:40 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwAWVAHnw6q4gsBGqVWwJWhvYufV8zh6rG3zhWnfGqxPm0ftVUPi075u5G5XHio4g1SGoQ7 X-Received: by 2002:a50:cf87:: with SMTP id h7mr22377100edk.324.1633391680732; Mon, 04 Oct 2021 16:54:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1633391680; cv=none; d=google.com; s=arc-20160816; b=iJd2eunq5gXW4D8dI8GYQ2qoiywxIvMQRuo+1858IHwBdf3+zWp+oHyUVMKRtGVrY7 jZCermY8UedIIoKZWd1YdiFjhteEJG4dWi6965bkT0x6yOhQVn6lNBSuTuaC34hPAqHI +tj54ou28IhHWfKE+//7OkcJHBLwpBZRHMtppIsl1edheRJg83LNy4mTykIfWbmX8GOE o1Sv/VMRm4jLiwze2j7OdwsB999aDY7GbrO+54qXg2NEF+hRMIuuuOXqMtalB+iANYiY aJjCIn+UuZv4n98h86FJfEPrlUYZN3p4hBxsIMBFogdPzrf6gsS/4Zo6yc7SejDFBtqm HqqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=ZvxCRJ3W65P7QqyG0dGWqzex/Oyw+5PGS6wynx4t+vI=; b=I0VIrjF0Z9Ymns8KEy5Gfl2lHVBibNn+x1nUXOftjC9pdZsc9oyJBoXZlwzq61/xH/ 7mokM74bqIPRn0dgWAD9pBWVcyiMKlM8kOR0yGhcGEwXByZ3tu4hefJS7pxY3bzDPH/z wXh7dQmws3Woj8IgQcXNpDnoqwXI4NvlXhjkoKSGh83aXAqQ+TpH0pkx8MKT7E1FGpKb nNmK3GNF04rXMKnirGIFGjXkZKC4DfkxZEndpuSl29QirXR2zdtPZHPZwOLMtdIFt7Mf KcJM5bD64cwL95RumZeM/3llexqiWHX82kaffJK2qfEjmLvxVMb5Jem/Hyw7nuh9cPO3 u1pQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Vm+uukhJ; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v17si6418369edb.590.2021.10.04.16.54.17; Mon, 04 Oct 2021 16:54:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Vm+uukhJ; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236889AbhJDWuB (ORCPT + 99 others); Mon, 4 Oct 2021 18:50:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54204 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233501AbhJDWuB (ORCPT ); Mon, 4 Oct 2021 18:50:01 -0400 Received: from mail-vs1-xe36.google.com (mail-vs1-xe36.google.com [IPv6:2607:f8b0:4864:20::e36]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BFF9EC061745 for ; Mon, 4 Oct 2021 15:48:11 -0700 (PDT) Received: by mail-vs1-xe36.google.com with SMTP id 188so21627582vsv.0 for ; Mon, 04 Oct 2021 15:48:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ZvxCRJ3W65P7QqyG0dGWqzex/Oyw+5PGS6wynx4t+vI=; b=Vm+uukhJI++Xq0v9Z0HCGT45wA/YAiNJcOP+dnKB5f6JYe+7WkkdNE0zRUICGVSwSx 9TF2QplzRl/MrhWcbJvCZo9EwAsmS9U/9ln9Be/VAvwcj6Fs3z9B9V5Xxxp6UOS7Pf3y 5ly3cvK7QtYPppSnK5+ZROMU7UJ5/gK5Wsu4hgKy6O+O5aRShaZ2R/vSLs9Dg+0iOgBG 7BFnXeXoVuYgH0ODsbZfkQ3Sy5HjXaRE2MWl2kEsgtDm3lHNQ0iUMgE7QTlp6sMwKZOw KuKUp8y9f+CkK/ISUlU1Nazh3fQEJhLiJkAEb5lEgZavcoG6U7HOVXPX4kc1G/p/VKBu vKlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ZvxCRJ3W65P7QqyG0dGWqzex/Oyw+5PGS6wynx4t+vI=; b=IxyNP64e27by3Rs3rVSddjmZmTdv7jysJcL2X/toXnJyNhC3j8mopNkQNuu8Zv7n7s SJuOp2Ij1f8vQdm31QNmp/o747qZazedkJ4eDrIOwiN9jgCa3G1hSYRJhfAmqpSfHZEE K5WI+d21NHdk3+d54jJL26R/O3X5jzvQSmlxs3Rj3bPLdm/3p0Ovasr5e+rKr3OafSPd ZsGQDGU+gdiJwby4/kUBTGlDita9mD0K+eBiSc9J3qMfLOGtQJiux3I5NMqrcTq38El5 xxa4/sAIT1FTAi/mGE6jaMGV/DDxAPqpRaaKrnpSNfaGVwMQD8G5ErWOoub3iIWijTty 0EcA== X-Gm-Message-State: AOAM531m7ju/CEMfy/uYwpxGL07tGdEQyhgmVSi2gTy90wAaLVyfqaTs UWRpAe4GImqcboLlgePCoBvtXAraQlydP6JwceQ= X-Received: by 2002:a05:6102:21d0:: with SMTP id r16mr16211859vsg.39.1633387690878; Mon, 04 Oct 2021 15:48:10 -0700 (PDT) MIME-Version: 1.0 References: <20210930223726.2886139-1-mcchou@chromium.org> In-Reply-To: <20210930223726.2886139-1-mcchou@chromium.org> From: Luiz Augusto von Dentz Date: Mon, 4 Oct 2021 15:48:00 -0700 Message-ID: Subject: Re: [BlueZ PATCH v7 0/4] Detailed error string To: Miao-chen Chou Cc: Bluetooth Kernel Mailing List , Luiz Augusto von Dentz , Howard Chung , Alain Michaud , Marcel Holtmann Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hi Miao, On Thu, Sep 30, 2021 at 3:46 PM Miao-chen Chou wrote: > > Chromium OS has been working closely with Linux Bluetooth community to > improve BlueZ stack, and there are increasing needs from applications > building their features around Bluetooth. One of the major feedback > from these application is the lack of the detailed failure reasons as > return for D-Bus method call, and these failure reasons can be used in > metrics, optimizing retry mechanism, hinting the reproduce scenario to > improve BlueZ stack. The current org.bluez.Error.* are serving the > generic errors well. However,g given org.bluez.Error.* errors are used > across different interface context which does not serve the detailed > failure reasons well. (See https://github.com/bluez/bluez/issues/131) > > Changes in v7: > - Fix nits > > Changes in v6: > - Rephrase error string > > Changes in v5: > - Replace error code with error string > > Changes in v4: > - Address make errors. > > Changes in v3: > - Correct error-codes.txt. > > Changes in v2: > - Add documentation for error codes > > Miao-chen Chou (4): > Add errors.txt to describe errors of D-Bus method returns > BR/EDR and LE connection failure reasons > Include detailed error string in Connect() return > Print error code for connect methods > > client/main.c | 3 +- > doc/errors.txt | 233 +++++++++++++++++++++++++++++++++++++++++++++++++ > src/device.c | 46 ++++++---- > src/error.c | 100 +++++++++++++++++++++ > src/error.h | 57 ++++++++++++ > 5 files changed, 422 insertions(+), 17 deletions(-) > create mode 100644 doc/errors.txt > > -- > 2.33.0.800.g4c38ced690-goog Applied, thanks. -- Luiz Augusto von Dentz