mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-12 16:15:05 -04:00
staging: comedi: addi_apci_3120: move apci3120_addon_write() to driver
Move this function from the included source file to the main driver source file. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
4ba10fc04a
commit
0b7defa702
@@ -1,17 +1,3 @@
|
||||
static void apci3120_addon_write(struct comedi_device *dev,
|
||||
unsigned int val, unsigned int reg)
|
||||
{
|
||||
struct apci3120_private *devpriv = dev->private;
|
||||
|
||||
/* 16-bit interface for AMCC add-on registers */
|
||||
|
||||
outw(reg, devpriv->addon + APCI3120_ADDON_ADDR_REG);
|
||||
outw(val & 0xffff, devpriv->addon + APCI3120_ADDON_DATA_REG);
|
||||
|
||||
outw(reg + 2, devpriv->addon + APCI3120_ADDON_ADDR_REG);
|
||||
outw((val >> 16) & 0xffff, devpriv->addon + APCI3120_ADDON_DATA_REG);
|
||||
}
|
||||
|
||||
static int apci3120_cancel(struct comedi_device *dev,
|
||||
struct comedi_subdevice *s)
|
||||
{
|
||||
|
||||
@@ -163,6 +163,20 @@ struct apci3120_private {
|
||||
unsigned short ctrl;
|
||||
};
|
||||
|
||||
static void apci3120_addon_write(struct comedi_device *dev,
|
||||
unsigned int val, unsigned int reg)
|
||||
{
|
||||
struct apci3120_private *devpriv = dev->private;
|
||||
|
||||
/* 16-bit interface for AMCC add-on registers */
|
||||
|
||||
outw(reg, devpriv->addon + APCI3120_ADDON_ADDR_REG);
|
||||
outw(val & 0xffff, devpriv->addon + APCI3120_ADDON_DATA_REG);
|
||||
|
||||
outw(reg + 2, devpriv->addon + APCI3120_ADDON_ADDR_REG);
|
||||
outw((val >> 16) & 0xffff, devpriv->addon + APCI3120_ADDON_DATA_REG);
|
||||
}
|
||||
|
||||
/*
|
||||
* There are three timers on the board. They all use the same base
|
||||
* clock with a fixed prescaler for each timer. The base clock used
|
||||
|
||||
Reference in New Issue
Block a user