aboutsummaryrefslogtreecommitdiff
path: root/drivers/pinctrl/realtek
AgeCommit message (Collapse)AuthorFilesLines
2024-08-05pinctrl: realtek: Constify struct regmap_configJavier Carrasco1-1/+1
`rtd_pinctrl_regmap_config` is not modified and can be declared as const to move its data to a read-only section. Signed-off-by: Javier Carrasco <[email protected]> Link: https://lore.kernel.org/[email protected] Signed-off-by: Linus Walleij <[email protected]>
2024-04-17pinctrl: realtek: fix module autoloadingKrzysztof Kozlowski2-0/+2
Add MODULE_DEVICE_TABLE(), so the module could be properly autoloaded based on the alias from of_device_id table. Pin controllers are considered core components, so usually they are built-in, however these can be built and used as modules on some generic kernel. Signed-off-by: Krzysztof Kozlowski <[email protected]> Message-ID: <[email protected]> Signed-off-by: Linus Walleij <[email protected]>
2023-11-24pinctrl: realtek: Fix logical error when finding descriptorTzuyi Chang1-2/+2
The pin descriptor should be returned if the name has been found in the descriptor table. Remove the negation in the if statement for accurate retrieval. Fixes: e99ce78030db ("pinctrl: realtek: Add common pinctrl driver for Realtek DHC RTD SoCs") Signed-off-by: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
2023-10-06pinctrl: realtek: Fix some NULL dereference warningsLinus Walleij1-1/+9
Just inspecting the code doesn't convince me that this is a real issue, but the tools complain that it is so I will just handle it. Cc: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Signed-off-by: Linus Walleij <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-10-06pinctrl: realtek: Tag unused pins as __maybe_unusedLinus Walleij2-2/+4
These pin definitions are helpful to have when working with the driver in the future, so they are in a sense a bit like documentation. They could be commented out as well, but why. This should fix these build warnings: drivers/pinctrl/realtek/pinctrl-rtd1315e.c:231:35: warning: 'rtd1315e_boot_sel_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1315e.c:231:35: warning: 'rtd1315e_reset_n_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1315e.c:231:35: warning: 'rtd1315e_scan_switch_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1315e.c:231:35: warning: 'rtd1315e_testmode_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1315e.c:231:35: warning: 'rtd1315e_wd_rset_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1319d.c:237:35: warning: 'rtd1319d_boot_sel_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1319d.c:237:35: warning: 'rtd1319d_reset_n_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1319d.c:237:35: warning: 'rtd1319d_scan_switch_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1319d.c:237:35: warning: 'rtd1319d_testmode_pins' defined but not used [-Wunused-const-variable=] drivers/pinctrl/realtek/pinctrl-rtd1319d.c:237:35: warning: 'rtd1319d_wd_rset_pins' defined but not used [-Wunused-const-variable=] Cc: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Signed-off-by: Linus Walleij <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2023-10-06pinctrl: realtek: Fix error handling in probe()Dan Carpenter1-5/+13
There are several issues in the probe function: 1) of_iomap() return NULL on error but the code checks for error pointers. 2) pinctrl_register() is the reverse. It returns error pointers but the code checks for NULL. 3) The error paths need to call iounmap(data->base) before returning to avoid a resource leak. Fixes: e99ce78030db ("pinctrl: realtek: Add common pinctrl driver for Realtek DHC RTD SoCs") Signed-off-by: Dan Carpenter <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
2023-09-20pinctrl: realtek: Add pinctrl driver for RTD1619BTzuyi Chang3-0/+1607
Add RTD1619B support using realtek common pinctrl driver. Signed-off-by: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
2023-09-20pinctrl: realtek: Add pinctrl driver for RTD1319DTzuyi Chang3-0/+1615
Add RTD1319D support using realtek common pinctrl driver. Signed-off-by: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
2023-09-20pinctrl: realtek: Add pinctrl driver for RTD1315ETzuyi Chang3-0/+1445
Add RTD1315E support using realtek common pinctrl driver. Signed-off-by: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>
2023-09-20pinctrl: realtek: Add common pinctrl driver for Realtek DHC RTD SoCsTzuyi Chang4-0/+715
The RTD SoCs share a similar design for pinmux and pinconfig. This common pinctrl driver supports different variants within the RTD SoCs. Signed-off-by: Tzuyi Chang <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Linus Walleij <[email protected]>