Lines Matching refs:item

79  * @item:	Links us into the configfs subsystem hierarchy.
99 struct config_item item;
130 if (config_item_name(&nt->item))
131 config_item_get(&nt->item);
136 if (config_item_name(&nt->item))
137 config_item_put(&nt->item);
235 static struct netconsole_target *to_target(struct config_item *item)
237 return item ?
238 container_of(item, struct netconsole_target, item) :
246 static ssize_t enabled_show(struct config_item *item, char *buf)
248 return snprintf(buf, PAGE_SIZE, "%d\n", to_target(item)->enabled);
251 static ssize_t extended_show(struct config_item *item, char *buf)
253 return snprintf(buf, PAGE_SIZE, "%d\n", to_target(item)->extended);
256 static ssize_t dev_name_show(struct config_item *item, char *buf)
258 return snprintf(buf, PAGE_SIZE, "%s\n", to_target(item)->np.dev_name);
261 static ssize_t local_port_show(struct config_item *item, char *buf)
263 return snprintf(buf, PAGE_SIZE, "%d\n", to_target(item)->np.local_port);
266 static ssize_t remote_port_show(struct config_item *item, char *buf)
268 return snprintf(buf, PAGE_SIZE, "%d\n", to_target(item)->np.remote_port);
271 static ssize_t local_ip_show(struct config_item *item, char *buf)
273 struct netconsole_target *nt = to_target(item);
281 static ssize_t remote_ip_show(struct config_item *item, char *buf)
283 struct netconsole_target *nt = to_target(item);
291 static ssize_t local_mac_show(struct config_item *item, char *buf)
293 struct net_device *dev = to_target(item)->np.dev;
299 static ssize_t remote_mac_show(struct config_item *item, char *buf)
301 return snprintf(buf, PAGE_SIZE, "%pM\n", to_target(item)->np.remote_mac);
311 static ssize_t enabled_store(struct config_item *item,
314 struct netconsole_target *nt = to_target(item);
370 static ssize_t extended_store(struct config_item *item, const char *buf,
373 struct netconsole_target *nt = to_target(item);
380 config_item_name(&nt->item));
402 static ssize_t dev_name_store(struct config_item *item, const char *buf,
405 struct netconsole_target *nt = to_target(item);
411 config_item_name(&nt->item));
427 static ssize_t local_port_store(struct config_item *item, const char *buf,
430 struct netconsole_target *nt = to_target(item);
436 config_item_name(&nt->item));
450 static ssize_t remote_port_store(struct config_item *item,
453 struct netconsole_target *nt = to_target(item);
459 config_item_name(&nt->item));
473 static ssize_t local_ip_store(struct config_item *item, const char *buf,
476 struct netconsole_target *nt = to_target(item);
481 config_item_name(&nt->item));
509 static ssize_t remote_ip_store(struct config_item *item, const char *buf,
512 struct netconsole_target *nt = to_target(item);
517 config_item_name(&nt->item));
545 static ssize_t remote_mac_store(struct config_item *item, const char *buf,
548 struct netconsole_target *nt = to_target(item);
554 config_item_name(&nt->item));
598 static void netconsole_target_release(struct config_item *item)
600 kfree(to_target(item));
638 config_item_init_type_name(&nt->item, name, &netconsole_target_type);
645 return &nt->item;
649 struct config_item *item)
652 struct netconsole_target *nt = to_target(item);
665 config_item_put(&nt->item);