mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-11-17 01:51:00 +03:00
Exclude data from cores unconditionally and metadata conditionally
This change allows us to align the code dump logic across platforms. Reviewed-by: Jorgen Lundman <lundman@lundman.net> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Don Brady <don.brady@delphix.com> Signed-off-by: Matt Macy <mmacy@FreeBSD.org> Closes #9691
This commit is contained in:
parent
ea79e90f99
commit
3c502d3b75
@ -269,6 +269,7 @@ enum zio_wait_type {
|
||||
|
||||
typedef void zio_done_func_t(zio_t *zio);
|
||||
|
||||
extern int zio_exclude_metadata;
|
||||
extern int zio_dva_throttle_enabled;
|
||||
extern const char *zio_type_name[ZIO_TYPES];
|
||||
|
||||
|
@ -121,6 +121,11 @@ int zfs_sync_pass_rewrite = 2; /* rewrite new bps starting in this pass */
|
||||
*/
|
||||
#define IO_IS_ALLOCATING(zio) ((zio)->io_orig_pipeline & ZIO_STAGE_DVA_ALLOCATE)
|
||||
|
||||
/*
|
||||
* Enable smaller cores by excluding metadata
|
||||
* allocations as well.
|
||||
*/
|
||||
int zio_exclude_metadata = 0;
|
||||
int zio_requeue_io_start_cut_in_line = 1;
|
||||
|
||||
#ifdef ZFS_DEBUG
|
||||
@ -153,7 +158,11 @@ zio_init(void)
|
||||
size_t size = (c + 1) << SPA_MINBLOCKSHIFT;
|
||||
size_t p2 = size;
|
||||
size_t align = 0;
|
||||
size_t cflags = (size > zio_buf_debug_limit) ? KMC_NODEBUG : 0;
|
||||
size_t data_cflags, cflags;
|
||||
|
||||
data_cflags = KMC_NODEBUG;
|
||||
cflags = (zio_exclude_metadata || size > zio_buf_debug_limit) ?
|
||||
KMC_NODEBUG : 0;
|
||||
|
||||
#if defined(_ILP32) && defined(_KERNEL)
|
||||
/*
|
||||
@ -201,7 +210,7 @@ zio_init(void)
|
||||
(void) sprintf(name, "zio_data_buf_%lu", (ulong_t)size);
|
||||
zio_data_buf_cache[c] = kmem_cache_create(name, size,
|
||||
align, NULL, NULL, NULL, NULL,
|
||||
data_alloc_arena, cflags);
|
||||
data_alloc_arena, data_cflags);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user