From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752690AbcFBCkG (ORCPT ); Wed, 1 Jun 2016 22:40:06 -0400 Received: from LGEAMRELO13.lge.com ([156.147.23.53]:47844 "EHLO lgeamrelo13.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752368AbcFBCkD (ORCPT ); Wed, 1 Jun 2016 22:40:03 -0400 X-Original-SENDERIP: 156.147.1.125 X-Original-MAILFROM: minchan@kernel.org X-Original-SENDERIP: 165.244.98.204 X-Original-MAILFROM: minchan@kernel.org X-Original-SENDERIP: 10.177.223.161 X-Original-MAILFROM: minchan@kernel.org Date: Thu, 2 Jun 2016 11:40:45 +0900 From: Minchan Kim To: Sergey Senozhatsky CC: Sergey Senozhatsky , Andrew Morton , Joonsoo Kim , Subject: Re: [PATCH v2 4/8] zram: use crypto api to check alg availability Message-ID: <20160602024045.GA3024@bbox> References: <20160531122017.2878-1-sergey.senozhatsky@gmail.com> <20160531122017.2878-5-sergey.senozhatsky@gmail.com> <20160601000304.GF19976@bbox> <20160601010707.GB461@swordfish> <20160601022708.GL19976@bbox> <20160601025236.GG461@swordfish> <20160601064709.GM19976@bbox> <20160601074845.GA491@swordfish> MIME-Version: 1.0 In-Reply-To: <20160601074845.GA491@swordfish> User-Agent: Mutt/1.5.21 (2010-09-15) X-MIMETrack: Itemize by SMTP Server on LGEKRMHUB01/LGE/LG Group(Release 8.5.3FP6|November 21, 2013) at 2016/06/02 11:39:59, Serialize by Router on LGEKRMHUB01/LGE/LG Group(Release 8.5.3FP6|November 21, 2013) at 2016/06/02 11:39:59, Serialize complete at 2016/06/02 11:39:59 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 01, 2016 at 04:48:45PM +0900, Sergey Senozhatsky wrote: > On (06/01/16 15:47), Minchan Kim wrote: > [..] > > > so both BUILTIN and BUILT-AS-A-MODULE cases are handled at compile > > > time now and we can avoid crypto_has_comp() checks for most of the > > > comp_algorithm calls, except for the case when someone requests an > > > out-of-tree module. > > > > Hmm, isn't it problem, either? > > > > That module was built but not installed. In that case, setting the > > algorithm will be failed. IOW, we are lying to user. > > have you ever seen this? really, why should we even bother? > if there is no requested algorithm we will fallback to LZO. Yeb, it seems I am too paranoid. Let's not take care about the case. We can simple return -EINVAL and fallback lzo. Thanks.