Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp1375475ybf; Sun, 1 Mar 2020 07:53:06 -0800 (PST) X-Google-Smtp-Source: APXvYqxXypXwuA+79kUECps7hq+4P5xFPPXvJgkDCOaJxcb0tAlSOycQq1sYvEamMJiRqx0EHwow X-Received: by 2002:a05:6830:1e64:: with SMTP id m4mr10668614otr.244.1583077986211; Sun, 01 Mar 2020 07:53:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583077986; cv=none; d=google.com; s=arc-20160816; b=oiEgPDkPUqAZI8UqWyPwSABgskxFO07hO+prUN5et/Iz0LQuNcIIAtp2PnzouwDD49 SA9W0YLX1GYqG8JxHM21YqXOK4xaFDUstuEsCXC1FW6oa3k27smimPjGcAvCkvOLngYh bSVCy+C9FDPpN7UQ8Pa2Exbio1WTtPj8Ic6GBEWjrvMnxwmdzcMGABKNVBcfteyX+jcR s7mTcOZOhqP/N1FuHW9gK0mIhJpaAJU+CBeXQ/EfMu1ir2t1SE9raVgT/5EERxfByQIB SSpDzMLRI0QY4cPM4vADPPVlbN5+FUn7oZNJ1X8emXm3gMgDAni9ZZpn0Hzf7p7COmzI PCXQ== 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=JfT3UHAhNKjRRmVkmMxZQeeE5WtwD4YLB+155ysu/2U=; b=GhT+BO/r2wE5HLWHrYHaewdnqY4ZE0F75vzoYn+5ElSquyDR6vHiQC7ipjdPiG13C8 PRkZy0fSt4c9xNM2iG6f9/smdvfzL9N82HNdjUgn6Xp26vRwKNWiVNQ/9oyocgRnOYn3 v5mgEnUtCBsl9a/i6T0r1DLX0MG+cWKeeCezfQ315yqkz8M9UkQhNa0o3vkW7qU5g3sJ fNxdd+MG+p0rtOFQ0KPaLAWGlFqhr+vGihK527DeFO3b1WmMG6JrBnZ9DIuao1pJk++w pKIs5Ds9xOyFR63x9VeDUJ3VL1wwy/8ubrpk9qpeK0wm4NthcX6NsXFwRhh2farOVTv9 NU3A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=keMmWRrD; 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 i8si4930223otp.254.2020.03.01.07.52.53; Sun, 01 Mar 2020 07:53:06 -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=keMmWRrD; 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 S1726621AbgCAPvv (ORCPT + 99 others); Sun, 1 Mar 2020 10:51:51 -0500 Received: from mail.kernel.org ([198.145.29.99]:35676 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725945AbgCAPvv (ORCPT ); Sun, 1 Mar 2020 10:51:51 -0500 Received: from archlinux (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (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 C4F9024677; Sun, 1 Mar 2020 15:51:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1583077910; bh=0ECRyP8P+2X0wVBMmme9Nxf2Jw6MqATtTdznUZ/M/gY=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=keMmWRrDdNZAgTEqGFo7Vy3pVDORPAH00Dx0GKWEhR/y/ZPoXARYdEfP0gUHKrKgF cY5PdprfxgIJbn8+Upd4TAwNDl0Xv00AQAQAeo7J4mFx3bLWfsyXSvcGVSdkIiFTOS r1XzXFr9fgWDlXqqgjaVUn7YB5QF086fT4q9aF+k= Date: Sun, 1 Mar 2020 15:51:43 +0000 From: Jonathan Cameron To: Sergiu Cuciurean Cc: , , , , , , , , , Subject: Re: [PATCH] iio: adc: ti-tlc4541: Use new structure for SPI transfer delays Message-ID: <20200301155143.538be150@archlinux> In-Reply-To: <20200227123427.20249-1-sergiu.cuciurean@analog.com> References: <20200227123427.20249-1-sergiu.cuciurean@analog.com> X-Mailer: Claws Mail 3.17.4 (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 Thu, 27 Feb 2020 14:34:27 +0200 Sergiu Cuciurean wrote: > In a recent change to the SPI subsystem [1], a new `delay` struct was added > to replace the `delay_usecs`. This change replaces the current > `delay_usecs` with `delay` for this driver. > > The `spi_transfer_delay_exec()` function [in the SPI framework] makes sure > that both `delay_usecs` & `delay` are used (in this order to preserve > backwards compatibility). > > [1] commit bebcfd272df6 ("spi: introduce `delay` field for > `spi_transfer` + spi_transfer_delay_exec()") > > Signed-off-by: Sergiu Cuciurean applied. Thanks, Jonathan > --- > drivers/iio/adc/ti-tlc4541.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/drivers/iio/adc/ti-tlc4541.c b/drivers/iio/adc/ti-tlc4541.c > index 4965246808bd..77620359b54c 100644 > --- a/drivers/iio/adc/ti-tlc4541.c > +++ b/drivers/iio/adc/ti-tlc4541.c > @@ -189,7 +189,8 @@ static int tlc4541_probe(struct spi_device *spi) > /* Setup default message */ > st->scan_single_xfer[0].rx_buf = &st->rx_buf[0]; > st->scan_single_xfer[0].len = 3; > - st->scan_single_xfer[1].delay_usecs = 3; > + st->scan_single_xfer[1].delay.value = 3; > + st->scan_single_xfer[1].delay.unit = SPI_DELAY_UNIT_NSECS; > st->scan_single_xfer[2].rx_buf = &st->rx_buf[0]; > st->scan_single_xfer[2].len = 2; >