linux/net/bridge
Zhang Rui 91a6902958 sysfs: add parameter "struct bin_attribute *" in .read/.write methods for sysfs binary attributes
Well, first of all, I don't want to change so many files either.

What I do:
Adding a new parameter "struct bin_attribute *" in the
.read/.write methods for the sysfs binary attributes.

In fact, only the four lines change in fs/sysfs/bin.c and
include/linux/sysfs.h do the real work.
But I have to update all the files that use binary attributes
to make them compatible with the new .read and .write methods.
I'm not sure if I missed any. :(

Why I do this:
For a sysfs attribute, we can get a pointer pointing to the
struct attribute in the .show/.store method,
while we can't do this for the binary attributes.
I don't know why this is different, but this does make it not
so handy to use the binary attributes as the regular ones.
So I think this patch is reasonable. :)

Who benefits from it:
The patch that exposes ACPI tables in sysfs
requires such an improvement.
All the table binary attributes share the same .read method.
Parameter "struct bin_attribute *" is used to get
the table signature and instance number which are used to
distinguish different ACPI table binary attributes.

Without this parameter, we need to offer different .read methods
for different ACPI table binary attributes.
This is impossible as there are various ACPI tables on different
platforms, and we don't know what they are until they are loaded.

Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2007-07-11 16:09:09 -07:00
..
netfilter [NETLINK]: Switch cb_lock spinlock to mutex and allow to override it 2007-04-25 22:29:03 -07:00
br.c bridge: check kmem_cache_create() error 2007-04-25 22:28:51 -07:00
br_device.c [BRIDGE]: Fix warning in net-2.6.22 2007-04-25 22:29:16 -07:00
br_fdb.c [BRIDGE]: Reduce frequency of forwarding cleanup timer in bridge. 2007-05-31 01:23:38 -07:00
br_forward.c [NET]: Allow forwarding of ip_summed except CHECKSUM_COMPLETE 2007-04-25 22:28:16 -07:00
br_if.c [NET]: Rework dev_base via list_head (v3) 2007-05-03 15:13:45 -07:00
br_input.c [BRIDGE]: if no STP then forward all BPDUs 2007-04-25 22:30:02 -07:00
br_ioctl.c [NET]: Rework dev_base via list_head (v3) 2007-05-03 15:13:45 -07:00
br_netfilter.c [NETFILTER]: bridge netfilter: consolidate header pushing/pulling code 2007-05-03 03:36:16 -07:00
br_netlink.c [NET]: Rework dev_base via list_head (v3) 2007-05-03 15:13:45 -07:00
br_notify.c bridge: change when netlink events go to STP 2007-04-25 22:28:48 -07:00
br_private.h bridge: check kmem_cache_create() error 2007-04-25 22:28:51 -07:00
br_private_stp.h Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
br_stp.c [BRIDGE]: Round off STP perodic timers. 2007-05-31 01:23:39 -07:00
br_stp_bpdu.c bridge: add support for user mode STP 2007-04-25 22:28:48 -07:00
br_stp_if.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
br_stp_timer.c [BRIDGE]: Round off STP perodic timers. 2007-05-31 01:23:39 -07:00
br_sysfs_br.c sysfs: add parameter "struct bin_attribute *" in .read/.write methods for sysfs binary attributes 2007-07-11 16:09:09 -07:00
br_sysfs_if.c sysfs: kill unnecessary attribute->owner 2007-07-11 16:09:06 -07:00
Kconfig [BRIDGE]: use llc for receiving STP packets 2006-03-20 22:59:06 -08:00
Makefile [BRIDGE]: netlink interface for link management 2006-06-17 21:26:14 -07:00