ChangeSet 1.1722.85.3, 2004/06/03 10:27:16-07:00, mochel@digitalimplant.org

[sysfs] Add attr_name() macro

- Returns the name of an embedded attribute in a higher-level 
  attribute.


 include/linux/sysfs.h |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


diff -Nru a/include/linux/sysfs.h b/include/linux/sysfs.h
--- a/include/linux/sysfs.h	Tue Jun 22 09:49:05 2004
+++ b/include/linux/sysfs.h	Tue Jun 22 09:49:05 2004
@@ -43,7 +43,7 @@
 
 #define __ATTR_NULL { .attr = { .name = NULL } }
 
-
+#define attr_name(_attr) (_attr).attr.name
 
 struct bin_attribute {
 	struct attribute	attr;
