kernel-hacking-2024-linux-s.../drivers/block
Stefano Stabellini 0930bba674 xen: modify kernel mappings corresponding to granted pages
If we want to use granted pages for AIO, changing the mappings of a user
vma and the corresponding p2m is not enough, we also need to update the
kernel mappings accordingly.
Currently this is only needed for pages that are created for user usages
through /dev/xen/gntdev. As in, pages that have been in use by the
kernel and use the P2M will not need this special mapping.
However there are no guarantees that in the future the kernel won't
start accessing pages through the 1:1 even for internal usage.

In order to avoid the complexity of dealing with highmem, we allocated
the pages lowmem.
We issue a HYPERVISOR_grant_table_op right away in
m2p_add_override and we remove the mappings using another
HYPERVISOR_grant_table_op in m2p_remove_override.
Considering that m2p_add_override and m2p_remove_override are called
once per page we use multicalls and hypercall batching.

Use the kmap_op pointer directly as argument to do the mapping as it is
guaranteed to be present up until the unmapping is done.
Before issuing any unmapping multicalls, we need to make sure that the
mapping has already being done, because we need the kmap->handle to be
set correctly.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
[v1: Removed GRANT_FRAME_BIT usage]
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
2011-09-29 10:32:58 -04:00
..
aoe
drbd Merge branch 'for-3.0-important' of git://git.drbd.org/linux-2.6-drbd into for-linus 2011-06-30 10:10:50 +02:00
paride block: fix mismerge of the DISK_EVENT_MEDIA_CHANGE removal 2011-06-02 05:29:19 +09:00
xen-blkback xen: modify kernel mappings corresponding to granted pages 2011-09-29 10:32:58 -04:00
amiflop.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
ataflop.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
brd.c brd: export module parameters 2011-05-26 21:06:50 +02:00
cciss.c cciss: fix compile issue 2011-05-06 08:27:00 -06:00
cciss.h cciss: do not attempt to read from a write-only register 2011-07-09 09:04:12 +02:00
cciss_cmd.h cciss: use new doorbell-bit-5 reset method 2011-05-06 08:23:55 -06:00
cciss_scsi.c atomic: use <linux/atomic.h> 2011-07-26 16:49:47 -07:00
cciss_scsi.h cciss: add cciss_tape_cmds module paramter 2011-05-06 08:23:59 -06:00
cpqarray.c
cpqarray.h
cryptoloop.c
DAC960.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
DAC960.h
floppy.c Merge branch 'idle-release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-idle-2.6 2011-05-29 11:18:09 -07:00
hd.c i8253: Create linux/i8253.h and use it in all 8253 related files 2011-06-09 15:01:37 +02:00
ida_cmd.h
ida_ioctl.h
Kconfig xen/blkback: Flesh out the description in the Kconfig. 2011-05-12 17:55:40 -04:00
loop.c loop: export module parameters 2011-05-27 07:59:25 +02:00
Makefile xen/blkback: Move it from drivers/xen to drivers/block 2011-04-18 14:30:26 -04:00
mg_disk.c
nbd.c nbd: adjust 'max_part' according to part_shift 2011-05-28 14:44:46 +02:00
osdblk.c
pktcdvd.c kill useless checks for sb->s_op == NULL 2011-07-20 01:44:21 -04:00
ps3disk.c
ps3vram.c
rbd.c rbd: set blk_queue request sizes to object size 2011-07-26 11:29:35 -07:00
rbd_types.h
smart1,2.h
sunvdc.c
swim.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
swim3.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
swim_asm.S
sx8.c
ub.c block: unexport DISK_EVENT_MEDIA_CHANGE for legacy/fringe drivers 2011-04-21 21:33:05 +02:00
umem.c
umem.h
viodasd.c Fix common misspellings 2011-03-31 11:26:23 -03:00
virtio_blk.c drivers, block: virtio_blk: Replace cryptic number with the macro 2011-05-30 11:14:13 +09:30
xd.c
xd.h
xen-blkfront.c xen-blkfront: Introduce BLKIF_OP_FLUSH_DISKCACHE support. 2011-05-12 08:56:03 -04:00
xsysace.c dt: remove extra xsysace platform_driver registration 2011-07-14 05:33:52 -06:00
z2ram.c