From patchwork Tue Mar 3 03:34:57 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mikel Rychliski X-Patchwork-Id: 11417119 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4C725924 for ; Tue, 3 Mar 2020 03:41:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 348F824680 for ; Tue, 3 Mar 2020 03:41:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726970AbgCCDl4 (ORCPT ); Mon, 2 Mar 2020 22:41:56 -0500 Received: from yyz.mikelr.com ([170.75.163.43]:57146 "EHLO yyz.mikelr.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726979AbgCCDl4 (ORCPT ); Mon, 2 Mar 2020 22:41:56 -0500 Received: from glidewell.ykf.mikelr.com (198-84-194-208.cpe.teksavvy.com [198.84.194.208]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by yyz.mikelr.com (Postfix) with ESMTPSA id 525E63CF2A; Mon, 2 Mar 2020 22:35:03 -0500 (EST) From: Mikel Rychliski To: amd-gfx@lists.freedesktop.org, linux-pci@vger.kernel.org Cc: Alex Deucher , =?utf-8?q?Christian_K=C3=B6nig?= , "David (ChunMing) Zhou" , Bjorn Helgaas , Matthew Garrett , Mikel Rychliski Subject: [PATCH 4/4] drm/amdgpu: iounmap unused mapping Date: Mon, 2 Mar 2020 22:34:57 -0500 Message-Id: <20200303033457.12180-5-mikel@mikelr.com> X-Mailer: git-send-email 2.13.7 In-Reply-To: <20200303033457.12180-1-mikel@mikelr.com> References: <20200303033457.12180-1-mikel@mikelr.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org Now that pci_platform_rom creates a new mapping to access the ROM image, we should remove this mapping after extracting the BIOS. Signed-off-by: Mikel Rychliski --- drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c index 50dff69a0f6e..ea6a1fa98ad9 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c @@ -207,6 +207,7 @@ static bool amdgpu_read_platform_bios(struct amdgpu_device *adev) return false; memcpy_fromio(adev->bios, bios, size); + iounmap(bios); if (!check_atom_bios(adev->bios, size)) { kfree(adev->bios);