Page MenuHomeFreeBSD

D57586.id179730.diff
No OneTemporary

D57586.id179730.diff

Index: sys/compat/linuxkpi/common/include/linux/kobject.h
===================================================================
--- sys/compat/linuxkpi/common/include/linux/kobject.h
+++ sys/compat/linuxkpi/common/include/linux/kobject.h
@@ -60,7 +60,22 @@
struct kref kref;
const struct kobj_type *ktype;
struct list_head entry;
- struct sysctl_oid *oidp;
+ union {
+ struct sysctl_oid *oidp;
+
+ /*
+ * On Linux, a `struct kernfs_node *` pointer, representing a
+ * directory in sysfs, is kept in the `sd` struct field.
+ *
+ * We don't have that on FreeBSD because we use sysctls
+ * instead. Let's alias the sysctl OID pointer to `sd`. This
+ * pointer is checked by the DRM drivers using:
+ * if (var->kobj.sd) {
+ * ...
+ * }
+ */
+ void *sd;
+ };
struct kset *kset;
};

File Metadata

Mime Type
text/plain
Expires
Fri, Aug 7, 9:07 AM (20 h, 47 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
36159026
Default Alt Text
D57586.id179730.diff (828 B)

Event Timeline