Print this page
5513 KM_NORMALPRI should be documented in kmem_alloc(9f) and kmem_cache_create(9f) man pages
14465 Present KM_NOSLEEP_LAZY as documented interface
Change-Id: I002ec28ddf390650f1fcba1ca94f6abfdb241439

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/smbsrv/smb2_fsctl_odx.c
          +++ new/usr/src/uts/common/fs/smbsrv/smb2_fsctl_odx.c
↓ open down ↓ 659 lines elided ↑ open up ↑
 660  660          }
 661  661  
 662  662          /*
 663  663           * Get a buffer used for copying, always
 664  664           * smb2_odx_buf_size (1M)
 665  665           *
 666  666           * Rather than sleep for this relatively large allocation,
 667  667           * allow the allocation to fail and return an error.
 668  668           * The client should then fall back to normal copy.
 669  669           */
 670      -        buffer = kmem_alloc(bufsize, KM_NOSLEEP | KM_NORMALPRI);
      670 +        buffer = kmem_alloc(bufsize, KM_NOSLEEP_LAZY);
 671  671          if (buffer == NULL) {
 672  672                  status = NT_STATUS_INSUFF_SERVER_RESOURCES;
 673  673                  goto out;
 674  674          }
 675  675  
 676  676          /*
 677  677           * Copy src to dst for xlen
 678  678           */
 679  679          resid = xlen;
 680  680          status = smb2_sparse_copy(sr, src_ofile, dst_ofile,
↓ open down ↓ 167 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX