Linux-Bluetooth Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH BlueZ] mesh: Show error message when io initialization fails
@ 2019-08-20  7:58 Michał Lowas-Rzechonek
  2019-08-28 16:45 ` Gix, Brian
  0 siblings, 1 reply; 2+ messages in thread
From: Michał Lowas-Rzechonek @ 2019-08-20  7:58 UTC (permalink / raw)
  To: linux-bluetooth

---
 mesh/mesh-io-generic.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/mesh/mesh-io-generic.c b/mesh/mesh-io-generic.c
index cc91f494e..42bf64a0b 100644
--- a/mesh/mesh-io-generic.c
+++ b/mesh/mesh-io-generic.c
@@ -21,6 +21,8 @@
 #include <config.h>
 #endif
 
+#include <errno.h>
+#include <string.h>
 #include <sys/time.h>
 #include <ell/ell.h>
 
@@ -285,7 +287,8 @@ static bool hci_init(struct mesh_io *io)
 {
 	io->pvt->hci = bt_hci_new_user_channel(io->pvt->index);
 	if (!io->pvt->hci) {
-		l_error("Failed to start mesh io (hci %u)", io->pvt->index);
+		l_error("Failed to start mesh io (hci %u): %s", io->pvt->index,
+							strerror(errno));
 		return false;
 	}
 
-- 
2.19.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH BlueZ] mesh: Show error message when io initialization fails
  2019-08-20  7:58 [PATCH BlueZ] mesh: Show error message when io initialization fails Michał Lowas-Rzechonek
@ 2019-08-28 16:45 ` Gix, Brian
  0 siblings, 0 replies; 2+ messages in thread
From: Gix, Brian @ 2019-08-28 16:45 UTC (permalink / raw)
  To: michal.lowas-rzechonek, linux-bluetooth

Applied

On Tue, 2019-08-20 at 09:58 +0200, Michał Lowas-Rzechonek wrote:
> ---
>  mesh/mesh-io-generic.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/mesh/mesh-io-generic.c b/mesh/mesh-io-generic.c
> index cc91f494e..42bf64a0b 100644
> --- a/mesh/mesh-io-generic.c
> +++ b/mesh/mesh-io-generic.c
> @@ -21,6 +21,8 @@
>  #include <config.h>
>  #endif
>  
> +#include <errno.h>
> +#include <string.h>
>  #include <sys/time.h>
>  #include <ell/ell.h>
>  
> @@ -285,7 +287,8 @@ static bool hci_init(struct mesh_io *io)
>  {
>  	io->pvt->hci = bt_hci_new_user_channel(io->pvt->index);
>  	if (!io->pvt->hci) {
> -		l_error("Failed to start mesh io (hci %u)", io->pvt->index);
> +		l_error("Failed to start mesh io (hci %u): %s", io->pvt->index,
> +							strerror(errno));
>  		return false;
>  	}
>  

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-20  7:58 [PATCH BlueZ] mesh: Show error message when io initialization fails Michał Lowas-Rzechonek
2019-08-28 16:45 ` Gix, Brian

Linux-Bluetooth Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-bluetooth/0 linux-bluetooth/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-bluetooth linux-bluetooth/ https://lore.kernel.org/linux-bluetooth \
		linux-bluetooth@vger.kernel.org linux-bluetooth@archiver.kernel.org
	public-inbox-index linux-bluetooth


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-bluetooth


AGPL code for this site: git clone https://public-inbox.org/ public-inbox