Skip to contentSkip to conversation

base/core.c: improve comment of the function device_find_child()

PATCH New Federico Vaga 1 participant 1 message Apr 15, 2013 Driver core

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 base/core.c: improve comment of the function device_find_child()

---
 drivers/base/core.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/base/core.c +2 -0
index 016312437..3c8512f 100644
@@ -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))
Signature · 1 line
1.8.1.4