Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751665AbcC2GgO (ORCPT ); Tue, 29 Mar 2016 02:36:14 -0400 Received: from cmccmta2.chinamobile.com ([221.176.66.80]:2880 "EHLO cmccmta2.chinamobile.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750952AbcC2GgM (ORCPT ); Tue, 29 Mar 2016 02:36:12 -0400 X-RM-TRANSID: 2ee756fa22579f5-20d6b X-RM-SPAM-FLAG: 00000000 X-RM-TRANSID: 2ee756fa225702a-972fa Date: Tue, 29 Mar 2016 14:35:44 +0800 From: Yaowei Bai To: Al Viro Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] fs/vfs: improve __mnt_is_readonly Message-ID: <20160329063544.GA3588@yaowei-K42JY> References: <1458871286-3099-1-git-send-email-baiyaowei@cmss.chinamobile.com> <20160326004332.GM17997@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160326004332.GM17997@ZenIV.linux.org.uk> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 463 Lines: 11 On Sat, Mar 26, 2016 at 12:43:32AM +0000, Al Viro wrote: > On Fri, Mar 25, 2016 at 10:01:26AM +0800, Yaowei Bai wrote: > > This patch refactors __mnt_is_readonly and makes it return bool to > > improve readability due to this particular function only using either > > one or zero as its return value. > > Improve in which way, if I may ask? A boolean return value can be more matchable with function's name and more suitable as this function only returns 0/1.