From nobody Sat Sep 26 22:01:59 2026 Received: from mail-05.mail-europe.com (mail-05.mail-europe.com [85.9.206.169]) (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 1964D33F8AA; Sat, 29 Aug 2026 08:29:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=85.9.206.169 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787992193; cv=none; b=SVDwc9jd4JMMGsginj8LqVapo72AHa1VLvlvFpnwDEBXz5r+1rInOn+feyjvpSaIIyzN25bzD9n1sjKoZpb8nxqQRgxv7ab6PGaTIWceyoMzZ4yd2pdiew8QW2+4h2ALPb/5c6l3fzZ5xN7XXBc1gN5pyCRslPvIR/NXIAAl5Qg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787992193; c=relaxed/simple; bh=17aXPwxiJwF69jf+c1HQ/RDCTJOMI6Tn1YRf/EMPGow=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:To:Cc; b=EctMc8GGQZ0o/j2KkbONeC9KgpPLqSQmlcCfBexdHejc9nxUKqPO1SkumaHFTa6Pb081vYmo4W2NPG9yD515uf5gKexsxSs005nCRGHgqefv75RaEZpxlnrCRE0jCm4G3uEFAuRRJG9U1spzq9FkRpPUF+n+r1iTQ5RV4JkrGUo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=berg.pm; spf=pass smtp.mailfrom=berg.pm; dkim=pass (2048-bit key) header.d=berg.pm header.i=@berg.pm header.b=a/Ip4aBb; arc=none smtp.client-ip=85.9.206.169 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=berg.pm Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=berg.pm Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=berg.pm header.i=@berg.pm header.b="a/Ip4aBb" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=berg.pm; s=protonmail; t=1787992179; x=1788251379; bh=7oRmJ2JX9SjpY6C/SXCk9S84RaRvCnvAhCHlB7P4mR8=; h=From:Date:Subject:Message-Id:To:Cc:From:To:Cc:Date:Subject: Reply-To:Feedback-ID:Message-ID:BIMI-Selector; b=a/Ip4aBbJGeReuRd1WH0oAu3Yq7/WmH9H7bbUFEtOhX/TRTmrrEWG3vJh6GonFM1W HI6BwREaaLaxGtLNjH5mp4hOPsM6ZPK3CLxgN9L/ZqdDpCDD6sqvMXNyd0MfOAnUqt NT7xOZAba8qKETyE/Fv9XRmGpm50Ug02GKKPxvUW7tgg4O8jrJE2TguN85Jrkvay9E YG0IG7HFfQ7KJkG3D+oDXcNykGVk35Rf/ClvVztToRdaH8j5Ji/qdl/vUYARGP1t7q xv7ops7uoiq+hO2+giFTv+Qb6aWa4IHWOzqfp0Zg6RR59WY1h6B36vep0VeUiKimxo zDf/2bFcv59Gg== X-Pm-Submission-Id: 4hX7hw5gNHz2Schg From: Jakob Berg Jespersen Date: Sat, 29 Aug 2026 10:29:09 +0200 Subject: [PATCH v3] platform/x86: int3472: support the POWER1 GPIO 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: <20260829-sp7plus-int3472-v3-1-454b50485ce2@berg.pm> X-B4-Tracking: v=1; b=H4sIAAAAAAAC/3WNTQ7CIBgFr9KwFtMPWimuvIdxQflpMdoSaImm6 d2FutCFLid5M29BQXurAzoWC/I62mDHIQHdFUj2Yug0tioxIiU5lAw4Do652xywHSZaMYIbU0L VNkozLlGynNfGPrbi+fLmMLdXLaecyYvehmn0z+0yQt79r0fAgGsCoqKmlsDh1Grf7d0d5XYkX zb5YZNkS2WE4UxIKtTHXtf1BYLqaFP8AAAA X-Change-ID: 20260719-sp7plus-int3472-8f014b8de79c To: Daniel Scally , Sakari Ailus , Hans de Goede , =?utf-8?q?Ilpo_J=C3=A4rvinen?= Cc: platform-driver-x86@vger.kernel.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, Tooraj Taraz , "Joseph V. Lavigne" , "D. Manresa" , Jakob Berg Jespersen X-Mailer: b4 0.15.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1787992176; l=4742; i=dev@berg.pm; s=20260719; h=from:subject:message-id; bh=17aXPwxiJwF69jf+c1HQ/RDCTJOMI6Tn1YRf/EMPGow=; b=dbV30rfjQdGqZ21edpu8veocZUStpZAUfOfjUl9Vy1eFK+OjkqOx5HOI0JHeI79P5Fh/3LEWa 3FbTlFhoVLQCyIihqGKjRvggxAufu8aC3rb+1uCwr8FRBeILl9gJ8Gy X-Developer-Key: i=dev@berg.pm; a=ed25519; pk=b1r+eoJThwSQ/r5DjO7jrcosyrIsyhlOuKk9CBdvBxs= INT3472 can describe a second sensor power rail as a GPIO of type POWER1 (0x08), which the driver does not recognise, so the rail is left unmapped and never enabled: int3472-discrete INT3472:01: GPIO type 0x08 unknown; the sensor may not work On the Microsoft Surface Pro 7+ the rear camera's INT3472 (INT347A, ov8865) has such a pin; without it the ov8865 "dvdd" supply resolves to a dummy regulator and the sensor never probes. Define the POWER0 (0x07) and POWER1 (0x08) GPIO types and map POWER1 to a regulator with con_id "dvdd" for all devices, the supply the in-tree ov8865 driver already requests. POWER0 is defined but left unmapped, as no device that uses it is known. Out-of-tree work approached the same rail by exposing it to the sensor as a new "pwr1" supply (linux-surface PR #1867 for the Surface Pro 9, PR #2201 for the Pro 7+ ov8865); mapping POWER1 to the existing "dvdd" keeps the change contained to int3472. With this change the Surface Pro 7+ rear camera probes and streams reliably. Link: https://github.com/linux-surface/linux-surface/pull/1867 Link: https://github.com/linux-surface/linux-surface/pull/2201 Suggested-by: Sakari Ailus Signed-off-by: Jakob Berg Jespersen Reviewed-by: Hans de Goede --- Changes in v3: - No functional changes; the patch is identical to v2, rebased onto current pdx86/for-next (which has since gained the multi-HID GPIO map entries and the IMX471 "vana" entries). - Resent with linux-media@vger.kernel.org on Cc, as requested. - Link to v2: https://patch.msgid.link/20260729-sp7plus-int3472-v2-1-cdfaf9= 7ac3ad@berg.pm Changes in v2: - Reworked from a per-device INT347A quirk into a generic mapping of the POWER1 (0x08) GPIO type to "dvdd" for all devices, per review. - Added INT3472_GPIO_TYPE_POWER0 (0x07) and POWER1 (0x08) definitions; POWER0 is defined but left unmapped for now. - Retested on the Surface Pro 7+ (kernel 7.1.5): the rear ov8865 probes, instantiates its VCM, and streams. - Link to v1: https://patch.msgid.link/20260719-sp7plus-int3472-v1-1-521a43= f5c191@berg.pm --- drivers/platform/x86/intel/int3472/discrete.c | 8 ++++++++ include/linux/platform_data/x86/int3472.h | 2 ++ 2 files changed, 10 insertions(+) diff --git a/drivers/platform/x86/intel/int3472/discrete.c b/drivers/platfo= rm/x86/intel/int3472/discrete.c index 6c729fcfce5d..6ab8e589fcd3 100644 --- a/drivers/platform/x86/intel/int3472/discrete.c +++ b/drivers/platform/x86/intel/int3472/discrete.c @@ -266,6 +266,10 @@ static void int3472_get_con_id_and_polarity(struct int= 3472_discrete_device *int3 *con_id =3D "avdd"; *gpio_flags =3D GPIO_ACTIVE_HIGH; break; + case INT3472_GPIO_TYPE_POWER1: + *con_id =3D "dvdd"; + *gpio_flags =3D GPIO_ACTIVE_HIGH; + break; case INT3472_GPIO_TYPE_DOVDD: *con_id =3D "dovdd"; *gpio_flags =3D GPIO_ACTIVE_HIGH; @@ -296,6 +300,8 @@ static void int3472_get_con_id_and_polarity(struct int3= 472_discrete_device *int3 * 0x00 Reset * 0x01 Power down * 0x02 Strobe + * 0x07 Power 0 + * 0x08 Power 1 * 0x0b Power enable * 0x0c Clock enable * 0x0d Privacy LED @@ -382,6 +388,7 @@ static int skl_int3472_handle_gpio_resources(struct acp= i_resource *ares, case INT3472_GPIO_TYPE_PRIVACY_LED: case INT3472_GPIO_TYPE_STROBE: case INT3472_GPIO_TYPE_POWER_ENABLE: + case INT3472_GPIO_TYPE_POWER1: case INT3472_GPIO_TYPE_DOVDD: case INT3472_GPIO_TYPE_HANDSHAKE: gpio =3D skl_int3472_gpiod_get_from_temp_lookup(int3472, agpio, con_id, = gpio_flags); @@ -408,6 +415,7 @@ static int skl_int3472_handle_gpio_resources(struct acp= i_resource *ares, case INT3472_GPIO_TYPE_POWER_ENABLE: second_sensor =3D int3472->quirks.avdd_second_sensor; fallthrough; + case INT3472_GPIO_TYPE_POWER1: case INT3472_GPIO_TYPE_DOVDD: case INT3472_GPIO_TYPE_HANDSHAKE: ret =3D skl_int3472_register_regulator(int3472, gpio, enable_time_us, diff --git a/include/linux/platform_data/x86/int3472.h b/include/linux/plat= form_data/x86/int3472.h index a73841dfae27..b1040e36deb8 100644 --- a/include/linux/platform_data/x86/int3472.h +++ b/include/linux/platform_data/x86/int3472.h @@ -25,6 +25,8 @@ #define INT3472_GPIO_TYPE_RESET 0x00 #define INT3472_GPIO_TYPE_POWERDOWN 0x01 #define INT3472_GPIO_TYPE_STROBE 0x02 +#define INT3472_GPIO_TYPE_POWER0 0x07 +#define INT3472_GPIO_TYPE_POWER1 0x08 #define INT3472_GPIO_TYPE_POWER_ENABLE 0x0b #define INT3472_GPIO_TYPE_CLK_ENABLE 0x0c #define INT3472_GPIO_TYPE_PRIVACY_LED 0x0d --- base-commit: 5b05bb3f6c5716fab6911e12d60dd1f43ad9806a change-id: 20260719-sp7plus-int3472-8f014b8de79c Best regards, -- =20 Jakob Berg Jespersen