static inline struct ls_device *dt2ls_dev(struct dt_device *d)
{
- return container_of0(d, struct ls_device, ls_top_dev);
+ return container_of_safe(d, struct ls_device, ls_top_dev);
}
struct ls_object {
static inline struct ls_object *lu2ls_obj(struct lu_object *o)
{
- return container_of0(o, struct ls_object, ls_obj.do_lu);
+ return container_of_safe(o, struct ls_object, ls_obj.do_lu);
}
static inline struct dt_object *ls_locate(const struct lu_env *env,
#define LOS_MAGIC 0xdecafbee
-/**
- * Used in __local_file_create() for object lock role
- **/
-enum los_object_role {
- LOS_PARENT,
- LOS_CHILD,
-};
-
#endif