mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
target/s390x: Introduce function when exiting PV
Replace an existing macro (s390_pv_cmd_exit) that looks like a function with an actual function. The function will be used when exiting PV instead of the macro. Reviewed-by: Steffen Eiden <seiden@linux.ibm.com> Reviewed-by: Janosch Frank <frankja@linux.ibm.com> Signed-off-by: Gautam Gala <ggala@linux.ibm.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Message-ID: <20250423080915.1048123-3-ggala@linux.ibm.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
This commit is contained in:
parent
2e6a9f03ba
commit
e27cbd17dd
1 changed files with 6 additions and 8 deletions
|
@ -59,14 +59,12 @@ static int __s390_pv_cmd(uint32_t cmd, const char *cmdname, void *data,
|
|||
*/
|
||||
#define s390_pv_cmd(cmd, data) __s390_pv_cmd(cmd, #cmd, data, NULL)
|
||||
#define s390_pv_cmd_pvrc(cmd, data, pvrc) __s390_pv_cmd(cmd, #cmd, data, pvrc)
|
||||
#define s390_pv_cmd_exit(cmd, data) \
|
||||
{ \
|
||||
int rc; \
|
||||
\
|
||||
rc = __s390_pv_cmd(cmd, #cmd, data, NULL); \
|
||||
if (rc) { \
|
||||
exit(1); \
|
||||
} \
|
||||
|
||||
static void s390_pv_cmd_exit(uint32_t cmd, void *data)
|
||||
{
|
||||
if (s390_pv_cmd(cmd, data)) {
|
||||
exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
int s390_pv_query_info(void)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue