Date: Sat, 4 May 2019 16:52:59 -0400 From: Yoshihiro Ota <ota@j.email.ne.jp> To: freebsd-arch@freebsd.org Cc: delphij@freebsd.org, kib@freebsd.org, imp@freebsd.org, jmg@freebsd.org, markj@freebsd.org, sobomax@freebsd.org Subject: Re: Zlib Upgrade in kernel Message-ID: <20190504165259.68a44a451dbf0072814d923d@j.email.ne.jp> In-Reply-To: <20190326000956.83bd72411661511656ea1b5d@j.email.ne.jp> References: <20190326000956.83bd72411661511656ea1b5d@j.email.ne.jp>
next in thread | previous in thread | raw e-mail | index | archive | help
Hello, After I posted zlib upgrade effort about a month ago, I got feedbacks and went through iterations of changes. https://reviews.freebsd.org/D19706 is ready for another review. I have few unfamilar peices. If anyone can comment, that will be great. Q.1 Can zfs boot loader start from gzipped file system? Q.2 Does anyone run gzipped a.out format on the latest systems? I was able to run a.out and gzipped a.out on FreeBSD 2.2.9. I ran a.out grabbed fron 2.2.9 on 12-STABLE and 13-CURRENT but gzipped a.out didn't start. Q.3 Does anyone have/use arm5 with compressed kernel? These are short summaries of zlib and unzip related code at the phabricator: zlib - FreeBSD adjusted kernel zlib is moved into netgraph. - contrib/zlib is moved to sys/contrib/zlib and adjusted in both user land and kernel. - zlib copy in zfs is removed and uses sys/contrib/zlib. - CTF is modified to use uncompress(). unzip - Cleaned up sys/mips. - arm5 is untouched. - gzipped a.out execution is untouched although it is broken in 12-stable/13-current. - kgzip and kgzldr are removed. Regards, Hiro On Tue, 26 Mar 2019 00:09:56 -0400 Yoshihiro Ota <ota@j.email.ne.jp> wrote: > Hello, > > Our zlib in kernel has been quite out-dated. > I looked in and started updating. > > I use contrib/zlib files and sys/contrib/zstd to compile zlib with least amount of changes to > zlib side. I split crc32 functions and also added few compile options to distinguish zlib calls. > I have to relocate current one as netgraph uses FreeBSD specific implementation. > > I started wondering if I should move contrib/zlib to sys/contrib/zlib and wanted to get some feed-dated. > I looked in and started updating. > > I use contrib/zlib files and sys/contrib/zstd to compile zlib with least amount of changes to > zlib side. I split crc32 functions and also added few compile options to distinguish zlib calls. > I have to relocate current one as netgraph uses FreeBSD specific implementation. > > I started wondering if I should move contrib/zlib to sys/contrib/zlib and wanted to get some feed > back on some of coding policies. > > I created https://reviews.freebsd.org/D19706, and noted in new sys/sys/zlib.h: > /* > * #1 - sys/crc32.h is split out of sys/libkern.h to avoid conflicts > * between zlib's crc32 and system crc32. > * #2 - Use contrib/zstd/lib/freebsd's stdlib compatible includes. > * #3 - ZLIB_C is created con/kern.pre.mk to share compile paths. > * -I contrib/zlib > * -I sys/contrib/zstd/lib/freebsd > * #4 - sys/zlib.h defines these. > * Z_PREIFX > * NO_GZIP > * Z_SOLO - this is for libkern/zlib.c and not needed for clients of zlib. > * #5 - opencryptodeflate.c > * zfs.state->dummy is an address and doesn't seem to be useful. > * Its DTRACE probe is removed. > * #6 - netgraph/deflate.c needs and uses FreeBSD enhancements to zlib. > * Moved sys/zlib.h to netgraph/zlib.h, sys/libkern/zlib.c to > * netgraph/zlib.c, and netgraph/deflate.c includes netgraph/zlib.c > * to compile as a part of deflate.c. > */ > > Regards, > Hiro > _______________________________________________ > freebsd-arch@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-arch > To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20190504165259.68a44a451dbf0072814d923d>