Ian Abbott [Thu, 8 Nov 2007 17:02:36 +0000 (17:02 +0000)]
Use 64-bit ns value when determining clock source.
Ian Abbott [Thu, 8 Nov 2007 16:45:45 +0000 (16:45 +0000)]
Renamed pci_iobase to iobase1.
Ian Abbott [Thu, 8 Nov 2007 16:33:30 +0000 (16:33 +0000)]
Used specific constants for base addresses of 8254 and 8255 chips instead
of using the constants for the first channel of each.
Ian Abbott [Thu, 8 Nov 2007 16:21:40 +0000 (16:21 +0000)]
Eliminated clock source and divisor values from private data and combined
a few functions. Note: reading the period of the timer subdevice is now
even more broken than it was before, but I'm planning to remove it anyway
due to conflicts with the AI and AO subdevices.
Ian Abbott [Thu, 8 Nov 2007 15:35:24 +0000 (15:35 +0000)]
Renamed some macros. Now access the timebase values via a look-up table to
eliminate some switch statements.
Ian Abbott [Thu, 8 Nov 2007 11:51:16 +0000 (11:51 +0000)]
amplc_pci230.c whitespace changes / comment reformatting.
Ian Abbott [Thu, 8 Nov 2007 10:52:04 +0000 (10:52 +0000)]
Spelling correction in Description: line.
Ian Abbott [Wed, 7 Nov 2007 17:18:57 +0000 (17:18 +0000)]
Fix for 2.6.10 and earlier. Rename comedi_compat_ioctl function to
comedi_compat_ioctl_ and define comedi_compat_ioctl macro to access it.
The comedi_compat_ioctl macro expands to 0 for 2.6.10 and earlier
(HAVE_COMPAT_IOCTL undefined) so it tried to define a function called '0'!
Ian Abbott [Wed, 7 Nov 2007 16:24:47 +0000 (16:24 +0000)]
Removed a stray comment.
Ian Abbott [Wed, 7 Nov 2007 16:18:28 +0000 (16:18 +0000)]
Make sure 32-bit ioctl handler for <= 2.6.10 kernel doesn't return
-ENOIOCTLCMD.
Ian Abbott [Wed, 7 Nov 2007 16:03:15 +0000 (16:03 +0000)]
Support 32-bit ioctl calls on 64-bit kernel (CONFIG_COMPAT).
Ian Abbott [Mon, 5 Nov 2007 14:07:00 +0000 (14:07 +0000)]
Replaced INSN_CONFIG_8254_SET_MODE with INSN_CONFIG_SET_COUNTER_MODE.
Ian Abbott [Mon, 5 Nov 2007 11:50:11 +0000 (11:50 +0000)]
Inline fixes: define inline functions before calling them.
Some versions of gcc treat it as an error. Others will ignore the inline
in this case and compile in a function call.
Ian Abbott [Mon, 5 Nov 2007 11:47:53 +0000 (11:47 +0000)]
Made cfc_bytes_per_scan() 'static inline' instead of plain 'inline'.
Frank Mori Hess [Sun, 4 Nov 2007 04:33:49 +0000 (04:33 +0000)]
Applied comedi_indent script to all source files.
Frank Mori Hess [Sun, 4 Nov 2007 04:28:25 +0000 (04:28 +0000)]
Removed some dead code that was causing errors in indent program.
Frank Mori Hess [Sun, 4 Nov 2007 04:14:37 +0000 (04:14 +0000)]
Removed some dead code that confused the indent program.
Frank Mori Hess [Sun, 4 Nov 2007 04:08:58 +0000 (04:08 +0000)]
Removed a bit of ifdef'd out code that confuses the indent program.
Frank Mori Hess [Sun, 4 Nov 2007 03:45:53 +0000 (03:45 +0000)]
Added wrapper around indent utility with options I'm going to apply
to comedi source files.
Ian Abbott [Fri, 2 Nov 2007 11:11:17 +0000 (11:11 +0000)]
Security fix in comedi_buf_alloc() for non-DMA data buffers. Allocate each
page using get_zeroed_page() instead of __get_free_page() to avoid exposing
random memory contents to user space if the buffer is mmap'ed.
Ian Abbott [Thu, 1 Nov 2007 17:47:00 +0000 (17:47 +0000)]
Sanitize resource types. Use new comedi_pci_enable and comedi_pci_disable
functions instead of ad hoc calls to request_region and release_region.
Ian Abbott [Thu, 1 Nov 2007 16:14:53 +0000 (16:14 +0000)]
Removed tests for whether PCI device supports bus-mastering as can't tell
from PCI device structure.
Ian Abbott [Thu, 1 Nov 2007 16:11:15 +0000 (16:11 +0000)]
Removed kernel 2.2 and 2.4 compatibility.
Removed checks for whether PCI device supports mastering as can't tell from
PCI device structure.
Ian Abbott [Thu, 1 Nov 2007 15:39:26 +0000 (15:39 +0000)]
New wrapper functions in comedi/drivers/comedi_pci.h:
comedi_pci_enable() combines pci_enable_device() and pci_request_regions().
comedi_pci_disable() combines pci_release_regions() and pci_disable_device().
Does the right thing for reference-counted PCI enables in 2.6.20 onwards.
Ian Abbott [Wed, 31 Oct 2007 14:40:24 +0000 (14:40 +0000)]
Check result of subdev_8255_init().
Ian Abbott [Wed, 31 Oct 2007 14:15:22 +0000 (14:15 +0000)]
For PCI260(+) make subdevice 2 UNUSED instead of AO with no channels.
Ian Abbott [Wed, 31 Oct 2007 14:01:28 +0000 (14:01 +0000)]
Added pci230+ and pci260+. Currently they are treated same as pci230 and
pci260 apart from the increased number of bits on the AI subdevice. The
cards can also be configured as the old pci230 or pci260.
Ian Abbott [Tue, 30 Oct 2007 16:49:21 +0000 (16:49 +0000)]
Untested compatibility fix for change to rt_task_init in RTAI >= 3.3
(the context of the callback function changed from 'int' to 'long').
Ian Abbott [Tue, 30 Oct 2007 15:46:34 +0000 (15:46 +0000)]
#ifdef out floating point register stuff.
Ian Abbott [Mon, 29 Oct 2007 15:52:01 +0000 (15:52 +0000)]
Added PCI-DIO24 info supplied by Yoshiya Matsuzaka.
Its software interface is same as PCI-DIO24H but with a different PCI
device ID.
Frank Mori Hess [Mon, 29 Oct 2007 00:00:25 +0000 (00:00 +0000)]
Regenerated ChangeLog with "cvs2cl -t" for 0.7.75 release.
Frank Mori Hess [Sun, 28 Oct 2007 23:59:48 +0000 (23:59 +0000)]
Bumped version for 0.7.75 release
Frank Mori Hess [Fri, 26 Oct 2007 17:59:36 +0000 (17:59 +0000)]
Fixed compile warning on amd64.
Frank Mori Hess [Thu, 25 Oct 2007 20:00:47 +0000 (20:00 +0000)]
Don't report bogus gate errors on 660x boards.
Frank Mori Hess [Thu, 25 Oct 2007 19:56:22 +0000 (19:56 +0000)]
Added enum for setting master clock of NI "frequency output" subdevice.
Frank Mori Hess [Thu, 25 Oct 2007 19:55:41 +0000 (19:55 +0000)]
Added subdevice for "frequency output" pin.
Frank Mori Hess [Thu, 25 Oct 2007 19:49:14 +0000 (19:49 +0000)]
Added check against maxdata for write instructions.
Frank Mori Hess [Wed, 24 Oct 2007 21:29:10 +0000 (21:29 +0000)]
Each comedi_async struct should have its own wait_queue_head_t.
Frank Mori Hess [Wed, 24 Oct 2007 18:14:55 +0000 (18:14 +0000)]
Prevent glitches when transitioning from static control of dio lines
to waveform output.
Ian Abbott [Wed, 24 Oct 2007 12:37:39 +0000 (12:37 +0000)]
Allocate non-DMA buffer pages using __get_free_page(). (Use of virt_to_page
on vmalloc'd memory was incorrect and failed on x86_64 for example.)
Clean up fully on allocation failure.
Ian Abbott [Mon, 22 Oct 2007 14:59:55 +0000 (14:59 +0000)]
Check dev->attached in interrupt routine.
Ian Abbott [Mon, 22 Oct 2007 12:19:19 +0000 (12:19 +0000)]
Some 64-bit fixes.
Frank Mori Hess [Thu, 18 Oct 2007 21:50:25 +0000 (21:50 +0000)]
Fix from Torben Mikael Hansen <comedi_ns@linhard.dk> for crash probably
caused by my recent porting work.
Frank Mori Hess [Thu, 18 Oct 2007 21:48:55 +0000 (21:48 +0000)]
Patch from Torben Mikael Hansen <comedi_ns@linhard.dk> which adds device
id for PCM-DAS16s/16.
Frank Mori Hess [Thu, 18 Oct 2007 21:40:34 +0000 (21:40 +0000)]
Got rid of fragile checks of specific device ids in mite.c (fixed problems
with pxi-6602 support). Added device id for pxi-6608. Made sure the
"window base size register" is disabled when using the "window base size
register 1", since it causes problems if both are enabled simultaneously.
Ian Abbott [Thu, 18 Oct 2007 18:01:45 +0000 (18:01 +0000)]
Some changes to deal with interrupts before device fully attached.
Frank Mori Hess [Wed, 17 Oct 2007 20:01:56 +0000 (20:01 +0000)]
Added pci device id for pxi-6602.
Ian Abbott [Wed, 17 Oct 2007 15:26:59 +0000 (15:26 +0000)]
Replaced kmalloc/memset sequence with kzalloc or kcalloc.
Ian Abbott [Wed, 17 Oct 2007 15:24:40 +0000 (15:24 +0000)]
Replaced kmalloc/memset sequence with kzalloc or kcalloc.
Removed call to memset after alloc_subdevices to avoid clobbering spinlocks.
Frank Mori Hess [Tue, 16 Oct 2007 19:59:32 +0000 (19:59 +0000)]
Added support for scan_begin_src = TRIG_EXT on analog output commands.
Frank Mori Hess [Tue, 16 Oct 2007 02:21:02 +0000 (02:21 +0000)]
Ported to linux 2.6.23 pcmcia interface. Compiles, but otherwise untested.
Frank Mori Hess [Tue, 16 Oct 2007 02:09:09 +0000 (02:09 +0000)]
Ported to linux 2.6.23 pcmcia interface. Compiles, but otherwise untested.
Frank Mori Hess [Tue, 16 Oct 2007 00:35:23 +0000 (00:35 +0000)]
Ported to linux 2.6.23 pcmcia interface. Compiles, but otherwise untested.
Frank Mori Hess [Mon, 15 Oct 2007 01:15:09 +0000 (01:15 +0000)]
Updated to linux 2.6.23 pcmcia interface. Compiles, but untested.
Frank Mori Hess [Mon, 15 Oct 2007 01:02:12 +0000 (01:02 +0000)]
Updated to 2.6.23 pcmcia interface. Compiles, otherwise untested.
Frank Mori Hess [Mon, 15 Oct 2007 00:43:18 +0000 (00:43 +0000)]
More linux 2.6.23 pcmcia fixes.
Frank Mori Hess [Mon, 15 Oct 2007 00:08:27 +0000 (00:08 +0000)]
Updated to 2.6.23 kernel pcmcia interface. It compiles now, don't know
if it actually works.
Frank Mori Hess [Fri, 12 Oct 2007 19:04:43 +0000 (19:04 +0000)]
Pruned obsolete lseek code.
Ian Abbott [Thu, 11 Oct 2007 14:23:09 +0000 (14:23 +0000)]
Added regshift parameter after base address in i8254_load(), i8254_mm_load(),
i8254_read(), i8254_mm_read(), i8254_write(), i8254_mm_write(),
i8254_set_mode(), i8254_mm_set_mode(), i8254_status(), i8254_mm_status().
The offsets to the four 8253/8254 registers will be shifted left by this
amount. This is to cater for cards where the four registers do not occupy
consecutive bytes.
Frank Mori Hess [Sun, 30 Sep 2007 14:42:11 +0000 (14:42 +0000)]
Support DESTDIR for module install/uninstall.
Frank Mori Hess [Sat, 29 Sep 2007 00:01:47 +0000 (00:01 +0000)]
Fixed use of ai channels >= 64 on 6225. Based on patch from
Ingmar Schoegl <ischoegl@mail.utexas.edu>.
Frank Mori Hess [Fri, 28 Sep 2007 18:40:55 +0000 (18:40 +0000)]
Eliminated the possibility of the ao dma channel getting allocated
more than once, when ni_ao_inttrig gets called a second time after
returning an error.
Ian Abbott [Fri, 14 Sep 2007 12:33:47 +0000 (12:33 +0000)]
Add slab.h compatibility header.
Ian Abbott [Fri, 14 Sep 2007 12:32:49 +0000 (12:32 +0000)]
Add kzalloc and kcalloc kernel compatibility functions.
Ian Abbott [Fri, 7 Sep 2007 17:04:27 +0000 (17:04 +0000)]
Corrected calculation of board name offset. Fixes segmentation violation
when reading /proc/comedi for comedi drivers that have num_names > 1.
Frank Mori Hess [Thu, 6 Sep 2007 03:22:51 +0000 (03:22 +0000)]
Change $(GREP) to $(EGREP), since we really only do a AC_PROG_EGREP
in configure, and apparently GREP isn't always defined, as reported
by Anders Blomdell.
Frank Mori Hess [Wed, 5 Sep 2007 12:37:43 +0000 (12:37 +0000)]
Added files I forgot to cvs add from patch by
Anders Blomdell <anders.blomdell@control.lth.se>
Frank Mori Hess [Tue, 4 Sep 2007 03:22:08 +0000 (03:22 +0000)]
Patch from Anders Blomdell <anders.blomdell@control.lth.se> which makes
some of the addi-data drivers useable:
Since I need to use a driver for apci3106, I guess that I'll have to do some
cleanup of the addi-data drivers, but after downloading the drivers from
addi-data (http://www.addi-data.com/treiber/linux/comedi/comedi_Driver.tar.gz,
v_1.13), and comparing them with cvs, I'm at a loss about which drivers to use
as a starting point. I have enclosed a [tentative] patch against CVS
(patch.addi-data.
20070828), that seems to work with apci3106-16-4. There is also
the patch against the CVS from late 2005 (patch.addi.2005-11-11) that I sent to
weber.serge@addi-data.com, asking him to do additional cleanup and then submit
it to the CVS maintainers, obviously this never happened :-( (and hence the last
batch of cards was of another brand).
Frank Mori Hess [Fri, 24 Aug 2007 18:44:38 +0000 (18:44 +0000)]
Fixed some calculations of number of bytes per scan when doing
digital io commands.
Ian Abbott [Tue, 21 Aug 2007 09:47:21 +0000 (09:47 +0000)]
Sanity check drivers setting do_cmd without setting do_cmdtest.
Frank Mori Hess [Fri, 17 Aug 2007 20:54:52 +0000 (20:54 +0000)]
read acknowledges irq bit does have an effect on a 6601.
Frank Mori Hess [Fri, 17 Aug 2007 19:56:37 +0000 (19:56 +0000)]
Added interrupt handler and enabled interrupts. Added initialization of output routing for pfi pins to reasonable defaults.
Frank Mori Hess [Fri, 17 Aug 2007 19:53:39 +0000 (19:53 +0000)]
Fixed missing initialization of some counter registers (and their software copies). Made ni_tio_cancel() safe to call in interrupt context without possibly corrupting software copies of registers.
Frank Mori Hess [Fri, 17 Aug 2007 19:49:48 +0000 (19:49 +0000)]
Added enum for setting output routing of pfi pins on 660x boards.
Frank Mori Hess [Thu, 16 Aug 2007 21:52:43 +0000 (21:52 +0000)]
Fixed failure to unlock spinlock after locking it. Fixed possibly
bogus perm_stale_data result from ni_tio_acknowledge_and_confirm().
Added (unused) support for accessing joint status register 1.
Frank Mori Hess [Wed, 15 Aug 2007 21:22:49 +0000 (21:22 +0000)]
Moved some interrupt enable/disable and interrupt handling
stuff from client drivers into ni_tio.c.
ni_stc.h:
Added some stuff for correlated digital output waveforms
that I missed in earlier commit.
ni_660x.c:
Added beginnings of support for buffered input counting (untested,
definitely doesn't work yet due to empty interrupt handler).
Added INSN_CONFIG_SET/GET_ROUTING support,
to allow switching of output signals between
counter outputs and static digital output. Fixed channel mix-ups
on input/output selection for static dio. Fixed static digital
output to work on full 32 bits. Replaced some preprocessor macros
with inline functions.
Frank Mori Hess [Wed, 15 Aug 2007 21:20:57 +0000 (21:20 +0000)]
Added comment describing purpose of comedi_set_hw_dev().
Frank Mori Hess [Mon, 13 Aug 2007 21:17:20 +0000 (21:17 +0000)]
Added support for dio write commands with NI M-series.
Frank Mori Hess [Mon, 13 Aug 2007 15:12:27 +0000 (15:12 +0000)]
Disable all of a channel's interrupts when it is released.
Frank Mori Hess [Mon, 13 Aug 2007 15:05:53 +0000 (15:05 +0000)]
NULL inttrig in do_become_nonbusy().
Frank Mori Hess [Thu, 9 Aug 2007 20:15:30 +0000 (20:15 +0000)]
Check for stale data error on counter input command if reloading
on gate is enabled.
Frank Mori Hess [Thu, 9 Aug 2007 19:17:57 +0000 (19:17 +0000)]
Added bit definitions for NI m-series correlated dio registers.
Frank Mori Hess [Thu, 9 Aug 2007 17:55:01 +0000 (17:55 +0000)]
Added definitions for possible scan_begin_srcs on NI m-series
with upcoming correlated dio command support.
Frank Mori Hess [Thu, 9 Aug 2007 13:03:37 +0000 (13:03 +0000)]
NI counters don't really support stop_src TRIG_COUNT.
Frank Mori Hess [Thu, 9 Aug 2007 12:58:26 +0000 (12:58 +0000)]
Made mite_done() update done status by reading status register.
Frank Mori Hess [Thu, 9 Aug 2007 00:22:00 +0000 (00:22 +0000)]
We need to use dma_free_coherent() instead of kfree() in mite_free_ring()
now.
Frank Mori Hess [Tue, 7 Aug 2007 20:06:29 +0000 (20:06 +0000)]
Set SRF_RUNNING and SRF_ERROR together atomically in comedi_event().
Frank Mori Hess [Tue, 7 Aug 2007 19:04:01 +0000 (19:04 +0000)]
Ported allocation of mite dma rings to modern kernel dma api.
Frank Mori Hess [Tue, 7 Aug 2007 16:22:22 +0000 (16:22 +0000)]
Set missing SDF_LSAMPL on NI GPCT subdevices. Made command
test for gpct command actually check something. Made
some of the command sources for gpct command actually
have an effect.
Ian Abbott [Mon, 6 Aug 2007 11:19:19 +0000 (11:19 +0000)]
Corrected pathname in file header comment.
Ian Abbott [Mon, 6 Aug 2007 11:05:41 +0000 (11:05 +0000)]
Moved description of configuration options so it will appear in drivers.txt
Ian Abbott [Mon, 6 Aug 2007 10:47:40 +0000 (10:47 +0000)]
Stripped file extension from 'Driver:' line. Most had .o, some had .ko or .c.
Also corrected pathnames in file header comments.
Ian Abbott [Mon, 6 Aug 2007 10:07:16 +0000 (10:07 +0000)]
Changed description line.
Frank Mori Hess [Thu, 2 Aug 2007 14:06:36 +0000 (14:06 +0000)]
Got rid of use of $(builddir), since it isn't defined by some versions
of auto* tools. Tweaked some obscure rules (used some gnu make extensions,
but I don't really care).
Frank Mori Hess [Wed, 1 Aug 2007 19:46:36 +0000 (19:46 +0000)]
Autogenerated ChangeLog with "cvs2cl -t"
Frank Mori Hess [Wed, 1 Aug 2007 19:41:39 +0000 (19:41 +0000)]
Fix problems apparently caused by builddir not being set by older versions
of auto* tools.
Frank Mori Hess [Wed, 1 Aug 2007 19:10:52 +0000 (19:10 +0000)]
Fixed "make uninstall". "make distcheck" passes now.
Ian Abbott [Wed, 1 Aug 2007 17:33:37 +0000 (17:33 +0000)]
Removed third parameter of calls to comedi_event().
Frank Mori Hess [Wed, 1 Aug 2007 17:21:59 +0000 (17:21 +0000)]
Added some missing headers to distribution tarball, bumped version for
upcoming release.
Frank Mori Hess [Wed, 1 Aug 2007 17:19:51 +0000 (17:19 +0000)]
Have "make install" respect configure prefix.