Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753217AbdFEQ0f (ORCPT ); Mon, 5 Jun 2017 12:26:35 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:59356 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752805AbdFEQ0c (ORCPT ); Mon, 5 Jun 2017 12:26:32 -0400 From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Christoph Hellwig , "Darrick J. Wong" Subject: [PATCH 4.9 79/94] xfs: fix integer truncation in xfs_bmap_remap_alloc Date: Mon, 5 Jun 2017 18:17:55 +0200 Message-Id: <20170605153106.441880887@linuxfoundation.org> X-Mailer: git-send-email 2.13.0 In-Reply-To: <20170605153103.156843111@linuxfoundation.org> References: <20170605153103.156843111@linuxfoundation.org> User-Agent: quilt/0.65 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 895 Lines: 32 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Christoph Hellwig commit 52813fb13ff90bd9c39a93446cbf1103c290b6e9 upstream. bno should be a xfs_fsblock_t, which is 64-bit wides instead of a xfs_aglock_t, which truncates the value to 32 bits. Signed-off-by: Christoph Hellwig Reviewed-by: Darrick J. Wong Signed-off-by: Darrick J. Wong Signed-off-by: Greg Kroah-Hartman --- fs/xfs/libxfs/xfs_bmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/xfs/libxfs/xfs_bmap.c +++ b/fs/xfs/libxfs/xfs_bmap.c @@ -3964,7 +3964,7 @@ xfs_bmap_remap_alloc( { struct xfs_trans *tp = ap->tp; struct xfs_mount *mp = tp->t_mountp; - xfs_agblock_t bno; + xfs_fsblock_t bno; struct xfs_alloc_arg args; int error;