]> git.baikalelectronics.ru Git - kernel.git/commit
phy: miphy365x: Avoid calling of_get_child_count() multiple times
authorAxel Lin <axel.lin@ingics.com>
Tue, 24 Feb 2015 11:53:45 +0000 (19:53 +0800)
committerKishon Vijay Abraham I <kishon@ti.com>
Wed, 4 Mar 2015 13:01:47 +0000 (18:31 +0530)
commit99d9acd987a1b13e51ed3054dad6f1b2036f4347
tree1855d7b75b4234c4029f9ecd4f3b88018cc0fea1
parent344eb10866378701da295dd1a9719f64545ea0a8
phy: miphy365x: Avoid calling of_get_child_count() multiple times

Currently, of_get_child_count() is called in each iteration of the for loop in
miphy365x_xlate(). This patch stores the return value of of_get_child_count()
in miphy_dev->nphys and call of_get_child_count() once in miphy365x_probe().

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
drivers/phy/phy-miphy365x.c