From patchwork Sun Jun 29 11:18:17 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kinglong Mee X-Patchwork-Id: 4444331 Return-Path: X-Original-To: patchwork-linux-nfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 4F4C4BEEAA for ; Sun, 29 Jun 2014 11:18:58 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 4671320328 for ; Sun, 29 Jun 2014 11:18:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id F2DB5202F8 for ; Sun, 29 Jun 2014 11:18:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752981AbaF2LSy (ORCPT ); Sun, 29 Jun 2014 07:18:54 -0400 Received: from mail-pa0-f47.google.com ([209.85.220.47]:34037 "EHLO mail-pa0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752449AbaF2LSy (ORCPT ); Sun, 29 Jun 2014 07:18:54 -0400 Received: by mail-pa0-f47.google.com with SMTP id kq14so6982595pab.20 for ; Sun, 29 Jun 2014 04:18:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=zcjI3I4EtPDwhrZ8Z4aYhbQLVsQNR802TceF0UsN7eg=; b=UpT6flZvBryj6Q6ZLadLUjt4+l2f2gZQRz4wE+MPsGjjjr6bMi1yjZoC89XCVwpIxT C45uV5C93AbBEh0PG0sm9TDZTh47aNHf9J3yNVA25BezEgBtMB3H8r+l7xjYZhNNPwkV lSBc65eyS42aZ6ceiXZAO0P7rwgJgq52+hW8W3PqihbyMNv6nn/WxQDeLYN+Wv0+oyZo ESNjE+39vmYd8jFueaHSSWxpLc+NfNkaHMLUjtIzR/DZDaYbwVMNHoHRD/6hE0n4IJsm e/yzoOb4OV5b/NXG+IpcGrv38dT2Zn8ZAV6UySn3Ctjy2iVIPTvVyPkzbI/AAE6bbR9p Ev4Q== X-Received: by 10.66.254.37 with SMTP id af5mr43401951pad.113.1404040733686; Sun, 29 Jun 2014 04:18:53 -0700 (PDT) Received: from [192.168.0.100] ([110.190.114.42]) by mx.google.com with ESMTPSA id gw8sm22850364pbc.28.2014.06.29.04.18.47 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 29 Jun 2014 04:18:52 -0700 (PDT) Message-ID: <53AFF5F9.2040401@gmail.com> Date: Sun, 29 Jun 2014 19:18:17 +0800 From: Kinglong Mee User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: kbuild test robot CC: "J. Bruce Fields" , kbuild-all@01.org, Linux NFS Mailing List , kinglongmee@gmail.com Subject: [PATCH] NFSD: Avoid warning message when compile at i686 arch References: <53aebf38.2Sl+piCGJ4BiEZLl%fengguang.wu@intel.com> In-Reply-To: <53aebf38.2Sl+piCGJ4BiEZLl%fengguang.wu@intel.com> Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP fs/nfsd/nfs4xdr.c: In function 'nfsd4_encode_readv': >> fs/nfsd/nfs4xdr.c:3137:148: warning: comparison of distinct pointer types lacks a cast [enabled by default] thislen = min(len, ((void *)xdr->end - (void *)xdr->p)); Reported-by: Fengguang Wu Signed-off-by: Kinglong Mee --- fs/nfsd/nfs4xdr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/nfsd/nfs4xdr.c b/fs/nfsd/nfs4xdr.c index ec198fa..1b61fbe 100644 --- a/fs/nfsd/nfs4xdr.c +++ b/fs/nfsd/nfs4xdr.c @@ -3150,7 +3150,7 @@ static __be32 nfsd4_encode_readv(struct nfsd4_compoundres *resp, len = maxcount; v = 0; - thislen = min(len, ((void *)xdr->end - (void *)xdr->p)); + thislen = min_t(long, len, ((void *)xdr->end - (void *)xdr->p)); p = xdr_reserve_space(xdr, (thislen+3)&~3); WARN_ON_ONCE(!p); resp->rqstp->rq_vec[v].iov_base = p;