firmware: xlnx-zynqmp: fix compilation warning

Fix compilation warning when ZYNQMP_FIRMWARE is not defined.

include/linux/firmware/xlnx-zynqmp.h: In function
'zynqmp_pm_get_eemi_ops':
 include/linux/firmware/xlnx-zynqmp.h:363:9: error: implicit
 declaration of function 'ERR_PTR'
 [-Werror=implicit-function-declaration]
     363 |  return ERR_PTR(-ENODEV);

include/linux/firmware/xlnx-zynqmp.h:363:18: note: each undeclared
identifier is reported only once for each function it appears in
   include/linux/firmware/xlnx-zynqmp.h: In function
'zynqmp_pm_get_api_version':
   include/linux/firmware/xlnx-zynqmp.h:367:10: error: 'ENODEV'
undeclared (first use in this function)
     367 |  return -ENODEV;
         |          ^~~~~~

Signed-off-by: Wendy Liang <wendy.liang@xilinx.com>
Link: https://lore.kernel.org/r/1606205898-12642-1-git-send-email-wendy.liang@xilinx.com
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
This commit is contained in:
Wendy Liang 2020-11-24 00:18:18 -08:00 committed by Michal Simek
parent 7b1c9b8441
commit 463edf5a59

View File

@ -13,6 +13,8 @@
#ifndef __FIRMWARE_ZYNQMP_H__
#define __FIRMWARE_ZYNQMP_H__
#include <linux/err.h>
#define ZYNQMP_PM_VERSION_MAJOR 1
#define ZYNQMP_PM_VERSION_MINOR 0