From d92d39d9bde805e7d237de534d8a7a3cc4b10ef1 Mon Sep 17 00:00:00 2001 From: H Hartley Sweeten Date: Mon, 23 Feb 2015 14:57:50 -0700 Subject: [PATCH] staging: comedi: me4000: convert driver to use the comedi_8254 module Some of the hardware supported by this driver include an 8254 timer. For aesthetics, convert it to use the comedi_8254 module to provide support for the 8254 timer. This also fixes the (*insn_read) and (*insn_write) to work like the comedi API expects. Currently they only read or write a single value. It also fixes the (*insn_config). Currently the driver is attempting to handle the configuration instructions GPCT_RESET and GPCT_SET_OPERATION. These are just arbitrary valuse and are not real comedi configuration_ids. They actually coorespond to: GPCT_RESET -> INSN_CONFIG_DIO_OUTPUT GPCT_SET_OPERATION -> INSN_CONFIG_ANALOG_TRIG The number of parameters for the instructions is validated by the comedi core in check_insn_config_length(). GPCT_RESET happens to work (insn->n == 1) but GPCT_SET_OPERATION would fail. The INSN_CONFIG_ANALOG_TRIG expects insn->n == 5 but GPCT_SET_OPERATION in this driver expects insn->n == 2. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-format-patch failed