Re: [PATCH 1/9] lib: zstd: Add zstd compatibility wrapper

Nick Terrell
2020-09-17T17:13:03Z

> On Sep 16, 2020, at 1:48 AM, Christoph Hellwig <hch@infradead.org> wrote:
>
> On Tue, Sep 15, 2020 at 08:42:54PM -0700, Nick Terrell wrote:
>> From: Nick Terrell <terrelln@fb.com>
>>
>> Adds zstd_compat.h which provides the necessary functions from the
>> current zstd.h API. It is only active for zstd versions 1.4.6 and newer.
>> That means it is disabled currently, but will become active when a later
>> patch in this series updates the zstd library in the kernel to 1.4.6.
>>
>> This header allows the zstd upgrade to 1.4.6 without changing any
>> callers, since they all include zstd through the compatibility wrapper.
>> Later patches in this series transition each caller away from the
>> compatibility wrapper. After all the callers have been transitioned away
>> from the compatibility wrapper, the final patch in this series deletes
>> it.
>
> Please just add wrappes to the main header instead of causing all
> this churn.

The goal of having it in a separate header is so the 3rd patch that actually
updates zstd can be 100% automatically generated. I didn’t want to mix
a small amount of edits into a large generated patch, because that would
be easy to miss.