Received: by 2002:a05:7412:8521:b0:e2:908c:2ebd with SMTP id t33csp2010012rdf; Mon, 6 Nov 2023 01:48:28 -0800 (PST) X-Google-Smtp-Source: AGHT+IHv58FKzaIIBygi2vUdVjoTUquhwGKT2MwwPc00rN1y1jv6QfHi6GMMZTFhJv/Kq6q92eAd X-Received: by 2002:a05:6a00:1255:b0:691:2d4:2389 with SMTP id u21-20020a056a00125500b0069102d42389mr25629239pfi.21.1699264107967; Mon, 06 Nov 2023 01:48:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1699264107; cv=none; d=google.com; s=arc-20160816; b=nUuHYlOwB+W2t/lRDMJXnfEwiKYpCdUYqrDUwJAV8/8I6qbuI8exduDdIdZB0IIH2j avu/5FGkxE6QOiFvLYTAfQyZYbpOiwn3n2uQKqGfm+e4oWDuqFioOiO0DPZQ/zEKqheJ e7mSsTVnGH39r6zFQDuxJd20D5L7TKEEzHqlhGMjzpWNpYGPdapkxrxt+onKFPA5/pdQ 9JXc4H0KRiJ2AA4qfe+VIhF/7gjFvKLp9/Rp8+iuQEicotEDWizkrFhG9YbAxk/6Q2iZ KjY93MdZ+L5+/rYzCgeZD3LMaBU+XSabLGcsDor0NjAW5LUjHCqAkdXhqVu06W7uW0yu 7dMQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version:date :message-id:subject:references:in-reply-to:cc:to:from:dkim-signature; bh=V+IimS/y1bq+s9hcRKBuhgzaPKoVDmob1q7UV3f4ZQg=; fh=HSvYz9sl/bN0lkWsj4+FdM/7ZEjo51RPd+YY2o1YNsg=; b=pEM9oTd3ByU4VviilyAjcw5ySDtS+2+ZlzRuErUqmP+410H0/IiTbfgYap0Orvrbh7 LyXid+xXpxTBs/ulLAg5flVuktV3hU7vLUj9Hmqav6ureRsmQ1JgU1DKRR2VRrK21gYr IbgUzjT0/09w5x0cb+uoQTjrHuJR7kSvnz7B/Yh067pvMr96oAjOntOQ3jerzEQ9y0VO 5cJcknxX4BJnbNCMp+aAclsa/x6ug6WWiauFnbOnChOMyMuReTCmEuUdjNRqkkKyn4cD KuSvIpRqxj1dxsra6cIiUddODsR71ZMm7bE28LE4WjR/XrYEeyXfrlbeFF0/nQlNHvo0 toxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UYgfyXoK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id 80-20020a630253000000b005a0018ec785si7037232pgc.375.2023.11.06.01.48.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Nov 2023 01:48:27 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UYgfyXoK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 2B15D806CF5D; Mon, 6 Nov 2023 01:48:26 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231246AbjKFJsY (ORCPT + 99 others); Mon, 6 Nov 2023 04:48:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48042 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230086AbjKFJsX (ORCPT ); Mon, 6 Nov 2023 04:48:23 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 11EB6DB for ; Mon, 6 Nov 2023 01:48:21 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4153DC433C7; Mon, 6 Nov 2023 09:48:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1699264100; bh=h+NSCPSwlpTiwPS/t/qXHGHCzH25S5Gk5v0x2k5LBkU=; h=From:To:Cc:In-Reply-To:References:Subject:Date:From; b=UYgfyXoKhcRw7fX2jwEFhlsk36VUopg/olpvjv+aIv6xKPdXk+tD6n6fRDQuEcQI4 K1rQntb/DrNvBP1wBahGsHLn+QBgq5jyUhlhYI0kHsu+RMWMagZ1OC4ytqNcxzRDS3 WNSGDxHS9zcPiy8ByzgU2yWBTkvwfwVTWq/kVyxn0KN5/oDD+/VVfKwMeSsAV21u+m xy2t9X8+oGMxjStITIzILXu5CwWUYyesF8T2+vbOceRau2lixoz+E24gInZRJPHNoF imCR3cW/nbBbRMCLHEaYscmjzrHpy0j4BOMFpE/R5LKcptNp5KLdalL/jOACNbLAg/ o4W5099wqcK9w== From: Maxime Ripard To: airlied@redhat.com, kraxel@redhat.com, airlied@gmail.com, daniel@ffwll.ch, Zongmin Zhou Cc: virtualization@lists.linux-foundation.org, spice-devel@lists.freedesktop.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org In-Reply-To: <20230801025309.4049813-1-zhouzongmin@kylinos.cn> References: <20230425014543.3448839-1-zhouzongmin@kylinos.cn> <20230801025309.4049813-1-zhouzongmin@kylinos.cn> Subject: Re: [RESEND PATCH] drm/qxl: prevent memory leak Message-Id: <169926409790.498855.8582421584361847884.b4-ty@kernel.org> Date: Mon, 06 Nov 2023 10:48:17 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Mailer: b4 0.12.3 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 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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Mon, 06 Nov 2023 01:48:26 -0800 (PST) On Tue, 01 Aug 2023 10:53:09 +0800, Zongmin Zhou wrote: > The allocated memory for qdev->dumb_heads should be released > in qxl_destroy_monitors_object before qxl suspend. > otherwise,qxl_create_monitors_object will be called to > reallocate memory for qdev->dumb_heads after qxl resume, > it will cause memory leak. > > > [...] Applied to drm/drm-misc (drm-misc-fixes). Thanks! Maxime