[dahdi-commits] tzafrir: branch linux/tzafrir/sysfs r8712 - /linux/team/tzafrir/sysfs/drivers...

SVN commits to the DAHDI project dahdi-commits at lists.digium.com
Sun May 30 09:27:38 CDT 2010


Author: tzafrir
Date: Sun May 30 09:27:34 2010
New Revision: 8712

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=8712
Log:
wcfxo: Remove unused SysFS attributes code

Modified:
    linux/team/tzafrir/sysfs/drivers/dahdi/wcfxo.c

Modified: linux/team/tzafrir/sysfs/drivers/dahdi/wcfxo.c
URL: http://svnview.digium.com/svn/dahdi/linux/team/tzafrir/sysfs/drivers/dahdi/wcfxo.c?view=diff&rev=8712&r1=8711&r2=8712
==============================================================================
--- linux/team/tzafrir/sysfs/drivers/dahdi/wcfxo.c (original)
+++ linux/team/tzafrir/sysfs/drivers/dahdi/wcfxo.c Sun May 30 09:27:34 2010
@@ -239,44 +239,6 @@
 	{ "CTR21", 0, 0, 3, 0, 0, 3, 0 },	/* Austria, Belgium, Denmark, Finland, France, Germany, 
 										   Greece, Iceland, Ireland, Italy, Luxembourg, Netherlands,
 										   Norway, Portugal, Spain, Sweden, Switzerland, and UK */
-};
-
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,14)
-#define fxo_pvt_attr(field, format_string)                                    \
-static ssize_t                                                             \
-field##_show(struct device *dev, struct device_attribute *attr, char *buf) \
-{                                                                          \
-        struct dahdi_span	*span;                                     \
-        struct wcfxo		*pvt;                                      \
-                                                                           \
-        span = dev_to_span(dev);                                           \
-        pvt = (struct wcfxo*)(span->pvt);                                  \
-        return sprintf(buf, format_string, pvt->field);                    \
-}
-
-#else
-#define span_attr(field, format_string)                                    \
-static ssize_t                                                             \
-field##_show(struct device *dev, char *buf)                                \
-{                                                                          \
-        struct dahdi_span	*span;                                     \
-        struct wcfxo		*pvt;                                      \
-                                                                           \
-        span = dev_to_span(dev);                                           \
-        pvt = (struct wcfxo*)(span->pvt);                                  \
-        return sprintf(buf, format_string, pvt->field);                    \
-}
-#endif
-
-/* A number of sample attributes */
-fxo_pvt_attr(offhook, "%d\n");
-fxo_pvt_attr(battery, "%d\n");
-
-/* FIXME: currently unused. Keep it at attributes for a future device/driver */
-static struct device_attribute span_dev_attrs[] = {
-        __ATTR_RO(battery),
-        __ATTR_RO(offhook),
-        __ATTR_NULL,
 };
 
 




More information about the dahdi-commits mailing list