Re: [RFC PATCH 11/13] time sync: generic infrastructure to map between time stamps generated by a clock source and system time

Andi Kleen
2008-11-11T16:17:53Z

> +
> +int clocksync_offset(struct clocksync *sync,
> + s64 *offset,
> + u64 *hwtstamp)
> +{
> + u64 starthw = 0, endhw = 0;
> + struct {
> + s64 offset;
> + s64 duration_sys;
> + } samples[100],

That should be separately allocated to avoid potential stack overflow.

Also as a style nit there are normally no {} around single line
statements.

-Andi