Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753835AbcCWC0m (ORCPT ); Tue, 22 Mar 2016 22:26:42 -0400 Received: from cmccmta2.chinamobile.com ([221.176.66.80]:2417 "EHLO cmccmta2.chinamobile.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753552AbcCWC0d (ORCPT ); Tue, 22 Mar 2016 22:26:33 -0400 X-RM-TRANSID: 2ee856f1fed6b77-9fe88 X-RM-SPAM-FLAG: 00000000 X-RM-TRANSID: 2ee356f1fed5f78-ae424 From: Yaowei Bai To: akpm@linux-foundation.org Cc: n-horiguchi@ah.jp.nec.com, kirill.shutemov@linux.intel.com, rientjes@google.com, iamjoonsoo.kim@lge.com, hannes@cmpxchg.org, vdavydov@virtuozzo.com, kuleshovmail@gmail.com, vbabka@suse.cz, mgorman@techsingularity.net, linux-mm@kvack.org, linux-kernel@vger.kernel.org, baiyaowei@cmss.chinamobile.com Subject: [PATCH 1/5] mm/hugetlb: is_vm_hugetlb_page can be boolean Date: Wed, 23 Mar 2016 10:26:05 +0800 Message-Id: <1458699969-3432-2-git-send-email-baiyaowei@cmss.chinamobile.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1458699969-3432-1-git-send-email-baiyaowei@cmss.chinamobile.com> References: <1458699969-3432-1-git-send-email-baiyaowei@cmss.chinamobile.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 940 Lines: 39 This patch makes is_vm_hugetlb_page return bool to improve readability due to this particular function only using either one or zero as its return value. No functional change. Signed-off-by: Yaowei Bai --- include/linux/hugetlb_inline.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/linux/hugetlb_inline.h b/include/linux/hugetlb_inline.h index 2bb681f..a4e7ca0 100644 --- a/include/linux/hugetlb_inline.h +++ b/include/linux/hugetlb_inline.h @@ -5,16 +5,16 @@ #include -static inline int is_vm_hugetlb_page(struct vm_area_struct *vma) +static inline bool is_vm_hugetlb_page(struct vm_area_struct *vma) { return !!(vma->vm_flags & VM_HUGETLB); } #else -static inline int is_vm_hugetlb_page(struct vm_area_struct *vma) +static inline bool is_vm_hugetlb_page(struct vm_area_struct *vma) { - return 0; + return false; } #endif -- 1.9.1