summaryrefslogtreecommitdiff
path: root/drivers/firmware/scmi/pinctrl.c
AgeCommit message (Collapse)Author
4 daysfirmware: scmi: Fix setting the functionDan Carpenter
Set BIT(10) when the function needs to be set, otherwise the setting is ignored. Fixes: 0cb160f1b629 ("scmi: pinctrl: add pinctrl driver for SCMI") Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Peng Fan <[email protected]>
2026-03-23scmi: pinctrl: add pinctrl driver for SCMIDan Carpenter
This driver adds the base support of pinctrl over SCMI. The driver does two main things. First, it allows you to configure the initial pin states. Secondly, it's used a base to build a GPIO driver on top of it. To configure the states then add a pinmux config to the scmi_pinctrl section: scmi_pinctrl: protocol@19 { reg = <0x19>; pinmux1: pinmux_test { pinmux = <0 1 0xFFFFFFFF 18 1 0 2 0xFFFFFFFF 18 1 0 3 0xFFFFFFFF 18 1>; function = "f_gpio1"; groups = "grp_1", "grp_3"; }; }; Under linux the pinctrl subsystem will parse the function and group properties and use that to handle muxing. However, under u-boot the pin muxing is done using the "pinmux" property, which feeds raw SCMI pinctrl PINCTRL_SETTINGS_CONFIGURE commands to the server. The numbers are: selector, identifier, function_id, config_type, and config_value. In the example above, it sets pins 1, 2, and 3 to 1. The linux-kernel ignores this pinmux property. Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Peng Fan <[email protected]> Signed-off-by: Peng Fan <[email protected]>