Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751989AbbFDCT5 (ORCPT ); Wed, 3 Jun 2015 22:19:57 -0400 Received: from mail-pa0-f41.google.com ([209.85.220.41]:33728 "EHLO mail-pa0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751340AbbFDCTm (ORCPT ); Wed, 3 Jun 2015 22:19:42 -0400 Date: Thu, 4 Jun 2015 11:19:35 +0900 From: Tejun Heo To: Rusty Russell Cc: Louis Langholtz , Andrew Morton , linux-kernel@vger.kernel.org Subject: Re: kernel/params.c: 'err' variable "set but not used" and perhaps should be? Message-ID: <20150604021935.GN20091@mtj.duckdns.org> References: <87vbf628uy.fsf@rustcorp.com.au> <7E8FFE0D-B9F7-4816-8ECF-2AA5980F3890@me.com> <20150603202237.GI20091@mtj.duckdns.org> <87eglsuujn.fsf@rustcorp.com.au> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87eglsuujn.fsf@rustcorp.com.au> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 959 Lines: 24 On Thu, Jun 04, 2015 at 11:03:16AM +0930, Rusty Russell wrote: > Please describe the circumstances under which this function can fail. Allocation failure obviously and violatin of certain API rules - e.g. dup names, wrong nesting, activation rule violations. Some can be warned automatically but I'm not sure about e.g. activation rule violation. Also, please note that w/ kmemcg order-0 allocation failures are a lot more common and we probably won't want to print out warnings automatically. For module's use case, it can just trigger warnings and continue on but I don't think it'd be a good idea to cripple the API by making it trigger warnings internally and then make it return void. Thanks. -- tejun -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/