LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   Is device drivers absolutely necessary? (https://www.linuxquestions.org/questions/linux-hardware-18/is-device-drivers-absolutely-necessary-110804/)

sleepymish 10-31-2003 10:10 AM

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

ToniT 10-31-2003 10:27 AM

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.

sleepymish 10-31-2003 10:43 AM

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?

acid_kewpie 10-31-2003 12:03 PM

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...

sleepymish 11-03-2003 07:59 AM

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!

michaelk 11-03-2003 08:09 AM

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.

sleepymish 11-03-2003 08:27 AM

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?

michaelk 11-03-2003 10:02 AM

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

http://www.jungo.com/linux.html

sleepymish 11-03-2003 11:28 AM

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?


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