From d7b6c574d17fed09a0d9fa4bc7674c13fa156805 Mon Sep 17 00:00:00 2001 From: H Hartley Sweeten Date: Fri, 20 Jun 2014 13:13:02 -0700 Subject: [PATCH] staging: comedi: dt282x: automatically handle D/A data format The DT2821 series board have jumpers that set the output range for the two Analog Output channels. The range_table for the Analog Output subdevice provides all possible ranges to the user. When a unipolar range is selected the board expects the data to be in a straight binary format. When a bipolar range is select the data should be in two's complement format. Currently, the user passes some configuration options when attaching to the driver to select the data format for each channel. If the user does not pass the config options, the data format is assumed to be straight binary. The Analog Output subdevice now has a range_table that provides the user will all possible ranges. Use the range information to determine if the data values need to be munged into two's complememnt values and deprecate the config options. Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- Reading git-format-patch failed