Re: stuck in netlink/connector

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

 



hi,

sorry but here (GMT+2), it is just the morning.

Soo

I have put three versions of my code:
unicast_wait.tgz => is a basic code taken from the website
www.linuxjournal.com/article/7356, it works but it is only for
understanding netlink socks.
threads.tgz => similar implementation but with a thread and a while(1)
=> just to see how threads works.
unicast_current.tgz => my current program

As you will see, my code is not very good, it is my first time in the
kernel, so I am trying many things but without thinking about mutex,
concurency etc...

Some information about my work:
I would like to capture trafic on infiniband devices using traps in
kernel. I have to dump information from specific module and forward
this to a userspace process.
that's why I was thinking about netlink socket.

For my current program, I will make a trap on Infiniband module to my
module in order to send informations on netlink socket. I just have to
know the pid of my userspace process: I will send the pid using the
callback function of netlink_kernel_create.

In order to learn how to program in kernel, i use:
Linux_device_drivers_3rd_edition
OReilly-Understanding_The_Linux.Kernel_3rd

If you can suggest me other references.

Regards,

Thierry


On Tue, Apr 21, 2009 at 6:54 AM, Prashant Bhole
<prashantsmailcenter@xxxxxxxxx> wrote:
> Hi,
> Please help!
>
> On Fri, Apr 17, 2009 at 2:33 PM, Prashant Bhole
> <prashantsmailcenter@xxxxxxxxx> wrote:
>>
>> Hi,
>> I am stuck in netlink and connector.
>> Netlink:
>> I used this article http://www.linuxjournal.com/article/7356 to learn
>> netlink. Modified the code by going through current kernel code which uses
>> netlink sockets. Now I have a code which can send data from user space to
>> kernel and vice versa. But kernel hangs after after few attempts of
>> executing it. Unable to figure out the problem. I have attached the code. It
>> would be great if sombody can solve the problem.
>>
>> Connector:
>> Then I turned to connector. Tried connector example in documentation. I am
>> not able to receive any message from kernel side. Please sombody try that
>> code and let me know if it is working properly.
>>
>> --
>> ~p~r~a~s~h~a~n~t~
>
>
>
> --
> ~p~r~a~s~h~a~n~t~
>

Attachment: unicast_wait.tgz
Description: GNU Zip compressed data

Attachment: threads.tgz
Description: GNU Zip compressed data

Attachment: netlink_current.tgz
Description: GNU Zip compressed data


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux