-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Illumos - 5408 managing ZFS cache devices requires lots of RAM
5408 managing ZFS cache devices requires lots of RAM Reviewed by: Christopher Siden <christopher.siden@delphix.com> Reviewed by: George Wilson <george.wilson@delphix.com> Reviewed by: Matthew Ahrens <mahrens@delphix.com> Reviewed by: Don Brady <dev.fs.zfs@gmail.com> Reviewed by: Josef 'Jeff' Sipek <josef.sipek@nexenta.com> Approved by: Garrett D'Amore <garrett@damore.org> Ported by: Tim Chase <tim@chase2k.com> Porting notes: Due to the restructuring of the ARC-related structures, this patch conflicts with at least the following existing ZoL commits: 6e1d727 Fix inaccurate arcstat_l2_hdr_size calculations The ARC_SPACE_HDRS constant no longer exists and has been somewhat equivalently replaced by HDR_L2ONLY_SIZE. e0b0ca9 Add visibility in to cached dbufs The new layering of l{1,2}arc_buf_hdr_t within the arc_buf_hdr struct requires additional structure member names to be used when referencing the inner items. Also, the presence of L1 or L2 inner member is indicated by flags using the new HDR_HAS_L{1,2}HDR macros. conflicts due to #2129 solely and/or in combination with these changes, in: cmd/ztest/ztest.c @ztest_dmu_read_write_zcopy abd_copy_from_buf(bigbuf_arcbufs[j]->b_data, (caddr_t)bigbuf + (off - bigoff), chunksize); stays, only if-statement above is expanded to: if (i != 5 || chunksize < (SPA_MINBLOCKSIZE * 2)) { module/zfs/arc.c @l2arc_decompress_zio bzero(hdr->b_buf->b_data, hdr->b_size); to abd_zero(hdr->b_buf->b_data, hdr->b_size); moved: struct l2arc_buf_hdr { to typedef struct l2arc_buf_hdr { keeping in mind for later: /* temporary buffer holder for in-flight compressed data */ abd_t *b_tmp_cdata; @l2arc_release_cdata_buf(arc_buf_hdr_t *hdr) abd_free(l2hdr->b_tmp_cdata, hdr->b_size); to zio_data_buf_free(l2hdr->b_tmp_cdata, hdr->b_size); to abd_free(hdr->b_l1hdr.b_tmp_cdata, hdr->b_size); @l2arc_decompress_zio(zio_t *zio, arc_buf_hdr_t *hdr, enum zio_compress c) bzero(hdr->b_buf->b_data, hdr->b_size); to bzero(hdr->b_l1hdr.b_buf->b_data, hdr->b_size) abd_zero(hdr->b_buf->b_data, hdr->b_size); to abd_zero(hdr->b_l1hdr.b_buf->b_data, hdr->b_size); line below that: zio->io_data = zio->io_orig_data = hdr->b_buf->b_data; to zio->io_data = zio->io_orig_data = hdr->b_l1hdr.b_buf->b_data; merge conflict in @arc_cksum_equal(arc_buf_t *buf) fletcher_2_native(buf->b_data, buf->b_hdr->b_size, &zc); to abd_fletcher_2_native(buf->b_data, buf->b_hdr->b_size, &zc); (no change) @arc_access(arc_buf_hdr_t *hdr, kmutex_t *hash_lock) cmn_err(CE_PANIC, "invalid arc state 0x%p", hdr->b_state); to cmn_err(CE_PANIC, "invalid arc state 0x%p", hdr->b_l1hdr.b_state); in include/sys/arc_impl.h void *b_tmp_cdata; to abd_t *b_tmp_cdata;
- Loading branch information
1 parent
115a8c2
commit af0684c
Showing
5 changed files
with
948 additions
and
634 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.