mpc85xx: replace probe with compatible

Upstream commit does this for simple cases, which all of these are.

Commit: 1c96fcdef8c7492ecf34ed70102a1ae5253ef9d1

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/16345
Signed-off-by: Robert Marko <robimarko@gmail.com>
This commit is contained in:
Rosen Penev 2024-09-06 15:08:18 -07:00 committed by Robert Marko
parent 4aacd51b2f
commit 078cade9f8
10 changed files with 10 additions and 120 deletions

View File

@ -13,7 +13,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -57,19 +56,9 @@ static void __init br200_wp_setup_arch(void)
machine_arch_initcall(br200_wp, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init br200_wp_probe(void)
{
if (of_machine_is_compatible("aerohive,br200-wp"))
return 1;
return 0;
}
define_machine(br200_wp) {
.name = "P1020 RDB",
.probe = br200_wp_probe,
.compatible = "aerohive,br200-wp",
.setup_arch = br200_wp_setup_arch,
.init_IRQ = br200_wp_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -62,19 +61,9 @@ static void __init firebox_t10_setup_arch(void)
machine_arch_initcall(firebox_t10, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init firebox_t10_probe(void)
{
if (of_machine_is_compatible("watchguard,firebox-t10"))
return 1;
return 0;
}
define_machine(firebox_t10) {
.name = "P1010 RDB",
.probe = firebox_t10_probe,
.compatible = "watchguard,firebox-t10",
.setup_arch = firebox_t10_setup_arch,
.init_IRQ = firebox_t10_pic_init,
#ifdef CONFIG_PCI

View File

@ -18,7 +18,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -64,19 +63,9 @@ static void __init hiveap_330_setup_arch(void)
machine_arch_initcall(hiveap_330, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init hiveap_330_probe(void)
{
if (of_machine_is_compatible("aerohive,hiveap-330"))
return 1;
return 0;
}
define_machine(hiveap_330) {
.name = "P1020 RDB",
.probe = hiveap_330_probe,
.compatible = "aerohive,hiveap-330",
.setup_arch = hiveap_330_setup_arch,
.init_IRQ = hiveap_330_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -66,19 +65,9 @@ static void __init msm_setup_arch(void)
machine_arch_initcall(msm, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init msm_probe(void)
{
if (of_machine_is_compatible("hpe,msm460"))
return 1;
return 0;
}
define_machine(msm) {
.name = "P1020 RDB",
.probe = msm_probe,
.compatible = "hpe,msm460",
.setup_arch = msm_setup_arch,
.init_IRQ = msm_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -66,19 +65,9 @@ static void __init panda_setup_arch(void)
machine_arch_initcall(panda, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init panda_probe(void)
{
if (of_machine_is_compatible("ocedo,panda"))
return 1;
return 0;
}
define_machine(panda) {
.name = "P1020 RDB",
.probe = panda_probe,
.compatible = "ocedo,panda",
.setup_arch = panda_setup_arch,
.init_IRQ = panda_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -62,19 +61,9 @@ static void __init red_15w_rev1_setup_arch(void)
machine_arch_initcall(red_15w_rev1, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init red_15w_rev1_probe(void)
{
if (of_machine_is_compatible("sophos,red-15w-rev1"))
return 1;
return 0;
}
define_machine(red_15w_rev1) {
.name = "P1010 RDB",
.probe = red_15w_rev1_probe,
.compatible = "sophos,red-15w-rev1",
.setup_arch = red_15w_rev1_setup_arch,
.init_IRQ = red_15w_rev1_pic_init,
#ifdef CONFIG_PCI

View File

@ -18,7 +18,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -59,19 +58,9 @@ static void __init tl_wdr4900_v1_setup_arch(void)
machine_arch_initcall(tl_wdr4900_v1, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init tl_wdr4900_v1_probe(void)
{
if (of_machine_is_compatible("tplink,tl-wdr4900-v1"))
return 1;
return 0;
}
define_machine(tl_wdr4900_v1) {
.name = "Freescale P1014",
.probe = tl_wdr4900_v1_probe,
.compatible = "tplink,tl-wdr4900-v1",
.setup_arch = tl_wdr4900_v1_setup_arch,
.init_IRQ = tl_wdr4900_v1_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -66,19 +65,9 @@ static void __init ws_ap3710i_setup_arch(void)
machine_arch_initcall(ws_ap3710i, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init ws_ap3710i_probe(void)
{
if (of_machine_is_compatible("enterasys,ws-ap3710i"))
return 1;
return 0;
}
define_machine(ws_ap3710i) {
.name = "P1020 RDB",
.probe = ws_ap3710i_probe,
.compatible = "enterasys,ws-ap3710i",
.setup_arch = ws_ap3710i_setup_arch,
.init_IRQ = ws_ap3710i_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -62,19 +61,9 @@ static void __init wsap3715i_setup_arch(void)
machine_arch_initcall(wsap3715i, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init wsap3715i_probe(void)
{
if (of_machine_is_compatible("enterasys,ws-ap3715i"))
return 1;
return 0;
}
define_machine(wsap3715i) {
.name = "P1010 RDB",
.probe = wsap3715i_probe,
.compatible = "enterasys,ws-ap3715i",
.setup_arch = wsap3715i_setup_arch,
.init_IRQ = wsap3715i_pic_init,
#ifdef CONFIG_PCI

View File

@ -20,7 +20,6 @@
#include <linux/kernel.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/of_platform.h>
#include <asm/time.h>
#include <asm/machdep.h>
@ -66,19 +65,9 @@ static void __init ws_ap3825i_setup_arch(void)
machine_arch_initcall(ws_ap3825i, mpc85xx_common_publish_devices);
/*
* Called very early, device-tree isn't unflattened
*/
static int __init ws_ap3825i_probe(void)
{
if (of_machine_is_compatible("extreme-networks,ws-ap3825i"))
return 1;
return 0;
}
define_machine(ws_ap3825i) {
.name = "P1020 RDB",
.probe = ws_ap3825i_probe,
.compatible = "extreme-networks,ws-ap3825i",
.setup_arch = ws_ap3825i_setup_arch,
.init_IRQ = ws_ap3825i_pic_init,
#ifdef CONFIG_PCI