From patchwork Tue Sep 17 23:38:24 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Min-Hua Chen X-Patchwork-Id: 13806498 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 65ECFCAC590 for ; Tue, 17 Sep 2024 23:40:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=KcWP11N1mECLdbFjOwZ7f9h1sIQvx2jN9KcgmIHEfqs=; b=ta9I6oZARSdYCZ0+32oG60PJcv KgZ4aZSicUxq+Izl23gXNx6mwwuG8yRs/nLJI/UcSSzapNMN3pI7mz5ULfp0QPqL3izEb3UvaKmE0 w5/aC0f4emfPNUOJx+VPZj0cDUMV7IEb36+xNUtSeX87YhZ9JvHqn1tfS4wlr58Jh5up1YCO+iaes meOveRoljXCCBxV0NOtFeNL8jSqsHmPu/eO9DxEoPypsZePYuddA8WQheskLxXK7QTGjjzr5UgGll O7fPTgcHpjdWXLFgNo+8M+9iu5EgwzIMwpsrNRAOq2RB2iY2uklsUvpQ0GOQy2AvdiM4nCxAYJvop MNHBXbjQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1sqhng-000000079y2-2MKh; Tue, 17 Sep 2024 23:40:04 +0000 Received: from mail-pl1-x634.google.com ([2607:f8b0:4864:20::634]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1sqhmY-000000079q5-0z1z for linux-arm-kernel@lists.infradead.org; Tue, 17 Sep 2024 23:38:57 +0000 Received: by mail-pl1-x634.google.com with SMTP id d9443c01a7336-206b9455460so2161585ad.0 for ; Tue, 17 Sep 2024 16:38:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1726616333; x=1727221133; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=KcWP11N1mECLdbFjOwZ7f9h1sIQvx2jN9KcgmIHEfqs=; b=EwDqQdnyU/VXjvbAN2t6GTTHV4JEgAmDvudPlwZ0zk+TjMAOwp7h9hLRO56ZJy+pt+ xe65KrS8oXNfWCGS9W4bI9GWz7OJNvN8SAEoH64tLSCEwhiihR0x0HbsgIefY+NwxSqY SZ+NUp+GjAbYaHkPi0/Aso/8vmgFzJD/3/AFjrpGMIccijd3V7QwQXmz6LFYcEviNNSg fMZKZ9g/uMlZJTv6rn7wsqT5+W9G+S+p24rdzwZMie/z1xgofpfXpcDUqIcevPoguvcB j+GL5KyN7sx8fETblSdMrWXUaTWiegsAG2Ns676j+JbJdrWRUfbFv3JoDv672S6aR32N YnRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726616333; x=1727221133; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=KcWP11N1mECLdbFjOwZ7f9h1sIQvx2jN9KcgmIHEfqs=; b=g0PZ6ZNs/du6NnUdyIdiXLYT9SAIUApPtR9J8jR0aYaA9lD9GMO4629UtnIOkgGrcn pEpe2QaqGTOnymKHHMrzozu9SQ1XSg4uUVxnWIUOTl+bgJmpZiNCS2M8AiMZLeLmiMm/ 6x/4eY3w08M4HXbKrqNER76uPGUQjZog+g21qJWNnbc1BSyVfZS0BIxloyHmPCHAyBlK QUhED+HncolxhAFC6ZoR0uU2nkRHfqNyOokMPZ9MUHM6xf7Igubz7DFjh96jXgAVp5LL mKZL7/2/NAAN+ZnjO43dAJ7SobYuEGO4hK7AD9erdI2nZddoy8fDnWOYENOeXNvh3Zs0 GYYw== X-Forwarded-Encrypted: i=1; AJvYcCXPO4WI/V/p2K/hP/2pGofg+SLpu17cIq3C0KoTguymXmJNE+f4lF4Csye1PH3NEvHGJ8PT9tLNvZBsRaHTwNJ7@lists.infradead.org X-Gm-Message-State: AOJu0YzHErxCY3OiXuKXkgPW2K1dl629L1TrkByLTx5kANznmIR5oQjW hOeBNnDdKsBzpp6EoUaIbAspWeQAzvCOafqpcw7Sv63RDlQvRLRH3Co+VA== X-Google-Smtp-Source: AGHT+IHm9WpKunvYUYVdRVcqdRL0Bvu5XN7F6kHqwZuyCwxSybIQSyzr4LjktjFz8vvpFTrPR48dmQ== X-Received: by 2002:a17:902:e88b:b0:205:8763:6c2d with SMTP id d9443c01a7336-2076e56e3c5mr288594445ad.9.1726616332643; Tue, 17 Sep 2024 16:38:52 -0700 (PDT) Received: from localhost.localdomain (111-240-85-119.dynamic-ip.hinet.net. [111.240.85.119]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-20794740131sm54880525ad.290.2024.09.17.16.38.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Sep 2024 16:38:52 -0700 (PDT) From: Min-Hua Chen To: Lorenzo Pieralisi , Hanjun Guo , Sudeep Holla , "Rafael J. Wysocki" , Len Brown Cc: Min-Hua Chen , linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] acpi/arm64: remove unnecessary cast Date: Wed, 18 Sep 2024 07:38:24 +0800 Message-ID: <20240917233827.73167-1-minhuadotchen@gmail.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240917_163854_696957_C9E6DCD7 X-CRM114-Status: GOOD ( 12.77 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DEFINE_RES_IRQ returns struct resource type, so it is unnecessary to cast it to struct resource. Remove the unnecessary cast to fix the following sparse warnings: drivers/acpi/arm64/gtdt.c:355:19: sparse: warning: cast to non-scalar drivers/acpi/arm64/gtdt.c:355:19: sparse: warning: cast from non-scalar No functional changes intended. Signed-off-by: Min-Hua Chen Acked-by: Hanjun Guo --- drivers/acpi/arm64/gtdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/acpi/arm64/gtdt.c b/drivers/acpi/arm64/gtdt.c index c0e77c1c8e09..24bd479de91f 100644 --- a/drivers/acpi/arm64/gtdt.c +++ b/drivers/acpi/arm64/gtdt.c @@ -352,7 +352,7 @@ static int __init gtdt_import_sbsa_gwdt(struct acpi_gtdt_watchdog *wd, } irq = map_gt_gsi(wd->timer_interrupt, wd->timer_flags); - res[2] = (struct resource)DEFINE_RES_IRQ(irq); + res[2] = DEFINE_RES_IRQ(irq); if (irq <= 0) { pr_warn("failed to map the Watchdog interrupt.\n"); nr_res--;