staging: comedi: 8253.h: tidy up the i8253_cascade_ns_to_timer*() users
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Thu, 26 Sep 2013 18:40:15 +0000 (11:40 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 26 Sep 2013 23:40:13 +0000 (16:40 -0700)
commitcb9cfd7ed3f6ed4c40167b4251cdb382b6b3ba1c
tree78aa9b8f1bd856b24b91e834580f3aa9531f703e
parentfa57560c5d4d58591dda2b160731eb4da3619016
staging: comedi: 8253.h: tidy up the i8253_cascade_ns_to_timer*() users

Introduce a couple defines for the common 8254 oscillator base values
used in the comedi drivers and remove the custom defines and open
coded values.

Change the i8253_cascade_ns_to_timer_2div() calls in the drivers to
the more generic i8253_cascade_ns_to_timer(). They are identical due
to the #define in the 8253.h header.

Remove the extra mask by TRIG_ROUND_MASK of the 'round_mode' parameter
to i8253_cascade_ns_to_timer(). That function already handles the mask.

Tidy up all the calls to i8253_cascade_ns_to_timer().

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
16 files changed:
drivers/staging/comedi/drivers/8253.h
drivers/staging/comedi/drivers/adl_pci9111.c
drivers/staging/comedi/drivers/adl_pci9118.c
drivers/staging/comedi/drivers/adv_pci1710.c
drivers/staging/comedi/drivers/amplc_pci224.c
drivers/staging/comedi/drivers/cb_das16_cs.c
drivers/staging/comedi/drivers/cb_pcidas.c
drivers/staging/comedi/drivers/das16.c
drivers/staging/comedi/drivers/das16m1.c
drivers/staging/comedi/drivers/das1800.c
drivers/staging/comedi/drivers/das800.c
drivers/staging/comedi/drivers/ni_labpc.c
drivers/staging/comedi/drivers/pcl711.c
drivers/staging/comedi/drivers/pcl812.c
drivers/staging/comedi/drivers/pcl816.c
drivers/staging/comedi/drivers/pcl818.c