A flow path for ethernet kernel driver

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

 



Hello, everybody,

I'm trying to develop a new Ethernet driver (Realtek) for Linux kernel 4.0.2. 

[    3.612938] r8169 Gigabit Ethernet driver 2.3LK-NAPI loaded

As part of my studies, I'm trying to trace the path for functions defined in drivers/net/ethernet/realtek/r8169.c, net/core/dev.c and net/core/dev_ioctl.c. I'm using "printks" for this purpose. For instance, something like: 

printk("TEST: __dev_set_promiscuity\n");

However, I'm not getting what's going on. I can set/unset the promiscuity behaviour via ifconfig command.

[  131.330091] device eth0 entered promiscuous mode
[  170.619086] device eth0 left promiscuous mode

By looking at the dmesg output above, I thought the function that deals with promiscuity was __dev_set_promiscuity() defined in net/core/dev.c, because this function calls a function to print the message above:

pr_info("device %s %s promiscuous mode\n", dev->name, dev->flags & IFF_PROMISC ? "entered" : "left");

But, when I tried to look for my printk message with dmesg after compiling and running the kernel, I couldn't find it.

$ cd linux-4.0.2/
$ make net && make modules
$ sudo make modules_install && sudo make install

Can somebody help me to understand what's happening?

Thanks in advance,

--
Airton Ishimori

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

[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