From: H Hartley Sweeten Date: Tue, 11 Sep 2012 01:53:16 +0000 (-0700) Subject: staging: comedi: adl_pci9111: remove pci9111_ao_set_data macro X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=dc79022aefaba02ab85edf7df70cd35164888523;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git staging: comedi: adl_pci9111: remove pci9111_ao_set_data macro This macro relies on a local variable having a specific name. Signed-off-by: H Hartley Sweeten Cc: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/comedi/drivers/adl_pci9111.c b/drivers/staging/comedi/drivers/adl_pci9111.c index 477aa2ba0f82..7d1737a8b65c 100644 --- a/drivers/staging/comedi/drivers/adl_pci9111.c +++ b/drivers/staging/comedi/drivers/adl_pci9111.c @@ -119,7 +119,7 @@ TODO: #define PCI9111_REGISTER_AD_FIFO_VALUE 0x00 /* AD Data stored in FIFO */ -#define PCI9111_REGISTER_DA_OUTPUT 0x00 +#define PCI9111_AO_REG 0x00 #define PCI9111_DIO_REG 0x02 #define PCI9111_REGISTER_EXTENDED_IO_PORTS 0x04 #define PCI9111_REGISTER_AD_CHANNEL_CONTROL 0x06 /* Channel @@ -229,11 +229,6 @@ TODO: &PCI9111_HR_AI_RESOLUTION_MASK) \ ^ PCI9111_HR_AI_RESOLUTION_2_CMP_BIT) -#define pci9111_ao_set_data(data) \ - outw(data&PCI9111_AO_RESOLUTION_MASK, \ - dev->iobase + PCI9111_REGISTER_DA_OUTPUT) - - static const struct comedi_lrange pci9111_hr_ai_range = { 5, { @@ -1055,7 +1050,8 @@ pci9111_ao_insn_write(struct comedi_device *dev, int i; for (i = 0; i < insn->n; i++) { - pci9111_ao_set_data(data[i]); + outw(data[i] & PCI9111_AO_RESOLUTION_MASK, + dev->iobase + PCI9111_AO_REG); dev_private->ao_readback = data[i]; }