HomeFreeBSD

Linux 2.6.39 compat, zlib_deflate_workspacesize()

Description

Linux 2.6.39 compat, zlib_deflate_workspacesize()

The function zlib_deflate_workspacesize() now take 2 arguments.
This was done to avoid always having to allocate the maximum size
workspace (268K). The caller can now specific the windowBits and
memLevel compression parameters to get a smaller workspace.

For our purposes we introduce a spl_zlib_deflate_workspacesize()
wrapper which accepts both arguments. When the two argument
version of zlib_deflate_workspacesize() is available the arguments
are passed through. When it's not we assume the worst case and
a maximally sized workspace is used.

Details

Provenance
Brian Behlendorf <behlendorf1@llnl.gov>Authored on Apr 20 2011, 9:22 PM
Parents
rGb1cbc4610c8b: Linux 2.6.39 compat, kern_path_parent()
Branches
Unknown
Tags
Unknown

Event Timeline

Brian Behlendorf <behlendorf1@llnl.gov> committed rG3dfc591ac400: Linux 2.6.39 compat, zlib_deflate_workspacesize() (authored by Brian Behlendorf <behlendorf1@llnl.gov>).Apr 20 2011, 9:39 PM