From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 C06163D9DDB; Fri, 9 Oct 2026 14:38:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791556727; cv=none; b=nJGmXU/RJkzf8ZSNjq3QihfvfQaq8pt0SzCFZo4K9bVjSxaHmOrEfxgC+v96mUu4fIglVg4deDU8cPCHn51ukRUHofDxgNDP2gIWLSuB4CckZFAYMHJux+Uof7q0uIPAuPWdBF3tArG9gmm8A+FozMl1fQ0MYmkO6jXHCZffGB8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791556727; c=relaxed/simple; bh=qG4mbBCJDifDuycEQhcD/DWPpz4X02SZyQqjd/hyg3w=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=OjS3WSS22GIJp5yzeNAGlQencbGF4wrvY/9xYmcAhFQvtvCOJtvoIi604xLGAATcWucD60MH+eTmhy+Vs7nnA+XiDOK6EIeiRkzfcntCmvjNLaAIF1Nt2OOv+8auzU/N9/+m2he33WhgzMhEa1PTZHtRbjd5+YqUVpv6N+IGtZs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=mp0tAYbh; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="mp0tAYbh" Received: by smtp.kernel.org (Postfix) with ESMTPSA id CE7AE1F000FF; Fri, 9 Oct 2026 14:38:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1791556726; bh=pvPJkCyWjG7LjYZUzqRGl93FBFUSXQzHg96mfgbaBcQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=mp0tAYbh68JVSu1aYQAX0J521URoqAlaFZi/YAiDIVOkr5+mhGu+YI4EATApgCn2o N7CIYQ8JOeRuvTvlwnBvp4dzmbu89NMBFVu9dyOmRaIOimqsaEzzBRXz75vgAK5iFG zhKWZPCLoOtK8XowZNu91RfufYhj3mKZq2BX0IKs= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, stable , Pannarat Wiriyaarritham , Heikki Krogerus Subject: [PATCH 7.2 232/428] usb: typec: ucsi: acpi: Assume UCSI 1.2 on Acer Nitro ANV15-41 Date: Fri, 9 Oct 2026 16:09:29 +0200 Message-ID: <20261009140951.208987159@linuxfoundation.org> X-Mailer: git-send-email 2.56.0 In-Reply-To: <20261009140946.008206689@linuxfoundation.org> References: <20261009140946.008206689@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 7.2-stable review patch. If anyone has any objections, please let me know. ------------------ From: Pannarat Wiriyaarritham commit 8c51ea651d043c786c37668c51624bd6b338a0ef upstream. The Acer Nitro ANV15-41 exposes a functional UCSI ACPI PPM but reports a UCSI VERSION value of zero. ucsi_register() rejects a zero version with -ENODEV, leaving the system without registered USB Type-C connectors. The PPM works correctly when using the UCSI 1.2 layout. With UCSI 1.2 assumed, both Type-C connectors register correctly and USB Power Delivery negotiation works. Add a DMI-specific UCSI operation for the Acer Nitro ANV15-41 that substitutes UCSI 1.2 only when firmware reports a zero version. Preserve any valid non-zero firmware version. Tested on an Acer Nitro ANV15-41 with BIOS V1.51. Fixes: c1b0bc2dabfa ("usb: typec: Add support for UCSI interface") Cc: stable Assisted-by: LLM Signed-off-by: Pannarat Wiriyaarritham Reviewed-by: Heikki Krogerus Link: https://patch.msgid.link/20260910023338.31816-1-pannarat.wiriyaarritham@danielcorp.dev Signed-off-by: Greg Kroah-Hartman --- drivers/usb/typec/ucsi/ucsi_acpi.c | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) --- a/drivers/usb/typec/ucsi/ucsi_acpi.c +++ b/drivers/usb/typec/ucsi/ucsi_acpi.c @@ -121,6 +121,33 @@ static const struct ucsi_operations ucsi .async_control = ucsi_acpi_async_control }; +static int ucsi_acer_read_version(struct ucsi *ucsi, u16 *version) +{ + struct ucsi_acpi *ua = ucsi_get_drvdata(ucsi); + int ret; + + ret = ucsi_acpi_read_version(ucsi, version); + if (ret) + return ret; + + if (!*version) { + dev_warn(ua->dev, "UCSI version is zero, assuming 1.2\n"); + *version = UCSI_VERSION_1_2; + } + + return 0; +} + +static const struct ucsi_operations ucsi_acer_ops = { + .read_version = ucsi_acer_read_version, + .read_cci = ucsi_acpi_read_cci, + .poll_cci = ucsi_acpi_poll_cci, + .read_message_in = ucsi_acpi_read_message_in, + .write_message_out = ucsi_acpi_write_message_out, + .sync_control = ucsi_sync_control_common, + .async_control = ucsi_acpi_async_control +}; + static int ucsi_gram_sync_control(struct ucsi *ucsi, u64 command, u32 *cci, void *val, size_t len, void *msg_out, size_t msg_out_size) @@ -164,6 +191,13 @@ static const struct ucsi_operations ucsi static const struct dmi_system_id ucsi_acpi_quirks[] = { { .matches = { + DMI_MATCH(DMI_SYS_VENDOR, "Acer"), + DMI_MATCH(DMI_PRODUCT_NAME, "Nitro ANV15-41"), + }, + .driver_data = (void *)&ucsi_acer_ops, + }, + { + .matches = { DMI_MATCH(DMI_SYS_VENDOR, "LG Electronics"), DMI_MATCH(DMI_PRODUCT_FAMILY, "LG gram PC"), DMI_MATCH(DMI_PRODUCT_NAME, "90Q"),