summaryrefslogtreecommitdiff
path: root/drivers/mfd/cgbc-core.c
AgeCommit message (Collapse)Author
2025-03-21mfd: cgbc-core: Add support for conga-SA8Thomas Richard
Add Board Controller support for the conga-SA8 module. Signed-off-by: Thomas Richard <thomas.richard@bootlin.com> Link: https://lore.kernel.org/r/20250318-b4-cgbc-sa8-support-v1-1-6ae9ec443c05@bootlin.com Signed-off-by: Lee Jones <lee@kernel.org>
2025-03-21mfd: cgbc: Add support for HWMONThomas Richard
The Board Controller has some internal sensors. Add a hwmon cell for the cgbc-hwmon driver which adds support for temperature, voltage, current and fan sensors. Signed-off-by: Thomas Richard <thomas.richard@bootlin.com> Link: https://lore.kernel.org/r/20250203-congatec-board-controller-hwmon-v4-2-ff6c76a4662c@bootlin.com Signed-off-by: Lee Jones <lee@kernel.org>
2025-03-14mfd: cgbc-core: Cleanup signedness in cgbc_session_request()Dan Carpenter
This doesn't affect how the code works because there are some implicit casts, but the "ret" variable is used to hold negative error codes so it should be type int. Declare it as "int" instead of "unsigned int". Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org> Link: https://lore.kernel.org/r/9e812dfa-e216-4e40-bbf0-d0b63b110bb0@stanley.mountain Signed-off-by: Lee Jones <lee@kernel.org>
2024-11-05mfd: cgbc-core: Fix error handling paths in cgbc_init_device()Christophe JAILLET
If an error occurs after a cgbc_session_request() call, it should be balanced by a corresponding cgbc_session_release(), as already done in the remove function. Fixes: 6f1067cfbee7 ("mfd: Add Congatec Board Controller driver") Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Reviewed-by: Thomas Richard <thomas.richard@bootlin.com> Link: https://lore.kernel.org/r/83194335554146efc52c331993f083bd765db6f9.1730205085.git.christophe.jaillet@wanadoo.fr Signed-off-by: Lee Jones <lee@kernel.org>
2024-11-01mfd: Switch back to struct platform_driver::remove()Uwe Kleine-König
After commit 0edb555a65d1 ("platform: Make platform_driver::remove() return void") .remove() is (again) the right callback to implement for platform drivers. Convert all platform drivers below drivers/mfd to use .remove(), with the eventual goal to drop struct platform_driver::remove_new(). As .remove() and .remove_new() have the same prototypes, conversion is done by just changing the structure member name in the driver initializer. On the way do a few whitespace changes to make indention consistent. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> Link: https://lore.kernel.org/r/20241025102943.250184-2-u.kleine-koenig@baylibre.com Signed-off-by: Lee Jones <lee@kernel.org>
2024-10-09mfd: Add Congatec Board Controller driverThomas Richard
Add core MFD driver for the Board Controller found on some Congatec SMARC module. This Board Controller provides functions like watchdog, GPIO, and I2C busses. This commit adds support only for the conga-SA7 module. Signed-off-by: Thomas Richard <thomas.richard@bootlin.com> Link: https://lore.kernel.org/r/20241001-congatec-board-controller-v3-1-39ceceed5c47@bootlin.com Signed-off-by: Lee Jones <lee@kernel.org>