The Linux 2.4 Parallel Port Subsystem
Tim Waugh
twaugh@redhat.com
Copyright
© 1999-2000 by Tim Waugh
Table of Contents
Design goals
The problems
The solutions
Standard transfer modes
Structure
Sharing core
Parports and their overrides
IEEE 1284 transfer modes
Pardevices and parport_drivers
The IEEE 1284.3 API
Device driver's view
Port drivers
The printer driver
User-level device drivers
Introduction to ppdev
User-level or kernel-level driver?
Programming interface
Starting and stopping:
open
and
close
Control:
ioctl
Transferring data:
read
and
write
Waiting for events:
poll
and
select
Examples
Linux parallel port driver API reference
parport_device_num
-- convert device coordinates
parport_device_coords
-- convert canonical device number
parport_find_device
-- find a specific device
parport_find_class
-- find a device in a specified class
parport_register_driver
-- register a parallel port device driver
parport_unregister_driver
-- deregister a parallel port device driver
parport_get_port
-- increment a port's reference count
parport_put_port
-- decrement a port's reference count
parport_find_number
-- find a parallel port by number
parport_find_base
-- find a parallel port by base address
parport_register_device
-- register a device on a parallel port
parport_unregister_device
-- deregister a device on a parallel port
parport_open
-- find a device by canonical device number
parport_close
-- close a device opened with
parport_open
parport_claim
-- claim access to a parallel port device
parport_claim_or_block
-- claim access to a parallel port device
parport_release
-- give up access to a parallel port device
parport_yield
-- relinquish a parallel port temporarily
parport_yield_blocking
-- relinquish a parallel port temporarily
parport_negotiate
-- negotiate an IEEE 1284 mode
parport_write
-- write a block of data to a parallel port
parport_read
-- read a block of data from a parallel port
parport_set_timeout
-- set the inactivity timeout for a device
The Linux 2.2 Parallel Port Subsystem
GNU Free Documentation License
Next >>>
Design goals