On Fri, 2013-02-15 at 14:31 +0100, Marco Porsch wrote:
> Hi,
>
> On 02/15/2013 01:46 PM, Johannes Berg wrote:
> > On Fri, 2013-02-15 at 12:40 +0000, [email protected] wrote:
> >> Please check again. The comment is split in two and placed on the
> >> respective new positions.
> >
> > Yeah, I see, the API is just total shit. First passing the TSF and then
> > calculating it to override? Why not do the calculation outside the API
> > always?
>
> The TBTT calculation does intentionally not use the mactime value.
>
> Synchronization uses the time in local TSF units and the exact same time
> point in peers TSF units at the time of sending/receiving (mactime field).
> The TBTT calculation uses the time of NOW, i.e. the current TSF after
> possible delays in firmware/driver/rx-handler which may have outdated
> the mactime field.
I'm talking about this API:
mesh_neighbour_update:
...
tsf = drv_get_tsf()
...
sync_ops->rx_bcn(..., tsf)
mesh_sync_offset_rx_bcn(..., t_r):
...
if (have_better_timestamp)
t_r = get_better_timestamp()
You can hardly claim that's an intuitive API.
johannes
_______________________________________________
Devel mailing list
[email protected]
http://lists.open80211s.org/cgi-bin/mailman/listinfo/devel