From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f52.google.com (mail-wm1-f52.google.com [209.85.128.52]) (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 36A073859C3 for ; Fri, 14 Aug 2026 22:23:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.52 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786746234; cv=none; b=KMxnFhSC0FX02/wiPRdvlDdRg7AxIi7JD7tPz456h0Fx7RbCflF/+p+dBirES0F6zAVN9W5oG4SiT+SIbRQKgVEdiph3QyZXO/o/ax0J4mfSH8aMLbPyEuWLZ64lmLe+9ra4lCoYOfpAppsfgps0lYmDkFfIm80irTIS0SWJAPY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786746234; c=relaxed/simple; bh=wnlNOPnY0hP37pyG/YOSqunFl1dMBiFL5sS10fnr0To=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:To:Cc; b=rjS1r2JnkaZBzQYTNh7vqx8Rf9vmxGCtv4AmMdMXx8r2CTCB3qhMf3WoOaNpsO9gk7IhqeToPtRB552F/cfOLzsy72WPoNq8l/YvCzP72WIRoGwgvJIIx8JTxz2tGgasbAyaz6IHgjyIDhye4pVuazdWYCs4yzKGE2w/oA9B4pU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=gbc8iRFy; arc=none smtp.client-ip=209.85.128.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="gbc8iRFy" Received: by mail-wm1-f52.google.com with SMTP id 5b1f17b1804b1-4954a9e8490so16153565e9.1 for ; Fri, 14 Aug 2026 15:23:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1786746231; x=1787351031; darn=vger.kernel.org; h=cc:to:message-id:content-transfer-encoding:content-type :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to:content-type; bh=dG3ky9ZlsV4zjJMppn5nLBEspHl5/MNFNDYpcigizeY=; b=gbc8iRFykpdO0WZ+7aXt2sLWuYW8G6G3FnGbyylpFnOAlfic/vQd9ACD3YeyQYtezF sbwhgyePHt+mgL1KmLCUOGQldxEhHJV7+jsHLQvhKRyJPtZ5FS3R5Kk7MbLkx32sAcit c1mXjqOhGVjkIND0NQ/9+PRkOOBhm8XG9lEhk8pxWiuIaMvtDpEK2zA0FvEXmHWtYdDl DbMBUVV65fWnLN5ezmfPok2zZ5LLVgn0Fs8U/+ganH7CD7jokN5LP2m3hEif5uzbxNOG ccAYH6J9or2oap90sFyxKNQq9WGHJGnWwzAxqQ+W/Hu3c1XhPVrPq5xTH4kVn1aiZAAY Pjsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786746231; x=1787351031; h=cc:to:message-id:content-transfer-encoding:content-type :mime-version:subject:date:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to:content-type; bh=dG3ky9ZlsV4zjJMppn5nLBEspHl5/MNFNDYpcigizeY=; b=rV0xtKi6Ewz6dOUsb5afbG4D2WFlPG/LUziB5trbAGXInZOgmCFbX9U6NHmIprqYoY Blx8QwWJ59nrFH6wf8gOY98B+xc0uNXFPrNC5iQSJc+2Q743yvSIvUgBhLs4lc4iP4fw uewYPsyWvp+7h3JZFhCPbgNWTpNAbKhtjDxd72+e/7ZyKDOHHIHT8RgzJJAhjBnQmr/A Dq13s5LbMZZxjYNXjNmkiXS0yIMCJC88X/Lz4NSJvpjMFd1/9EIgTvMPUqyQlmjyXN6X CquTrtD63cEUpx3wGJnBfg8UbeQjFfT6Qo9Z2Eoxp+GimdphQZPTtILipgfb+LR73wnn LBHw== X-Forwarded-Encrypted: i=1; AHgh+Rqs7jqPXqGeivqv0wrH6fE/cpXUKlDuS6JbnY3Iou7rSbPf2mlnD/eDsBfNPVud+v7Wy9aSb/Sr0/HlRSg=@vger.kernel.org X-Gm-Message-State: AOJu0Yw3gCZJxdmO7J1UIbbCIayxzY9j6KwodyDyVjBnTeqShXQaPF7R Zpasp9HqfWxfwNnL+pbE2zWS4lqr/IlsK/TNMI4CdFa/JpWixt1Zso9MgC0VJw== X-Gm-Gg: AR+sD13JcLrMdDZ/XwCNPNRP31CxpK1QDtVoeH+87FGLB4tEKTKoQdBlYe7ljPU4bOz ZBQhYrvZVbmigWzN3RW7Dp4CxB46kF3dL9CiBqlZqvATXF/EMEf4/QUD79ZuHLupzj+WGu3RlBb qJJTX1uv8odaj7yBp2NL8rw3EDBkH0/i1NBvQYLUUpuJEig85/LXAliMyHHYiI7gRTb7RDqRLHd L4XSpwW8mS3gKnklZ356g5kc42bv+kYbpDggWZYndG90BN/yaWxOfMn+dyer/rufhMDsd6zHnua i+saa5nqWKM92ZtqAP0vTZPUBY7QE6j6YvLq+t2Wv1kHGbxloD++r8oftRmrXps8tm/4zxcu1oo 9SvHftqG88l7jGRpOqPWheUzrPXjMQ+ZG3AEpbd2u18CXw9hKFDAaKpqvBJXn1WNGW8xZdxwq25 XgmF24P3md81G4cItTNt8Elu4WUffAL7OXRvllES9hKEv+TDc3DwijXZfBeqRbnGVQRT5gxChfH HcXpVe7WpGSLsvy X-Received: by 2002:a05:600c:3145:b0:493:f783:c46a with SMTP id 5b1f17b1804b1-49987ab45famr107072235e9.6.1786746231309; Fri, 14 Aug 2026 15:23:51 -0700 (PDT) Received: from [127.0.1.1] ([2001:4bb8:16f:15e0:4de3:7ab4:f4f1:da62]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-499877d7974sm63203885e9.1.2026.08.14.15.23.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Aug 2026 15:23:50 -0700 (PDT) From: Javier Carrasco Date: Sat, 15 Aug 2026 00:23:47 +0200 Subject: [PATCH] iio: gts-helper: fix error headers 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: 7bit Message-Id: <20260815-iio-gts-err-headers-v1-1-3a668373aaae@gmail.com> X-B4-Tracking: v=1; b=H4sIAHKVf2oC/x3MSwqAMAxF0a1Ixgaq+MOtiANrnzUTlUREEPduc XgG9z5kUIFRnz2kuMRk3xKKPKN5nbYIlpBMpSsb1xUVi+wcT2Oo8oopQI1Di9k3vob3LaXyUCx y/9dhfN8PG+y/C2UAAAA= To: Matti Vaittinen , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko Cc: linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, Javier Carrasco X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1786746229; l=2391; i=javier.carrasco.cruz@gmail.com; s=20260111; h=from:subject:message-id; bh=wnlNOPnY0hP37pyG/YOSqunFl1dMBiFL5sS10fnr0To=; b=f06yo0G8ZHRe0YmLrMGzOvCYfklwUTbgvmAYwnNigLVSqcSvgoOXHiQsYO2iGVswPW1iqh52Z URPwwHB4fnSD5dMC14g2M8DyKPbmGMK65uLSYj15sWaXtrXbkYunHJM X-Developer-Key: i=javier.carrasco.cruz@gmail.com; a=ed25519; pk=Lge8w8xidNSf/INy7JAIbAW+Hezkp3nsBh2OjKL7lLU= Both industrialio-gts-helper.c and iio-gts-helper.h use error codes defined in (usually included via ), but only industrialio-gts-helper.c includes it. On the other hand, that file also uses error macros like IS_ERR() and PTR_ERR(), which are included in . Add the right includes to provide the used elements from the error headers: - in iio-gts-helper.h - in industrialio-gts-helper.c, which in turn includes , which only includes Signed-off-by: Javier Carrasco --- I stumbled upon this while refactoring veml6031x00.c (which uses IIO GTS) just because clangd threw a couple of errors where -EINVAL is returned in iio-gts-helper.h In the end everything compiles anyway, and therefore I have not added a "Fixes:" tag, but please let me know if that is really required for something like this. It is also true that if the gts header is included first, the compiler will throw the same error clangd showed me and the kernel won't compile... Unlikely to ever happen, though. I have compiled and tested this implementation with the driver I am attempting to upstream without any issues. --- drivers/iio/industrialio-gts-helper.c | 2 +- include/linux/iio/iio-gts-helper.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/iio/industrialio-gts-helper.c b/drivers/iio/industrialio-gts-helper.c index 4f52dc373abf..af6ed37fb34a 100644 --- a/drivers/iio/industrialio-gts-helper.c +++ b/drivers/iio/industrialio-gts-helper.c @@ -5,7 +5,7 @@ */ #include -#include +#include #include #include #include diff --git a/include/linux/iio/iio-gts-helper.h b/include/linux/iio/iio-gts-helper.h index 66f830ab9b49..f63a482b82b8 100644 --- a/include/linux/iio/iio-gts-helper.h +++ b/include/linux/iio/iio-gts-helper.h @@ -7,6 +7,7 @@ #ifndef __IIO_GTS_HELPER__ #define __IIO_GTS_HELPER__ +#include #include struct device; --- base-commit: dc59e4fea9d83f03bad6bddf3fa2e52491777482 change-id: 20260814-iio-gts-err-headers-d7ecb6b5ebb7 Best regards, -- Javier Carrasco