- 04 5月, 2014 40 次提交
-
-
由 H Hartley Sweeten 提交于
This member of the private data is a copy of the cmd->scan_begin_arg. Use that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is a copy of the cmd->convert_arg. Use that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is a copy of the cmd->chanlist. Use that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is a copy of the cmd->scan_end_arg. Use that instead. Use a local variable in apci3120_cyclic_ai() for the DMA 'scan_bytes', which is the cmd->scan_end_arg * 2. Replace the open-coded '2' with sizeof(short). Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is a copy of the cmd->flags. Use that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data can be determined by checking the cmd->stop_src. Do that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data can be determined by checking the cmd->stop_src. Do that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data can be determined by checking the cmd->stop_src. Do that instead. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
Use a local variable for the comedi_cmd and tidy up this function a bit. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This step in the (*do_cmdtest) fixes the comedi_cmd arguments, usually for TRIG_TIMER sources. Tidy up this step to clarify the code and remove the extra local variables. All the arguments are unsigned long so change the 'tmp' local variable type and rename it for aesthetics. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
None of the comedi drivers use the i8253_cascade_ns_to_timer_2div_old() or i8253_cascade_ns_to_timer_power() helpers to calculate the cascaded divisors. Remove them to avoid any confusion. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
All of the comedi drivers use the i8253_cascade_ns_to_timer macro when calculating the divisors for the cascaded timers. This macro just causes the i8253_cascade_ns_to_timer_2div() inline to be used. Rename i8253_cascade_ns_to_timer_2div() and remove the macro. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
The analog input async command can use the pacer for the scan_begin_src or the convert_src. The (*do_cmdtest) calculates the divisors when validating the cmd argument. There is no reason to recalc the divisors in the (*do_cmd). Just use the values from the private data. For aesthetics, rename the setup_counters() function so it has namespace associated with the driver. Refactor the function to use the values from the private data and absorb das1800_set_frequency() to clarify the code. Refactor the function to use the i8254_set_mode() and i8254_write() helpers instead of i8254_load(). This allows us to use the I8254_* defines when setting the mode to clarify the code. This function will not fail so change the return type to void to simplify the (*do_cmd) a bit. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
Refactor this code to reduce the indent level and the > 80 char lines. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
The analog input async command can use the pacer for the convert_src. The (*do_cmdtest) calculates the divisors when validating the cmd argument. There is no reason to recalc the divisors in the (*do_cmd). Just use the values from the private data. Refactor das16m1_set_pacer() to use the i8254_set_mode() and i8254_write() helpers instead of i8254_load(). This allows us to use the I8254_* defines when setting the mode to clarify the code. Tidy up das16m1_cmd_exec() a bit. The pacer only needs to be set when the convert_src is TRIG_TIMER. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
The analog output async command can use the pacer for the scan_begin_src. The (*do_cmdtest) calculates the divisors when validating the cmd argument. There is no reason to recalc the divisors in the (*do_cmd). Just use the values from the private data. For aesthetics, factor out the code that loads the counters to match the analog input. Refactor the code to use the i8254_set_mode() and i8254_write() helpers instead of i8254_load(). This allows us to use the I8254_* defines when setting the mode to clarify the code. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
The analog input async command can use the pacer for the scan_bagin_src or the convert_src. The (*do_cmdtest) validates that only one of these sources has the TRIG_TIMER selected and calculates the divisors when validating the cmd argument. There is no reason to recalc the divisors in the (*do_cmd). Just use the values from the private data. Also, refactor cb_pcidas_load_counters() to use the i8254_set_mode() and i8254_write() helpers instead of i8254_load(). This allows us to use the I8254_* defines when setting the mode to clarify the code. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is not ued by the driver. Remove it. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is always set to I8254_OSC_BASE_10MHZ. Remove it from the private data and just open code the value. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This define enables code that checks for analog input channel dropout when reading samples. The define is enabled so we might as well always enable the code and remove the define. Factor out the common channel dropout detect code as a helper function and cleanup the code. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
For aesthetics, rename the helper functions that are called by the interrupt function to handle reading the analog input samples. Also, change the parameters to the helpers to the comedi_device and comedi_subdevice pointers. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
For aesthetics, rename this function so it has namespace associated with the driver. Change the parameters to the function. The 'mode' is really a flag to load the counters and the divisors can be found in the private data. To clarify the code and remove the magic numbers, use the 8253.h helpers to set the timer mode and load the counters. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
The local variable 'mode' is not necessary. We can determine the mode by checking the cmd->convert_src and cmd->start_src. Do this instead to clarify the code. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
When the cmd->convert_src == TRIG_TIMER the divisors needed to generate the pacer time are calculated in the (*do_cmdtest) to validate the cmd->convert_arg. The core always does the (*do_cmdtest) before the (*do_cmd) so there is no reason to recalc the divisors. Save the calculated divisors in the private data as 'next_divisor[12]'. The (*do_cmd) then transfers them to the private data 'divisor[12]' so that they can be used to set the timer for the command immediately or later when the cmd->start_src is TRIG_EXT (mode 2 in this driver). Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is is not necessary. We can just check the cmd->flags for TRIG_WAKE_EOS when needed. Remvoe the member. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is set to 0 but never used. Just remove it. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
This member of the private data is not necessary. We can determine if the analog input command is neverending by checking the cmd->stop_src: TRIG_COUNT -> !neverending_ai TRIG_NONE -> neverending_ai Do that instead and remove the unnecessary member. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
The chanlist is checked in Step 5 of the (*do_cmdtest) there is no reason to check it again in the (*do_cmd). The only reason its done again is to get the actual 'seglen', the non-repeating length of the chanlist. Save the 'seglen' found by pci171x_ai_check_chanlist() in the private data and use that in the (*do_cmd). Rename the private data member to clarify it. Also, remove the unused 'act_chanlist_pos' member from the private data. Refactor the error handling in pci171x_ai_check_chanlist() so it returns and errno for failure and 0 for success. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 H Hartley Sweeten 提交于
Tidy up this function to clarify what the chanlist is being checked for. Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Raghavendra Ganiga 提交于
This is a patch to fix coding style warnings found by checkpatch.pl tool Signed-off-by: NRaghavendra Chandra Ganiga <ravi23ganiga@gmail.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chase Southwood 提交于
This driver no longer reads the eeprom to find the board specific data, all the necessary data is in the boardinfo. Use the boardinfo directly instead of passing through devpriv->s_EeParameters. Signed-off-by: NChase Southwood <chase.southwood@gmail.com> Cc: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chase Southwood 提交于
The i_IorangeBase1, i_PCIEeprom, and pc_EepromChip data in the boardinfo was only needed to work out the usage of the PCI bars. Now that that is squared away, this info is no longer needed and can be removed. Signed-off-by: NChase Southwood <chase.southwood@gmail.com> Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chase Southwood 提交于
This driver only uses PCI bar 0 (devpriv->i_IobaseAmcc), and PCI bar 1 (dev->iobase), don't bother reading the unused PCI bars. Signed-off-by: NChase Southwood <chase.southwood@gmail.com> Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chase Southwood 提交于
This board always has 32 digital inputs. Remove the test when initializing the subdevice. Also, since this board is the only one supported by this driver, remove the boardinfo about the digital inputs and just use the data directly in the subdevice init. Signed-off-by: NChase Southwood <chase.southwood@gmail.com> Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chase Southwood 提交于
This include is no longer needed. Signed-off-by: NChase Southwood <chase.southwood@gmail.com> Cc: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Chase Southwood 提交于
Reading the eeprom on this board is not necessary. All information required is in the boardinfo. Remove the eeprom support code which is not really useful here. Signed-off-by: NChase Southwood <chase.southwood@gmail.com> Cc: Ian Abbott <abbotti@mev.co.uk> Reviewed-by: NH Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Christian Engelmayer 提交于
Some board pointer are assigned twice via comedi_board() in the comedi low level driver attach functions. Remove the duplicate assignment from the variable definition where the pointer is not used anyway until assigned later in the function when dev->board_ptr, that comedi_board() relies on, is setup correctly. Signed-off-by: NChristian Engelmayer <cengelma@gmx.at> Reviewed-by: NIan Abbott <abbotti@mev.co.uk> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Alan Cox 提交于
This is a bug fix that has been lurking in the Google tree but not pushed upstream. From: Octavian Purdila <octavian.purdila@intel.com> The memory region is already reserved in goldfish_init() during platform init. Signed-off-by: NOctavian Purdila <octavian.purdila@intel.com> Signed-off-by: NJun Tian <jun.j.tian@intel.com> Signed-off-by: NAlan Cox <alan@linux.intel.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Alan 提交于
The base code imported from the Google tree is ifdef heaven. Prepare to fix this by adding a helper function. Signed-off-by: NAlan Cox <alan@linux.intel.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-
由 Jun Tian 提交于
Enable the 64-bit nand data support in the goldfish nand driver. Signed-off-by: NJun Tian <jun.j.tian@intel.com> Signed-off-by: NOctavian Purdila <octavian.purdila@intel.com> Signed-off-by: NAlan Cox <alan@linux.intel.com> Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
-