#include "parallel_io.h"
#include "axis_pci.h"
Include dependency graph for parallel_io.c:

Functions | |
| void | FlushOutputsToDevice (struct axis_pci_device_entry *device) |
| Flush output mirrors out to hardware. | |
| void | init_parallel_io (struct axis_pci_device_entry *device) |
| Initalises AXIS parallel. | |
| void | enable_axis_inputs (struct axis_pci_device_entry *device) |
| Enables Axis inputs. | |
| void | enable_axis_outputs (struct axis_pci_device_entry *device) |
| Enables Axis outputs. | |
| void | update_inputs_bitmap (struct axis_pci_device_entry *device) |
| synchs the inputs mirror with physical hardware | |
| loff_t | axis_input_llseek (struct file *file_ptr, loff_t offset,int whence) |
| handles user lseek calls for input device. | |
| ssize_t | axis_input_read (struct file *file_ptr, char *buf, size_t count, loff_t *ppos) |
| Gets data from the inputs and returns it to userland. | |
| void | axis_dipswitch_update (struct axis_pci_device_entry *device) |
| Updates dipswitch mirror. | |
| ssize_t | axis_dipswitch_read (struct file *file_ptr, char *buf, size_t count, loff_t *ppos) |
| Gets data from the dipswitchs and returns it to userland. | |
| ssize_t | axis_input_write (struct file *file_ptr, const char *buf, size_t count, loff_t *ppos) |
| int | axis_input_ioctl (struct inode *inode_ptr, struct file *file_ptr, unsigned int type, unsigned long data) |
| Provides an interface to allow user land to control input processing. | |
| int | axis_input_open (struct inode *inode_ptr, struct file *file_ptr) |
| open function input device | |
| int | axis_input_release (struct inode *inode_ptr, struct file *file_ptr) |
| Called by kernel in response to a process closing input device. | |
| int | axis_dipswitch_open (struct inode *inode_ptr, struct file *file_ptr) |
| open function for dipswitches | |
| int | axis_dipswitch_release (struct inode *inode_ptr, struct file *file_ptr) |
| Called by kernel in response to a process closing a device. | |
| int | axis_input_fsync (struct file *file_ptr, struct dentry *directory, int datasync) |
| updates input mirror after user request | |
| loff_t | axis_output_llseek (struct file *file_ptr, loff_t offset,int whence) |
| handles user lseek calls for output device. | |
| ssize_t | axis_output_read (struct file *file_ptr, char *buf, size_t count, loff_t *ppos) |
| Returns current output state. | |
| ssize_t | axis_output_write (struct file *file_ptr, const char *buf, size_t count, loff_t *ppos) |
| Copies data from USER space and sends it to outputs. | |
| int | axis_output_ioctl (struct inode *inode_ptr, struct file *file_ptr, unsigned int type, unsigned long data) |
| Provides an interface to allow user land to output handling. | |
| int | axis_output_open (struct inode *inode_ptr, struct file *file_ptr) |
| open function for parallel output | |
| int | axis_output_release (struct inode *inode_ptr, struct file *file_ptr) |
| Called by kernel in response to a process closing a device. | |
| int | axis_output_fsync (struct file *file_ptr, struct dentry *directory, int datasync) |
| Forces outputs to be updated. | |
| void | bin_to_text (unsigned char *bin_start, char *text_start, off_t offset, int count, size_t buffer_size) |
| Given a pointer to a binary block creates a text string out off 1 and 0 to represent it. | |
| int | proc_read_inputs (char *buf, char **start, off_t offset, int count, int *eof, void *data) |
| /Proc read inputs callback function | |
| int | proc_read_dipswitches (char *buf, char **start, off_t offset, int count, int *eof, void *data) |
| /Proc read dipswitchs callback function | |
| int | proc_read_outputs (char *buf, char **start, off_t offset, int count, int *eof, void *data) |
| /Proc read output callback function | |
| int | proc_write_outputs (struct file *file, const char *buffer, unsigned long count, void *data) |
| Passed a text string converts it to a binary form and writes it to the outputs. | |
| int | proc_write_single_output (struct file *file, const char *buffer, unsigned long count, void *data) |
| Passed a text string converts it to a binary form and writes it to a specific single output. | |
| int | proc_read_single_input (char *buf, char **start, off_t offset, int count, int *eof, void *data) |
| /Proc read input callback function | |
| int | proc_read_single_dipswitch (char *buf, char **start, off_t offset, int count, int *eof, void *data) |
| /Proc read dipswitch callback function | |
| int | proc_read_single_output (char *buf, char **start, off_t offset, int count, int *eof, void *data) |
| /Proc read outputs callback function | |
| void | create_proc_input_entries (struct axis_pci_device_entry *device) |
| create /proc entries for inputs | |
| void | create_proc_output_entries (struct axis_pci_device_entry *device) |
| create /proc entries for outputs | |
| void | delete_proc_output_entries (struct axis_pci_device_entry *device) |
| Remove the /proc output entries. | |
| void | delete_proc_input_entries (struct axis_pci_device_entry *device) |
| Remove the /proc input entries. | |
| void | create_proc_dipswitch_entries (struct axis_pci_device_entry *device) |
| create /proc entries for dipswitches | |
| void | delete_proc_dipswitch_entries (struct axis_pci_device_entry *device) |
| Remove the /proc dipswitch entries. | |
Variables | |
| input_def | input_definitions [] |
| Associates a text string wil. | |
| output_def | output_definitions [] |
| file_operations | input_file_operations |
| file_operations | dipswitch_file_operations |
| file_operations | output_file_operations |
|
||||||||||||
|
open function for dipswitches
This open is called from the general open after its worked out what type of subdevice user space has requested Nothing to be done the default axis open sets everything up OK |
|
||||||||||||||||||||
|
Gets data from the dipswitchs and returns it to userland.
Called by kernel in response to a user application making a read call. Note the user buffer pointer is not a valid address from inside the kernel. Reads the dipswitchs values from the fpga and stores then in the bitswitch map associated with the PCI device structure Read inputs expands bit packed IO to byte aligned IO so to read the first 8 inputs read the first 8 bytes not the first one this should make locking and sharing simpler |
Here is the call graph for this function:

