From patchwork Tue Jun 23 19:57:59 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 223263 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DB992C433DF for ; Tue, 23 Jun 2020 21:10:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id AA8D2204EA for ; Tue, 23 Jun 2020 21:10:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592946627; bh=ZpNXU+lOBK99/weNKs9dBLEjsm8HvJhyAZAbey3M6VQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=ZJh38SIULVeUC9RxqXzZdLRGZaC1yRAWhUbaC+IuVPSeTbaLWo6Nfb/gPk4U0W0s6 GaV5HRM3IspvIPYd356eSg4wsS0v/4GrxZaRNg7CovX+g2AtBnQ+ZqCqA0fwoSrngQ D6RrOb2D1DsrP76ddOlXM4ttKvgY9QDNi6l37Lm8= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391380AbgFWUdN (ORCPT ); Tue, 23 Jun 2020 16:33:13 -0400 Received: from mail.kernel.org ([198.145.29.99]:54250 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391142AbgFWUdH (ORCPT ); Tue, 23 Jun 2020 16:33:07 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 6D8C12064B; Tue, 23 Jun 2020 20:33:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592944387; bh=ZpNXU+lOBK99/weNKs9dBLEjsm8HvJhyAZAbey3M6VQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ADIr+ZWbX5p97hRdRVCkd57sW9f66CQZljneYZ2LmUwZ1IWxg2dlgGLUgha3gXIoV 6wo8gF2mo37Dcw8jUxPzrT9nMT9sfFjn+drfoOmfTQkyH48aBf3rvwrNXzKF3JV6SU 9ivZ5WNxnw9S8jKNn3YebCzxKzup7qZwZbxp7pBE= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Huacai Chen , Gerd Hoffmann Subject: [PATCH 5.4 284/314] drm/qxl: Use correct notify port address when creating cursor ring Date: Tue, 23 Jun 2020 21:57:59 +0200 Message-Id: <20200623195352.528417778@linuxfoundation.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20200623195338.770401005@linuxfoundation.org> References: <20200623195338.770401005@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Huacai Chen commit 80e5f89da3ab949fbbf1cae01dfaea29f5483a75 upstream. The command ring and cursor ring use different notify port addresses definition: QXL_IO_NOTIFY_CMD and QXL_IO_NOTIFY_CURSOR. However, in qxl_device_init() we use QXL_IO_NOTIFY_CMD to create both command ring and cursor ring. This doesn't cause any problems now, because QEMU's behaviors on QXL_IO_NOTIFY_CMD and QXL_IO_NOTIFY_CURSOR are the same. However, QEMU's behavior may be change in future, so let's fix it. P.S.: In the X.org QXL driver, the notify port address of cursor ring is correct. Signed-off-by: Huacai Chen Cc: Link: http://patchwork.freedesktop.org/patch/msgid/1585635488-17507-1-git-send-email-chenhc@lemote.com Signed-off-by: Gerd Hoffmann Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/qxl/qxl_kms.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/gpu/drm/qxl/qxl_kms.c +++ b/drivers/gpu/drm/qxl/qxl_kms.c @@ -218,7 +218,7 @@ int qxl_device_init(struct qxl_device *q &(qdev->ram_header->cursor_ring_hdr), sizeof(struct qxl_command), QXL_CURSOR_RING_SIZE, - qdev->io_base + QXL_IO_NOTIFY_CMD, + qdev->io_base + QXL_IO_NOTIFY_CURSOR, false, &qdev->cursor_event);