fix rtl8366s OF binding
authorJohn Crispin <john@openwrt.org>
Fri, 12 Apr 2013 18:56:05 +0000 (18:56 +0000)
committerJohn Crispin <john@openwrt.org>
Fri, 12 Apr 2013 18:56:05 +0000 (18:56 +0000)
Signed-off-by: John Crispin <blogic@openwrt.org>
SVN-Revision: 36323

target/linux/generic/files/drivers/net/phy/rtl8366s.c

index 196d49e4c6ee38736f650e424b259c14956f4e56..3dc2a87aed0b1db293e01ae8225d620e71b7d2e7 100644 (file)
@@ -256,7 +256,7 @@ static int rtl8366s_setup(struct rtl8366_smi *smi)
        int err;
 
        pdata = smi->parent->platform_data;
-       if (pdata->num_initvals && pdata->initvals) {
+       if (pdata && pdata->num_initvals && pdata->initvals) {
                unsigned i;
 
                dev_info(smi->parent, "applying initvals\n");
@@ -1110,7 +1110,7 @@ static int rtl8366s_remove(struct platform_device *pdev)
 
 #ifdef CONFIG_OF
 static const struct of_device_id rtl8366s_match[] = {
-       { .compatible = "rtl8366s" },
+       { .compatible = "realtek,rtl8366s" },
        {},
 };
 MODULE_DEVICE_TABLE(of, rtl8366s_match);