|
||||||||||||
|
Called by kernel in response to a process closing a device.
Called by kernel if user application closes device, nothing to do |
|
|
Updates dipswitch mirror.
Reads dipswitch hardware and updates mirror data |
|
||||||||||||||||
|
updates input mirror after user request
Allows user applications to force a clean input read |
Here is the call graph for this function:

|
||||||||||||||||||||
|
Provides an interface to allow user land to control input processing.
To allow user applications options other then read / write the driver supports IOCTL calls the type constants are defined in axis.h No ioctls defined so far |
|
||||||||||||||||
|
handles user lseek calls for input device.
Called by kernel in response to a user application making a llseek call. Resets the file_ptrs f_pos element to new position |
|
||||||||||||
|
open function input device
This open is called from the general open after its worked out what type of subdevice user space has requested Nothing to be done the default axis open sets everything up OK |
|
||||||||||||||||||||
|
Gets data from the inputs and returns it to userland.
Called by kernel in response to a user application making a read call. Note the user buffer pointer is not a valid address from inside the kernel. Read inputs expands bit packed IO to byte aligned IO so to read the first 8 inputs read the first 8 bytes not the first one this should make locking and sharing simpler |
Here is the call graph for this function:

|
||||||||||||
|
Called by kernel in response to a process closing input device.
Called by kernel if user application closes device, nothing to do |
|
||||||||||||||||||||
|
|
|
||||||||||||||||
|
Forces outputs to be updated.
Flushs parallel output buffers to device, callable from user space |
Here is the call graph for this function:

