Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp8366699rwd; Tue, 20 Jun 2023 14:13:49 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4I5lXHc/yj53wB58q5Ts/XDhkYuyoCaTthzQLQEfLj2T2suVFXYPe1dVA5nhyHMldPWxlj X-Received: by 2002:a05:6a20:841d:b0:10c:6dbc:2806 with SMTP id c29-20020a056a20841d00b0010c6dbc2806mr20133847pzd.46.1687295629252; Tue, 20 Jun 2023 14:13:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1687295629; cv=pass; d=google.com; s=arc-20160816; b=ltUdlEdWVJANe32g1GaofUNad0+/zA5bwHJsXsJrBr+PkPF7FjeaQ82b5PAFtmEvia KJSH6qQtvLUT9hmrh6Z8AU8ZH5smboHxdMIcaXIRLUZpvXfJljaqcJWknFozKDUSl12H RSqGWrajZaTUTjfy+ScdJKRUJKOnQRsCvSNXYEa3+zEU84B6r0BpNPGeyjMbzmuXN2Co 0+TAqi1QhkEcs6oNAJofMi5zKT5fLLbisgZD4tG2Wr1xsQdON7eqrCF4VhKGA5Kp25XC bBeWMopodlM3d0sJJ47z9EOsf0/GWAkZBPLoa02joRQKUhYbgnreIBYu3N8bfeLZb6bo 1Dow== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :in-reply-to:from:references:cc:to:content-language:subject :user-agent:date:message-id:dkim-signature:dkim-signature; bh=8PaFQZmpiOkDHkxygNkd8SpR2UsL/7MFszQITCIeINw=; b=fPRDtzdVGjUz9VhejcM169WtyC1rhps/rqX1XJMI5MpzALWSlisyxF2DJZRPiqMQ/J vnBtnH5AwtqYMdzY51sRo2K+/4EAEups2X55JpCUFcHS+70ur5VSLUph0B65LxiKYVCD a8kmwtnEOoNE0LMkjoEvXyi3PQMjFrX3Fbx+7T9FSt2tfDVxk/JI7K5eEC13D9RrmnJp +T6fh6/ZrBnFqpgu4pSD4xwZirsT5VDFpWwkZf+SyMvXEs4eoJvEe19wqM6Vig3OgNCN 7+59hKIWl8jG4ZWG7C6I0snHgtM7vE0f7K1RfzF5Lq2valwGdlN1rJcXJNLi2rmnVsVM gGig== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2023-03-30 header.b="Ue/tAJTX"; dkim=pass header.i=@oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=IiLOAIfQ; arc=pass (i=1 spf=pass spfdomain=oracle.com dkim=pass dkdomain=oracle.com dmarc=pass fromdomain=oracle.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a7-20020a634d07000000b00553b783ad80si2442839pgb.603.2023.06.20.14.13.36; Tue, 20 Jun 2023 14:13:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2023-03-30 header.b="Ue/tAJTX"; dkim=pass header.i=@oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=IiLOAIfQ; arc=pass (i=1 spf=pass spfdomain=oracle.com dkim=pass dkdomain=oracle.com dmarc=pass fromdomain=oracle.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229596AbjFTU0K (ORCPT + 99 others); Tue, 20 Jun 2023 16:26:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60522 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229470AbjFTU0I (ORCPT ); Tue, 20 Jun 2023 16:26:08 -0400 Received: from mx0b-00069f02.pphosted.com (mx0b-00069f02.pphosted.com [205.220.177.32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2324B99 for ; Tue, 20 Jun 2023 13:26:06 -0700 (PDT) Received: from pps.filterd (m0333520.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 35KK8ubl000646; Tue, 20 Jun 2023 20:25:46 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=message-id : date : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding : mime-version; s=corp-2023-03-30; bh=8PaFQZmpiOkDHkxygNkd8SpR2UsL/7MFszQITCIeINw=; b=Ue/tAJTXdLupIAqLN9lxCMjPlPuJ6h4dH99RNWLrNELJE3K/0oMTxIYgQKhpB1lReR5M C3IYlHPkOwBubBZFI0s2nzxLUEykKHJn9G84pz0BitNYwkIwRTZU3xTUYdTLqbjjc1cE 7RsRFYqFPtjZyS/S7f1uBGnNphq+RpZbCsKd7MjZc+wGsYjDszemnVwJOFTDuulukxcH ztEu0yIAhXAbcezD9QzlkI63nheimGFwV/3z+6VD7hN42j/aNJ36GnU7jK4T75i3Xwfi VpRZHHGdwn1QwWAyeq7DKjp9ytDOg7z+HYaVFgjb7dIRfO9btdwjVcFbMbxdsWprlM3f Ew== Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.appoci.oracle.com [138.1.114.2]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3r94vcntvg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 20 Jun 2023 20:25:46 +0000 Received: from pps.filterd (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 35KJb9So032944; Tue, 20 Jun 2023 20:25:45 GMT Received: from nam12-mw2-obe.outbound.protection.outlook.com (mail-mw2nam12lp2045.outbound.protection.outlook.com [104.47.66.45]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 3r93963mqw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 20 Jun 2023 20:25:45 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lTPcvZTuvFf1dE4U6nbcwKuZoDIWyfiMAKx9g6s/ndEZ0BI3PrCuUZemikUK4MThv7fpl7pQqfdY+lbUPwY/nn/t8iypCK58bEyfPolZ1qs3/7viF+GQF8PXhYvRe0yzW8JW7uC//bEJVbPWsCdGF22DS89O/qtfXZwFBRtT4Op0j1lyVeGb7rEkCiEWL4+8Ums+heLADMBdytZHsxcwpVT2jfZWe1lsyF/M+F2VbObezN/XENc0CpkCnCaw1qa8G49zrZ6RGCxYqdfffXtMUWYhr5utrgc/Bl7EAwBLWwPci4ro3g6/yP/Q+Tq7ijkn1oD6MgkilEFCndv9H8+Uaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=8PaFQZmpiOkDHkxygNkd8SpR2UsL/7MFszQITCIeINw=; b=iQzZLSNre2CU/I51O/evq5fPbs72YM3nzMpCAjQkHmXSGyU+d4a+QZn62SDTvO2Roq2TAq2eQk/DUYABm7GskYbe3Xngmp3v7pjm2VkhT/tUD5iLRNzkOmBL33VJ0nWp2gxRduGl6BKNa38CpjogfFdnCEZlt9Et7ORGUJRnYmfte6KDoGwMKMHioEjqZB99u2kqwnx4ioWuDh3m16LnOY+2i/IYIj1huRzrnSSsdnHQv/LMbrqi0y7TvN+9iXN4qQjHxJsekT76xSIhFkIiVJNB/7E3dWDiLoUwVkehvsRiS6Ok0IONlnftgjL3UrIkDAwMV9v+I1ag99n6RXxcqg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=8PaFQZmpiOkDHkxygNkd8SpR2UsL/7MFszQITCIeINw=; b=IiLOAIfQOQ2Vktz2vCjYUEGwAWkYaahvz/jRud8hMZKI+obxiMq2eXVV9PJkFr8HDFb/I822k5Gp/RlKlvBsTjv1fYvadz4ggP7GpZWgrI3tNK7Dy5v4JQxY2lSftatAh4MYZBQtU7wDxIxXcggUd2GkRDdFLDbQ+QchUS4q0Ko= Received: from MW5PR10MB5738.namprd10.prod.outlook.com (2603:10b6:303:19b::14) by PH0PR10MB4583.namprd10.prod.outlook.com (2603:10b6:510:43::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6521.21; Tue, 20 Jun 2023 20:25:43 +0000 Received: from MW5PR10MB5738.namprd10.prod.outlook.com ([fe80::9c17:d256:43b9:7e96]) by MW5PR10MB5738.namprd10.prod.outlook.com ([fe80::9c17:d256:43b9:7e96%5]) with mapi id 15.20.6500.036; Tue, 20 Jun 2023 20:25:43 +0000 Message-ID: <3bc70da4-efa0-462b-8dbf-0569fc2c0275@oracle.com> Date: Tue, 20 Jun 2023 15:24:59 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [PATCH] fs: jfs: fixed UBSAN: shift-out-of-bounds in dbFree Content-Language: en-US To: anupsharma , r33s3n6@gmail.com, mudongliangabcd@gmail.com, liushixin2@huawei.com, wuhoipok@gmail.com Cc: jfs-discussion@lists.sourceforge.net, linux-kernel@vger.kernel.org, linux-kernel-mentees@lists.linuxfoundation.org, skhan@linuxfoundation.org References: From: Dave Kleikamp In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: CH2PR19CA0016.namprd19.prod.outlook.com (2603:10b6:610:4d::26) To MW5PR10MB5738.namprd10.prod.outlook.com (2603:10b6:303:19b::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MW5PR10MB5738:EE_|PH0PR10MB4583:EE_ X-MS-Office365-Filtering-Correlation-Id: cddeeada-2dc3-489b-0d84-08db71cc6d32 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: xAMZFHUg+WYIsNoVNUDTo4Y/G0GBNo0Rf5UZWfPdO06mlb5SbOCNpNNAzlHuKSwZI2Ph2B1s41ViTtAXU7rrwpuN9e7XoTRjDnWWmjb9ajqB9MJcgr5YRRC6ykYrsP6VpdYS7LTfKCeeGLsXPvpkF9BdBI7huXimbsozlLRxiQDWIvi1mvDxKMwwafU207whyFdzQrXaAtua+VMCm90b18bnYhGxVVWbB4SmSmlWl5GDN0aWhDKL11ObRUuNrmTpF2cH4Z74rAuQ5QjtBrCZWJ8/3f/wSXpOHRKs1VG0P9qjYoijRak5ZSUE8AiTtCoDNXc4n1y6lGqjtaQ6Fkfg8Dc7G2tu0D0aN+zZXrpd3ecS8rNMGm6MP4KYXMYccU5ubyNKYeRvtJz/i/U0LR1J92lhFuQ+1CNHEVMW3AU/AMxqGIGpRKVNw62rbow+jAtt2RrXSQ+X4GpwYs+iJ0ipofZ3EOie7RROjrlAuQQOp0GB/Nys3xpihTQSQctnK41Fnfh+96rG4Lj/fFdTs8xS0l3RrhV7iNNDgSatFamO+Mu+XPGM1t4OUxv0yjuzBNvV2lbrB+988ktbWhx/jlqmCCtdBaSoTCaEAEJePL6QZSZMUxz96NgBfeut36s4VmJ324PZsGJTqj9R3H6XhQ4nOfkgUw/qWqga1cJwZ7QiWQk= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MW5PR10MB5738.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230028)(136003)(346002)(396003)(366004)(39860400002)(376002)(451199021)(83380400001)(6512007)(8676002)(8936002)(41300700001)(4326008)(5660300002)(66476007)(316002)(66556008)(66946007)(2616005)(31696002)(36756003)(86362001)(26005)(186003)(6506007)(31686004)(38100700002)(6666004)(478600001)(966005)(6486002)(2906002)(44832011)(99710200001)(43740500002)(45980500001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?RnE3MWhZQmg0U3FOcldKYVV1c0RKQzNnakJ2dnV1K1BTUUc4Ukp1SXJtUG5C?= =?utf-8?B?emwvZi9uenNvVWtQem1abVZTWnhxM2dyTGZ3Y2JMWHJXWWVpWi9LNUsvN2tr?= =?utf-8?B?NGxQL3hnRHFjSlZNR3NqUWVwUXBSZXdwME9ISm8rc2RRa2d6RVErejZuUkxj?= =?utf-8?B?R1A1aENUVGVvWE9JcXgzU1QwaTFvU2c2aGU4Ylp4Y1h1OFg4ajdwQVhXejFu?= =?utf-8?B?V09yZXNVb2FZei9wWHgyQ1FkY0phakhSV1EyZ25yZENnQ2ViMG5OMjVXMWhD?= =?utf-8?B?QTdML0RpYTJydzBsNGIzR3VmQ25MN29UeUYzdnZ5d2RxSVp4akdOVkwwV2NV?= =?utf-8?B?MHUrMUsrWTh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?B?U1g3NlJmYUhJcDJ4VjlTR2tEQkZodlBsT0tGUE1WcEhCNHdGOFczQ2FXLzNj?= =?utf-8?B?ZnBqUXkwL0o5UUZLS3U3R25mbDRDeEF5M3psTkVKVVJJMEZKdkloem1Gdndu?= =?utf-8?B?c1dyYkwyQ2ZtN21OazNLeGUvOFg1OW9OYlkwTmhiT2lCSVdWcDZHYmNCbVlo?= =?utf-8?B?UGg1SWprazBVVzdkOVJsMDlLZjVvV21JWVQ0Qy93cDlBcjNSNURwWjFXWm1P?= =?utf-8?B?RzNNczZ2dktrb2R6b1NKWlY4M1JnSDJ5NUxSOHhienNkRjhEdUJtK0dvS0tD?= =?utf-8?B?eWgwbi9WLytDNXhaU05SZkVDeUdSZUx0bEIxMm9HbEZtbGhMZklvQjExTXIw?= =?utf-8?B?RzcwMVJFWUc0NWZRNmZkaThxWkNHM0dZWitZNkxPZnlhc3JWcklFenhvUlhO?= =?utf-8?B?Q05PSlkzNVlmOHoyWHJMMzNFVE01SWVYbVBCUkhIZmtyL2RFYVRiUmkrRjJZ?= =?utf-8?B?UVRUcnI1QVpHaGlvUFFWYWtoVHRERm9wUXRERTRYQ2ZZVkh3YVRqU2QxN0xE?= =?utf-8?Q?x/pHVaENJzrszB4IRO0OTXBsNRwYKqZ2JM?= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: cddeeada-2dc3-489b-0d84-08db71cc6d32 X-MS-Exchange-CrossTenant-AuthSource: MW5PR10MB5738.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Jun 2023 20:25:43.0593 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: pJ03eKlN2vlQVNE07VjR/+yQO2jr6tKWrWEfZCpan4lmyggt54nzpi10OILMf2+AaCPrXebAEoNAloFGET5pIotNu0/qE5qhxSUC0BqAu24= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH0PR10MB4583 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.957,Hydra:6.0.591,FMLib:17.11.176.26 definitions=2023-06-20_15,2023-06-16_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=855 phishscore=0 bulkscore=0 suspectscore=0 mlxscore=0 spamscore=0 malwarescore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2305260000 definitions=main-2306200184 X-Proofpoint-GUID: 9BU6a0-o7AFw2wff0iNu64AijUZCN3Dm X-Proofpoint-ORIG-GUID: 9BU6a0-o7AFw2wff0iNu64AijUZCN3Dm X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org I want to apologize about this one. Recently, Siddh Raman Pant submitted a similar patch and I picked that one up. I'm sorry that I let yours get buried in my inbox, since it was submitted earlier. I actually prefer his patch since it caught it earlier during mount time, but that's no excuse to not give you a more timely response. Thanks, Shaggy On 4/14/23 8:53AM, anupsharma wrote: > Syzkaller reported the following issue: > option from the mount to silence this warning. > ======================================================= > find_entry called with index = 0 > read_mapping_page failed! > ERROR: (device loop0): txCommit: > ERROR: (device loop0): remounting filesystem as read-only > ================================================================================ > UBSAN: shift-out-of-bounds in fs/jfs/jfs_dmap.c:381:12 > shift exponent 134217736 is too large for 64-bit type 'long long' > CPU: 1 PID: 5068 Comm: syz-executor350 Not tainted 6.3.0-rc2-syzkaller-00069-g0ddc84d2dd43 #0 > Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023 > Call Trace: > > __dump_stack lib/dump_stack.c:88 [inline] > dump_stack_lvl+0x1e7/0x2d0 lib/dump_stack.c:106 > ubsan_epilogue lib/ubsan.c:217 [inline] > __ubsan_handle_shift_out_of_bounds+0x3c3/0x420 lib/ubsan.c:387 > dbFree+0x46e/0x650 fs/jfs/jfs_dmap.c:381 > txFreeMap+0x96a/0xd50 fs/jfs/jfs_txnmgr.c:2510 > xtTruncate+0xe5c/0x3260 fs/jfs/jfs_xtree.c:2467 > jfs_free_zero_link+0x46e/0x6e0 fs/jfs/namei.c:758 > jfs_evict_inode+0x35f/0x440 fs/jfs/inode.c:153 > evict+0x2a4/0x620 fs/inode.c:665 > __dentry_kill+0x436/0x650 fs/dcache.c:607 > shrink_dentry_list+0x39c/0x6a0 fs/dcache.c:1201 > shrink_dcache_parent+0xcd/0x480 > do_one_tree+0x23/0xe0 fs/dcache.c:1682 > shrink_dcache_for_umount+0x7d/0x120 fs/dcache.c:1699 > generic_shutdown_super+0x67/0x340 fs/super.c:472 > kill_block_super+0x7e/0xe0 fs/super.c:1398 > deactivate_locked_super+0xa4/0x110 fs/super.c:331 > cleanup_mnt+0x426/0x4c0 fs/namespace.c:1177 > task_work_run+0x24a/0x300 kernel/task_work.c:179 > exit_task_work include/linux/task_work.h:38 [inline] > do_exit+0x68f/0x2290 kernel/exit.c:869 > do_group_exit+0x206/0x2c0 kernel/exit.c:1019 > __do_sys_exit_group kernel/exit.c:1030 [inline] > __se_sys_exit_group kernel/exit.c:1028 [inline] > __x64_sys_exit_group+0x3f/0x40 kernel/exit.c:1028 > do_syscall_x64 arch/x86/entry/common.c:50 [inline] > do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 > entry_SYSCALL_64_after_hwframe+0x63/0xcd > RIP: 0033:0x7fa87e2289b9 > Code: Unable to access opcode bytes at 0x7fa87e22898f. > RSP: 002b:00007fff4bfe3938 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7 > RAX: ffffffffffffffda RBX: 00007fa87e2a3330 RCX: 00007fa87e2289b9 > RDX: 000000000000003c RSI: 00000000000000e7 RDI: 0000000000000001 > RBP: 0000000000000001 R08: ffffffffffffffc0 R09: 00007fa87e29de40 > R10: 00007fff4bfe3850 R11: 0000000000000246 R12: 00007fa87e2a3330 > R13: 0000000000000001 R14: 0000000000000000 R15: 0000000000000001 > > ================================================================================ > > db_l2nbperpage which is used as a shift exponent to get the buffer > for the current dmap will be less than and equal to 64. > > Tested via syzbot. > > Reported-by: syzbot+d2cd27dcf8e04b232eb2@syzkaller.appspotmail.com > Link: https://syzkaller.appspot.com/bug?id=2a70a453331db32ed491f5cbb07e81bf2d225715 > > Signed-off-by: Anup Sharma > --- > fs/jfs/jfs_dmap.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/fs/jfs/jfs_dmap.c b/fs/jfs/jfs_dmap.c > index a3eb1e826947..d2cf56dd8f91 100644 > --- a/fs/jfs/jfs_dmap.c > +++ b/fs/jfs/jfs_dmap.c > @@ -184,7 +184,10 @@ int dbMount(struct inode *ipbmap) > err = -EINVAL; > goto err_release_metapage; > } > - > + if (bmp->db_l2nbperpage >= 64) { > + err = -EINVAL; > + goto err_release_metapage; > + } > bmp->db_maxlevel = le32_to_cpu(dbmp_le->dn_maxlevel); > bmp->db_maxag = le32_to_cpu(dbmp_le->dn_maxag); > bmp->db_agpref = le32_to_cpu(dbmp_le->dn_agpref);