Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1645903rwd; Thu, 8 Jun 2023 23:23:51 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ425+P7oSLjxaUwK8GET9vaKvAylKRtHeGOWFXPJWdRdQpjYHHBF7V2OtU9ZujNSkfkuzsv X-Received: by 2002:a05:6358:9fa5:b0:125:a552:4389 with SMTP id fy37-20020a0563589fa500b00125a5524389mr522205rwb.22.1686291831390; Thu, 08 Jun 2023 23:23:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686291831; cv=none; d=google.com; s=arc-20160816; b=zg6VH4TAnNaQjN3TmmbBc10pwQOtn2CdyJEGM1dOp3n1npjQn9vRSH+sY+QUXrUmjV Y8d4HJmK3jTu2OChE6PhLD9SQ0UMCfHychu7O/expJkZv8f+pw86Rcz6wdrzI7d9zpnH FqLLyrJ74PrXp3PyDQOSZVKYiJ1hobCU4UMR+MKsEwjop0q85UFtHc2qiETstBeqTPhe 58Xa4D5Q+Kaie8OiT9ApjKBlbnqsNF2HqWXAirONnH40BfKmsD5/7mrd9wHdwbcijHdM 2lZPT/QnHFeG6SPmmzzJ/HgdF+xi4C9e7kC8As9ssa3Slk1oe3sENiqrzRZCqRHyvLDF 58ZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=q4jkVgxGgFq/M1N64LfY0rHVCp0BTEeRXBq/u8uTpp4=; b=zoR0dcuhI0RypIFk1l3KgMbFvisi7BgWsZuB//2FXXsNqe02QCGV0FsMJdUl5MRGd3 uVZ7y9JKLwIGOxk/pI5rBkJaxbbbBGq7rilHyC+/loecJzXUkln+3SVHJocImqIp7QMV HDbqusB3EFPI4dGEbOQK1uJf3F49BVzVZP4jD11agDF7rbqQFyrUa1TnxcLu0WifIKL7 +sqlTQnBAnzFDSJ635ANxDM/Ueyod1HW324M3qL/IG36TQXjZkabAHQ46y6hlh+ijH6d 0qLiFZX6r0bEbNADgyCTgDCJNT7p/5N1HkummulfV0Ll7HMLHTJqsIzmz2UrMJfviopA Qg+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=BUcm9vaf; 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=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s134-20020a632c8c000000b00543ae703b97si2067246pgs.209.2023.06.08.23.23.38; Thu, 08 Jun 2023 23:23:51 -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=@linuxfoundation.org header.s=korg header.b=BUcm9vaf; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235563AbjFIGJX (ORCPT + 99 others); Fri, 9 Jun 2023 02:09:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37020 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229518AbjFIGJV (ORCPT ); Fri, 9 Jun 2023 02:09:21 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2C0E1FE6; Thu, 8 Jun 2023 23:09:20 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 6A05261560; Fri, 9 Jun 2023 06:09:20 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 54AD7C433D2; Fri, 9 Jun 2023 06:09:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1686290959; bh=VymAURH6DqwhMHojBPt5ZuPQYK69zpD8+HmhzERJHQs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=BUcm9vafTjmhcgggePjJmaz/CH0W+mbeHr5qrrQwiB0h1f0JVSlBxyQKzOgMopEnY lFRs6FwN6lXiIizorV33KI6IMNKLqQPxpXoK4tRUII5GGb3Z08TYo2zB8FwXnZmiP8 Hwt8ucnJj7jNCiplSapmsMgpbeFiRHshdQZliN6g= Date: Fri, 9 Jun 2023 08:09:17 +0200 From: Greg Kroah-Hartman To: Mike Kravetz Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, dri-devel@lists.freedesktop.org, qemu-devel@nongnu.org, Gerd Hoffmann , Vivek Kasireddy , Dongwon Kim , Junxiao Chang , kirill.shutemov@linux.intel.com, mhocko@suse.com, jmarchan@redhat.com, muchun.song@linux.dev, James Houghton , David Hildenbrand , Andrew Morton , stable@vger.kernel.org Subject: Re: [PATCH] udmabuf: revert 'Add support for mapping hugepages (v4)' Message-ID: <2023060908-pretender-boastful-cbb9@gregkh> References: <20230608204927.88711-1-mike.kravetz@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230608204927.88711-1-mike.kravetz@oracle.com> X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,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 On Thu, Jun 08, 2023 at 01:49:27PM -0700, Mike Kravetz wrote: > This effectively reverts commit 16c243e99d33 ("udmabuf: Add support > for mapping hugepages (v4)"). Recently, Junxiao Chang found a BUG > with page map counting as described here [1]. This issue pointed out > that the udmabuf driver was making direct use of subpages of hugetlb > pages. This is not a good idea, and no other mm code attempts such use. > In addition to the mapcount issue, this also causes issues with hugetlb > vmemmap optimization and page poisoning. > > For now, remove hugetlb support. > > If udmabuf wants to be used on hugetlb mappings, it should be changed to > only use complete hugetlb pages. This will require different alignment > and size requirements on the UDMABUF_CREATE API. > > [1] https://lore.kernel.org/linux-mm/20230512072036.1027784-1-junxiao.chang@intel.com/ > > Fixes: 16c243e99d33 ("udmabuf: Add support for mapping hugepages (v4)") > Cc: > Signed-off-by: Mike Kravetz Acked-by: Greg Kroah-Hartman