2002-02-24 23:30:07

by David Stroupe

[permalink] [raw]
Subject: Q: Interfacing to driver

I have created a driver for a custom board. This driver exports the
functions that I need to access from my user programs to control the
card. How do I declare and call this driver function within my user
code so that it will call the device driver function?
TIA

--
Best regards,
David Stroupe
Keyed-Up Software



2002-02-25 09:04:46

by Jan Hudec

[permalink] [raw]
Subject: Re: Q: Interfacing to driver

> I have created a driver for a custom board. This driver exports the
> functions that I need to access from my user programs to control the
> card. How do I declare and call this driver function within my user
> code so that it will call the device driver function?
> TIA

Exporting makes symbol available to other kernel modules.
You need to register char device or proc entry and define ioctl for it to
call functions you need. You may define read and write if you can define
kind of a comunication protocol.

--------------------------------------------------------------------------------
- Jan Hudec `Bulb' <[email protected]>

2002-02-25 15:38:59

by Zwane Mwaikambo

[permalink] [raw]
Subject: Re: Q: Interfacing to driver

On Sun, 24 Feb 2002, David Stroupe wrote:

> I have created a driver for a custom board. This driver exports the
> functions that I need to access from my user programs to control the
> card. How do I declare and call this driver function within my user
> code so that it will call the device driver function?

Usually done with an ioctl (Check out many of the character drivers for
example), you oughta send these kinda questions to the kernelnewbies list
though (CCd)

Zwane