--- zzzz-none-000/linux-3.10.107/drivers/net/phy/mdio-mux-mmioreg.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/drivers/net/phy/mdio-mux-mmioreg.c 2021-02-04 17:41:59.000000000 +0000 @@ -15,7 +15,6 @@ #include #include #include -#include #include #include @@ -48,7 +47,7 @@ struct mdio_mux_mmioreg_state *s = data; if (current_child ^ desired_child) { - void *p = ioremap(s->phys, 1); + void __iomem *p = ioremap(s->phys, 1); uint8_t x, y; if (!p) @@ -114,12 +113,14 @@ if (!iprop || len != sizeof(uint32_t)) { dev_err(&pdev->dev, "mdio-mux child node %s is " "missing a 'reg' property\n", np2->full_name); + of_node_put(np2); return -ENODEV; } if (be32_to_cpup(iprop) & ~s->mask) { dev_err(&pdev->dev, "mdio-mux child node %s has " "a 'reg' value with unmasked bits\n", np2->full_name); + of_node_put(np2); return -ENODEV; } } @@ -146,7 +147,7 @@ return 0; } -static struct of_device_id mdio_mux_mmioreg_match[] = { +static const struct of_device_id mdio_mux_mmioreg_match[] = { { .compatible = "mdio-mux-mmioreg", }, @@ -157,7 +158,6 @@ static struct platform_driver mdio_mux_mmioreg_driver = { .driver = { .name = "mdio-mux-mmioreg", - .owner = THIS_MODULE, .of_match_table = mdio_mux_mmioreg_match, }, .probe = mdio_mux_mmioreg_probe,