Показаны сообщения с ярлыком netbsd. Показать все сообщения
Показаны сообщения с ярлыком netbsd. Показать все сообщения

вторник, 31 мая 2011 г.

SO_TIMESTAPMNS option in NetBSD

I've made a small patch that implements SO_TIMESTAMPNS option in NetBSD kernel. Userlevel program that can test it is here.
One nasty thing i faced is that i used older header files for userspace program, and struct timespec was changed since.

struct timespec
{
    time_t tv_sec; //Now 64 bits long (was 32)
    long tv_nsec;
};
I have been getting zero tv_nsec all the time because of that. 
For real the receieved structre is:
+---------------------------+
| tv_sec  | [lower 4 bytes] |
| tv_sec  | [upper 4 bytes] |
| tv_nsec | [4 bytes]       |
+---------------------------+
Userspace thinks:
+---------------------------+
| tv_sec  | [lower 4 bytes] |
| tv_nsec | [4 bytes]       |
+---------------------------+
Had a hard time debugging that ;)

среда, 27 апреля 2011 г.

GSoC is on the way

My GSoC 2011 proposal has been approved!

I'm going to need the network card w/frame time-stamping capability for tests.
This one seems suitable.

I've set up project page here where I will post current project status.