Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3851539pxv; Mon, 19 Jul 2021 10:14:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzT4geaCaOUPYDU7zgNvVVeCBrMgIcPuGVlq1+gXYzbBg1xT+e2PLgIfFbsGOGI6dyCRncM X-Received: by 2002:a6b:cf15:: with SMTP id o21mr19988259ioa.9.1626714898495; Mon, 19 Jul 2021 10:14:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626714898; cv=none; d=google.com; s=arc-20160816; b=BZyhjhCx0w1BmJmj7af/Ni2rmj4Ui9p4u67ai0m+dEZQaySQ7NrGGvDNecrHQsx10s boV776ML5xfdNC3atV7CFIeflTn+xM3SPkQ76efx41RYsmLXRN+wm9TKpiUUo9FIdQVa EYP4UKo0y/YIt2PW+3WPdWzmr2HM4PDaekikr1d7SbvLAp9G1EKxUm7yDdojzh0+ev7z y4Wk4KZ0cD7XT8Ls/IANi9b+/QPG6PhCcsbgSDeI+RJZcM4KN5gUDuTmRoXi3YPxR+Sj DAVM3fM4eJTRxwSeRzFQ4oJOnax/TGkciR1KQKAGhBXuAjHWnqp03L/dbqf7EDnyL15B L9gg== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=nFGvBZJ7BOJdMe856wYZhaMLaP4Yq3pAYj+QMicVQ1o=; b=mMIApqD3FQ8Wi7MnQe2zh8ZNRwPc+QsVtQ4Fye0JjrsrAsdm2tkW+p8CGjrL2jcNhO jnM/lC1TdMwI8Xsh5HfSoPFtLYvW06eg1/GlC6bVXYnvPEvmbtJA2q6IBZn6eDf6vxbx k931zagxVOQqYzjmCNePdHA99pMnya+WoCAuSZ6PAJSrly0FnxFrWcGgyfDeNVaplPzZ +H+yFQVIOJYYnqrgz9dAlcFGc1CKrADgNyXXbL+fYX0VnTuYZBSWafCg/6KmJrfuMAEl 0b+ZSraVef8X/lgub/g80sKazB8oh1h98cerRwBKRzeU7873otHYnoeFFi9hJDcK20WE K8bA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=uBoDx9Tz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b15si21433498ilv.151.2021.07.19.10.14.46; Mon, 19 Jul 2021 10:14:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=uBoDx9Tz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352674AbhGSQdg (ORCPT + 99 others); Mon, 19 Jul 2021 12:33:36 -0400 Received: from mail.kernel.org ([198.145.29.99]:59504 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346608AbhGSPRn (ORCPT ); Mon, 19 Jul 2021 11:17:43 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8F98C613F1; Mon, 19 Jul 2021 15:57:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626710257; bh=Kr5HoqsE5MPFdwwLrEQmw5vIHfZj7/DGPLKFuD6t3uY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uBoDx9Tz12ha9BWRYfEC/IdAdQcepcuUwrbU3rA3nLWsIRygT0l7L0IZaBNja9aZG v+eClcNjRHT0HmcQW7MfUwNkDv7PT4LNLxPVnUhvTpSko6KY0YFovwBdWgjhnE+Ggd UWF8/sHtzse9lgSYI6zH8S+nNR0WIWtD1hXT6w6k= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Liguang Zhang , "Rafael J. Wysocki" , Sasha Levin Subject: [PATCH 5.10 140/243] ACPI: AMBA: Fix resource name in /proc/iomem Date: Mon, 19 Jul 2021 16:52:49 +0200 Message-Id: <20210719144945.437342514@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210719144940.904087935@linuxfoundation.org> References: <20210719144940.904087935@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Liguang Zhang [ Upstream commit 7718629432676b5ebd9a32940782fe297a0abf8d ] In function amba_handler_attach(), dev->res.name is initialized by amba_device_alloc. But when address_found is false, dev->res.name is assigned to null value, which leads to wrong resource name display in /proc/iomem, "" is seen for those resources. Signed-off-by: Liguang Zhang Signed-off-by: Rafael J. Wysocki Signed-off-by: Sasha Levin --- drivers/acpi/acpi_amba.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/acpi/acpi_amba.c b/drivers/acpi/acpi_amba.c index 49b781a9cd97..ab8a4e0191b1 100644 --- a/drivers/acpi/acpi_amba.c +++ b/drivers/acpi/acpi_amba.c @@ -76,6 +76,7 @@ static int amba_handler_attach(struct acpi_device *adev, case IORESOURCE_MEM: if (!address_found) { dev->res = *rentry->res; + dev->res.name = dev_name(&dev->dev); address_found = true; } break; -- 2.30.2