blob: 1a9bfb0597b5c0588538bbee7a3df39abb657585 [file] [log] [blame]
The Android Open Source Project1dc9e472009-03-03 19:28:35 -08001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 ****************************************************************************
11 ****************************************************************************/
12#ifndef _ATTRIBUTE_CONTAINER_H_
13#define _ATTRIBUTE_CONTAINER_H_
Ben Cheng4b29af02012-03-07 16:14:53 -080014
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080015#include <linux/device.h>
16#include <linux/list.h>
17#include <linux/klist.h>
18#include <linux/spinlock.h>
Ben Cheng4b29af02012-03-07 16:14:53 -080019
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080020struct attribute_container {
21 struct list_head node;
22 struct klist containers;
23 struct class *class;
24 struct class_device_attribute **attrs;
25 int (*match)(struct attribute_container *, struct device *);
26#define ATTRIBUTE_CONTAINER_NO_CLASSDEVS 0x01
27 unsigned long flags;
28};
Ben Cheng4b29af02012-03-07 16:14:53 -080029
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080030struct attribute_container *attribute_container_classdev_to_container(struct class_device *);
31struct class_device *attribute_container_find_class_device(struct attribute_container *, struct device *);
32struct class_device_attribute **attribute_container_classdev_to_attrs(const struct class_device *classdev);
Ben Cheng4b29af02012-03-07 16:14:53 -080033
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080034#endif