All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Freeman <johnf@optimation.com.au>
To: Brad Midgley <bmidgley@gmail.com>
Cc: linux-bluetooth@vger.kernel.org
Subject: Re: Intermittent "Address already in use" error
Date: Thu, 30 Jul 2009 19:17:59 +1000	[thread overview]
Message-ID: <19071709.1248945485270.JavaMail.root@safetgram> (raw)
In-Reply-To: <27042187.1248802358830.JavaMail.root@safetgram>

Brad Midgley wrote:
>> Once it gets into this state, all further attempts to bind fail with
>> "Address already in use" ... until I reboot.
> 
> if you're using kernel modules, you might be able to unload/reload a
> bluetooth related kernel module to restore it. This would also help
> narrowing down the cause.

The bad news is that I can't unload the sco or bluetooth modules when the 
problem occurs because they are allegedly "in use".

The good news is that I have found a combination of circumstances that makes the 
problem hard-on rather than intermittent.  As a result, I have discovered some 
additional symptoms.  In addition to the /sys/class/bluetooth/sco file that is 
not cleaned-up, there is also a /sys/class/bluetooth/rfcomm file with contents 
that correspond to a listen() on a RFCOMM socket.  There is also a leftover SDP 
entry arising from advertise_service() even after stop_advertising() has been 
called.

 From what I know of sysfs (learned during the past 24 hours), these entries are 
controlled by reference counts, so it looks like the counts are getting screwed 
somewhere.

Can anyone suggest where I should start looking?

John.



  parent reply	other threads:[~2009-07-30  9:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-07-24 10:08 Intermittent "Address already in use" error John Freeman
2009-07-24 16:47 ` Brad Midgley
     [not found] ` <5111969.1248454126654.JavaMail.root@safetgram>
2009-07-28  8:36   ` John Freeman
2009-07-28 17:31     ` Brad Midgley
     [not found]     ` <27042187.1248802358830.JavaMail.root@safetgram>
2009-07-30  9:17       ` John Freeman [this message]
2009-07-30 23:23         ` Brad Midgley
     [not found]         ` <2648525.1248996255356.JavaMail.root@safetgram>
2009-07-31  1:06           ` John Freeman
     [not found]           ` <33459247.1249002454978.JavaMail.root@safetgram>
2009-07-31  6:36             ` John Freeman

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=19071709.1248945485270.JavaMail.root@safetgram \
    --to=johnf@optimation.com.au \
    --cc=bmidgley@gmail.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.