int ao_bits;
int have_dio;
}pci230_board;
-pci230_board pci230_boards[] = {
+static pci230_board pci230_boards[] = {
{
name: "Amplicon PCI230",
id: PCI_DEVICE_ID_PCI230,
*/
static int pci230_attach(comedi_device *dev,comedi_devconfig *it);
static int pci230_detach(comedi_device *dev);
-comedi_driver driver_amplc_pci230={
+static comedi_driver driver_amplc_pci230={
driver_name: "amplc_pci230",
module: THIS_MODULE,
attach: pci230_attach,
#define DADATA 8 // FIRST D/A DATA REGISTER (0)
-comedi_lrange cb_pcidda_ranges =
+static comedi_lrange cb_pcidda_ranges =
{
6,
{
*/
static int cb_pcidda_attach(comedi_device *dev,comedi_devconfig *it);
static int cb_pcidda_detach(comedi_device *dev);
-comedi_driver driver_cb_pcidda={
+static comedi_driver driver_cb_pcidda={
driver_name: "cb_pcidda",
module: THIS_MODULE,
attach: cb_pcidda_attach,
static int dt2801_attach(comedi_device *dev,comedi_devconfig *it);
static int dt2801_detach(comedi_device *dev);
-comedi_driver driver_dt2801={
+static comedi_driver driver_dt2801={
driver_name: "dt2801",
module: THIS_MODULE,
attach: dt2801_attach,
}
-comedi_lrange *dac_range_table[]={
+static comedi_lrange *dac_range_table[]={
&range_bipolar10,
&range_bipolar5,
&range_bipolar2_5,
&range_unipolar5
};
-comedi_lrange *dac_range_lkup(int opt)
+static comedi_lrange *dac_range_lkup(int opt)
{
if(opt<0 || opt>5)return &range_unknown;
return dac_range_table[opt];
}
-comedi_lrange *ai_range_table[]={
- &range_dt2801_ai_pgl_bipolar,
- &range_bipolar5,
- &range_bipolar2_5,
- &range_unipolar10,
- &range_unipolar5
-};
-comedi_lrange *ai_range_lkup(int type,int opt)
+static comedi_lrange *ai_range_lkup(int type,int opt)
{
switch(type){
case 0:
static char *driver_name = "dt2811";
-comedi_lrange range_dt2811_pgh_ai_5_unipolar = { 4, {
+static comedi_lrange range_dt2811_pgh_ai_5_unipolar = { 4, {
RANGE( 0, 5 ),
RANGE( 0, 2.5 ),
RANGE( 0, 1.25 ),
RANGE( 0, 0.625 )
}};
-comedi_lrange range_dt2811_pgh_ai_2_5_bipolar = { 4, {
+static comedi_lrange range_dt2811_pgh_ai_2_5_bipolar = { 4, {
RANGE( -2.5, 2.5 ),
RANGE( -1.25, 1.25 ),
RANGE( -0.625, 0.625 ),
RANGE( -0.3125, 0.3125 )
}};
-comedi_lrange range_dt2811_pgh_ai_5_bipolar = { 4, {
+static comedi_lrange range_dt2811_pgh_ai_5_bipolar = { 4, {
RANGE( -5, 5 ),
RANGE( -2.5, 2.5 ),
RANGE( -1.25, 1.25 ),
RANGE( -0.625, 0.625 )
}};
-comedi_lrange range_dt2811_pgl_ai_5_unipolar = { 4, {
+static comedi_lrange range_dt2811_pgl_ai_5_unipolar = { 4, {
RANGE( 0, 5 ),
RANGE( 0, 0.5 ),
RANGE( 0, 0.05 ),
RANGE( 0, 0.01 )
}};
-comedi_lrange range_dt2811_pgl_ai_2_5_bipolar = { 4, {
+static comedi_lrange range_dt2811_pgl_ai_2_5_bipolar = { 4, {
RANGE( -2.5, 2.5 ),
RANGE( -0.25, 0.25 ),
RANGE( -0.025, 0.025 ),
RANGE( -0.005, 0.005 )
}};
-comedi_lrange range_dt2811_pgl_ai_5_bipolar = { 4, {
+static comedi_lrange range_dt2811_pgl_ai_5_bipolar = { 4, {
RANGE( -5, 5 ),
RANGE( -0.5, 0.5 ),
RANGE( -0.05, 0.05 ),
static int dt2811_attach(comedi_device *dev,comedi_devconfig *it);
static int dt2811_detach(comedi_device *dev);
-comedi_driver driver_dt2811={
+static comedi_driver driver_dt2811={
driver_name: "dt2811",
module: THIS_MODULE,
attach: dt2811_attach,
#define PCL711_TIMEOUT 100
#define PCL711_DRDY 0x10
-int i8253_osc_base = 500; /* 2 Mhz */
+static int i8253_osc_base = 500; /* 2 Mhz */
typedef struct {
char *name;
static int pcl711_attach(comedi_device *dev,comedi_devconfig *it);
static int pcl711_detach(comedi_device *dev);
-comedi_driver driver_pcl711={
+static comedi_driver driver_pcl711={
driver_name: "pcl711",
module: THIS_MODULE,
attach: pcl711_attach,
#define RANGE_mA(a,b) {(a)*1e6,(b)*1e6,UNIT_mA}
-comedi_lrange range_4_20mA={ 1, {RANGE_mA(4,20)}};
-comedi_lrange range_0_20mA={ 1, {RANGE_mA(0,20)}};
+static comedi_lrange range_4_20mA={ 1, {RANGE_mA(4,20)}};
+static comedi_lrange range_0_20mA={ 1, {RANGE_mA(0,20)}};
static comedi_lrange *rangelist_726[]={
&range_unipolar5, &range_unipolar10,
#define n_boardtypes (sizeof(boardtypes)/sizeof(boardtype))
#define this_board ((boardtype *)dev->board_ptr)
-comedi_driver driver_pcl726={
+static comedi_driver driver_pcl726={
driver_name: "pcl726",
module: THIS_MODULE,
attach: pcl726_attach,
#define n_boardtypes (sizeof(boardtypes)/sizeof(boardtype))
#define this_board ((boardtype *)dev->board_ptr)
-comedi_driver driver_pcl812={
+static comedi_driver driver_pcl812={
driver_name: "pcl812",
module: THIS_MODULE,
attach: pcl812_attach,
/*
==============================================================================
*/
-void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2);
-void setup_range_channel(comedi_device * dev, comedi_subdevice * s,
+static void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2);
+static void setup_range_channel(comedi_device * dev, comedi_subdevice * s,
unsigned int rangechan, char wait);
-int pcl812_ai_cancel(comedi_device * dev, comedi_subdevice * s);
+static int pcl812_ai_cancel(comedi_device * dev, comedi_subdevice * s);
/*
==============================================================================
*/
/*
==============================================================================
*/
-void pcl812_cmdtest_out(int e,comedi_cmd *cmd) {
+static void pcl812_cmdtest_out(int e,comedi_cmd *cmd) {
rt_printk("pcl812 e=%d startsrc=%x scansrc=%x convsrc=%x\n",e,cmd->start_src,cmd->scan_begin_src,cmd->convert_src);
rt_printk("pcl812 e=%d startarg=%d scanarg=%d convarg=%d\n",e,cmd->start_arg,cmd->scan_begin_arg,cmd->convert_arg);
rt_printk("pcl812 e=%d stopsrc=%x scanend=%x\n",e,cmd->stop_src,cmd->scan_end_src);
/*
==============================================================================
*/
-void setup_range_channel(comedi_device * dev, comedi_subdevice * s,
+static void setup_range_channel(comedi_device * dev, comedi_subdevice * s,
unsigned int rangechan, char wait)
{
unsigned char chan_reg=CR_CHAN(rangechan); // normal board
/*
==============================================================================
*/
-void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2)
+static void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2)
{
#ifdef PCL812_EXTDEBUG
rt_printk("pcl812 EDBG: BGN: start_pacer(%d,%u,%u)\n",mode,divisor1,divisor2);
/*
==============================================================================
*/
-int pcl812_ai_cancel(comedi_device * dev, comedi_subdevice * s)
+static int pcl812_ai_cancel(comedi_device * dev, comedi_subdevice * s)
{
#ifdef PCL812_EXTDEBUG
rt_printk("pcl812 EDBG: BGN: pcl812_ai_cancel(...)\n");
#define n_boardtypes (sizeof(boardtypes)/sizeof(boardtype))
-comedi_driver driver_pcl818={
+static comedi_driver driver_pcl818={
driver_name: "pcl818",
module: THIS_MODULE,
attach: pcl818_attach,
/*
==============================================================================
*/
-int check_and_setup_channel_list(comedi_device * dev, comedi_subdevice * s, comedi_trig * it);
-int pcl818_ai_cancel(comedi_device * dev, comedi_subdevice * s);
-void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2);
-int set_rtc_irq_bit(unsigned char bit);
-void rtc_dropped_irq(unsigned long data);
-int rtc_setfreq_irq(int freq);
+static int check_and_setup_channel_list(comedi_device * dev, comedi_subdevice * s, comedi_trig * it);
+static int pcl818_ai_cancel(comedi_device * dev, comedi_subdevice * s);
+static void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2);
+static int set_rtc_irq_bit(unsigned char bit);
+static void rtc_dropped_irq(unsigned long data);
+static int rtc_setfreq_irq(int freq);
/*
==============================================================================
ANALOG INPUT MODE 1 or 3 DMA , 818 cards
*/
#ifdef CONFIG_COMEDI_TRIG
-void pcl818_ai_mode13dma_int(int mode, comedi_device * dev, comedi_subdevice * s, comedi_trig * it)
+static void pcl818_ai_mode13dma_int(int mode, comedi_device * dev, comedi_subdevice * s, comedi_trig * it)
{
unsigned int flags;
unsigned int bytes;
ANALOG INPUT MODE 1 or 3 DMA rtc, 818 cards
*/
#ifdef CONFIG_COMEDI_TRIG
-void pcl818_ai_mode13dma_rtc(int mode, comedi_device * dev, comedi_subdevice * s, comedi_trig * it)
+static void pcl818_ai_mode13dma_rtc(int mode, comedi_device * dev, comedi_subdevice * s, comedi_trig * it)
{
unsigned int flags;
sampl_t *pole;
==============================================================================
Start/stop pacer onboard pacer
*/
-void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2)
+static void start_pacer(comedi_device * dev, int mode, unsigned int divisor1, unsigned int divisor2)
{
outb(0xb4, dev->iobase + PCL818_CTRCTL);
outb(0x74, dev->iobase + PCL818_CTRCTL);
Check if channel list from user is builded correctly
If it's ok, then program scan/gain logic
*/
-int check_and_setup_channel_list(comedi_device * dev, comedi_subdevice * s, comedi_trig * it)
+static int check_and_setup_channel_list(comedi_device * dev, comedi_subdevice * s, comedi_trig * it)
{
unsigned int chansegment[16];
unsigned int i, nowmustbechan, seglen, segpos;
==============================================================================
Check if board is switched to SE (1) or DIFF(0) mode
*/
-int check_single_ended(unsigned int port)
+static int check_single_ended(unsigned int port)
{
if (inb(port+PCL818_STATUS)&0x20) { return 1; }
else { return 0; }
==============================================================================
cancel any mode 1-4 AI
*/
-int pcl818_ai_cancel(comedi_device * dev, comedi_subdevice * s)
+static int pcl818_ai_cancel(comedi_device * dev, comedi_subdevice * s)
{
if (devpriv->irq_blocked>0) {
// rt_printk("pcl818_ai_cancel()\n");
==============================================================================
chech for PCL818
*/
-int pcl818_check(int iobase)
+static int pcl818_check(int iobase)
{
outb(0x00, iobase + PCL818_MUX);
udelay(1);
==============================================================================
reset whole PCL-818 cards
*/
-void pcl818_reset(comedi_device * dev)
+static void pcl818_reset(comedi_device * dev)
{
if (devpriv->usefifo) { // FIFO shutdown
outb(0, dev->iobase + PCL818_FI_INTCLR);
==============================================================================
Enable(1)/disable(0) periodic interrupts from RTC
*/
-int set_rtc_irq_bit(unsigned char bit)
+static int set_rtc_irq_bit(unsigned char bit)
{
unsigned char val;
unsigned long flags;
==============================================================================
Restart RTC if something stop it (xntpd every 11 mins or large IDE transfers)
*/
-void rtc_dropped_irq(unsigned long data)
+static void rtc_dropped_irq(unsigned long data)
{
comedi_device *dev = (void *)data;
unsigned long flags,tmp;
==============================================================================
Set frequency of interrupts from RTC
*/
-int rtc_setfreq_irq(int freq)
+static int rtc_setfreq_irq(int freq)
{
int tmp = 0;
int rtc_freq;
char *name;
int n_ai_bits;
};
-struct pcmad_board_struct pcmad_boards[]={
+static struct pcmad_board_struct pcmad_boards[]={
{
name: "pcmad12",
n_ai_bits: 12,
static int pcmad_attach(comedi_device *dev,comedi_devconfig *it);
static int pcmad_detach(comedi_device *dev);
-comedi_driver driver_pcmad={
+static comedi_driver driver_pcmad={
driver_name: "pcmad",
module: THIS_MODULE,
attach: pcmad_attach,
int fifoLen;
} rtdBoard;
-rtdBoard rtd520Boards[] = {
+static rtdBoard rtd520Boards[] = {
{
name: "DM7520",
device_id: 0x7520,
static int rtd_attach (comedi_device *dev, comedi_devconfig *it);
static int rtd_detach (comedi_device *dev);
-comedi_driver rtd520Driver={
+static comedi_driver rtd520Driver={
driver_name: "rtd520",
module: THIS_MODULE,
attach: rtd_attach,
detach: rtd_detach,
-
- /* It is not necessary to implement the following members if you are
- * writing a driver for a ISA PnP or PCI card */
- /* Most drivers will support multiple types of boards by
- * having an array of board structures. These were defined
- * in rtd520Boards[] above. Note that the element 'name'
- * was first in the structure -- Comedi uses this fact to
- * extract the name of the board without knowing any details
- * about the structure except for its length.
- * When a device is attached (by comedi_config), the name
- * of the device is given to Comedi, and Comedi tries to
- * match it by going through the list of board names. If
- * there is a match, the address of the pointer is put
- * into dev->board_ptr and driver->attach() is called.
- *
- * Note that these are not necessary if you can determine
- * the type of board in software. ISA PnP, PCI, and PCMCIA
- * devices are such boards.
- */
- board_name: rtd520Boards,
+ board_name: rtd520Boards,
offset: sizeof(rtdBoard),
- num_names: sizeof(rtd520Boards) / sizeof(rtdBoard),
+ num_names: sizeof(rtd520Boards) / sizeof(rtdBoard),
};
static int rtd_ai_rinsn (comedi_device *dev, comedi_subdevice *s,
int ai_bits;
int have_dio;
}skel_board;
-skel_board skel_boards[] = {
+static skel_board skel_boards[] = {
{
name: "skel-100",
ai_chans: 16,
*/
static int skel_attach(comedi_device *dev,comedi_devconfig *it);
static int skel_detach(comedi_device *dev);
-comedi_driver driver_skel={
+static comedi_driver driver_skel={
driver_name: "dummy",
module: THIS_MODULE,
attach: skel_attach,