提交 3c576de3 编写于 作者: J Jakub Kicinski 提交者: David S. Miller

nfp: fix readq on absolute RTsyms

Return the error and report value through the output param.

Fixes: 640917dd ("nfp: support access to absolute RTsyms")
Reported-by: NDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: NJakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: NFrancois H. Theron <francois.theron@netronome.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 9e7e6cab
......@@ -337,8 +337,10 @@ int __nfp_rtsym_readq(struct nfp_cpp *cpp, const struct nfp_rtsym *sym,
u64 addr;
int err;
if (sym->type == NFP_RTSYM_TYPE_ABS)
return sym->addr;
if (sym->type == NFP_RTSYM_TYPE_ABS) {
*value = sym->addr;
return 0;
}
err = nfp_rtsym_to_dest(cpp, sym, action, token, off, &cpp_id, &addr);
if (err)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册