|
||||||||||||||||||||
|
Provides an interface to allow user land to output handling.
To allow user applications options other then read / write the driver support IOCTL calls the type constants are defined in axis.h Currently no IOCTLS defined for outputs |
|
||||||||||||||||
|
handles user lseek calls for output device.
Called by kernel in response to a user application making a llseek call. Resets the file_ptrs f_pos element to new position |
|
||||||||||||
|
open function for parallel output
This open is called from the general open after its worked out what type of subdevice user space has requested Nothing to be done the default axis open sets everything up OK |
|
||||||||||||||||||||
|
Returns current output state.
Reads the axis outputs, allows an application to see the current output state as a small complication we convert a hardware representation of one bit per output to a software one of one byte per output. This should give application programs effective random access to the outputs and reduce the chances of any nasty race conditions. |
|
||||||||||||
|
Called by kernel in response to a process closing a device.
Called by kernel if user application closes device, nothing to do |
|
||||||||||||||||||||
|
Copies data from USER space and sends it to outputs.
Writes parallel outputs to hardware. The hardware allocates one bit per output. However to reduce possible race conditions caused by multiple programs modifing seperate but physically close outputs the user interface sees one byte per output. All non zero values are assumed to represent a logic on. Called by the kernel in response to a write call by a user application. Note the buffer address supplied will not be a valid kernel address |
Here is the call graph for this function:

|
||||||||||||||||||||||||
|
Given a pointer to a binary block creates a text string out off 1 and 0 to represent it.
Given a pointer to a binary block creates a text string out off 1 and 0 to represent it |
|
|
create /proc entries for dipswitches
Called by the PCI probe function creates a directory full of inputs |
Here is the call graph for this function:

|
|
create /proc entries for inputs
Called by the PCI probe function creates a directory full of inputs |
Here is the call graph for this function:

|
|
create /proc entries for outputs
Called by the PCI probe function creates a directory full of outputs |
Here is the call graph for this function:

|
|
Remove the /proc dipswitch entries.
Removes the /proc dipswitch entries |
|
|
Remove the /proc input entries.
Delete all the input /proc entries called if PCI device removed (unlikely) or on module unload |
|
|
Remove the /proc output entries.
Remove all the entries in the /proc file system related to outputs |
|
|
Enables Axis inputs.
Enables Axis inputs |
|
|
Enables Axis outputs.
Enables Axis outputs |
|
|
Flush output mirrors out to hardware.
Flush output mirrors out to hardware and writes the outputs to the physical devices |
|
|
Initalises AXIS parallel.
Initalises AXIS parallel, called as PCI device is detected |
Here is the call graph for this function:

|
||||||||||||||||||||||||||||
|
/Proc read dipswitchs callback function
Read all the dipswitchs and output them as text. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
||||||||||||||||||||||||||||
|
/Proc read inputs callback function
Read all the inputs and output them as text. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
||||||||||||||||||||||||||||
|
/Proc read output callback function
Read all the outputs and output them as text. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
||||||||||||||||||||||||||||
|
/Proc read dipswitch callback function
Read an dipswitch input and output it as text. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
||||||||||||||||||||||||||||
|
/Proc read input callback function
Read a single input and output it as text. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
||||||||||||||||||||||||||||
|
/Proc read outputs callback function
Read an output and output its current state as text. A callback function passed to the /proc file syste, |
|
||||||||||||||||||||
|
Passed a text string converts it to a binary form and writes it to the outputs.
Passed a text string converts it to a binary form and writes it to the outputs. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
||||||||||||||||||||
|
Passed a text string converts it to a binary form and writes it to a specific single output.
Passed a text string converts it to a binary form and writes it to a specific single output. A callback function passed to the /proc file system |
Here is the call graph for this function:

|
|
synchs the inputs mirror with physical hardware
Reads the inputs temp version pending stage two inputs |
|
|
Initial value:
{
llseek: axis_input_llseek,
read: axis_dipswitch_read,
open: axis_dipswitch_open,
release: axis_dipswitch_release,
}
|
|
|
Associates a text string wil.
|
|
|
Initial value:
{
llseek: axis_input_llseek,
read: axis_input_read,
write: axis_input_write,
ioctl: axis_input_ioctl,
open: axis_input_open,
release: axis_input_release,
fsync: axis_input_fsync,
}
|
|
|
|
|
|
Initial value:
{
llseek: axis_output_llseek,
read: axis_output_read,
write: axis_output_write,
ioctl: axis_output_ioctl,
open: axis_output_open,
release: axis_output_release,
fsync: axis_output_fsync,
}
|
1.3.6