]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
tcpm: Parse and log AVS APDO
authorBadhri Jagan Sridharan <badhri@google.com>
Wed, 15 Oct 2025 04:30:13 +0000 (04:30 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Oct 2025 08:58:31 +0000 (10:58 +0200)
commitf82890c98f3e3fd61983e9021354c632ecd47427
tree72f8115069363ee244d140e73661d27c7878fd68
parent8ad194699fc17bec5307b59d36676f43ea460b05
tcpm: Parse and log AVS APDO

The USB PD specification introduced new Adjustable Voltage Supply (AVS)
types for both Standard Power Range (SPR) and Extended Power Range (EPR)
sources.

Add definitions to correctly parse and handle the new AVS APDO. Use
bitfield macros to add inline helper functions to extract voltage,
current, power, and peak current fields to parse and log the details
of the new EPR AVS and SPR AVS APDO.

Signed-off-by: Badhri Jagan Sridharan <badhri@google.com>
Reviewed-by: Amit Sunil Dhamne <amitsd@google.com>
Reviewed-by: Kyle Tso <kyletso@google.com>
Reviewed-by: RD Babiera <rdbabiera@google.com>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Link: https://patch.msgid.link/20251015043017.3382908-1-badhri@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/typec/tcpm/tcpm.c
include/linux/usb/pd.h