Commit:     25478445c4a39318acbe08ba8df7945766cbb5b5
Parent:     50e8a2890ed0eeb7a11ae0c39144fcdd1cad1cf8
Author:     Alexey Dobriyan <[EMAIL PROTECTED]>
AuthorDate: Fri Feb 8 04:20:14 2008 -0800
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Fri Feb 8 09:22:32 2008 -0800

    Fix container_of() usage
    Using "attr" twice is not OK, because it effectively prohibits such
    container_of() on variables not named "attr".
    Signed-off-by: Alexey Dobriyan <[EMAIL PROTECTED]>
    Acked-by: Rusty Russell <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
 arch/sh/kernel/cpu/sh4/sq.c    |    2 +-
 drivers/lguest/lguest_device.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/sh/kernel/cpu/sh4/sq.c b/arch/sh/kernel/cpu/sh4/sq.c
index 3008c00..8250e01 100644
--- a/arch/sh/kernel/cpu/sh4/sq.c
+++ b/arch/sh/kernel/cpu/sh4/sq.c
@@ -263,7 +263,7 @@ struct sq_sysfs_attr {
        ssize_t (*store)(const char *buf, size_t count);
-#define to_sq_sysfs_attr(attr) container_of(attr, struct sq_sysfs_attr, attr)
+#define to_sq_sysfs_attr(a)    container_of(a, struct sq_sysfs_attr, attr)
 static ssize_t sq_sysfs_show(struct kobject *kobj, struct attribute *attr,
                             char *buf)
diff --git a/drivers/lguest/lguest_device.c b/drivers/lguest/lguest_device.c
index 84f85e2..1b2ec0b 100644
--- a/drivers/lguest/lguest_device.c
+++ b/drivers/lguest/lguest_device.c
@@ -47,7 +47,7 @@ struct lguest_device {
 /* Since the virtio infrastructure hands us a pointer to the virtio_device all
  * the time, it helps to have a curt macro to get a pointer to the struct
  * lguest_device it's enclosed in.  */
-#define to_lgdev(vdev) container_of(vdev, struct lguest_device, vdev)
+#define to_lgdev(vd) container_of(vd, struct lguest_device, vdev)
  * Device configurations
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at

Reply via email to