Received: by 2002:a05:7412:98c1:b0:fa:551:50a7 with SMTP id kc1csp276372rdb; Fri, 5 Jan 2024 09:23:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IHzJoZmG1H6FPydNt3a5wrb7G+6oZ8/tNfn3hDQ1FVqtMyy1nj7/DmmcQCnFsDaf4JqBTzC X-Received: by 2002:a17:906:6b91:b0:a26:f7ea:7cb6 with SMTP id l17-20020a1709066b9100b00a26f7ea7cb6mr2134901ejr.16.1704475426669; Fri, 05 Jan 2024 09:23:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704475426; cv=none; d=google.com; s=arc-20160816; b=qAmfEkv2inTuQPebBIeAxEOEsKSHmBsDkvJt79Vefb/UcbJLk5oUt61Pl9XqUHqmvQ +W6lqOBYNewo6cJAIFMpsnaRcQZQkLHxbL7DZ1DNo0f5htowmUEVOtBqCUimZ705QPeS 8whu2KYgy3mklh1puMqS6mZWA22R7Tzh0XPiZlna6dxXosTbTQJRqYKsLLAjjDARMXGm JMuVYZpGrEg/wV35CM4eJjgl8QLp56q928TwPM/cHIYKcqXJFQeKaxv4HTNrSOFm9yHv RjeY9njueHyooHhp96V/63wNn4vmNixcwGvxEGbjU2u7/bxO54szInrVnlE6C+kqOiRg RRFg== 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=L2qUZvjVZIZkY/BqEpnbV7C2OUzTR+OzcQfnt1cm3UY=; fh=L/75A92C4r6s7p0wl3tLaypnglq6P35gl2qn6oQwgpg=; b=u2KeUXajH8w3W1/NULhHXp0mk6isPXNJryADLC04WnQL/nZbvCPx+WFZIpMviaZYuK oHC/cPQ9LU3+UIMTESDVXJM640WGnI9Pj6FIuB4+i7xR6kRJssB562H+ZD9qo5i8YvlL kOnD07QzrzGbAMliW23Im+nlB0NmeRrt/epFodV3CCU2wktZ2+epfDzm/JtlOhi/NPp7 V65av7TL1IhvosmaL20zabiE1yVuRJ9OVN4QVv+P1QOQ+4JDdEy4kbjtEu1/8eY34P5X rjiLB4acprl22nnITGZF/vdk9GhH+H4U+xDuthOLLUjVbh/f/MyHnbUow5spYbj8zkAd F9AA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=LMyrg8a2; spf=pass (google.com: domain of linux-kernel+bounces-18108-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-18108-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id bq25-20020a170906d0d900b00a27cb1bb37bsi758563ejb.616.2024.01.05.09.23.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jan 2024 09:23:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-18108-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=LMyrg8a2; spf=pass (google.com: domain of linux-kernel+bounces-18108-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-18108-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.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 am.mirrors.kernel.org (Postfix) with ESMTPS id 6B5661F23FA3 for ; Fri, 5 Jan 2024 17:23:46 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 60440347AD; Fri, 5 Jan 2024 17:23:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="LMyrg8a2" X-Original-To: linux-kernel@vger.kernel.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (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 459D6328DB for ; Fri, 5 Jan 2024 17:23:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1704475400; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=L2qUZvjVZIZkY/BqEpnbV7C2OUzTR+OzcQfnt1cm3UY=; b=LMyrg8a2MwnhXFbbeiJnUpt8Xgfm97dweKm06ThEs67XpnUNcXp4usbu6XTcpnF0IGIEHi AlJHuUHiUUhbQ0B92L5Qgkwc3sUKigOYmlxsow25Q5arh/Ekvmj4eck49s3ppdiRjOuXGI vI8nz7IrnEC2wD9P0Z8w4UjaGxyh5F8= Received: from mail-qt1-f200.google.com (mail-qt1-f200.google.com [209.85.160.200]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-389-SlB6JFXJPpaydRIiUBl7iQ-1; Fri, 05 Jan 2024 12:23:18 -0500 X-MC-Unique: SlB6JFXJPpaydRIiUBl7iQ-1 Received: by mail-qt1-f200.google.com with SMTP id d75a77b69052e-4277052412cso2250931cf.0 for ; Fri, 05 Jan 2024 09:23:18 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704475398; x=1705080198; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=L2qUZvjVZIZkY/BqEpnbV7C2OUzTR+OzcQfnt1cm3UY=; b=Dh4/xoTLUzwRSr35pXokGhlJMStmsHbXsHilKS3VxGoO0EYBObQ83tUhjFE729su+E 6oZF0PT0VxhLYLuo5ENyz43gglp6EIkPaYMm10U6CNWeSk9WDEbutwewL2dX+zIpSjc1 AfvG+gtAy4jt0YDmyypNRROQsDsQiaRyezVgYb6BjeDd9gRxIeurSkaNfjsH1E+QXTQ5 dAKf1z8IU90stvsTdHY4qjM2A6xHz6yxE+UguSZpHrhGj2PfLpE33m5KLjc+ReKp3gXt uIP1WGfF1kapbeXd2+WSFiYfhMzTMQuuBMpmSwJqJItAg7FvcHSJ7X7RFQ5QiTWu6Zqr 3EFQ== X-Gm-Message-State: AOJu0YxzEhzaCixjxemQ8W8kXaF5y5Y07Nv8niQjjDOXbqFJNgb9nOdg 19u8FTF4TX6WINzHJvKlA5cwzdHVsTAwztTyUXZ5Ns+goM5WZ64TDQz9mVMC/CQv5Tem6iZXO2h 7109wQfy1rn2WN40twwxz71CkezIf/F8p X-Received: by 2002:a05:622a:50:b0:428:2650:f3e2 with SMTP id y16-20020a05622a005000b004282650f3e2mr5249590qtw.5.1704475397794; Fri, 05 Jan 2024 09:23:17 -0800 (PST) X-Received: by 2002:a05:622a:50:b0:428:2650:f3e2 with SMTP id y16-20020a05622a005000b004282650f3e2mr5249572qtw.5.1704475397552; Fri, 05 Jan 2024 09:23:17 -0800 (PST) Received: from pstanner-thinkpadt14sgen1.remote.csb ([2001:9e8:32d1:a900:227b:d2ff:fe26:2a7a]) by smtp.gmail.com with ESMTPSA id t22-20020ac865d6000000b004282c862fccsm884750qto.57.2024.01.05.09.23.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jan 2024 09:23:17 -0800 (PST) From: Philipp Stanner To: Greg Kroah-Hartman , "Rafael J. Wysocki" , Laurentiu Palcu , Lucas Stach , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Mark Brown , Takashi Iwai , David Gow , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Cc: linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, Philipp Stanner Subject: [PATCH 2/2] drm/dcss: request memory region Date: Fri, 5 Jan 2024 18:22:19 +0100 Message-ID: <20240105172218.42457-4-pstanner@redhat.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240105172218.42457-2-pstanner@redhat.com> References: <20240105172218.42457-2-pstanner@redhat.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 The driver's memory regions are currently just ioremap()ed, but not reserved through a request. That's not a bug, but having the request is a little more robust. Implement the region-request through the corresponding managed devres-function. Signed-off-by: Philipp Stanner --- drivers/gpu/drm/imx/dcss/dcss-dev.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/imx/dcss/dcss-dev.c b/drivers/gpu/drm/imx/dcss/dcss-dev.c index 4f3af0dfb344..efd3a998652d 100644 --- a/drivers/gpu/drm/imx/dcss/dcss-dev.c +++ b/drivers/gpu/drm/imx/dcss/dcss-dev.c @@ -177,10 +177,10 @@ struct dcss_dev *dcss_dev_create(struct device *dev, bool hdmi_output) return ERR_PTR(-ENODEV); } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (!res) { - dev_err(dev, "cannot get memory resource\n"); - return ERR_PTR(-EINVAL); + res = devm_platform_get_resource(pdev, IORESOURCE_MEM, 0, "dcss"); + if (IS_ERR(res)) { + dev_err(dev, "cannot get / request memory resource\n"); + return res; } dcss = kzalloc(sizeof(*dcss), GFP_KERNEL); -- 2.43.0