Received: by 2002:a05:7412:98c1:b0:fa:551:50a7 with SMTP id kc1csp318717rdb; Fri, 5 Jan 2024 10:48:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IFbO2nZmyZ0HAmOVMDgv0LnMSpM5u7IPToleWQVKQpuunTUhx97P/VadAzXKj0KATsTbznN X-Received: by 2002:a05:620a:1207:b0:781:551a:a53e with SMTP id u7-20020a05620a120700b00781551aa53emr2464556qkj.73.1704480504686; Fri, 05 Jan 2024 10:48:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704480504; cv=none; d=google.com; s=arc-20160816; b=xAEta59PZ5b/UOhVGESEspSBcK4gNcGPU2+qZLfsNS8X3mHP+tKMNbrnVeXHz3MzNA wVlMsoC8gyBXy/FuLEM04eLbF726mtrcqn3E5mQmHwF5oq5E7gbP8IjaP7QalELpZw0s eEKhix4Rs9RWmEri0zMy6+eR3Vh7ewIxmhbaW8IV/DMTcAvYKx0MsNXH6wYRoR/SlN8B Pno/RvM9+yP5JzbidDxtGzgNf429ylIkMDmmaYfmbdO3rQzNBCpGw4L4GyBP75wWiz0s /J3MW6c7P6a55rp1zM2KV4gZ3JoOGKDpYzY1XPrnHbrCszIfmczlzCgtgFhqjeHHT777 vKBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=tbgILMUI3duBs/UxlRMvv0w5D6/6296Rt8xcGhFxJkM=; fh=5cel2jD5h+yPMXVwxbomyVhwojHUqATy6nFjd4aOh4o=; b=gDy0FSWGLzCyaSRgiadVPQ/9RBCWc5x6OPhckuoPcwYObvpVxibw+cl6BSjD1YXeqc SPHcHQMOkiKp9WzVqGQZBkjE0nv+BZeitiwzpDONQQr2gKxNX+34PSXgzcs7WlphvQ+J x+rd7/D0aOgN0fB46PGw4iMeg82Jw9NHhQ70nn0v3U2NnUqbesTFAXz3nJ0R1pnAku3X g6zZbjqh+WR4Qn2RiL5VUecKKsgzH26NfTAFys7Qj7lxHBF7XClTXzM/ah9qkIbSHZPw EoRjsAgUIywMAi1DIpQZ4t6Z6eyoBa/+sgy6Dg4BFOMlBF0HS0NjRCQsh/druKaAtY/F o+Dw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=AWeQh8Ef; spf=pass (google.com: domain of linux-kernel+bounces-18244-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-18244-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id y16-20020a05620a44d000b007830f941ea8si184984qkp.326.2024.01.05.10.48.24 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jan 2024 10:48:24 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-18244-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=AWeQh8Ef; spf=pass (google.com: domain of linux-kernel+bounces-18244-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-18244-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 6EF351C231E9 for ; Fri, 5 Jan 2024 18:48:24 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E007F36B1C; Fri, 5 Jan 2024 18:46:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="AWeQh8Ef" X-Original-To: linux-kernel@vger.kernel.org Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C1F5236AEF for ; Fri, 5 Jan 2024 18:46:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1704480414; bh=ogKb7d41PScFLzJ54iuk6ZS0vpsAlBKn+e0Ym6lcvII=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AWeQh8EfRh3NwZ17ZU18fulJX9TFyKsccd1mq/XyYbmkMluipimpxzcn7DicPPTwf iCH66lPnhUorGMqu7uJIBWLlt9uL1JZqC+vVwQTuW+CRhhQ5MvjK6Eq3x9HGtEi2+X CvPdXzYkpy+9ZGFL2OEZsmbniaaULZpZHc0o9vPhhYj1icOZYOqmkD9JjeVc15QyDM avj1W+ipJQuYGqVOWbBCgmU5lWW+nBH8bQIlNqAOj70et0O7QmoS1SLvkcO0n7tQpG 12oiP0cPZ1baqzMsn/Io3ocw+5KNbv3Gw0T6mYmb58qiPpQ6gVJ3CA3rpmymk9tXRy 4plg+ejoTBT5A== Received: from workpc.. (cola.collaboradmins.com [195.201.22.229]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: dmitry.osipenko) by madrid.collaboradmins.com (Postfix) with ESMTPSA id E692E3782041; Fri, 5 Jan 2024 18:46:52 +0000 (UTC) From: Dmitry Osipenko To: David Airlie , Gerd Hoffmann , Gurchetan Singh , Chia-I Wu , Daniel Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , =?UTF-8?q?Christian=20K=C3=B6nig?= , Qiang Yu , Steven Price , Boris Brezillon , Emma Anholt , Melissa Wen Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, kernel@collabora.com, virtualization@lists.linux-foundation.org Subject: [PATCH v19 06/30] drm/shmem-helper: Remove obsoleted is_iomem test Date: Fri, 5 Jan 2024 21:46:00 +0300 Message-ID: <20240105184624.508603-7-dmitry.osipenko@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240105184624.508603-1-dmitry.osipenko@collabora.com> References: <20240105184624.508603-1-dmitry.osipenko@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Everything that uses the mapped buffer should be agnostic to is_iomem. The only reason for the is_iomem test is that we're setting shmem->vaddr to the returned map->vaddr. Now that the shmem->vaddr code is gone, remove the obsoleted is_iomem test to clean up the code. Acked-by: Maxime Ripard Suggested-by: Thomas Zimmermann Reviewed-by: Boris Brezillon Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/drm_gem_shmem_helper.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/gpu/drm/drm_gem_shmem_helper.c b/drivers/gpu/drm/drm_gem_shmem_helper.c index 043e8e3b129c..1f0a66386415 100644 --- a/drivers/gpu/drm/drm_gem_shmem_helper.c +++ b/drivers/gpu/drm/drm_gem_shmem_helper.c @@ -315,12 +315,6 @@ int drm_gem_shmem_vmap_locked(struct drm_gem_shmem_object *shmem, if (obj->import_attach) { ret = dma_buf_vmap(obj->import_attach->dmabuf, map); - if (!ret) { - if (drm_WARN_ON(obj->dev, map->is_iomem)) { - dma_buf_vunmap(obj->import_attach->dmabuf, map); - return -EIO; - } - } } else { pgprot_t prot = PAGE_KERNEL; -- 2.43.0