QE: use subsys_initcall to init qe
Use subsys_initcall to init qe to adapt ARM architecture. Remove qe_reset from PowerPC platform file. Signed-off-by: Zhao Qiang <qiang.zhao@freescale.com> Signed-off-by: Scott Wood <scottwood@freescale.com>
This commit is contained in:
parent
1291e49e89
commit
302c059f2e
@ -136,8 +136,6 @@ static void __init mpc83xx_km_setup_arch(void)
|
|||||||
mpc83xx_setup_pci();
|
mpc83xx_setup_pci();
|
||||||
|
|
||||||
#ifdef CONFIG_QUICC_ENGINE
|
#ifdef CONFIG_QUICC_ENGINE
|
||||||
qe_reset();
|
|
||||||
|
|
||||||
np = of_find_node_by_name(NULL, "par_io");
|
np = of_find_node_by_name(NULL, "par_io");
|
||||||
if (np != NULL) {
|
if (np != NULL) {
|
||||||
par_io_init(np);
|
par_io_init(np);
|
||||||
|
@ -74,8 +74,6 @@ static void __init mpc832x_sys_setup_arch(void)
|
|||||||
mpc83xx_setup_pci();
|
mpc83xx_setup_pci();
|
||||||
|
|
||||||
#ifdef CONFIG_QUICC_ENGINE
|
#ifdef CONFIG_QUICC_ENGINE
|
||||||
qe_reset();
|
|
||||||
|
|
||||||
if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) {
|
if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) {
|
||||||
par_io_init(np);
|
par_io_init(np);
|
||||||
of_node_put(np);
|
of_node_put(np);
|
||||||
|
@ -203,8 +203,6 @@ static void __init mpc832x_rdb_setup_arch(void)
|
|||||||
mpc83xx_setup_pci();
|
mpc83xx_setup_pci();
|
||||||
|
|
||||||
#ifdef CONFIG_QUICC_ENGINE
|
#ifdef CONFIG_QUICC_ENGINE
|
||||||
qe_reset();
|
|
||||||
|
|
||||||
if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) {
|
if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) {
|
||||||
par_io_init(np);
|
par_io_init(np);
|
||||||
of_node_put(np);
|
of_node_put(np);
|
||||||
|
@ -82,8 +82,6 @@ static void __init mpc836x_mds_setup_arch(void)
|
|||||||
mpc83xx_setup_pci();
|
mpc83xx_setup_pci();
|
||||||
|
|
||||||
#ifdef CONFIG_QUICC_ENGINE
|
#ifdef CONFIG_QUICC_ENGINE
|
||||||
qe_reset();
|
|
||||||
|
|
||||||
if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) {
|
if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) {
|
||||||
par_io_init(np);
|
par_io_init(np);
|
||||||
of_node_put(np);
|
of_node_put(np);
|
||||||
|
@ -35,9 +35,6 @@ static void __init mpc836x_rdk_setup_arch(void)
|
|||||||
ppc_md.progress("mpc836x_rdk_setup_arch()", 0);
|
ppc_md.progress("mpc836x_rdk_setup_arch()", 0);
|
||||||
|
|
||||||
mpc83xx_setup_pci();
|
mpc83xx_setup_pci();
|
||||||
#ifdef CONFIG_QUICC_ENGINE
|
|
||||||
qe_reset();
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -105,7 +105,6 @@ void __init mpc85xx_qe_init(void)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
qe_reset();
|
|
||||||
of_node_put(np);
|
of_node_put(np);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -671,6 +671,19 @@ unsigned int qe_get_num_of_snums(void)
|
|||||||
}
|
}
|
||||||
EXPORT_SYMBOL(qe_get_num_of_snums);
|
EXPORT_SYMBOL(qe_get_num_of_snums);
|
||||||
|
|
||||||
|
static int __init qe_init(void)
|
||||||
|
{
|
||||||
|
struct device_node *np;
|
||||||
|
|
||||||
|
np = of_find_compatible_node(NULL, NULL, "fsl,qe");
|
||||||
|
if (!np)
|
||||||
|
return -ENODEV;
|
||||||
|
qe_reset();
|
||||||
|
of_node_put(np);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
subsys_initcall(qe_init);
|
||||||
|
|
||||||
#if defined(CONFIG_SUSPEND) && defined(CONFIG_PPC_85xx)
|
#if defined(CONFIG_SUSPEND) && defined(CONFIG_PPC_85xx)
|
||||||
static int qe_resume(struct platform_device *ofdev)
|
static int qe_resume(struct platform_device *ofdev)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user