|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v3 3/8] gzip: refactor the gunzip window into common state
On 4/24/24 12:34, Daniel P. Smith wrote: Begin moving core state, in this case the gunzip window, into struct gunzip_state to allow a per decompression instance. In doing so, drop the define aliasing of window to slide. Signed-off-by: Daniel P. Smith <dpsmith@xxxxxxxxxxxxxxxxxxxx> --- xen/common/gzip/gunzip.c | 21 ++++++++---- xen/common/gzip/inflate.c | 68 +++++++++++++++++++-------------------- 2 files changed, 48 insertions(+), 41 deletions(-) diff --git a/xen/common/gzip/gunzip.c b/xen/common/gzip/gunzip.c index b7cadadcca8b..e47f10ae19ad 100644 --- a/xen/common/gzip/gunzip.c +++ b/xen/common/gzip/gunzip.c @@ -4,10 +4,12 @@ #include <xen/lib.h> #include <xen/mm.h>-static unsigned char *__initdata window;- #define WSIZE 0x80000000U+struct gunzip_state {+ unsigned char *window; +}; + static unsigned char *__initdata inbuf; static unsigned int __initdata insize;@@ -43,7 +45,7 @@ typedef unsigned long ulg;#endifstatic long __initdata bytes_out;-static void flush_window(void); +static void flush_window(struct gunzip_state *s);static __init void error(const char *x) Looks like I inadvertently dropped the corresponding free when breaking up the monolithic patch. v/r, dps
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |