Re: SRM support in OBEX

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Nami,

2011/6/22 Li, Nami <nami@xxxxxxxxxxxxxxxx>:
> Hi, Piotr
>  I worked on SRM several weeks ago but finally stopped.
>  It`s easy to set and check SRM header, as well as set the response mode to OBEX_RSP_MODE_SINGLE. And it is already well supported in obex_work function when the response mode is SRM, client and server can continue send data without remote side response or request. The obex_work callback relationship is:
> obex_session_start()
>                                        ...
>                        g_io_add_watch_full(io, G_PRIORITY_DEFAULT,     G_IO_IN | G_IO_HUP | G_IO_ERR | G_IO_NVAL,      obex_handle_input, obex, obex_handle_destroy);
>                                        ...
> obex_handle_input()
>                                        ...
>                        OBEX_HandleInput(obex, 1)
>                                        ...
> OBEX_HandleInput()
>                                        ...
>                        obex_work(self, timeout);
>
> The problem in SRM is:
> If remote side doesn`t send any data to local side, then the G_IO_IN condition couldn`t be set. So how obex_work can be called?
>
> I haven`t found any good solution for this issue. So if you can spend some time on SRM, I`ll be very happy:)

No top posting in this list, please.

So back to the topic, we probably need to add another watch with
G_IO_OUT when using SRM so that it wake ups whenever we can write to
the socket/fd, obviously this should only be active when we are
sending data (GET) and there is no need to call OBEX_HandleInput.


-- 
Luiz Augusto von Dentz
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux