Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1567159imu; Sun, 16 Dec 2018 03:58:29 -0800 (PST) X-Google-Smtp-Source: AFSGD/Up2MFBFJMf2jjP6HNUsnluNa+HN2GctpQmweSMcLdbxkFGNcECyXQ2HwNplcAI2wGzXxSn X-Received: by 2002:a65:6148:: with SMTP id o8mr8743838pgv.451.1544961509899; Sun, 16 Dec 2018 03:58:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544961509; cv=none; d=google.com; s=arc-20160816; b=krefLc+K7VHfJ7ejSv2S8BsBN//G7Eq3IspeB4MzJ+fHBtxYgh1q1XZKeljar+4/8o PUnKL8vAqEmbtGGkdTVY7KSQvUSujWwot0x8V5e+xt/lCs+6zOKmILIN4BvPiPotYZ/q VUrPzUYPYnbIDTWOdBaNGKreDQ8NAJV2X0MtGd/zJS7ZGdXPp7hAMbgK9M3YI3kyQSXR IOtFkgBtzsm+Ifbv7GQewPCyWT78Iy4glzBVZ6DJW1dT+dPD9eOG0Fzk16Ja3mveZ5e6 26c8g6pVt3tW17ivygByxnvf+EN2rg0/mhP0JukZLSYBsH5MnwUcnui94Kk8rZgD2uaR ziGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=pup8oXnRK5X585D9wczYgvNAg/clUv2xJ7920gAu+lk=; b=qSJIeBxrRN/8a4RV4sh7fH7bxJTkZcQHynDlZG4Zgx/MzJs3j79xl86EDugLAdBRWK t35mi+T62b/Hc4/e0s+TkDA7Izc9wkBAMGMgKjB4t4j86Bqmd2zK2zIZDhbg/BxFWE/6 f6OmZV8cjwzxHxoUHpUf9YQhBZ0ymtXdbR/a2ud6HGr8DlgWXU3xjAeXLUK7eyrIQ06u WjcpCab1FaeHKl1F/r1u+NfKNGGOTNXxWadLNXBgzIyBUjVObOlVH2vt2DWzmme9sLM3 SAEv2rYsYpTigPTMTwu5zqIf9c8Y1FcK8pS6JeWqNUx5Eb6HjoiBKJ6peyjkGK9ebFU2 XONg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=POcIgo1j; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k189si8305437pgd.589.2018.12.16.03.57.59; Sun, 16 Dec 2018 03:58:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=POcIgo1j; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730373AbeLPL4l (ORCPT + 99 others); Sun, 16 Dec 2018 06:56:41 -0500 Received: from mail.kernel.org ([198.145.29.99]:36922 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730066AbeLPL4k (ORCPT ); Sun, 16 Dec 2018 06:56:40 -0500 Received: from archlinux (cpc91196-cmbg18-2-0-cust659.5-4.cable.virginm.net [81.96.234.148]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 91BB8217FB; Sun, 16 Dec 2018 11:56:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1544961399; bh=wRo6MfWNWIVIeuJnIM/mBHk1CwnjH0efsZsYNtZTRqc=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=POcIgo1j9lku81lTxXwSREAzAc/Kdo/Q9vYfAsov48lPVACBKwFZltfFqtHtjfj0Y Ac6UhaW/sneYa2kqgCjc0Nmg0aAE6xJZm6c7zTJPUOP6oZje10DPpxtZUZRPtLdQwl UKIUd9JsTv+TA8L9YGll7YdI9Uc2mAxpo/z7Z2dk= Date: Sun, 16 Dec 2018 11:56:34 +0000 From: Jonathan Cameron To: Jeremy Fertic Cc: Lars-Peter Clausen , Michael Hennerich , Hartmut Knaack , Peter Meerwald-Stadler , Greg Kroah-Hartman , linux-iio@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 09/11] staging: iio: adt7316: remove dac vref buffer bypass from adt751x Message-ID: <20181216115634.2e75aa75@archlinux> In-Reply-To: <20181212005503.28054-10-jeremyfertic@gmail.com> References: <20181212005503.28054-1-jeremyfertic@gmail.com> <20181212005503.28054-10-jeremyfertic@gmail.com> X-Mailer: Claws Mail 3.17.2 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 11 Dec 2018 17:55:01 -0700 Jeremy Fertic wrote: > The option to allow the external vref to bypass the reference buffer is > only available for adt7316/7/8. Remove the attributes for adt751x as > well as the chip->id checks from the show and store functions. > > Signed-off-by: Jeremy Fertic Another good little cleanup, well separated from the other bits so applied to the togreg branch of iio.git and pushed out as testing for the autobuilders to play with it., Thanks, Jonathan > --- > drivers/staging/iio/addac/adt7316.c | 14 -------------- > 1 file changed, 14 deletions(-) > > diff --git a/drivers/staging/iio/addac/adt7316.c b/drivers/staging/iio/addac/adt7316.c > index 3348fdf08f2e..bca599d8c51c 100644 > --- a/drivers/staging/iio/addac/adt7316.c > +++ b/drivers/staging/iio/addac/adt7316.c > @@ -964,9 +964,6 @@ static ssize_t adt7316_show_DA_AB_Vref_bypass(struct device *dev, > struct iio_dev *dev_info = dev_to_iio_dev(dev); > struct adt7316_chip_info *chip = iio_priv(dev_info); > > - if ((chip->id & ID_FAMILY_MASK) == ID_ADT75XX) > - return -EPERM; > - > return sprintf(buf, "%d\n", > !!(chip->dac_config & ADT7316_VREF_BYPASS_DAC_AB)); > } > @@ -981,9 +978,6 @@ static ssize_t adt7316_store_DA_AB_Vref_bypass(struct device *dev, > u8 dac_config; > int ret; > > - if ((chip->id & ID_FAMILY_MASK) == ID_ADT75XX) > - return -EPERM; > - > dac_config = chip->dac_config & (~ADT7316_VREF_BYPASS_DAC_AB); > if (buf[0] == '1') > dac_config |= ADT7316_VREF_BYPASS_DAC_AB; > @@ -1009,9 +1003,6 @@ static ssize_t adt7316_show_DA_CD_Vref_bypass(struct device *dev, > struct iio_dev *dev_info = dev_to_iio_dev(dev); > struct adt7316_chip_info *chip = iio_priv(dev_info); > > - if ((chip->id & ID_FAMILY_MASK) == ID_ADT75XX) > - return -EPERM; > - > return sprintf(buf, "%d\n", > !!(chip->dac_config & ADT7316_VREF_BYPASS_DAC_CD)); > } > @@ -1026,9 +1017,6 @@ static ssize_t adt7316_store_DA_CD_Vref_bypass(struct device *dev, > u8 dac_config; > int ret; > > - if ((chip->id & ID_FAMILY_MASK) == ID_ADT75XX) > - return -EPERM; > - > dac_config = chip->dac_config & (~ADT7316_VREF_BYPASS_DAC_CD); > if (buf[0] == '1') > dac_config |= ADT7316_VREF_BYPASS_DAC_CD; > @@ -1713,8 +1701,6 @@ static struct attribute *adt7516_attributes[] = { > &iio_dev_attr_DAC_update_mode.dev_attr.attr, > &iio_dev_attr_all_DAC_update_modes.dev_attr.attr, > &iio_dev_attr_update_DAC.dev_attr.attr, > - &iio_dev_attr_DA_AB_Vref_bypass.dev_attr.attr, > - &iio_dev_attr_DA_CD_Vref_bypass.dev_attr.attr, > &iio_dev_attr_DAC_internal_Vref.dev_attr.attr, > &iio_dev_attr_VDD.dev_attr.attr, > &iio_dev_attr_in_temp.dev_attr.attr,