base/core.c: improve comment of the function device_find_child()
authorFederico Vaga <federico.vaga@gmail.com>
Mon, 15 Apr 2013 09:18:11 +0000 (11:18 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 21 May 2013 16:29:00 +0000 (09:29 -0700)
Signed-off-by: Federico Vaga <federico.vaga@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/core.c

index 0163124..3c8512f 100644 (file)
@@ -1372,6 +1372,8 @@ int device_for_each_child(struct device *parent, void *data,
  * if it does.  If the callback returns non-zero and a reference to the
  * current device can be obtained, this function will return to the caller
  * and not iterate over any more devices.
+ *
+ * NOTE: you will need to drop the reference with put_device() after use.
  */
 struct device *device_find_child(struct device *parent, void *data,
                                 int (*match)(struct device *dev, void *data))