1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-22 11:17:19 +00:00
freebsd/sys/geom
Marcel Moolenaar 855be5b2c1 Make sure not to do I/O for more than MAXPHYS bytes. Doing so can cause
problems in our providers, such as a KASSERT in md(4). We can initiate
I/O for more than MAXPHYS bytes if we've been given a BIO for MAXPHYS
bytes, the blocks from which we're reading couldn't be compressed and
we had compression in preceeding blocks resulting in misalignment of
the blocks we're trying to read relative to the sector. We're forced to
round up the I/O length to make it an multiple of the sector size.

When we detect the condition, we'll reduce the block count and perform
a "short" read. In g_uzip_done() we need to consider the original I/O
length and stop early if we're about to deflate a block that we didn't
read. By using bio_completed in the cloned BIO and not bio_length to
check for this, we automatically and gracefully handle short reads that
our providers may be doing on top of the short reads we may initiate
ourselves.

Obtained from:	Juniper Networks, Inc.
2014-04-15 15:41:57 +00:00
..
bde
cache Partially revert r259080. bde@ pointed out that there are a lot more style bugs 2013-12-08 09:34:56 +00:00
concat Merge GEOM direct dispatch changes from the projects/camlock branch. 2013-10-22 08:22:19 +00:00
eli In g_eli_crypto_hmac_init(), zero out after using the ipad buffer, 2014-02-08 05:17:49 +00:00
gate Merge GEOM direct dispatch changes from the projects/camlock branch. 2013-10-22 08:22:19 +00:00
journal Partially revert r259080. bde@ pointed out that there are a lot more style bugs 2013-12-08 09:34:56 +00:00
label An all-or-nothing approach to labels isn't flexible enough. Embedded 2014-04-06 02:44:37 +00:00
linux_lvm
mirror Show error code when failing to destroy a mirror on delay 2014-04-05 03:01:29 +00:00
mountver
multipath Removed unneeded and dangerous assignment. It would probably cause NULL 2014-01-19 16:37:57 +00:00
nop gnop: make sure that newly allocated memory for softc is zeroed 2013-10-23 01:34:18 +00:00
part Align and round the partitionable disk space to 4K by default. 2014-04-12 20:28:39 +00:00
raid Fix wrong sizes used to access PD_Type and PD_State DDF metadata fields. 2014-04-10 16:00:33 +00:00
raid3
sched
shsec
stripe Do not increment bio_data in case of BIO_DELETE. 2014-04-10 10:12:56 +00:00
uncompress Fix the build with DEBUG enabled. Where possible, fix style(9) issues. 2014-02-07 13:06:48 +00:00
uzip Make sure not to do I/O for more than MAXPHYS bytes. Doing so can cause 2014-04-15 15:41:57 +00:00
vinum
virstor
zero Merge GEOM direct dispatch changes from the projects/camlock branch. 2013-10-22 08:22:19 +00:00
geom_aes.c
geom_bsd_enc.c
geom_bsd.c
geom_ccd.c
geom_ctl.c Always free sbuf in gctl_free(). 2014-01-23 21:30:31 +00:00
geom_ctl.h
geom_dev.c Fix bug introduced at r256607. We have to recalculate bp_resid here since 2013-12-12 08:23:28 +00:00
geom_disk.c Fix spelling error in g_trace() call. 2014-04-10 17:00:44 +00:00
geom_disk.h Reject attempts to attack a disk device that has the old NEEDSGIANT 2013-10-25 19:19:12 +00:00
geom_dump.c Escape special XML chars, returned by some devices, confusing XML parsers. 2013-11-27 14:25:06 +00:00
geom_event.c
geom_flashmap.c
geom_fox.c
geom_int.h Escape special XML chars, returned by some devices, confusing XML parsers. 2013-11-27 14:25:06 +00:00
geom_io.c Merge GEOM direct dispatch changes from the projects/camlock branch. 2013-10-22 08:22:19 +00:00
geom_kern.c Merge GEOM direct dispatch changes from the projects/camlock branch. 2013-10-22 08:22:19 +00:00
geom_map.c
geom_mbr_enc.c
geom_mbr.c
geom_pc98_enc.c
geom_pc98.c Change <sys/diskpc98.h> to not redefine the same symbols that are 2013-08-07 00:00:48 +00:00
geom_redboot.c
geom_slice.c Make sure we don't free memory that's already been freed by setting 2014-04-06 02:20:42 +00:00
geom_slice.h
geom_subr.c Make g_access() KASSERT() more useful. 2014-04-15 14:41:41 +00:00
geom_sunlabel_enc.c
geom_sunlabel.c
geom_vfs.c Merge GEOM direct dispatch changes from the projects/camlock branch. 2013-10-22 08:22:19 +00:00
geom_vfs.h
geom_vol_ffs.c
geom.h Improve ZFS N-way mirror read performance by using load and locality 2013-10-23 09:54:58 +00:00
notes