opal.h (ea0d856cb26d4d78b9529de49a0f89379224e2f9) opal.h (d0226d315dba5e401a124b394a1af5e35e082b08)
1/*
2 * PowerNV OPAL definitions.
3 *
4 * Copyright 2011 IBM Corp.
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version

--- 268 unchanged lines hidden (view full) ---

277struct opal_sg_list *opal_vmalloc_to_sg_list(void *vmalloc_addr,
278 unsigned long vmalloc_size);
279void opal_free_sg_list(struct opal_sg_list *sg);
280
281extern int opal_error_code(int rc);
282
283ssize_t opal_msglog_copy(char *to, loff_t pos, size_t count);
284
1/*
2 * PowerNV OPAL definitions.
3 *
4 * Copyright 2011 IBM Corp.
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * as published by the Free Software Foundation; either version

--- 268 unchanged lines hidden (view full) ---

277struct opal_sg_list *opal_vmalloc_to_sg_list(void *vmalloc_addr,
278 unsigned long vmalloc_size);
279void opal_free_sg_list(struct opal_sg_list *sg);
280
281extern int opal_error_code(int rc);
282
283ssize_t opal_msglog_copy(char *to, loff_t pos, size_t count);
284
285static inline int opal_get_async_rc(struct opal_msg msg)
286{
287 if (msg.msg_type != OPAL_MSG_ASYNC_COMP)
288 return OPAL_PARAMETER;
289 else
290 return be64_to_cpu(msg.params[1]);
291}
292
285#endif /* __ASSEMBLY__ */
286
287#endif /* _ASM_POWERPC_OPAL_H */
293#endif /* __ASSEMBLY__ */
294
295#endif /* _ASM_POWERPC_OPAL_H */