From f70575805708cabdedea7498aaa3f710fde4d920 Mon Sep 17 00:00:00 2001 From: hc <hc@nodka.com> Date: Wed, 31 Jan 2024 03:29:01 +0000 Subject: [PATCH] add lvds1024*800 --- kernel/drivers/iio/dac/cio-dac.c | 15 +++------------ 1 files changed, 3 insertions(+), 12 deletions(-) diff --git a/kernel/drivers/iio/dac/cio-dac.c b/kernel/drivers/iio/dac/cio-dac.c index 6898b0c..77a6916 100644 --- a/kernel/drivers/iio/dac/cio-dac.c +++ b/kernel/drivers/iio/dac/cio-dac.c @@ -1,15 +1,7 @@ +// SPDX-License-Identifier: GPL-2.0-only /* * IIO driver for the Measurement Computing CIO-DAC * Copyright (C) 2016 William Breathitt Gray - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License, version 2, as - * published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. * * This driver supports the following Measurement Computing devices: CIO-DAC16, * CIO-DAC06, and PC104-DAC06. @@ -74,8 +66,8 @@ if (mask != IIO_CHAN_INFO_RAW) return -EINVAL; - /* DAC can only accept up to a 16-bit value */ - if ((unsigned int)val > 65535) + /* DAC can only accept up to a 12-bit value */ + if ((unsigned int)val > 4095) return -EINVAL; priv->chan_out_states[chan->channel] = val; @@ -118,7 +110,6 @@ indio_dev->channels = cio_dac_channels; indio_dev->num_channels = CIO_DAC_NUM_CHAN; indio_dev->name = dev_name(dev); - indio_dev->dev.parent = dev; priv = iio_priv(indio_dev); priv->base = base[id]; -- Gitblit v1.6.2