RE: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-29 Thread Song Bao Hua (Barry Song)
.kernel.org; linux...@kvack.org; > linux-ker...@vger.kernel.org; Luis Claudio R . Goncalves > ; Mahipal Challa ; > Seth Jennings ; Dan Streetman ; > Vitaly Wool ; Wangzhou (B) > ; fanghao (A) ; Colin > Ian King > Subject: Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for

Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-29 Thread Sebastian Andrzej Siewior
On 2020-09-29 10:02:15 [+], Song Bao Hua (Barry Song) wrote: > > My point was that there will be a warning at run-time and you don't want > > that. There are raw_ accessors if you know what you are doing. But… > > I have only seen get_cpu_ptr/var() things will disable preemption. I don't > th

RE: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-29 Thread Song Bao Hua (Barry Song)
.kernel.org; linux...@kvack.org; > linux-ker...@vger.kernel.org; Luis Claudio R . Goncalves > ; Mahipal Challa ; > Seth Jennings ; Dan Streetman ; > Vitaly Wool ; Wangzhou (B) > ; fanghao (A) ; Colin > Ian King > Subject: Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for

Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-29 Thread Sebastian Andrzej Siewior
On 2020-09-29 05:14:31 [+], Song Bao Hua (Barry Song) wrote: > After second thought and trying to make this change, I would like to change > my mind > and disagree with this idea. Two reasons: > 1. while using this_cpu_ptr() without preemption lock, people usually put all > things bound > wit

RE: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-28 Thread Song Bao Hua (Barry Song)
ux...@kvack.org; > linux-ker...@vger.kernel.org; Luis Claudio R . Goncalves > ; Mahipal Challa ; > Seth Jennings ; Dan Streetman ; > Vitaly Wool ; Wangzhou (B) > ; fanghao (A) ; Colin > Ian King > Subject: RE: [PATCH v6] mm/zswap: move to use crypto_acomp API for > hard

RE: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-28 Thread Song Bao Hua (Barry Song)
.kernel.org; linux...@kvack.org; > linux-ker...@vger.kernel.org; Luis Claudio R . Goncalves > ; Mahipal Challa ; > Seth Jennings ; Dan Streetman ; > Vitaly Wool ; Wangzhou (B) > ; fanghao (A) ; Colin > Ian King > Subject: Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for >

Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-28 Thread Sebastian Andrzej Siewior
On 2020-08-19 00:31:00 [+1200], Barry Song wrote: > diff --git a/mm/zswap.c b/mm/zswap.c > index fbb782924ccc..00b5f14a7332 100644 > --- a/mm/zswap.c > +++ b/mm/zswap.c > @@ -127,9 +129,17 @@ module_param_named(same_filled_pages_enabled, > zswap_same_filled_pages_enabled, > * data structures > *

Re: [PATCH v6] mm/zswap: move to use crypto_acomp API for hardware acceleration

2020-09-28 Thread Vitaly Wool
On Tue, Aug 18, 2020 at 2:34 PM Barry Song wrote: > > Right now, all new ZIP drivers are adapted to crypto_acomp APIs rather > than legacy crypto_comp APIs. Tradiontal ZIP drivers like lz4,lzo etc > have been also wrapped into acomp via scomp backend. But zswap.c is still > using the old APIs. Tha