LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 10-31-2003, 10:10 AM   #1
sleepymish
LQ Newbie
 
Registered: Oct 2003
Posts: 16

Rep: Reputation: 0
Question Is device drivers absolutely necessary?


Hi,

I'm a total newbie to the Linux world and I have a general question about it.

I have a computer station with Linux installed. I want to connect PCI cards to it through the PCI bus. I'm wondering if I absolutely need a device driver for the PCI card in order for the Linux OS to recognize the card at startup?

Thanks!
Michelle
 
Old 10-31-2003, 10:27 AM   #2
ToniT
Senior Member
 
Registered: Oct 2003
Location: Zurich, Switzerland
Distribution: Debian/unstable
Posts: 1,357

Rep: Reputation: 47
Depends on what you want do do with the card. To only detect it, no. To do something special with the card (what this special is, depends on the card), yes the os have to have some prior knowledge of the hardware in question to do some magic with it.
 
Old 10-31-2003, 10:43 AM   #3
sleepymish
LQ Newbie
 
Registered: Oct 2003
Posts: 16

Original Poster
Rep: Reputation: 0
The PCI card is used for data acquisition. I want to poll a register on the PCI card to see if data is available, if it is, data will be transmitted over the PCI bus. Do I need a device driver to do that?
 
Old 10-31-2003, 12:03 PM   #4
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
you always need some sort of driver to use a piece of hardware... i really don't understand what you're trying to say.... If you are doing it at the low level you seem to be suggesting then you would be writing the driver itself i guess...
 
Old 11-03-2003, 07:59 AM   #5
sleepymish
LQ Newbie
 
Registered: Oct 2003
Posts: 16

Original Poster
Rep: Reputation: 0
Well, what I'm hoping to do is plug in the PCI card, bootup my linux machine, and the machine will "magically" recognize the card. I want to memory map some registers in the PCI card, poll the registers, and go in to grab data when it's available.

I know windows machines need drivers, i'm just wondering if Linux needs the same.

Thanks for all your help!
 
Old 11-03-2003, 08:09 AM   #6
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
So what kind of PCI card is it? Do you know its I/O memory addressing etc?

If your expecting to do some high level programming with the card then yes you will need a device driver. Otherwise you should be able to write a program that can read the I/O memory.

So just like Acid_kewpie said you would be writing the driver in your program.

Last edited by michaelk; 11-03-2003 at 08:11 AM.
 
Old 11-03-2003, 08:27 AM   #7
sleepymish
LQ Newbie
 
Registered: Oct 2003
Posts: 16

Original Poster
Rep: Reputation: 0
For clarification, I want to access the hardware in the PCI card through software (i.e. memory map) ... do I need to write a device driver to do that?
 
Old 11-03-2003, 10:02 AM   #8
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
http://www.tldp.org/HOWTO/IO-Port-Programming.html

http://www.jungo.com/linux.html
 
Old 11-03-2003, 11:28 AM   #9
sleepymish
LQ Newbie
 
Registered: Oct 2003
Posts: 16

Original Poster
Rep: Reputation: 0
I do know the memory addressing of the PCI Card. It's a card made by Xilinx (www.xilinx.com). I want to write software programs in C/C++ to access these memory addresses. Correct me if I'm wrong, but it looks like I might be able to use the link (http://www.tldp.org/HOWTO/IO-Port-Programming.html) as a guide to write codes to access the PCI card hardware?
 
  


Reply



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
New to device drivers sksingh Linux - Software 1 08-02-2004 07:03 AM
About Device drivers eshwar_ind Programming 3 02-24-2004 04:25 PM
Device Drivers Mohsen Programming 3 01-25-2004 01:08 AM
Device Drivers reza_asghari Programming 5 08-30-2002 01:05 PM
Device Drivers Poorman Linux - Newbie 1 07-05-2002 04:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 11:41 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
Open Source Consulting | Domain Registration