qemu-e2k/include
Hanna Reitz 73895f3838 jobs: Give Job.force_cancel more meaning
We largely have two cancel modes for jobs:

First, there is actual cancelling.  The job is terminated as soon as
possible, without trying to reach a consistent result.

Second, we have mirror in the READY state.  Technically, the job is not
really cancelled, but it just is a different completion mode.  The job
can still run for an indefinite amount of time while it tries to reach a
consistent result.

We want to be able to clearly distinguish which cancel mode a job is in
(when it has been cancelled).  We can use Job.force_cancel for this, but
right now it only reflects cancel requests from the user with
force=true, but clearly, jobs that do not even distinguish between
force=false and force=true are effectively always force-cancelled.

So this patch has Job.force_cancel signify whether the job will
terminate as soon as possible (force_cancel=true) or whether it will
effectively remain running despite being "cancelled"
(force_cancel=false).

To this end, we let jobs that provide JobDriver.cancel() tell the
generic job code whether they will terminate as soon as possible or not,
and for jobs that do not provide that method we assume they will.

Signed-off-by: Hanna Reitz <hreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Message-Id: <20211006151940.214590-7-hreitz@redhat.com>
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
2021-10-07 10:42:34 +02:00
..
authz Prefer 'on' | 'off' over 'yes' | 'no' for bool options 2021-01-29 17:07:53 +00:00
block block: use int64_t instead of int in driver discard handlers 2021-09-29 13:46:32 -05:00
chardev chardev: add some comments about the class methods 2021-09-14 16:57:11 +04:00
crypto crypto: Make QCryptoTLSCreds* structures private 2021-06-29 18:30:24 +01:00
disas Drop the deprecated lm32 target 2021-05-12 18:20:25 +02:00
exec memory: Name all the memory listeners 2021-09-30 15:30:24 +02:00
fpu Remove leading underscores from QEMU defines 2021-06-21 05:49:01 +02:00
hw machine: Move smp_prefer_sockets to struct SMPCompatProps 2021-10-01 15:29:15 +02:00
io io: add qio_channel_readv_full_all_eof & qio_channel_readv_full_all helpers 2021-02-10 09:23:28 +00:00
libdecnumber include: Make headers more self-contained 2019-08-16 13:31:51 +02:00
migration vfio: Support for RamDiscardManager in the vIOMMU case 2021-07-08 15:54:45 -04:00
monitor target/i386: Add HMP and QMP interfaces for SGX 2021-09-30 15:30:24 +02:00
net vhost_net: do not assume nvqs is always 2 2021-09-04 17:34:05 -04:00
qapi qapi: introduce forwarding visitor 2021-07-23 18:17:17 +02:00
qemu jobs: Give Job.force_cancel more meaning 2021-10-07 10:42:34 +02:00
qom qom: export more functions for use with non-UserCreatable objects 2021-07-06 08:33:51 +02:00
scsi scsi: inline sg_io_sense_from_errno() into the callers. 2021-03-06 11:42:56 +01:00
semihosting semihosting: Move include/hw/semihosting/ -> include/semihosting/ 2021-03-10 15:34:12 +00:00
standard-headers linux-headers: Update 2021-07-09 11:01:06 +10:00
sysemu memory: Name all the memory listeners 2021-09-30 15:30:24 +02:00
tcg tcg: Remove tcg_global_reg_new defines 2021-09-14 12:00:20 -07:00
ui ui/gtk-egl: Wait for the draw signal for dmabuf blobs 2021-09-15 08:41:59 +02:00
user Remove leading underscores from QEMU defines 2021-06-21 05:49:01 +02:00
elf.h linux-user: elf: s390x: Prepare for Vector enhancements facility 2021-06-21 08:48:21 +02:00
glib-compat.h configure: bump min required glib version to 2.56 2021-06-02 09:11:32 +02:00
qemu-common.h qemu-common.h: Update copyright string to 2021 2021-03-09 22:19:24 +01:00
qemu-io.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
trace-tcg.h trace: get rid of generated-events.h/generated-events.c 2016-10-12 09:54:52 +02:00