From nobody Sun Feb 8 00:12:27 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 569592EB875; Mon, 20 Oct 2025 08:52:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760950332; cv=none; b=e6t5FxDcAJvNb/2RG3sX2Mry8wzpJEPQj8QVhuWPkSjYJzAmNIZ66YhBYZWxQgR0DyyG7LqulItAjJ2ZTPuFxELQePfk8hrsasU4op42p4+1/xPqKkVt2FsIDb1p19WY9Xyvy61ZMJz77GBoAr2zFKW3BIFjXkBEr2kM4oi46Gg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760950332; c=relaxed/simple; bh=3+kq7/U09g+lg6l/mbSdhdcOsFznfvQ0hxb1HcpN6Fw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ilFVQv5fHkiw8gdq8hTosmuHqTcLiSnlsz0IFvNuPqiMvI1NXHgY+HBGurzSrYQqcCk1yAvXC8cuZOZXKb3o2KbnNzWQoiXHTOObRaM8D6SDpYN5q//R6/mRIpZ4uTeoGdaDGpt1zV91zm6c3s9+nZ1yKPKhy0IYKKbWhVF75T0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=oADbZ2kX; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="oADbZ2kX" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E0804C116B1; Mon, 20 Oct 2025 08:52:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760950331; bh=3+kq7/U09g+lg6l/mbSdhdcOsFznfvQ0hxb1HcpN6Fw=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=oADbZ2kXwOz1p5Gq14LMjM9Kfib6Fa6BhUHZebOUy0iqq0jLWYNFeYtYn4CGggE3N R3F37/LK9zyVLQMqNqB9sh60pfRnsN1S/dPDuCUb0abw2xg9aoicDg8Y7RMZghkaPz RkXiRaTgOgwHxyA5S/U+anizIK2Nm5QkZtNLeapV3AC2XOU4Mziukw9KKiN+5peUW0 X5nlk82uq36kfWYsUqxqEotLQE9JgX2RDKEiQvxFes7TObBmRMm5II+Hh/9AkB+qg/ hTe5Ug1jHz7EYbrtalAH4lkDiWUMf1CM8GrawFcx4yPBqLQ/VOBGRWFR2yZWM2BOXY SHIlagx90BO7A== From: William Breathitt Gray Date: Mon, 20 Oct 2025 17:51:44 +0900 Subject: [PATCH v2 1/3] gpio: 104-idio-16: Define maximum valid register address offset 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: <20251020-fix-gpio-idio-16-regmap-v2-1-ebeb50e93c33@kernel.org> References: <20251020-fix-gpio-idio-16-regmap-v2-0-ebeb50e93c33@kernel.org> In-Reply-To: <20251020-fix-gpio-idio-16-regmap-v2-0-ebeb50e93c33@kernel.org> To: Linus Walleij , Bartosz Golaszewski , Andy Shevchenko Cc: Bartosz Golaszewski , Michael Walle , Ioana Ciornei , Mark Brown , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, William Breathitt Gray , Mark Cave-Ayland , stable@vger.kernel.org X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1290; i=wbg@kernel.org; h=from:subject:message-id; bh=3+kq7/U09g+lg6l/mbSdhdcOsFznfvQ0hxb1HcpN6Fw=; b=owGbwMvMwCW21SPs1D4hZW3G02pJDBlff1gyXvsYtC9u1iwxibxPcx9r/9DweaNn/H2D/AatN z+MJl092VHKwiDGxSArpsjSa3727oNLqho/XszfBjOHlQlkCAMXpwBMhL2HkWHBhB13t6sVJEw0 Nb3g9Oi5zW4nJy/vq3tn7FV3X+rwZ2UhI8NfmbrLz5KPLdrSkakrVZdWUnO61eGAp9KGhdFeEp6 XrDkA X-Developer-Key: i=wbg@kernel.org; a=openpgp; fpr=8D37CDDDE0D22528F8E89FB6B54856CABE12232B Attempting to load the 104-idio-16 module fails during regmap initialization with a return error -EINVAL. This is a result of the regmap cache failing initialization. Set the idio_16_regmap_config max_register member to fix this failure. Fixes: 2c210c9a34a3 ("gpio: 104-idio-16: Migrate to the regmap API") Reported-by: Mark Cave-Ayland Closes: https://lore.kernel.org/r/9b0375fd-235f-4ee1-a7fa-daca296ef6bf@nuta= nix.com Suggested-by: Mark Cave-Ayland Cc: stable@vger.kernel.org Reviewed-by: Andy Shevchenko Signed-off-by: William Breathitt Gray Reviewed-by: Linus Walleij --- drivers/gpio/gpio-104-idio-16.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpio/gpio-104-idio-16.c b/drivers/gpio/gpio-104-idio-1= 6.c index ffe7e1cb6b238856b9d13b2a278fe6c44b9cc8d3..fe5c10cd5c327ace1b715e9a275= 90211dce06fb0 100644 --- a/drivers/gpio/gpio-104-idio-16.c +++ b/drivers/gpio/gpio-104-idio-16.c @@ -59,6 +59,7 @@ static const struct regmap_config idio_16_regmap_config = =3D { .reg_stride =3D 1, .val_bits =3D 8, .io_port =3D true, + .max_register =3D 0x5, .wr_table =3D &idio_16_wr_table, .rd_table =3D &idio_16_rd_table, .volatile_table =3D &idio_16_rd_table, --=20 2.51.0 From nobody Sun Feb 8 00:12:27 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A339B2ED85D; Mon, 20 Oct 2025 08:52:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760950334; cv=none; b=EKeP/hHI0Q8wVOnEP4quW4NRPsvEEziS0/tXjSdJZUJhY04Drlh0dzhMpb7rHHs2opuQguhoTsfTkcnJ3CaoObDNKlOIrBkaBVmdEjRwyR6q1WnP1dLcrOoYhAdoFMF7dTpYT9+0LjOk2/jBAc36ZeSPosGb1sZQUsY4EoG2lrs= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760950334; c=relaxed/simple; bh=KH/2eJBrnrJKkAQLjlIxYoFdFIMreqzV2jotQA78V5g=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=NALirDyLJF1pqKqEDbLhTstZFruoDi9dYJIZnU4xFxi9V5EOa0yTLFypJ/1SxUKxK7Nr60QX4mgZMLNNNRWFDZot4Z/7yBWBKLOqq+P2dbRLmMTaU6ZtFrqR5yq5dUBZKCpbnoJdhVYOYWmLZev4GMgSPv1/3ju0GdhaULINLKM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=qG5hTlwX; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="qG5hTlwX" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 215DAC113D0; Mon, 20 Oct 2025 08:52:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760950333; bh=KH/2eJBrnrJKkAQLjlIxYoFdFIMreqzV2jotQA78V5g=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=qG5hTlwXNHMmaeDno1wSZ9unCLsdXO1ZB519d7D0PlSOvZz4qy5inaAa6cZWSgTvc aQXi4YajRLX5gZxgqWPOY0Q4kQ9XW/kpuPOqrOWWOEg6k6M8czA8Oo+ZsNKSpA9tE3 U7O5eYllyobvfgpBLL5d7MPWe4jvMbJFsrneeIMg3qiTTwfQbo/RWZ3ZbRsIXcaS7E Dif2t8J0hZ/GwT6oGyHIFk9dMgFTAnzcb8TD0QwRw+81jfB64or/CwyKXaOLxatZx+ wPJCTzXdmYYGUsRZLpNdmQVyLyzwxeWmnZNZ2cDXJpPf+KD+oY274yQjHw7GP3E6A9 a3tApMXITCUbA== From: William Breathitt Gray Date: Mon, 20 Oct 2025 17:51:45 +0900 Subject: [PATCH v2 2/3] gpio: pci-idio-16: Define maximum valid register address offset 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: <20251020-fix-gpio-idio-16-regmap-v2-2-ebeb50e93c33@kernel.org> References: <20251020-fix-gpio-idio-16-regmap-v2-0-ebeb50e93c33@kernel.org> In-Reply-To: <20251020-fix-gpio-idio-16-regmap-v2-0-ebeb50e93c33@kernel.org> To: Linus Walleij , Bartosz Golaszewski , Andy Shevchenko Cc: Bartosz Golaszewski , Michael Walle , Ioana Ciornei , Mark Brown , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, William Breathitt Gray , Mark Cave-Ayland , stable@vger.kernel.org X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=1290; i=wbg@kernel.org; h=from:subject:message-id; bh=KH/2eJBrnrJKkAQLjlIxYoFdFIMreqzV2jotQA78V5g=; b=owGbwMvMwCW21SPs1D4hZW3G02pJDBlff1g6Xiz9tcC68vD/rIrFwc8z5FQXWT/bM9HExTb3Y lCXDcu+jlIWBjEuBlkxRZZe87N3H1xS1fjxYv42mDmsTCBDGLg4BWAia7MY/tcY/DI9Hp0ucHXq rP2lnjcU4j+fcZinfW1LuO5tzYCp65Yz/A9V/WgrLHPpuPLPpS4TZu9P0w5n7nn99Z2rnMG1COb vMewA X-Developer-Key: i=wbg@kernel.org; a=openpgp; fpr=8D37CDDDE0D22528F8E89FB6B54856CABE12232B Attempting to load the pci-idio-16 module fails during regmap initialization with a return error -EINVAL. This is a result of the regmap cache failing initialization. Set the idio_16_regmap_config max_register member to fix this failure. Fixes: 73d8f3efc5c2 ("gpio: pci-idio-16: Migrate to the regmap API") Reported-by: Mark Cave-Ayland Closes: https://lore.kernel.org/r/9b0375fd-235f-4ee1-a7fa-daca296ef6bf@nuta= nix.com Suggested-by: Mark Cave-Ayland Cc: stable@vger.kernel.org Reviewed-by: Andy Shevchenko Signed-off-by: William Breathitt Gray Reviewed-by: Linus Walleij --- drivers/gpio/gpio-pci-idio-16.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpio/gpio-pci-idio-16.c b/drivers/gpio/gpio-pci-idio-1= 6.c index 476cea1b5ed774d18511aaf71d8ca2d71bcc9ff0..9d28ca8e1d6fac4bdc105b85058= 3607b5e5a87ea 100644 --- a/drivers/gpio/gpio-pci-idio-16.c +++ b/drivers/gpio/gpio-pci-idio-16.c @@ -41,6 +41,7 @@ static const struct regmap_config idio_16_regmap_config = =3D { .reg_stride =3D 1, .val_bits =3D 8, .io_port =3D true, + .max_register =3D 0x7, .wr_table =3D &idio_16_wr_table, .rd_table =3D &idio_16_rd_table, .volatile_table =3D &idio_16_rd_table, --=20 2.51.0 From nobody Sun Feb 8 00:12:27 2026 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A1D422EA75C; Mon, 20 Oct 2025 08:52:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760950335; cv=none; b=YMab/UQ2YW5iNzMudhp/nXyfjkuu4aOjXM338VlYtz6Ka1dyBjvJjXUfYSibH8SqYLJmUsyD5qN4+w+Dgeh5bC/VncXo9ZjMUBjQ9qPA9cjRsMFuydbGRDRBFOrJ5tbGZR4acuRmrhcUnNYV9vBA5jQ/U3xeAjboZnKSzsla5AM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1760950335; c=relaxed/simple; bh=EoUVxeSptFcOjrgPFfQZEWOsyUwL1/hLMlc22Yj9G24=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=biocpHKKiQWXGIGRbNWDmwGL19B4pidsaUsA2m1Iz+8pIhYs3WsiSpPBO+Z1yY5zA7/Hl5wJlo/A+WebiAXKPbi+OB9EpbTs9QJZvhisMwQQUGs3WRIXGe0mT1ZLpJ9DwSPsWlxrm5ztsFyrWLTB5Aky7UOHVtOGcuY5DFSEs9c= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=kte/KPZG; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="kte/KPZG" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 52B5AC4CEF9; Mon, 20 Oct 2025 08:52:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1760950334; bh=EoUVxeSptFcOjrgPFfQZEWOsyUwL1/hLMlc22Yj9G24=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=kte/KPZGk8PlzHP/nqp16ImYv56FvR2+OMTwexmHCbcrEDcMUn2NURupU9d/+Kkfz oQW1ZWj78iwGusaJKI/AJvGiNHn+p3kTyNicSq0jyKOpZRdxUVVVqNi7WSfW3gJpCZ xzyEk5nywWVK6yU/E9WSS532q6kpgDl52ojP5kERVy7qauwE05/O7ttaM2Akx6yWu3 pNeKt3Xiu5Wo9v7ogX2mE8mtTMMZuBmgQJ45piSPtGFV5f1A3sPd5dsP+Vd0+KwqqN PupVON33uj6bVyyy12MMsqYyWJC5QCr2+ukYZO0U9sQE0Lvg2id2BEYN8C3AD+jVrK tcEj2GseYg33w== From: William Breathitt Gray Date: Mon, 20 Oct 2025 17:51:46 +0900 Subject: [PATCH v2 3/3] gpio: idio-16: Define fixed direction of the GPIO lines 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: <20251020-fix-gpio-idio-16-regmap-v2-3-ebeb50e93c33@kernel.org> References: <20251020-fix-gpio-idio-16-regmap-v2-0-ebeb50e93c33@kernel.org> In-Reply-To: <20251020-fix-gpio-idio-16-regmap-v2-0-ebeb50e93c33@kernel.org> To: Linus Walleij , Bartosz Golaszewski , Andy Shevchenko Cc: Bartosz Golaszewski , Michael Walle , Ioana Ciornei , Mark Brown , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, William Breathitt Gray , Mark Cave-Ayland , stable@vger.kernel.org X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=2018; i=wbg@kernel.org; h=from:subject:message-id; bh=EoUVxeSptFcOjrgPFfQZEWOsyUwL1/hLMlc22Yj9G24=; b=owGbwMvMwCW21SPs1D4hZW3G02pJDBlff1helOPOnmbtVvKsmaGpcPuW++6+LzP/Zi7btTbm5 u/bZVP8O0pZGMS4GGTFFFl6zc/efXBJVePHi/nbYOawMoEMYeDiFICJ6Mxh+CtrNC/T7fPhilCL t5HGT5q/mE6t1Dj+XupQSEDGczfNEA5Ghpb/pb4Gd9+bbdTjeF51pmJWZMGcS2JyX18trn5cpHM wnQkA X-Developer-Key: i=wbg@kernel.org; a=openpgp; fpr=8D37CDDDE0D22528F8E89FB6B54856CABE12232B The direction of the IDIO-16 GPIO lines is fixed with the first 16 lines as output and the remaining 16 lines as input. Set the gpio_config fixed_direction_output member to represent the fixed direction of the GPIO lines. Fixes: db02247827ef ("gpio: idio-16: Migrate to the regmap API") Reported-by: Mark Cave-Ayland Closes: https://lore.kernel.org/r/9b0375fd-235f-4ee1-a7fa-daca296ef6bf@nuta= nix.com Suggested-by: Michael Walle Cc: stable@vger.kernel.org # ae495810cffe: gpio: regmap: add the .fixed_dir= ection_output configuration parameter Cc: stable@vger.kernel.org Reviewed-by: Andy Shevchenko Signed-off-by: William Breathitt Gray Reviewed-by: Linus Walleij --- drivers/gpio/gpio-idio-16.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/gpio/gpio-idio-16.c b/drivers/gpio/gpio-idio-16.c index 0103be977c66bb8d165c1c92123368be6832d120..4fbae6f6a49727df40f2793b42c= a207d78ec272b 100644 --- a/drivers/gpio/gpio-idio-16.c +++ b/drivers/gpio/gpio-idio-16.c @@ -6,6 +6,7 @@ =20 #define DEFAULT_SYMBOL_NAMESPACE "GPIO_IDIO_16" =20 +#include #include #include #include @@ -107,6 +108,7 @@ int devm_idio_16_regmap_register(struct device *const d= ev, struct idio_16_data *data; struct regmap_irq_chip *chip; struct regmap_irq_chip_data *chip_data; + DECLARE_BITMAP(fixed_direction_output, IDIO_16_NGPIO); =20 if (!config->parent) return -EINVAL; @@ -164,6 +166,9 @@ int devm_idio_16_regmap_register(struct device *const d= ev, gpio_config.irq_domain =3D regmap_irq_get_domain(chip_data); gpio_config.reg_mask_xlate =3D idio_16_reg_mask_xlate; =20 + bitmap_from_u64(fixed_direction_output, GENMASK_U64(15, 0)); + gpio_config.fixed_direction_output =3D fixed_direction_output; + return PTR_ERR_OR_ZERO(devm_gpio_regmap_register(dev, &gpio_config)); } EXPORT_SYMBOL_GPL(devm_idio_16_regmap_register); --=20 2.51.0