From nobody Tue Oct 7 08:53:16 2025 Received: from mail-oi1-f176.google.com (mail-oi1-f176.google.com [209.85.167.176]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D8F1C29C35B for ; Thu, 10 Jul 2025 22:40:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.176 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187240; cv=none; b=LDyZoPF6czFsUkkZZaiAcf56bZiJFulGAXwaJyaj4fXCcbU1WZGsAmtoUNzBV9XJZfMafWnMTnB9RnX+FvQRDO3uaTN95hNQeb9ra2VBBk9FzY6ZOVVUZOVNpNSaVg2+/n/og3PQ8xqpSYqA0Z5GGWGCtOTewDHLenEWhteePyM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187240; c=relaxed/simple; bh=MaYXwOVhgpK5Xi5DZi0kiBPz0Bgrh0rRZus9pfeI4MU=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=S96Z62bsF1YkW24h6ol0P41f+qC9kJpnKu2EKo4rj7XNGE5wK+/pH9YBAoAa8kbxLLwmTAah2vDIChOJ2t75RRHc1y1o/6wnLOqZoZfSEVspXAa9fVaB+BDV0adGqrDxvlynuppfuSrsNprglfctgM5Fu9FqPIS8aonGVLLry/s= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=SD03mh7/; arc=none smtp.client-ip=209.85.167.176 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="SD03mh7/" Received: by mail-oi1-f176.google.com with SMTP id 5614622812f47-40ba3c10b3bso539422b6e.1 for ; Thu, 10 Jul 2025 15:40:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1752187237; x=1752792037; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=cn3FuFolIz/oVPrLKB9jwmwj/1LLi3bqA0GwWnqdwBs=; b=SD03mh7/YN5TeWOyUNkBhg8L6KPpmbnIsnPsXFCMIETGsbQ5eYuwEpVdUnGvNeKvfA m0VL+HVJeT6aktlf8z+EcEN/cHqL1dXm1CxOqidpyORWpPLQVbSbJN1uqjRylL1kptk1 Fi37/3q+/gZhdT08KcPwx4FNMtOT5MLaPQj3rKaHQqNYmmJ0RdzQ+7cnZ5WxKe6HiNY9 wX9XorbJGfoFjgFjoabjf6Spw1DNTc4njZvnhIxoX0/djbBHWdwRNA+HFYmfAfcLnEpK wfpGuTdzO5y6g/EPxHLjxngR3Q/2sop7LAoBgeHOZzFtsrqxzKbwuaHn7bmDmSwPa17U DspA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752187237; x=1752792037; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=cn3FuFolIz/oVPrLKB9jwmwj/1LLi3bqA0GwWnqdwBs=; b=IJ6V63Ry6x8qjKW5Zhl9Owpo14+JXVVqcQeJJgl25AtHiGEPLZ+rWNUWjzFcRmJ3Xr U39XbxfjVqAGyRtb9LfGesvHt6mqdNGlv8CydRfyDS3qZyU15qL4E0RtChnt8FdiEC7R sgGPhMl8gtsrFkDjpCh1tUnuBTb+KodSeo1wreJ/9y3bUm084UNFBJGQHskz2dTI8ngu XdH9YWL2FT5r9ZvINQc9Oy5g2gsQ43Qz83y2GKL7NMQ/LOMyR5ELjXGR3lwkPg8RvRkn Agc16EarlfdqKUa8j+hLUFvlxmszZpmnuKh7ZCT7FCzB3pemoa8m2UKaLGLkEdqdYII3 c5MQ== X-Forwarded-Encrypted: i=1; AJvYcCWt0pGIYtDLL3uf46g3OrO7qy5G+eZHEuNS6JWwQKnOgIKdoDNWy9oZ6PgUNUb/P8FaY0wtGMCWcEcbGTs=@vger.kernel.org X-Gm-Message-State: AOJu0YxSNTEUqDzulzNbI5H6MWZwA721lX3tfdAkx81CQGhh2S2ZCFnf NJFLXu3U0qMax7o8lOxSqDNDG1MVN319mbbG34qUi1sia2l9kvG6EvCHZuQMgoxN7Og= X-Gm-Gg: ASbGncuiaBY6YUKovuURitOUhc1cif6a/jB352hJyO8CsTit7MCeRyIBVeb55WGXdHZ eJ8/AYq6LAEC9KwmMQ1348zHIPzwh+41h1hmbYCrguBmG6yn86ZuSUOCUb2tBEmhcXRq4k2gr/Q hf9WcASVLHi97PZV8hy9bbIVL07FFD/copmt8ibhooxAGTGkNgtdFLwkGi0xcFk3+JBSer/wDwt La0fFDPCCKKzhW3HIc2rHJ4F3A/IgQuz+l0DULBTR7qcTPYXH/PkAo8RRLL4xpelutS51vFMjvD KTk1urRNudaVxyfjhfMF2cZW6jUyrb6GvltiW7Bg7rMD9IMIrxU9BiZvh7fy5E8H++7cPMDwDm+ jHt8hVF90FubI9zgABCELyzWfwg== X-Google-Smtp-Source: AGHT+IHYUQBd8GeQ+9Tb5ObCJT4XR2tTpt4gxlV5blMQaypp/KU5zeE7veLWTa1cVd6iC+qH7UKS5w== X-Received: by 2002:a05:6808:444b:b0:406:6fd3:ff14 with SMTP id 5614622812f47-4150f4bfee6mr1026731b6e.25.1752187236704; Thu, 10 Jul 2025 15:40:36 -0700 (PDT) Received: from [127.0.1.1] ([2600:8803:e7e4:1d00:891b:7836:c92:869]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-613d9d950f1sm305944eaf.18.2025.07.10.15.40.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Jul 2025 15:40:35 -0700 (PDT) From: David Lechner Date: Thu, 10 Jul 2025 17:39:50 -0500 Subject: [PATCH 1/5] iio: adc: ad7173: rename ad7173_chan_spec_ext_info Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250710-iio-adc-ad7137-add-filter-support-v1-1-acffe401c4d2@baylibre.com> References: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> In-Reply-To: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> To: Michael Hennerich , Jonathan Cameron , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, David Lechner X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1201; i=dlechner@baylibre.com; h=from:subject:message-id; bh=MaYXwOVhgpK5Xi5DZi0kiBPz0Bgrh0rRZus9pfeI4MU=; b=owEBbQGS/pANAwAKAcLMIAH/AY/AAcsmYgBocEE/eU1VlTlQKHR3pqsR26n9yqGb/IAQ3XTiT cAPJqfD+tCJATMEAAEKAB0WIQTsGNmeYg6D1pzYaJjCzCAB/wGPwAUCaHBBPwAKCRDCzCAB/wGP wA7WB/9l/qvw969ULrPF3r4bQGB5gCkZBseIzNoyb3Ug2CjJ4ugerY7zMKfWU7tj/ppD37ti27D u7azLTGeGyjiYjzFlKVxSpLAPScBoE2a8MXkXoQ+1TbLyeufImoccg0pxeGFRX+D/DjqrX3gS7s 36ZEWZ+j5Yt3506NfSSU6Ao7+yzKhlufkKTvsrVRNuR6dlO5yn0kwomQ9H7uFL10bHUPM+ZcVIf dIkYkiXEHySCMYE9bhLP28VYwNopnBX53OBJ0EatcRip0y8O7/gPO5Rio88HBNSipCmwEyhZgJL F8qxOUcZTpLOeRejMev/Bm/stOHkzTrm11E7z3lpKCUdmADA X-Developer-Key: i=dlechner@baylibre.com; a=openpgp; fpr=8A73D82A6A1F509907F373881F8AF88C82F77C03 Rename ad7173_calibsys_ext_info[] to ad7173_chan_spec_ext_info[]. This array is not limited to calibration attributes, so the name should be more generic. Signed-off-by: David Lechner Reviewed-by: Nuno S=C3=A1 --- drivers/iio/adc/ad7173.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/iio/adc/ad7173.c b/drivers/iio/adc/ad7173.c index ed5020167089ab96eb1927c9b1ae207e36f8b9e7..5daf21c6ba5637b2e47dcd052bd= d019c3ecbb442 100644 --- a/drivers/iio/adc/ad7173.c +++ b/drivers/iio/adc/ad7173.c @@ -369,7 +369,7 @@ static const struct iio_enum ad7173_syscalib_mode_enum = =3D { .get =3D ad7173_get_syscalib_mode }; =20 -static const struct iio_chan_spec_ext_info ad7173_calibsys_ext_info[] =3D { +static const struct iio_chan_spec_ext_info ad7173_chan_spec_ext_info[] =3D= { { .name =3D "sys_calibration", .write =3D ad7173_write_syscalib, @@ -1399,7 +1399,7 @@ static const struct iio_chan_spec ad7173_channel_temp= late =3D { .storagebits =3D 32, .endianness =3D IIO_BE, }, - .ext_info =3D ad7173_calibsys_ext_info, + .ext_info =3D ad7173_chan_spec_ext_info, }; =20 static const struct iio_chan_spec ad7173_temp_iio_channel_template =3D { --=20 2.43.0 From nobody Tue Oct 7 08:53:16 2025 Received: from mail-oi1-f177.google.com (mail-oi1-f177.google.com [209.85.167.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8DD662BD027 for ; Thu, 10 Jul 2025 22:40:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.177 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187240; cv=none; b=lMF3yRzcunkgPc2aqt/sVevmelqry9Rocx31TZeFJeN+g4bD+WCu4F61um83pbpB9EMMxJ/H4gXFJksR6kxaY1W36K1cU7c34G5ntciupwDCJG45mkThJwXBGOtTs8SpnbDrr85PXdV6N8AbNlM93w2X9Pv71F4mrMZDjtEpygg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187240; c=relaxed/simple; bh=Y4xxzpQMXT0tVAh0B+9LP1ypOj3L5Cj0Clka4wYTVnI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=kCDWag5Gfn0nhfL8TIilYb5XJxz4+zMXlc7ni1Uz7WHDNNboBHNa2Mze9IAESKtXlwwolHEgBXr2UZ5UWKkjYIAl79spjDEHSmyvxrdjy+37Mc2xtrvf7WH+aVzG2SrUz2uvifb2FBxfXl88ghG8uLZj56EBY371GytjnPRmW5U= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=A3o4uWvp; arc=none smtp.client-ip=209.85.167.177 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="A3o4uWvp" Received: by mail-oi1-f177.google.com with SMTP id 5614622812f47-40b99490728so1241789b6e.0 for ; Thu, 10 Jul 2025 15:40:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1752187237; x=1752792037; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=VIBjwMYnL74TcVrAH5e3IGRZZKgXqxeLaFBUWJ6E5yw=; b=A3o4uWvpwJbT7T61DXFECIZ2RvI/bz71hV+L7EfHspzSG4ickqRBcrzEwYv8yXDBkB d8Uda8sqcDcxeXxBE3gC2aQdqcpss0nkW4zIOvs5yR3GiYRNy2eVrgRVEkYJFgZuleCh xwFBeSrcMFRpNau3pmlUXVxuo7gT6fkot37bEY//dCLLJc865ZIEcDwnUV1njWDKmuw7 n26gCn8X8zq7JTw4viT8J4GoTuDw3u9rJRqqI8Jq03yETHB21BnNJh+ZRCR5xIeuNTX7 ea2VD5dLwFFZTKgpew5A2haz8422+XmFr6HqTTtRpfIC+d3D4iGzS5Ux7bETJorHWi1g A8eQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752187237; x=1752792037; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=VIBjwMYnL74TcVrAH5e3IGRZZKgXqxeLaFBUWJ6E5yw=; b=siSwMLYB46NKhm6sTGEH6cmOqmBqr6/bEfLbjIJ0B7kVhuWSoppv2/PRPjZsf+Ls4T ZdKAqFC2U1HivFfxmTUYf3yYrmnmNOB4ckTNxzarBd9U6h2KPt8CdI6TWuwtgR+bkJTe uAU6JmJXiv4TkuByrDcUz3ddn8Z8fSpVQj9xmTH6GqJPrayZyUIoc33yMdfN67OWqOsv gHnfOoQ7oOS4wAKcxQMhnb7HVsoFFfIAPHrLF2OUSznhRKoEw/xELaYG6OrWOZS+a/CM cBKFO5aw6CW1ncxXs7HfA6I6nICigjh6DsRV4HUgHUUTD6jdkPw8o3IQW0l3pyORjJGJ IRFw== X-Forwarded-Encrypted: i=1; AJvYcCUukbAIa2x3ZhwQRnEj463D/diyORBxa3/HK3WxiVCdm4/GVbwCa1NUAAPPh6XZdujLYvOEh2cH2FvRtoM=@vger.kernel.org X-Gm-Message-State: AOJu0YyHm0LYClzedONNUCmxvPUwa6m7Ux4li5aFV1vonVVX/CueQTZe Ne5AW/5dAgT+YE3a8uJGZ/T2htcgFJDNHfbY2KtRarvyGv01KGNTmCd3kp1SBycUfYI= X-Gm-Gg: ASbGnct4z4cxiptlE1jPNdFUOh2tUwKoVLROCt2g7eWNwYr7OHyOnda7aEmmbL1NGB/ ZxOA1EiSL8GAExXwNPG4x/56p8ohlrYF82luYkmpFXT4ulaSL6JCISwxywVat2C3+vSHcWe1BeB lLvsdxkml437+dBLtsmRtsvoN+c2A593yjbTAoKG2pizHzFeLyK1Q4QBVhnvfpWQLywMq+xKTEG tZo6WA547w506jSif/A29ZkNc1QuKjEyCrsJrQo962dW1dM7buIJSfd6iai/JV4KQ5v0JmO342i QoEeEBlW8UtuDMAOmxyP66RW15cOOVizWK36BIz9ksZz1HWKNEZXxLMpfwzKtt04YFPPNfqJF5P zZMVoGG7PWk1vKZxj7IysGNe44Q== X-Google-Smtp-Source: AGHT+IE0jBieUnW+rRGfWxll6L52XTUO/aByQNjjFVxiGHTKx/oAlmLkC6wro7rhwPBufH+QA4JFrQ== X-Received: by 2002:a05:6808:220f:b0:3f8:bbf3:3a18 with SMTP id 5614622812f47-413c4890f1cmr3917546b6e.16.1752187237575; Thu, 10 Jul 2025 15:40:37 -0700 (PDT) Received: from [127.0.1.1] ([2600:8803:e7e4:1d00:891b:7836:c92:869]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-613d9d950f1sm305944eaf.18.2025.07.10.15.40.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Jul 2025 15:40:37 -0700 (PDT) From: David Lechner Date: Thu, 10 Jul 2025 17:39:51 -0500 Subject: [PATCH 2/5] iio: adc: ad7173: rename odr field Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250710-iio-adc-ad7137-add-filter-support-v1-2-acffe401c4d2@baylibre.com> References: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> In-Reply-To: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> To: Michael Hennerich , Jonathan Cameron , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, David Lechner X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=3350; i=dlechner@baylibre.com; h=from:subject:message-id; bh=Y4xxzpQMXT0tVAh0B+9LP1ypOj3L5Cj0Clka4wYTVnI=; b=owEBbQGS/pANAwAKAcLMIAH/AY/AAcsmYgBocEFG9srtwbvcID06yiIQNe6pU879Zuxtnvmfy fKROwb7ExiJATMEAAEKAB0WIQTsGNmeYg6D1pzYaJjCzCAB/wGPwAUCaHBBRgAKCRDCzCAB/wGP wKeSB/9qDmJmuCanZotA2Zn3hgDWFta7IAV0s/RKiWUXnhfr/+xEEaT5j/eOllCOubgJuNeUxA2 HjnlYeRd0bZSEmzYuN9KVWZJ4dVvQbkiKsLae01JHtM2VgLmCaTAKlmgOOsl229QmdGhCYJcHYX h7U0bswENjIP8oj32wBm4jktVe40Pq1MpvoliTqjkhFybA+iWMz7wsQnwprfaFG9ebDFHrM79EV 8R2fs7RdinBMV1AWhKQF20AjJViCjeTcveF1TpbJS0ty3IUxNvxafYtL//kPH7smNkt0pSvLkPC KqPooEsnl5KELdG5WuhwRpcAngy/Q6nuR1hBUz6c4jqf2Imf X-Developer-Key: i=dlechner@baylibre.com; a=openpgp; fpr=8A73D82A6A1F509907F373881F8AF88C82F77C03 Rename odr to sinc5_odr_index in the channel setup structure. In a following commit, we will be adding a separate odr field for when the sinc3 filter is used instead so having sinc5 in the name will help avoid confusion. And _index makes it more clear that this is an index of the sinc5_data_rates array and not the output data rate itself. Signed-off-by: David Lechner Reviewed-by: Nuno S=C3=A1 --- drivers/iio/adc/ad7173.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/iio/adc/ad7173.c b/drivers/iio/adc/ad7173.c index 5daf21c6ba5637b2e47dcd052bdd019c3ecbb442..01d78d531d6c024dd92fff21b8b= 2afb750092b66 100644 --- a/drivers/iio/adc/ad7173.c +++ b/drivers/iio/adc/ad7173.c @@ -205,7 +205,7 @@ struct ad7173_channel_config { struct_group(config_props, bool bipolar; bool input_buf; - u8 odr; + u8 sinc5_odr_index; u8 ref_sel; ); }; @@ -582,13 +582,13 @@ static bool ad7173_setup_equal(const struct ad7173_ch= annel_config *cfg1, sizeof(struct { bool bipolar; bool input_buf; - u8 odr; + u8 sinc5_odr_index; u8 ref_sel; })); =20 return cfg1->bipolar =3D=3D cfg2->bipolar && cfg1->input_buf =3D=3D cfg2->input_buf && - cfg1->odr =3D=3D cfg2->odr && + cfg1->sinc5_odr_index =3D=3D cfg2->sinc5_odr_index && cfg1->ref_sel =3D=3D cfg2->ref_sel; } =20 @@ -650,7 +650,7 @@ static int ad7173_load_config(struct ad7173_state *st, return ret; =20 return ad_sd_write_reg(&st->sd, AD7173_REG_FILTER(free_cfg_slot), 2, - AD7173_FILTER_ODR0_MASK & cfg->odr); + AD7173_FILTER_ODR0_MASK & cfg->sinc5_odr_index); } =20 static int ad7173_config_channel(struct ad7173_state *st, int addr) @@ -1183,7 +1183,7 @@ static int ad7173_read_raw(struct iio_dev *indio_dev, return -EINVAL; } case IIO_CHAN_INFO_SAMP_FREQ: - reg =3D st->channels[chan->address].cfg.odr; + reg =3D st->channels[chan->address].cfg.sinc5_odr_index; =20 *val =3D st->info->sinc5_data_rates[reg] / MILLI; *val2 =3D (st->info->sinc5_data_rates[reg] % MILLI) * (MICRO / MILLI); @@ -1229,7 +1229,7 @@ static int ad7173_write_raw(struct iio_dev *indio_dev, break; =20 cfg =3D &st->channels[chan->address].cfg; - cfg->odr =3D i; + cfg->sinc5_odr_index =3D i; cfg->live =3D false; break; =20 @@ -1655,7 +1655,7 @@ static int ad7173_fw_parse_channel_config(struct iio_= dev *indio_dev) chan_st_priv->cfg.bipolar =3D false; chan_st_priv->cfg.input_buf =3D st->info->has_input_buf; chan_st_priv->cfg.ref_sel =3D AD7173_SETUP_REF_SEL_INT_REF; - chan_st_priv->cfg.odr =3D st->info->odr_start_value; + chan_st_priv->cfg.sinc5_odr_index =3D st->info->odr_start_value; chan_st_priv->cfg.openwire_comp_chan =3D -1; st->adc_mode |=3D AD7173_ADC_MODE_REF_EN; if (st->info->data_reg_only_16bit) @@ -1727,7 +1727,7 @@ static int ad7173_fw_parse_channel_config(struct iio_= dev *indio_dev) chan->scan_index =3D chan_index; chan->channel =3D ain[0]; chan_st_priv->cfg.input_buf =3D st->info->has_input_buf; - chan_st_priv->cfg.odr =3D st->info->odr_start_value; + chan_st_priv->cfg.sinc5_odr_index =3D st->info->odr_start_value; chan_st_priv->cfg.openwire_comp_chan =3D -1; =20 chan_st_priv->cfg.bipolar =3D fwnode_property_read_bool(child, "bipolar"= ); --=20 2.43.0 From nobody Tue Oct 7 08:53:16 2025 Received: from mail-oi1-f172.google.com (mail-oi1-f172.google.com [209.85.167.172]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5452A2BEC57 for ; Thu, 10 Jul 2025 22:40:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187242; cv=none; b=slb3n5w1wx2xkRxa48u5IygjCbcf0L8DsDWcNJiHdOTCJeEOtoVahGgjBQ2B1QBL/dlXpjZ+1JzEezK7y1URqK+6Op6yl5LWtJ+yio16CcTWIXxfLSuP3ds4cw6tMomYM4bL0uM8lQB/vowvCb6QekpCQHBAMz8Q6vRrnEQ2Z2o= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187242; c=relaxed/simple; bh=5bdT9u7+zUU/EH6ZF4Z6GM0stM6K3nQtPtLbsi1mVEc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=TRbqjSsGQGRy+EAiiE8+w1j8iShZkZlIulIIVlptvgBJ5R3s5M7KINnhSV0UEri8nzChHFx9Cu6kX+KFPY0WWfMu8USIy63P7ofe5l2C6hU6cWiS2B1uOXvMNazBA3AcNR1V37hIUgFEMmzgMHBL32LMfb8+0XUAq5nmwuR2LC8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=L60QcHz7; arc=none smtp.client-ip=209.85.167.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="L60QcHz7" Received: by mail-oi1-f172.google.com with SMTP id 5614622812f47-4067b7d7e52so520080b6e.2 for ; Thu, 10 Jul 2025 15:40:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1752187239; x=1752792039; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=uXgLk8W8QTkOU8+h291ODhZkOTvb9VZJA4vkKvX4D1M=; b=L60QcHz7S2TAh4C2kGz9gAfZW3TaU6Tu0d+hGMPaaLTgZnEWNrkHCXamLQHz3lnG1c WQ8bw5uqwToIPgiwlDFgcOBwrWGQPdgGi5u3QYgqjw8N9lG2WgXTLtldkujE/t2d4oBU P0EAfcIE2J9+i1LsClMh4LvrPfwTEoIdLK8/QWAvZpF3ZeiLLI2Sfwpw8YguxBZrAfkO DEL7lU7gf330aaN9fL5c2ht2H4m/Srp5QntlKSYPSc8fbSzxLTAyiCYodA8049uoQjeX 7GGe0kp1qJKMvI+bX4Mkp3xdEc8KKLM5DLtCKPxo5X7fZcEeOjVAQ+r3DNPBKWaWsdZf ZcMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752187239; x=1752792039; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=uXgLk8W8QTkOU8+h291ODhZkOTvb9VZJA4vkKvX4D1M=; b=M2xkJ2KgIexApVcs4R3S8HF46+oO6pWRBHCbeJvXC22rfS3Aqz+t8x/lj54cRPufV6 qU5FaXaXZAOSwToKE08f/fAJfKsvMfcC1ZYaQQLvJVZ4vh1/mgiV+36BylB3IOuCH/2j nD3BBIkrRRTB68or4nYrglLAKnzs8TwkEhWnDb74BQsrPpRLm7NpN9TvLAqyUkutbQPb CI04BRgVbZtBX9IluuS3c+tFWSXRhXnuwL20O2Z9qhG/jO3LTWyebmgkBJ1UAUPtUXio UHOMM6a39YUSFlfjZ69uTyiKX710y3ZG2//AnC6wAlBXzUO51cz0GiRNBySA2cGRYbWU 95Iw== X-Forwarded-Encrypted: i=1; AJvYcCUtAfq44OE8Yn7hg6VePSyjNacvGqFbRtuXwcHR8Ty3Q7ecifZcVnMuwb2hgp+P+SOHRvG7fq7UcB74fhU=@vger.kernel.org X-Gm-Message-State: AOJu0Yw+r9jroHS5SvHC4RFiI2wtPj7mjGP6TGA7NRhgnjmzrqt1+Jit O0jJ2iW1CVxUdM0ri+ZIIINxY3GDLOVjVMmenlcBWur57N8+CojbZovAre6oUqzZE9U= X-Gm-Gg: ASbGnctCGA1fTZpZh1MeUNOhhMbEFRXmufaoLGAakb1ELufP73riNZApRWGDsIqesxL Lz5cTxZMXQIyKWQREzfFn92lUv7V7gW+jyT8/lkA8HGOmvYr4oj5BzKoHYwxHBEqFSQtKEZvpW5 dA7gzmIfl35/YkRclGXnYrTeQ+uWrGn2p/qpq6BVnIBnhdodNtBM4Wh/7l7vz3DMcjsU47Y374V rEOoEM2HBwluhH1IAr2QOgEKBxuUsjq0vet1HL0jrpmYbhHRtCXHcW5KonmmpSLZzhnTUJ3kHTM gOvBMNIz7PaOCNrd4C8ZKeiwUisNnE7CqaGoFD0MHYb7mzv8JTUJ6wc1RDlFGbRf/QYA5y7VxEv 5EKOaDQKYIbCNzwMWYy5F25yDAw== X-Google-Smtp-Source: AGHT+IHYhu4aWzhKsn4ftUrzwF4SZl7WT973TrEde9Vj8ht1ehAqV895s4qxbk73e9QCS3fzjoYBGQ== X-Received: by 2002:a05:6808:1488:b0:401:e69a:8af2 with SMTP id 5614622812f47-4150d64551fmr998815b6e.5.1752187239420; Thu, 10 Jul 2025 15:40:39 -0700 (PDT) Received: from [127.0.1.1] ([2600:8803:e7e4:1d00:891b:7836:c92:869]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-613d9d950f1sm305944eaf.18.2025.07.10.15.40.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Jul 2025 15:40:39 -0700 (PDT) From: David Lechner Date: Thu, 10 Jul 2025 17:39:52 -0500 Subject: [PATCH 3/5] iio: adc: ad7173: support changing filter type Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250710-iio-adc-ad7137-add-filter-support-v1-3-acffe401c4d2@baylibre.com> References: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> In-Reply-To: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> To: Michael Hennerich , Jonathan Cameron , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, David Lechner X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=12379; i=dlechner@baylibre.com; h=from:subject:message-id; bh=5bdT9u7+zUU/EH6ZF4Z6GM0stM6K3nQtPtLbsi1mVEc=; b=owEBbQGS/pANAwAKAcLMIAH/AY/AAcsmYgBocEFNEAX+X26q7B+P90CYdxnJFaVynHrX8WZef eCuxPsl/lGJATMEAAEKAB0WIQTsGNmeYg6D1pzYaJjCzCAB/wGPwAUCaHBBTQAKCRDCzCAB/wGP wAXkCACPkbhXlM/+7ffkjgJVDI0J/aqHad7arJqrxpv2Rg/lGqcruNyKkAfczRARRIgTWeroYV+ wPptNLxip5O0NTWbw8h3S/pIKRiQh4WG1hmz7TlXcxIhj2meZ1QXC16sXDmvsgj6RyNuCjF3gha 99xSWVxmVLHzBGvPi7GI1tzorg7dKDMgyb83Xzfh0xG9MMppcHNeg4M7TK95KFC/PNJ/Pz2785N dR6dis3Q4Fc7+F9/Zz3MGR9wdkvN4oCHxoJU6RQ4be4OgkoA9Mws16wNwGgVPxbzSO70h3Mr42E zNtmACOHzH/XlZyJ88zouPimAxZ5gUIOqSWFZ01kXyZaaL7B X-Developer-Key: i=dlechner@baylibre.com; a=openpgp; fpr=8A73D82A6A1F509907F373881F8AF88C82F77C03 Add support for changing the filter type to the ad7173 driver. This family of chips by default uses a sinc5+sinc1 filter. There are also optional post-filters that can be added in this configuration for various 50/60Hz rejection purposes. The sinc3 filter doesn't have any post-filters and handles the output data rate (ODR) a bit differently. Here, we've opted to use SINC3_MAPx to get the maximum possible sampling frequencies with the SINC3 filter. Adding support consists of adding the filter_type and filter_type_available attributes, making the sampling_frequency attribute aware of the filter type, and programming the filter parameters when we configure the channel of the ADC for reading a sample. Signed-off-by: David Lechner Reviewed-by: Nuno S=C3=A1 --- drivers/iio/adc/ad7173.c | 186 +++++++++++++++++++++++++++++++++++++++++++= ++-- 1 file changed, 181 insertions(+), 5 deletions(-) diff --git a/drivers/iio/adc/ad7173.c b/drivers/iio/adc/ad7173.c index 01d78d531d6c024dd92fff21b8b2afb750092b66..c235096fbad4aeb77a7385001a1= 6bc0ecd603f46 100644 --- a/drivers/iio/adc/ad7173.c +++ b/drivers/iio/adc/ad7173.c @@ -8,6 +8,7 @@ * AD7175-8/AD7176-2/AD7177-2 * * Copyright (C) 2015, 2024 Analog Devices, Inc. + * Copyright (C) 2025 BayLibre, SAS */ =20 #include @@ -149,7 +150,12 @@ (pin2) < st->info->num_voltage_in && \ (pin2) >=3D st->info->num_voltage_in_div) =20 -#define AD7173_FILTER_ODR0_MASK GENMASK(5, 0) +#define AD7173_FILTER_SINC3_MAP BIT(15) +#define AD7173_FILTER_SINC3_MAP_DIV GENMASK(14, 0) +#define AD7173_FILTER_ENHFILTEN BIT(11) +#define AD7173_FILTER_ENHFILT_MASK GENMASK(10, 8) +#define AD7173_FILTER_ORDER BIT(6) +#define AD7173_FILTER_ODR_MASK GENMASK(5, 0) #define AD7173_MAX_CONFIGS 8 #define AD4111_OW_DET_THRSH_MV 300 =20 @@ -190,6 +196,15 @@ struct ad7173_device_info { u8 num_gpios; }; =20 +enum ad7173_filter_type { + AD7173_FILTER_SINC3, + AD7173_FILTER_SINC5_SINC1, + AD7173_FILTER_SINC5_SINC1_PF1, + AD7173_FILTER_SINC5_SINC1_PF2, + AD7173_FILTER_SINC5_SINC1_PF3, + AD7173_FILTER_SINC5_SINC1_PF4, +}; + struct ad7173_channel_config { /* Openwire detection threshold */ unsigned int openwire_thrsh_raw; @@ -205,8 +220,10 @@ struct ad7173_channel_config { struct_group(config_props, bool bipolar; bool input_buf; + u16 sinc3_ord_div; u8 sinc5_odr_index; u8 ref_sel; + enum ad7173_filter_type filter_type; ); }; =20 @@ -266,6 +283,24 @@ static const unsigned int ad7175_sinc5_data_rates[] = =3D { 5000, /* 20 */ }; =20 +/** + * ad7173_sinc3_ord_div_from_odr() - Convert ODR to divider value + * @odr_millihz: ODR (sampling_frequency) in milliHz + * Returns: Divider value for SINC3 filter to pass. + */ +static u16 ad7173_sinc3_ord_div_from_odr(u32 odr_millihz) +{ + /* + * Divider is f_MOD (1 MHz) / 32 / ODR. ODR freq is in milliHz, so + * we need to convert f_MOD to the same units. When SING_CYC=3D1 or + * multiple channels are enabled (currently always the case), there + * is an additional factor of 3. + */ + u32 div =3D DIV_ROUND_CLOSEST(MEGA * MILLI, odr_millihz * 32 * 3); + /* Avoid divide by 0 and limit to register field size. */ + return clamp(div, 1U, AD7173_FILTER_SINC3_MAP_DIV); +} + static unsigned int ad4111_current_channel_config[] =3D { /* Ain sel: pos neg */ 0x1E8, /* 15:IIN0+ 8:IIN0=E2=88=92 */ @@ -369,6 +404,47 @@ static const struct iio_enum ad7173_syscalib_mode_enum= =3D { .get =3D ad7173_get_syscalib_mode }; =20 +static const char * const ad7173_filter_types_str[] =3D { + [AD7173_FILTER_SINC3] =3D "sinc3", + [AD7173_FILTER_SINC5_SINC1] =3D "sinc5+sinc1", + [AD7173_FILTER_SINC5_SINC1_PF1] =3D "sinc5+sinc1+pf1", + [AD7173_FILTER_SINC5_SINC1_PF2] =3D "sinc5+sinc1+pf2", + [AD7173_FILTER_SINC5_SINC1_PF3] =3D "sinc5+sinc1+pf3", + [AD7173_FILTER_SINC5_SINC1_PF4] =3D "sinc5+sinc1+pf4", +}; + +static int ad7173_set_filter_type(struct iio_dev *indio_dev, + const struct iio_chan_spec *chan, + unsigned int val) +{ + struct ad7173_state *st =3D iio_priv(indio_dev); + + if (!iio_device_claim_direct(indio_dev)) + return -EBUSY; + + st->channels[chan->address].cfg.filter_type =3D val; + st->channels[chan->address].cfg.live =3D false; + + iio_device_release_direct(indio_dev); + + return 0; +} + +static int ad7173_get_filter_type(struct iio_dev *indio_dev, + const struct iio_chan_spec *chan) +{ + struct ad7173_state *st =3D iio_priv(indio_dev); + + return st->channels[chan->address].cfg.filter_type; +} + +static const struct iio_enum ad7173_filter_type_enum =3D { + .items =3D ad7173_filter_types_str, + .num_items =3D ARRAY_SIZE(ad7173_filter_types_str), + .set =3D ad7173_set_filter_type, + .get =3D ad7173_get_filter_type, +}; + static const struct iio_chan_spec_ext_info ad7173_chan_spec_ext_info[] =3D= { { .name =3D "sys_calibration", @@ -379,6 +455,16 @@ static const struct iio_chan_spec_ext_info ad7173_chan= _spec_ext_info[] =3D { &ad7173_syscalib_mode_enum), IIO_ENUM_AVAILABLE("sys_calibration_mode", IIO_SHARED_BY_TYPE, &ad7173_syscalib_mode_enum), + IIO_ENUM("filter_type", IIO_SEPARATE, &ad7173_filter_type_enum), + IIO_ENUM_AVAILABLE("filter_type", IIO_SHARED_BY_TYPE, + &ad7173_filter_type_enum), + { } +}; + +static const struct iio_chan_spec_ext_info ad7173_temp_chan_spec_ext_info[= ] =3D { + IIO_ENUM("filter_type", IIO_SEPARATE, &ad7173_filter_type_enum), + IIO_ENUM_AVAILABLE("filter_type", IIO_SHARED_BY_TYPE, + &ad7173_filter_type_enum), { } }; =20 @@ -582,14 +668,18 @@ static bool ad7173_setup_equal(const struct ad7173_ch= annel_config *cfg1, sizeof(struct { bool bipolar; bool input_buf; + u16 sinc3_ord_div; u8 sinc5_odr_index; u8 ref_sel; + enum ad7173_filter_type filter_type; })); =20 return cfg1->bipolar =3D=3D cfg2->bipolar && cfg1->input_buf =3D=3D cfg2->input_buf && + cfg1->sinc3_ord_div =3D=3D cfg2->sinc3_ord_div && cfg1->sinc5_odr_index =3D=3D cfg2->sinc5_odr_index && - cfg1->ref_sel =3D=3D cfg2->ref_sel; + cfg1->ref_sel =3D=3D cfg2->ref_sel && + cfg1->filter_type =3D=3D cfg2->filter_type; } =20 static struct ad7173_channel_config * @@ -630,6 +720,7 @@ static int ad7173_load_config(struct ad7173_state *st, { unsigned int config; int free_cfg_slot, ret; + u8 post_filter_enable, post_filter_select; =20 free_cfg_slot =3D ida_alloc_range(&st->cfg_slots_status, 0, st->info->num_configs - 1, GFP_KERNEL); @@ -649,8 +740,49 @@ static int ad7173_load_config(struct ad7173_state *st, if (ret) return ret; =20 + /* + * When SINC3_MAP flag is enabled, the rest of the register has a + * different meaning. We are using this option to allow the most + * possible sampling frequencies with SINC3 filter. + */ + if (cfg->filter_type =3D=3D AD7173_FILTER_SINC3) + return ad_sd_write_reg(&st->sd, AD7173_REG_FILTER(free_cfg_slot), 2, + FIELD_PREP(AD7173_FILTER_SINC3_MAP, 1) | + FIELD_PREP(AD7173_FILTER_SINC3_MAP_DIV, + cfg->sinc3_ord_div)); + + switch (cfg->filter_type) { + case AD7173_FILTER_SINC5_SINC1_PF1: + post_filter_enable =3D 1; + post_filter_select =3D 2; + break; + case AD7173_FILTER_SINC5_SINC1_PF2: + post_filter_enable =3D 1; + post_filter_select =3D 3; + break; + case AD7173_FILTER_SINC5_SINC1_PF3: + post_filter_enable =3D 1; + post_filter_select =3D 5; + break; + case AD7173_FILTER_SINC5_SINC1_PF4: + post_filter_enable =3D 1; + post_filter_select =3D 6; + break; + default: + post_filter_enable =3D 0; + post_filter_select =3D 0; + break; + } + return ad_sd_write_reg(&st->sd, AD7173_REG_FILTER(free_cfg_slot), 2, - AD7173_FILTER_ODR0_MASK & cfg->sinc5_odr_index); + FIELD_PREP(AD7173_FILTER_SINC3_MAP, 0) | + FIELD_PREP(AD7173_FILTER_ENHFILT_MASK, + post_filter_enable) | + FIELD_PREP(AD7173_FILTER_ENHFILTEN, + post_filter_select) | + FIELD_PREP(AD7173_FILTER_ORDER, 0) | + FIELD_PREP(AD7173_FILTER_ODR_MASK, + cfg->sinc5_odr_index)); } =20 static int ad7173_config_channel(struct ad7173_state *st, int addr) @@ -1183,6 +1315,13 @@ static int ad7173_read_raw(struct iio_dev *indio_dev, return -EINVAL; } case IIO_CHAN_INFO_SAMP_FREQ: + if (st->channels[chan->address].cfg.filter_type =3D=3D AD7173_FILTER_SIN= C3) { + /* Inverse operation of ad7173_sinc3_ord_div_from_odr() */ + *val =3D MEGA; + *val2 =3D 3 * 32 * st->channels[chan->address].cfg.sinc3_ord_div; + return IIO_VAL_FRACTIONAL; + } + reg =3D st->channels[chan->address].cfg.sinc5_odr_index; =20 *val =3D st->info->sinc5_data_rates[reg] / MILLI; @@ -1221,6 +1360,10 @@ static int ad7173_write_raw(struct iio_dev *indio_de= v, * * This will cause the reading of CH1 to be actually done once every * 200.16ms, an effective rate of 4.99sps. + * + * Both the sinc5 and sinc3 rates are set here so that if the filter + * type is changed, the requested rate will still be set (aside from + * rounding differences). */ case IIO_CHAN_INFO_SAMP_FREQ: freq =3D val * MILLI + val2 / MILLI; @@ -1230,6 +1373,7 @@ static int ad7173_write_raw(struct iio_dev *indio_dev, =20 cfg =3D &st->channels[chan->address].cfg; cfg->sinc5_odr_index =3D i; + cfg->sinc3_ord_div =3D ad7173_sinc3_ord_div_from_odr(freq); cfg->live =3D false; break; =20 @@ -1246,17 +1390,40 @@ static int ad7173_update_scan_mode(struct iio_dev *= indio_dev, const unsigned long *scan_mask) { struct ad7173_state *st =3D iio_priv(indio_dev); + u16 sinc3_count =3D 0; + u16 sinc3_div =3D 0; int i, j, k, ret; =20 for (i =3D 0; i < indio_dev->num_channels; i++) { - if (test_bit(i, scan_mask)) + const struct ad7173_channel_config *cfg =3D &st->channels[i].cfg; + + if (test_bit(i, scan_mask)) { + if (cfg->filter_type =3D=3D AD7173_FILTER_SINC3) { + sinc3_count++; + + if (sinc3_div =3D=3D 0) { + sinc3_div =3D cfg->sinc3_ord_div; + } else if (sinc3_div !=3D cfg->sinc3_ord_div) { + dev_err(&st->sd.spi->dev, + "All enabled channels must have the same sampling_frequency for sinc= 3 filter_type\n"); + return -EINVAL; + } + } + ret =3D ad7173_set_channel(&st->sd, i); - else + } else { ret =3D ad_sd_write_reg(&st->sd, AD7173_REG_CH(i), 2, 0); + } if (ret < 0) return ret; } =20 + if (sinc3_count && sinc3_count < bitmap_weight(scan_mask, indio_dev->num_= channels)) { + dev_err(&st->sd.spi->dev, + "All enabled channels must have sinc3 filter_type\n"); + return -EINVAL; + } + /* * On some chips, there are more channels that setups, so if there were * more unique setups requested than the number of available slots, @@ -1415,6 +1582,7 @@ static const struct iio_chan_spec ad7173_temp_iio_cha= nnel_template =3D { .storagebits =3D 32, .endianness =3D IIO_BE, }, + .ext_info =3D ad7173_temp_chan_spec_ext_info, }; =20 static void ad7173_disable_regulators(void *data) @@ -1655,7 +1823,11 @@ static int ad7173_fw_parse_channel_config(struct iio= _dev *indio_dev) chan_st_priv->cfg.bipolar =3D false; chan_st_priv->cfg.input_buf =3D st->info->has_input_buf; chan_st_priv->cfg.ref_sel =3D AD7173_SETUP_REF_SEL_INT_REF; + chan_st_priv->cfg.sinc3_ord_div =3D ad7173_sinc3_ord_div_from_odr( + st->info->sinc5_data_rates[st->info->odr_start_value] + ); chan_st_priv->cfg.sinc5_odr_index =3D st->info->odr_start_value; + chan_st_priv->cfg.filter_type =3D AD7173_FILTER_SINC5_SINC1; chan_st_priv->cfg.openwire_comp_chan =3D -1; st->adc_mode |=3D AD7173_ADC_MODE_REF_EN; if (st->info->data_reg_only_16bit) @@ -1727,7 +1899,11 @@ static int ad7173_fw_parse_channel_config(struct iio= _dev *indio_dev) chan->scan_index =3D chan_index; chan->channel =3D ain[0]; chan_st_priv->cfg.input_buf =3D st->info->has_input_buf; + chan_st_priv->cfg.sinc3_ord_div =3D ad7173_sinc3_ord_div_from_odr( + st->info->sinc5_data_rates[st->info->odr_start_value] + ); chan_st_priv->cfg.sinc5_odr_index =3D st->info->odr_start_value; + chan_st_priv->cfg.filter_type =3D AD7173_FILTER_SINC5_SINC1; chan_st_priv->cfg.openwire_comp_chan =3D -1; =20 chan_st_priv->cfg.bipolar =3D fwnode_property_read_bool(child, "bipolar"= ); --=20 2.43.0 From nobody Tue Oct 7 08:53:16 2025 Received: from mail-oi1-f180.google.com (mail-oi1-f180.google.com [209.85.167.180]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 192BC2BFC65 for ; Thu, 10 Jul 2025 22:40:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.180 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187242; cv=none; b=GTIeLLcf0+WqHufXaXnHftk837GxRMnOLwYsp+vKnLWVDpWjIJ4ptNCtEWnBTy9f2rJlL0+qLPTadwgbylsFf7NYqRENZVqCrTPBq9cmpYXaE8oqh+YowAZHW3NbOSZSJYsdFtmiOm/ASlpXfHGK9ffv/4mUQ2iSrMoazVOrV+w= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187242; c=relaxed/simple; bh=IJZKvY6FBhurwS1AU0uzFel1FJe911tg+2DmrcpgsRc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=cIn0O7MF59aEkGBuRAlW5wEr6LLn192DebdL/EfQK8wYhIyhl4935tG8CU58Nsw5xwjWv1rqt7Hhjn+O/cXiVADobLKFHy7csVd9ZmH/bcrLj8r2sAzYLnkt4Pj1vd6Lx+L4iFct60MUjnahjiybZgHVqQo6uCqdKrPeJWtbnVc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=lygnHjyB; arc=none smtp.client-ip=209.85.167.180 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="lygnHjyB" Received: by mail-oi1-f180.google.com with SMTP id 5614622812f47-407aaace4daso613798b6e.2 for ; Thu, 10 Jul 2025 15:40:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1752187240; x=1752792040; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=om7b5uZ8WHk1bPibPL7QZXk7ri+VTy/kb134tH/V9wI=; b=lygnHjyBosaBs9UF3etlMLBnr4/doZmaAqU7/cfJlqxj0RHBXJ0+bf5DMfu30rVJpu J1ykBcaygpMDsFWYKeOFgeJwYRyG4qLjTvtZWo1pyK9hUF1zS2QX7d3N1sJi410TE9PF /8sZ16b6td8FRMsJZbCN+W4i3pMg3EzWpTOH+oq8iFvXhN51VfvGtLromyj2tSuBTLqt hoAnY8M3nyh2sdr9hqTQlzn4YpM3sfIA3m459PDqAaSH/8T8tP/c/JBZv83bFqfYHeVH 6zAx9ZUPRvjHg/Hb8PvzqivKIpCWFxk8KG0pUfFOhKySWRoJXJNxg1HNhynQoLA4SNbh 4LPg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752187240; x=1752792040; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=om7b5uZ8WHk1bPibPL7QZXk7ri+VTy/kb134tH/V9wI=; b=EvqqNznH9nkcE/tT3zVaBzYF55pgKpZAsMWcJZ5QIQWtVH6T86LV833m0csWKvcL1V sldM4ISbtzKqD9QuzrdR5gOurrhfTMRmwDf7O3b6vHfUXk6T2Y7mdnDjY+UzdclIcSQ8 3T41laV0snjdJQjF1BpnmAXVTd6fbNr4UlNAM+dhLBTTxOClr7k2bnzDiqT/n89DI8oh dRoLzOQa7dAVsIIeniC3f9lDTk6zG9B8THrXH+WUSPM6SyPomYjvPE+wRVKMPNN4opnx YIKJQLoe3YrBGq8wIqEWS/RO8l8FqzppZYowLR2AAkKgWZkfAXyD333vfrCLNdJKpx1U L8sw== X-Forwarded-Encrypted: i=1; AJvYcCWmTlMbjNNJwDLq17aCjjhf76zV/LRUUH6noSPhLvH/VZ9eq2QFddfQTHuLtlFJP+/vHljyNXhZB/0nt5w=@vger.kernel.org X-Gm-Message-State: AOJu0YyQIIhUTJV6Ropg06DURVqZ4YV8fZM+qjx6FgwSx7Ac+8q8PEGg ME7+xizqfM+hrDXBXBcSeX6uKqGVCUAlaJr45OMRZ4BilyUuUDrzKfJgARwIAYuE9D5p6D5bgnQ TyAWcspw= X-Gm-Gg: ASbGnctEkDKp4WizOa0tg+fbpm7Csw7HwfSaeuF7lK5nAhbp69HhtHUxXop502n1DTS h80Xfc+qmGcZ0Yzf9oLN9n+9PP7aVSKplF2NI5IVflqMST9v15aT7v6MWekl7E7KLtEW+2fDyvv d9kBvAY/mEi+YzHkLIPwRWA0yGTRZqN5oKfn/n282s7QJbtG5MNT7vqLXl9J3dzCuupHxdUAqCW Q0D5CBGeOpRCitZtWtSNNDMHlJJOKGN4+TgVYjqgkEpCfzcVQsMV+KMlJOxxf2kl8j0dWNFKfHT bdxPUlCyasQ9lcgiFpltK5ab6aFVUnwi93zjCPFbYhfBBihF5zZL8MXEzijAipw20t1rEG6U8II FVLbcLzZuQGPwpJL1K2GBVl+RSA== X-Google-Smtp-Source: AGHT+IGV6HBrFWz+tHpNptE5u87WlNfv9fSRMeLEg9obnOkAgSX/3KrF2tqOFqyPzQt7UV8Nk5GuIQ== X-Received: by 2002:a05:6808:3006:b0:403:3c95:3684 with SMTP id 5614622812f47-41537566dd0mr443537b6e.1.1752187240141; Thu, 10 Jul 2025 15:40:40 -0700 (PDT) Received: from [127.0.1.1] ([2600:8803:e7e4:1d00:891b:7836:c92:869]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-613d9d950f1sm305944eaf.18.2025.07.10.15.40.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Jul 2025 15:40:39 -0700 (PDT) From: David Lechner Date: Thu, 10 Jul 2025 17:39:53 -0500 Subject: [PATCH 4/5] iio: ABI: alphabetize filter types Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250710-iio-adc-ad7137-add-filter-support-v1-4-acffe401c4d2@baylibre.com> References: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> In-Reply-To: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> To: Michael Hennerich , Jonathan Cameron , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, David Lechner X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=2034; i=dlechner@baylibre.com; h=from:subject:message-id; bh=IJZKvY6FBhurwS1AU0uzFel1FJe911tg+2DmrcpgsRc=; b=owEBbQGS/pANAwAKAcLMIAH/AY/AAcsmYgBocEFTOhSmUKEQ9LoHSdk245HzX8F7z5dzSMUAS l/m2GBOQsSJATMEAAEKAB0WIQTsGNmeYg6D1pzYaJjCzCAB/wGPwAUCaHBBUwAKCRDCzCAB/wGP wCVdB/98NLFD/0vupVh2gFzCrWI+k0DI8fsPAQGcjrM4TjOUsyuqZ/7b3wZI6JNZ3S2/0iVzo4b S9HVqWHcFUrYK1/qJXVtMIhd6zwF0NyTA67D+AHAScySjRPoJQGIWw0vvpgUu0v1fxwSiMMKPiN 63Ic1g8UPXEwKVhguxYlq1wdd2ueXdpwP89Hcmn8mzXIYmcUns/Kn9xmL8TcQFoqdWOGxIVfCfE vu22WpJ++7+uhepGjRPev6CY523rhsBWlSLHGYH2TnmxaNg1guUpphnEiflTr3SD5v8GJh56iOW E2LbG/lT5GqvRUp7KqK2xgMxv2oUOGDvWAPdH7Ali5wyu0gC X-Developer-Key: i=dlechner@baylibre.com; a=openpgp; fpr=8A73D82A6A1F509907F373881F8AF88C82F77C03 Put the filter types in alphabetical order by name. This makes it easier to find a specific filter type when looking through the documentation. Signed-off-by: David Lechner Reviewed-by: Nuno S=C3=A1 --- Documentation/ABI/testing/sysfs-bus-iio | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/te= sting/sysfs-bus-iio index fcc40d211ddf388ad70f489177ba2fcebdb9f8dc..3a13596b6eb081483a1f45fb0c4= 46d2ab3b4c708 100644 --- a/Documentation/ABI/testing/sysfs-bus-iio +++ b/Documentation/ABI/testing/sysfs-bus-iio @@ -2307,21 +2307,21 @@ Description: conversion time. Poor noise performance. * "sinc3" - The digital sinc3 filter. Moderate 1st conversion time. Good noise performance. - * "sinc4" - Sinc 4. Excellent noise performance. Long - 1st conversion time. - * "sinc5" - The digital sinc5 filter. Excellent noise - performance - * "sinc4+sinc1" - Sinc4 + averaging by 8. Low 1st conversion - time. - * "sinc3+rej60" - Sinc3 + 60Hz rejection. - * "sinc3+sinc1" - Sinc3 + averaging by 8. Low 1st conversion - time. * "sinc3+pf1" - Sinc3 + device specific Post Filter 1. * "sinc3+pf2" - Sinc3 + device specific Post Filter 2. * "sinc3+pf3" - Sinc3 + device specific Post Filter 3. * "sinc3+pf4" - Sinc3 + device specific Post Filter 4. - * "sinc5+pf1" - Sinc5 + device specific Post Filter 1. + * "sinc3+rej60" - Sinc3 + 60Hz rejection. + * "sinc3+sinc1" - Sinc3 + averaging by 8. Low 1st conversion + time. + * "sinc4" - Sinc 4. Excellent noise performance. Long + 1st conversion time. + * "sinc4+sinc1" - Sinc4 + averaging by 8. Low 1st conversion + time. + * "sinc5" - The digital sinc5 filter. Excellent noise + performance * "sinc5+avg" - Sinc5 + averaging by 4. + * "sinc5+pf1" - Sinc5 + device specific Post Filter 1. * "wideband" - filter with wideband low ripple passband and sharp transition band. =20 --=20 2.43.0 From nobody Tue Oct 7 08:53:16 2025 Received: from mail-oo1-f41.google.com (mail-oo1-f41.google.com [209.85.161.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B1F492C15BF for ; Thu, 10 Jul 2025 22:40:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.161.41 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187244; cv=none; b=Idw4yoeYMjLgP5Kny6uwjEosods+4kiZJehPfqJK78MBsTpbxUUy/XLuBzKg/2Ss93vOoHsJJtmN5vg17iOfT7UDFYJFaQ3tLIGfcKNXHZmYXgcehZFgBCDPTXRmUKnQ9yuqgtPBwYoUKz8KKWGgO7k3ep4gHtGODY4gpGy72vM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752187244; c=relaxed/simple; bh=CCj9iOwvg6zzBiEjcAxAf7V65hcOnGTyWH1FdMb4jHw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Aa/8o3gS+QdXzLUfwv3st07HVoFq7yuOI1TniOzPKVj+FL4bkCtJ34lbMnnq4ddcefoW1rVSP0I88i0tAuLTgtxtcK8Y5y9spknHFHWXnI9uYNIa+R0DTBzyajZXSt3ZphTJEBiCWFnlaUELJnsUrA084cbvfpVF2Tf06Sfntsw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b=jxS1aYsp; arc=none smtp.client-ip=209.85.161.41 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="jxS1aYsp" Received: by mail-oo1-f41.google.com with SMTP id 006d021491bc7-60f0a92391bso799715eaf.0 for ; Thu, 10 Jul 2025 15:40:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1752187242; x=1752792042; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=U2xSpg91xD37d6BWc4wU5FsBfQPR8cbxm4QoC+z5aRA=; b=jxS1aYsptr+OUi+Opa749Fn2g+cJ5CEbG8j4YbHQd9z2oNOmhlTF9VffOEkP6h9Hf/ jIbmbgYCRgYySQjIlM7WWc2P0r/wMCZDBNALvvXbNiYxUD3W4EnqbSmik6EWwlUFgD5M RMTSRBG+nSAClLHm1MzTqgIqOsnpgLAzKTbDwtbtVkyhYiRwtqz7Viel/ImVKmpVz1Qe GDI8klexStBawVBlCo142uSqpxOcHJN9XttNOKtzCsqRdMve+kIpfnH301+0Lh5rLOSL zewaEb7nB1YcV4JBlKPY8ZVi/LbcxZ/8mmYZJygJS0lHX2y62JFsFFWz2Xe5d+FFHoJX 5FoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752187242; x=1752792042; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=U2xSpg91xD37d6BWc4wU5FsBfQPR8cbxm4QoC+z5aRA=; b=qDuTWq6KJG14gGs55vHOurk5sZF1yOpwWJ89JhFWFLl4dAMw3QqKsXIowNo+h4HqtH EiLahii0IxTha9lJEl98MbTgGS9AIgw5ka1kcmkxC5v54lyrKz2ZFMWWJJhEOMyGF6xA ZMw9WjjzHvhK/P0Rxot68Npis7IhOOT6/nhqKNhKKcNreE4Iew7zPkvysoaQDCs2TxMt AVdX4b8a64BsXFDvAm0WTHatZE+civyoHGJiVKzfL0abLEsYw58o2iD+C3UgIiPvemB7 z2ZngEv5pwM1ZdBfVkTjLFyPWH2k36ElaHRAoe33HSRGLs8ke7YZQCTBtoqx2suEQqay ycVw== X-Forwarded-Encrypted: i=1; AJvYcCWlFwLi8WvXNtSrIB0nBMCgbLFV0iAUv0UzjDk30RsHdKIBKrapDMBbKNhTMciY3guVLLygoaXuUVwUYXc=@vger.kernel.org X-Gm-Message-State: AOJu0Yw0bOdt6u9rGzgbc3ZG3RrPgajNjNND6pA6/zknIwNDWFuujuEh 8sLVz5qxiGcFsRbnbMzyxgIF6lTk4Oz4VoBh1ZmiUTaOoX84quDtGXfQEKr4qQ65TpQ= X-Gm-Gg: ASbGncszSVmYUX40z8U2ITmCNKtNlK0Y0ZCzlKrqeZwCdrD5q/Qxqd0sLNU1D5WKZwt vCCxkRRIy8nQwU7wby4+G4NfbF8R44ZaEzUpglE+l+lyuNKQIh1QfgIepbKRwp6tIsJhyfuuM1t Whg9/8coUvPDgCnz4iMF2OGR3EqhBNPUmV92+BX3F+WSgBkjAmX+T6P9GJ8EStHyLJ6FJuo1PRS tT5M7fLo9iGOxN6R/QdHbxeOMtjVQduw7JYThNwRFS4fS8ubCa5uXwAqsazMVpbSyg9ZXgz0wmY 2shQdJ2n6gWOpAYysCuSoV4VbWiga2wGcB3Ryl9ldzy9ZFqlppTK9IqI88Vi5iSGTNtNDYMFXpv NGdkDJcgz1lWOGljdm+ZK6N/hTg== X-Google-Smtp-Source: AGHT+IHJDQiMpjjkeqNdEuJu5mN4++lh2a4XmuyNidTzS9J7M+fjY820BsBEPCbiv8ZDDnnAsrB+NQ== X-Received: by 2002:a05:6820:984:b0:611:a799:cb65 with SMTP id 006d021491bc7-613e5eee3e5mr686252eaf.2.1752187241855; Thu, 10 Jul 2025 15:40:41 -0700 (PDT) Received: from [127.0.1.1] ([2600:8803:e7e4:1d00:891b:7836:c92:869]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-613d9d950f1sm305944eaf.18.2025.07.10.15.40.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 10 Jul 2025 15:40:40 -0700 (PDT) From: David Lechner Date: Thu, 10 Jul 2025 17:39:54 -0500 Subject: [PATCH 5/5] iio: ABI: add filter types for ad7173 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250710-iio-adc-ad7137-add-filter-support-v1-5-acffe401c4d2@baylibre.com> References: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> In-Reply-To: <20250710-iio-adc-ad7137-add-filter-support-v1-0-acffe401c4d2@baylibre.com> To: Michael Hennerich , Jonathan Cameron , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, David Lechner X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1198; i=dlechner@baylibre.com; h=from:subject:message-id; bh=CCj9iOwvg6zzBiEjcAxAf7V65hcOnGTyWH1FdMb4jHw=; b=kA0DAAoBwswgAf8Bj8AByyZiAGhwQVmi7U4x7Z81Pd604/fp6tXpK5nHzaYBkLN7GNL2D8fA2 okBMwQAAQoAHRYhBOwY2Z5iDoPWnNhomMLMIAH/AY/ABQJocEFZAAoJEMLMIAH/AY/AoHEIAJz/ ZbeF6gEdPUjASRNpVs40nlVt2BK9rtMsxEuaZz/sHASFwBGhP5kFmWGHmCu1kEvWinSHlnJ4sY4 SSJqglMdg/zM7Vx5HAIO4VoJKFcIMlewpIlWNs3R3CPQu6ZuvEZXdM/DL9GK6sgZnPpTA5sPVtb KS6TSsQMSI28YbG5cWIQU6/fzi0kUt2vP8B0ZUD42V/PBLxM/glpM/LzqWj+aqISl4jKMoxkDXf TZvAM0ed8kTb4eA/DJEiZkwE/EmTRB4bxVM/xUT7xvGd+EhogjBdPfpwDmLeTawT95nene2QaNu czzRRg+j+4O2I9rHycRqyiIs0QkgMEQkYQIwrqo= X-Developer-Key: i=dlechner@baylibre.com; a=openpgp; fpr=8A73D82A6A1F509907F373881F8AF88C82F77C03 Add new filter types used in the ad7173 driver to the IIO ABI documentation. These chips have a few filter types that haven't been seen before in other drivers. Signed-off-by: David Lechner Reviewed-by: Nuno S=C3=A1 --- Documentation/ABI/testing/sysfs-bus-iio | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Documentation/ABI/testing/sysfs-bus-iio b/Documentation/ABI/te= sting/sysfs-bus-iio index 3a13596b6eb081483a1f45fb0c446d2ab3b4c708..05ecf0b551698d3c7bf2d225507= a1e0ecc253c86 100644 --- a/Documentation/ABI/testing/sysfs-bus-iio +++ b/Documentation/ABI/testing/sysfs-bus-iio @@ -2322,6 +2322,11 @@ Description: performance * "sinc5+avg" - Sinc5 + averaging by 4. * "sinc5+pf1" - Sinc5 + device specific Post Filter 1. + * "sinc5+sinc1" - Sinc5 + Sinc1. + * "sinc5+sinc1+pf1" - Sinc5 + Sinc1 + device specific Post Filter 1. + * "sinc5+sinc1+pf2" - Sinc5 + Sinc1 + device specific Post Filter 2. + * "sinc5+sinc1+pf3" - Sinc5 + Sinc1 + device specific Post Filter 3. + * "sinc5+sinc1+pf4" - Sinc5 + Sinc1 + device specific Post Filter 4. * "wideband" - filter with wideband low ripple passband and sharp transition band. =20 --=20 2.43.0