LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-21-2012, 07:39 AM   #1
sathyavathi.16
LQ Newbie
 
Registered: Jan 2011
Posts: 3

Rep: Reputation: 0
pci_register_driver doesnt call prob function..


Hi All,

Im trying to insert NVMe driver module i have some doubt in understanding the probe function. the pci_register_driver function never calls the probe function. i dont know what might be the problem.

The value returned from pci_register_driver is 0 which indicates success.. I am using printk in the probe function, but I noticed that probe is never called.
Please can anyboby help me on this.

when i insert the module and check the /var/log/dmesg it show that the Init has occured occurred but the probe is never called.

Thanks in advance
 
Old 09-21-2012, 01:13 PM   #2
flower.Hercules
Member
 
Registered: Aug 2005
Distribution: Gentoo
Posts: 228

Rep: Reputation: 31
When pci_register_driver returns 0, it doesn't mean success, it means there wasn't an error. It's possible that the device you want wasn't found. Not finding the device isn't an error and will therefore return 0.
 
1 members found this post helpful.
Old 09-22-2012, 01:16 AM   #3
sathyavathi.16
LQ Newbie
 
Registered: Jan 2011
Posts: 3

Original Poster
Rep: Reputation: 0
what could be the reason for the divice not to be found?? before inserting the module i download the .bit file to the device via JTAG and it is successful.
where might be the problem???

Thanks in advance
 
Old 09-24-2012, 02:42 AM   #4
sathyavathi.16
LQ Newbie
 
Registered: Jan 2011
Posts: 3

Original Poster
Rep: Reputation: 0
Hi,

what could be the reason for the divice not to be found?? before inserting the module i download the .bit file to the device via JTAG and it is successful.
where might be the problem???

when i isssue lspci i could see the PCI device being listed but still my probe function is not called..

Thanks in advance
 
Old 07-09-2015, 10:07 AM   #5
ravisankar
LQ Newbie
 
Registered: Jul 2015
Posts: 1

Rep: Reputation: Disabled
Smile pci_register_driver wake up probe function

first remove the in built pci ethernet module like (my system having broadcom (module name is tg3).removed by using "rmmod tg3 ". Now insert ur pci device(in our case NVME).It automatically calls probe function.

1.rmmod tg3(see lsmod if broadcom,otherwise other name).
2.insmod pci.ko(my sample pci driver program)
3.dmesg

probe is called.

anydoubt reply this thread

Last edited by ravisankar; 07-09-2015 at 10:08 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] g++ error message no matching function for call to some function Jerry Mcguire Programming 6 04-13-2010 09:37 PM
[SOLVED] Threaded function cannot call a function with extern "C" but nonthreaded function can morty346 Programming 16 01-12-2010 06:00 PM
Compilation issue when Function is parameter in function call on LINUX sa20358 Linux - Software 2 07-24-2008 11:19 PM
error: ‘KBUILD_MODNAME’ undeclared in function ‘pci_register_driver’ amio.praba@gmail.com Linux - Embedded & Single-board computer 0 06-30-2008 03:31 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:42 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration