+ remove-__must_check-for-device_for_each_child.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Remove __must_check for device_for_each_child()
has been added to the -mm tree.  Its filename is
     remove-__must_check-for-device_for_each_child.patch

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

------------------------------------------------------
Subject: Remove __must_check for device_for_each_child()
From: Russell King <rmk+lkml@xxxxxxxxxxxxxxxx>

The return code from device_for_each_child() depends on the values which
the helper function returns.  If the helper function always returns zero,
it's utterly pointless to check the return code from
device_for_each_child().

The only code which knows if the return value should be checked is the
caller itself, so forcing the return code to always be checked is silly. 
Hence, remove the __must_check annotation.

Signed-off-by: Russell King <rmk+kernel@xxxxxxxxxxxxxxxx>
Cc: Greg KH <greg@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

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

diff -puN include/linux/device.h~remove-__must_check-for-device_for_each_child include/linux/device.h
--- a/include/linux/device.h~remove-__must_check-for-device_for_each_child
+++ a/include/linux/device.h
@@ -393,7 +393,7 @@ extern void device_unregister(struct dev
 extern void device_initialize(struct device * dev);
 extern int __must_check device_add(struct device * dev);
 extern void device_del(struct device * dev);
-extern int __must_check device_for_each_child(struct device *, void *,
+extern int device_for_each_child(struct device *, void *,
 		     int (*fn)(struct device *, void *));
 extern int device_rename(struct device *dev, char *new_name);
 
_

Patches currently in -mm which might be from rmk+lkml@xxxxxxxxxxxxxxxx are

remove-__must_check-for-device_for_each_child.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux