From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ot1-f45.google.com (mail-ot1-f45.google.com [209.85.210.45]) (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 EEC663815D7 for ; Mon, 19 Jan 2026 15:00:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.45 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768834811; cv=none; b=FtV8haOZrD4zId1S/k5CoxeJJJhazckQmFTE7AQQpAhoDsj9pX/KzDq7oaqb7TpCwFTPtQDiTqm8o6qbMKuoLYumkShl376E6+x1x2Htc8/UlydmFekclDxZE/0hSIA0V7sgvuyQQACVGzrQyBJ0WjG7wjIloOQm+nMJOHEAyQA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768834811; c=relaxed/simple; bh=cm0kBCrCagAmIwIfdqQivns34awEDM3DgQZ629eJSvM=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=KdUu4K34CQFVBYst7Kg3D2MRaXNhAjqASGm5IVNXKgEnVNik3khhdJ4P45GP5s6BUW+aC1Vx5eQqZXjJdVieXl7T5UWxITaPw7jLOZA5rASwz0HcIQq3ERgJC0/dir9qc8cRGZ8UraRMoz8Z0lgAHcZqpGXdNyJKWK20xiaAy7I= 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=0xB2+8Oz; arc=none smtp.client-ip=209.85.210.45 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="0xB2+8Oz" Received: by mail-ot1-f45.google.com with SMTP id 46e09a7af769-7d11e2ee188so1156139a34.1 for ; Mon, 19 Jan 2026 07:00:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1768834808; x=1769439608; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=C4+U9ZGKYVnrOMk8WBltvHJAB0HdENMPvpMm9u9ZXYU=; b=0xB2+8OzBFiJoPPCweIGUvNIB9ZIbkaJ6OebkHuDTSGJJNH/Trg7jS96Oz+vqutLqh xUCQScZVIt3+R5GpihO6DxjNDPONRtv6KbXM+aPzM5sBI5h5yusnFKGeey5YdDsMs4Aq vYeJR00cdK/P3ZRr0O1nEEZ0rwGZFYhIgWjJv2DrRPg58twM+/mPTAYzTFeqWKM0IjJO y5wkl24cdr2QmhFOuFZ3Z1D0BjPu2tNesWoQv3Q9qDOG+PyI4ZvIKXVrtzbTOPnKSm7J CXzBvHI5qK3bjnoum4kjWsPRPHDumM+m5L6SZaeFnvsdz3vfIKyr3E21l+kn0KhoAsd/ kTTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1768834808; x=1769439608; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=C4+U9ZGKYVnrOMk8WBltvHJAB0HdENMPvpMm9u9ZXYU=; b=Y1ldBv0yLYW6pHFSgJrNJ3O96DuIDXRHbsqRsbiSASaZ1q5JZXq6JOse99Pvj2Uxem QqnP2WANlQlSXd960VhvXzs7jI4GnznhkU6JYBCniOVWuKZxUOtw/H1g1f6i67YcczMC YdMZqSYnI8OBj4a2En58wdDoWpaUokd2yH761Bz25pWgshesYwxqrgT8i2HQXQQtmUG5 YJISkKhtxLMKdP2+bcB5iN1lENbAUZq5fYrEzrW3lcmzGuMhWHwdrnJJ0iQMFM8pTp/A lTzOV+eklDyEACHGRS4hh850puDI+eZ4hKCnD/1gH5TZU9yCaoVZ86SizEkTrfaW/Pd5 ft2A== X-Forwarded-Encrypted: i=1; AJvYcCWQvlMsmJ6CJu72R5/t6AYWdXHq7VF4y3MwPQ4Qe1k7ES/Z1b0uJw5LhUw16qyOFgPwBL7Lq0PR0TpAzcE=@vger.kernel.org X-Gm-Message-State: AOJu0YxC4/UKjydB2hATtzEALEfOVv43wfnV4V0T7lA4RgoUQCtSAGrX 0rdFjuXE+/QNRFwNnfJfe2kZBbxpkX4Or1S3b6oqnfpjKZi5EF6557/6LBFpEg0fdE+47yUWrhD L4fPZ X-Gm-Gg: AY/fxX7lS1+1s/L7YFGjnagD6T5x3ZN+QMZvCDE3pW8leVYIsFaBNuhB4tdNEJNyNhK fhRTrFvPu/WkvXYS67SLM7R0BMSF6xXQyIkebMkNs7R6GxQakS32Pn4wkesQ0C/qK4iWU1hGwE8 YvQxWRxFQ8zHJwUHCFVWIJ1BLVmOvzDq84/f55Od8xnuefRx8YsJzPbPE6sxvV4mzZANVRWk93D 7vz8cKVEJR0l/y9rucDoLEOQdIxUwu/+zkanv4o+vffyA45vK0gdWDldowhS+B1P1aISNCCsJxR EKp22Gea/Zr/mGK6K5QaOF95e/N+frdAH8E5k5NsyDD3RWO7R74GrlD4AaalFnBPphtAV2K3hIw IhikvDrGCWyia2ikFujZrw5AVrbsxJnB3pt9xjBUfW97AcHPpTwA56Qn6/V0orQf57Ai75iEX74 3muNCJHDICDh9C4mESzHaL04iQbxl01g19X95mWcvFmwALC41dh/ispRjrocdp X-Received: by 2002:a05:6820:984:b0:65f:72ce:5e38 with SMTP id 006d021491bc7-6611896c48bmr4616133eaf.57.1768834807830; Mon, 19 Jan 2026 07:00:07 -0800 (PST) Received: from ?IPV6:2600:8803:e7e4:500:d51b:6660:8b0f:6002? ([2600:8803:e7e4:500:d51b:6660:8b0f:6002]) by smtp.gmail.com with ESMTPSA id 006d021491bc7-661186da6f4sm4457101eaf.7.2026.01.19.07.00.06 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 19 Jan 2026 07:00:07 -0800 (PST) Message-ID: <69c4bf5a-e081-4660-a4ef-a92e9b081b41@baylibre.com> Date: Mon, 19 Jan 2026 09:00:06 -0600 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 2/4] iio: industrialio-backend: support backend capabilities To: Tomas Melin , =?UTF-8?Q?Nuno_S=C3=A1?= , Michael Hennerich , Nuno Sa , Lars-Peter Clausen , Jonathan Cameron , Andy Shevchenko , Olivier Moysan Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org References: <20260114-b4-ad9467-optional-backend-v3-0-d2c84979d010@vaisala.com> <20260114-b4-ad9467-optional-backend-v3-2-d2c84979d010@vaisala.com> <1f431375-f2cb-49a7-a0bd-6c00273a3c92@vaisala.com> Content-Language: en-US From: David Lechner In-Reply-To: <1f431375-f2cb-49a7-a0bd-6c00273a3c92@vaisala.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 1/19/26 7:49 AM, Tomas Melin wrote: ... >>>  int iio_backend_chan_enable(struct iio_backend *back, unsigned int chan); >>> @@ -235,6 +251,7 @@ int iio_backend_read_raw(struct iio_backend *back, >>>   long mask); >>>  int iio_backend_extend_chan_spec(struct iio_backend *back, >>>   struct iio_chan_spec *chan); >>> +int iio_backend_has_caps(struct iio_backend *back, u32 caps); >> >> Not what David suggested and I do agree with him FWIW. > AFAIU this was exactly what was suggested. Citing: Slight difference. Should return bool instead of int. > >>> bool iio_backend_has_capabilities(struct iio_backend *back, u32 flags) >>> (caps is fine too if we want to keep it short) > > Using the longer format is not very practical. Can we keep it as > iio_backend_has_caps ? Yes, I said as much already. But I guess you are asking Nuno. ;-)