[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bluetooth-dev] Connection management problem
The stack as it is designed today has one problem.
See the following scenario :
btd(m) is waiting for a new incoming connection.
A terminal connects baseband + L2CAP + RFCOMM dlci 0 and dlci 2 (for example).
btd sees (thru the BTISCONNECTED ioctl) that an rfcomm port is connected ->
it starts the modem emulator + ppp.
For the moment everything is fine.
The terminal (for whatever reason) closes the RFCOMM dlci 2 but keeps dlci 0
opened, and kills its ppp.
The ppp launched by btd doesn't get any TERM request and stays opened, and
btd still considers that the line is connected. So btd doesn't do anything.
The terminal opens now RFCOMM dlci 2 and starts dialing + ppp.
The ppp launched by btd sees the dialing messages and throws them away... The
terminal can not connect anymore.
I think we should modify the way the SESSIONSTATE is handled in the kernel
part of the stack. When the stack receives an RFCOMM connection/disconnection
request on a non 0 dlci, it should call
bt_register_rfcomm/bt_unregister_rfcomm. These functions should not be called
when dlci == 0 because anyway, no tty data will ever go thru this rfcomm
To unsubscribe from this list: send the line "unsubscribe bluetooth-dev" in
the body of a message to email@example.com