reset: berlin: support module build
Make reset-berlin driver to be tristate module, support to build as
a module, this is useful for GKI.
Partially reverts commit ed4dba99ca
("reset: berlin: make it
explicitly non-modular")
Signed-off-by: Jisheng Zhang <Jisheng.Zhang@synaptics.com>
Link: https://lore.kernel.org/r/20210607181015.5b8d3711@xhacker.debian
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
This commit is contained in:
parent
4fb26fb83f
commit
5e787cdf03
|
@ -43,8 +43,9 @@ config RESET_BCM6345
|
||||||
This enables the reset controller driver for BCM6345 SoCs.
|
This enables the reset controller driver for BCM6345 SoCs.
|
||||||
|
|
||||||
config RESET_BERLIN
|
config RESET_BERLIN
|
||||||
bool "Berlin Reset Driver" if COMPILE_TEST
|
tristate "Berlin Reset Driver"
|
||||||
default ARCH_BERLIN
|
depends on ARCH_BERLIN || COMPILE_TEST
|
||||||
|
default m if ARCH_BERLIN
|
||||||
help
|
help
|
||||||
This enables the reset controller driver for Marvell Berlin SoCs.
|
This enables the reset controller driver for Marvell Berlin SoCs.
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
#include <linux/delay.h>
|
#include <linux/delay.h>
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
#include <linux/mfd/syscon.h>
|
#include <linux/mfd/syscon.h>
|
||||||
#include <linux/init.h>
|
#include <linux/module.h>
|
||||||
#include <linux/of.h>
|
#include <linux/of.h>
|
||||||
#include <linux/of_address.h>
|
#include <linux/of_address.h>
|
||||||
#include <linux/platform_device.h>
|
#include <linux/platform_device.h>
|
||||||
|
@ -93,6 +93,7 @@ static const struct of_device_id berlin_reset_dt_match[] = {
|
||||||
{ .compatible = "marvell,berlin2-reset" },
|
{ .compatible = "marvell,berlin2-reset" },
|
||||||
{ },
|
{ },
|
||||||
};
|
};
|
||||||
|
MODULE_DEVICE_TABLE(of, berlin_reset_dt_match);
|
||||||
|
|
||||||
static struct platform_driver berlin_reset_driver = {
|
static struct platform_driver berlin_reset_driver = {
|
||||||
.probe = berlin2_reset_probe,
|
.probe = berlin2_reset_probe,
|
||||||
|
@ -101,4 +102,9 @@ static struct platform_driver berlin_reset_driver = {
|
||||||
.of_match_table = berlin_reset_dt_match,
|
.of_match_table = berlin_reset_dt_match,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
builtin_platform_driver(berlin_reset_driver);
|
module_platform_driver(berlin_reset_driver);
|
||||||
|
|
||||||
|
MODULE_AUTHOR("Antoine Tenart <antoine.tenart@free-electrons.com>");
|
||||||
|
MODULE_AUTHOR("Sebastian Hesselbarth <sebastian.hesselbarth@gmail.com>");
|
||||||
|
MODULE_DESCRIPTION("Synaptics Berlin reset controller");
|
||||||
|
MODULE_LICENSE("GPL");
|
||||||
|
|
Loading…
Reference in New Issue