From patchwork Sat Jul 2 10:17:41 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: kernel test robot X-Patchwork-Id: 9210871 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C319160752 for ; Sat, 2 Jul 2016 10:13:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A6E5A28391 for ; Sat, 2 Jul 2016 10:13:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9864A286DA; Sat, 2 Jul 2016 10:13:57 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2514228391 for ; Sat, 2 Jul 2016 10:13:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750939AbcGBKNy (ORCPT ); Sat, 2 Jul 2016 06:13:54 -0400 Received: from mga02.intel.com ([134.134.136.20]:17731 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750815AbcGBKNx (ORCPT ); Sat, 2 Jul 2016 06:13:53 -0400 Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga101.jf.intel.com with ESMTP; 02 Jul 2016 03:13:52 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.26,562,1459839600"; d="scan'208";a="987562354" Received: from bee.sh.intel.com (HELO bee) ([10.239.97.14]) by orsmga001.jf.intel.com with ESMTP; 02 Jul 2016 03:13:51 -0700 Received: from kbuild by bee with local (Exim 4.83) (envelope-from ) id 1bJHvh-000WDb-CK; Sat, 02 Jul 2016 18:13:41 +0800 Date: Sat, 2 Jul 2016 18:17:41 +0800 From: kbuild test robot To: Tahsin Erdogan Cc: kbuild-all@01.org, Jens Axboe , linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, Tahsin Erdogan Subject: [PATCH] block: fix boolreturn.cocci warnings Message-ID: <20160702101741.GA101651@lkp-sb04> References: <201607021803.JUE6Gs7g%fengguang.wu@intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1467429991-18469-1-git-send-email-tahsin@google.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: fengguang.wu@intel.com X-SA-Exim-Scanned: No (on bee); SAEximRunCond expanded to false Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP block/elevator.c:73:9-10: WARNING: return of 0/1 in function 'elv_bio_merge_ok' with return type bool Return statements in functions returning bool should use true/false instead of 1/0. Generated by: scripts/coccinelle/misc/boolreturn.cocci CC: Tahsin Erdogan Signed-off-by: Fengguang Wu --- elevator.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-block" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/block/elevator.c +++ b/block/elevator.c @@ -70,12 +70,12 @@ static int elv_iosched_allow_bio_merge(s bool elv_bio_merge_ok(struct request *rq, struct bio *bio) { if (!blk_rq_merge_ok(rq, bio)) - return 0; + return false; if (!elv_iosched_allow_bio_merge(rq, bio)) - return 0; + return false; - return 1; + return true; } EXPORT_SYMBOL(elv_bio_merge_ok);