]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
dm: cpu: Test against cpu_ops->get_info in cpu_get_info()
authorBin Meng <bmeng.cn@gmail.com>
Fri, 12 Jun 2015 06:52:19 +0000 (14:52 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Wed, 9 Sep 2015 11:29:22 +0000 (13:29 +0200)
In cpu_get_info() it wrongly tests against cpu_ops->get_desc to see
if it is NULL. It should test against cpu_ops->get_info.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
drivers/cpu/cpu-uclass.c

index aa0267ca03e9c7cf3c37fac47c822e084ba23ec4..d6be9d4dcf5cd534a9efb5627a91dfe405887065 100644 (file)
@@ -26,7 +26,7 @@ int cpu_get_info(struct udevice *dev, struct cpu_info *info)
 {
        struct cpu_ops *ops = cpu_get_ops(dev);
 
-       if (!ops->get_desc)
+       if (!ops->get_info)
                return -ENOSYS;
 
        return ops->get_info(dev, info);