--- zzzz-none-000/linux-4.4.60/drivers/of/base.c 2017-04-08 07:53:53.000000000 +0000 +++ dragonfly-4020-701/linux-4.4.60/drivers/of/base.c 2018-11-08 13:36:17.000000000 +0000 @@ -143,7 +143,7 @@ /* Important: Don't leak passwords */ bool secure = strncmp(pp->name, "security-", 9) == 0; - if (!IS_ENABLED(CONFIG_SYSFS)) + if (!IS_ENABLED(CONFIG_SYSFS) || IS_ENABLED(CONFIG_AVM_THIN_SYSFS)) return 0; if (!of_kset || !of_node_is_attached(np)) @@ -167,7 +167,7 @@ struct property *pp; int rc; - if (!IS_ENABLED(CONFIG_SYSFS)) + if (!IS_ENABLED(CONFIG_SYSFS) || IS_ENABLED(CONFIG_AVM_THIN_SYSFS)) return 0; if (!of_kset) @@ -197,6 +197,7 @@ void __init of_core_init(void) { +#if !defined(CONFIG_AVM_THIN_SYSFS) struct device_node *np; /* Create the kset, and register existing nodes */ @@ -214,6 +215,7 @@ /* Symlink in /proc as required by userspace ABI */ if (of_root) proc_symlink("device-tree", NULL, "/sys/firmware/devicetree/base"); +#endif } static struct property *__of_find_property(const struct device_node *np, @@ -1767,7 +1769,7 @@ void __of_remove_property_sysfs(struct device_node *np, struct property *prop) { - if (!IS_ENABLED(CONFIG_SYSFS)) + if (!IS_ENABLED(CONFIG_SYSFS) || IS_ENABLED(CONFIG_AVM_THIN_SYSFS)) return; /* at early boot, bail here and defer setup to of_init() */ @@ -1834,7 +1836,7 @@ void __of_update_property_sysfs(struct device_node *np, struct property *newprop, struct property *oldprop) { - if (!IS_ENABLED(CONFIG_SYSFS)) + if (!IS_ENABLED(CONFIG_SYSFS) || IS_ENABLED(CONFIG_AVM_THIN_SYSFS)) return; /* At early boot, bail out and defer setup to of_init() */