From patchwork Thu Jul 18 23:43:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 13736787 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 7B5F3C3DA61 for ; Thu, 18 Jul 2024 23:45:39 +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:References:In-Reply-To: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:List-Owner; bh=qiy79RCH12nO+kuD43r9KxQZmT684plvYyRVA5SbNNc=; b=K8NW+m6mLCN8n9Ju2bZ1cT1b45 ywQbkIWbJOJXeV0aknGLAlBy7e37ekJPdqbMSnDajvh0hRlqTmNM/O8lY68iu/XkAPzztj42keGbE 38TDMVVBEg258GkvHHIBhnBL6v03xgptgdCXMyF7nZ8imsr8kdofcYoiRJ9Ll+hKHimeHi0yT/yjr PvCap4f4EHnZpMUnBFIhHoEa9/FBq4uWVvXLvDsDyhLiNIKvjOID9hzRlu2riRrtPykIfqhVbYDA5 gXQpOinLLJhi6EA/+qZk56/IaQy6c04U7uQVRITX0p1z3wBPjn1aE/5Sxv1e88Jo9KibEAs1hnOyY VVSzyxSg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sUaoR-000000011lo-1j41; Thu, 18 Jul 2024 23:45:27 +0000 Received: from mail-lj1-x22f.google.com ([2a00:1450:4864:20::22f]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sUama-0000000115k-2oKX for linux-arm-kernel@lists.infradead.org; Thu, 18 Jul 2024 23:43:34 +0000 Received: by mail-lj1-x22f.google.com with SMTP id 38308e7fff4ca-2eea7e2b0e6so21540541fa.3 for ; Thu, 18 Jul 2024 16:43:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1721346211; x=1721951011; darn=lists.infradead.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=qiy79RCH12nO+kuD43r9KxQZmT684plvYyRVA5SbNNc=; b=eW4XjwDwPI61PJznhFS4WJUKni858awq33B1gA1apPrL3boRWp7hun8NND7l86wkL2 9CNaoAH5tl6pGBHHqTHL8stPm6yqWO6N0+1Ng181O5KQOqbobDYrLRg1BTSOnZXm6x+z j/dYzmjqWuRK3zqDhfk2wVt2Jjp2Z1oypm3QOdv4o2JdB8S1rsFYtrzgfoeYrOd8LZoC h9bU3je3FkENMcE63tWfS+9s0juLT1IIz9f1szOn4tE3/Ptr7LyQzAqGrStxVy7kubUs /gv4bJE6tvugjyJA+zjGzGbPL+whW8IxVv/Up5pOJBemjKAAfhSsYxOtALyIOAevM16L Oc4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1721346211; x=1721951011; 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=qiy79RCH12nO+kuD43r9KxQZmT684plvYyRVA5SbNNc=; b=G/Sp9IWAN2Nj6otDT4MAeJubcy/RJC6e5hY6B5scAMleG2UO0DBsVKvEz5101A7deX FfXZaptW76uOKT66J9uS76SO/VZW90k4hNm10zeIGnXbSj/N/QfaadGooq1NRpvG+lwA O+WsZj1nDiKHHyjXnq7lOIxFIRSTnCMgsCcYZuWUFoVynYXAZb454hF5UkGy0PbCj6jt kagGt2Y2AN4/LETOzyu+WvqJb06Q4zIvmmDyLFRLuf32lDC5Mtrfd5RGfhjxaYtM5qIM 62Q5P2lM3GBRnalRQ2o3Z7DmKHnsbRrEVF852fm+YnogDrNcZTD2e9RVRVZds8uB3jmq 3Njw== X-Forwarded-Encrypted: i=1; AJvYcCWqOKU+TZlgHjJqyy8Fi7zKbVlDgvJyPO2d4x6OH9CITZQNKuBY27qH5X0IrAZ2uKNDMH2miPIXhcQRQiAlInrAmIcHpDqiqBbVKuW2tsLSWRlCk/w= X-Gm-Message-State: AOJu0Yw0LWdKP6vH5UguqxqasnciR1wPi58Wd1YRu7TmxkpZ+6qHE6fI mlf8bXnGksy68nlatPWR/n+qNCwTWk6+fa3sIB0EkzkNO8AwEN+vJmATgI9jay01NyqvVtqGb2m D X-Google-Smtp-Source: AGHT+IE/PQcs9Xj45ekRvDZ9k+t/Et7RHcrmh62SIuBoPAG7Wl7rJpYPtWq1KQeWzrJ9ZjlpqQ2KEA== X-Received: by 2002:a05:6512:39c7:b0:52c:8df9:2e6f with SMTP id 2adb3069b0e04-52ee5429228mr4551665e87.42.1721346210863; Thu, 18 Jul 2024 16:43:30 -0700 (PDT) Received: from uffe-tuxpro14.. (h-178-174-189-39.A498.priv.bahnhof.se. [178.174.189.39]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-52ef556b4fbsm22491e87.139.2024.07.18.16.43.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 18 Jul 2024 16:43:30 -0700 (PDT) From: Ulf Hansson To: Viresh Kumar , Nishanth Menon , Stephen Boyd Cc: Bjorn Andersson , Konrad Dybcio , Nikunj Kela , Prasad Sodagudi , Thierry Reding , Jonathan Hunter , Ulf Hansson , linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 5/6] pmdomain: core: Drop the redundant dev_to_genpd_dev() Date: Fri, 19 Jul 2024 01:43:18 +0200 Message-Id: <20240718234319.356451-6-ulf.hansson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240718234319.356451-1-ulf.hansson@linaro.org> References: <20240718234319.356451-1-ulf.hansson@linaro.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240718_164332_732557_4110B393 X-CRM114-Status: GOOD ( 10.71 ) 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 There's no longer any users of dev_to_genpd_dev(), hence let's drop it. Signed-off-by: Ulf Hansson --- Changes in v2: - None. --- drivers/pmdomain/core.c | 10 ---------- include/linux/pm_domain.h | 6 ------ 2 files changed, 16 deletions(-) diff --git a/drivers/pmdomain/core.c b/drivers/pmdomain/core.c index fdbc3aab9083..bc89edcbd583 100644 --- a/drivers/pmdomain/core.c +++ b/drivers/pmdomain/core.c @@ -184,16 +184,6 @@ static struct generic_pm_domain *dev_to_genpd(struct device *dev) return pd_to_genpd(dev->pm_domain); } -struct device *dev_to_genpd_dev(struct device *dev) -{ - struct generic_pm_domain *genpd = dev_to_genpd(dev); - - if (IS_ERR(genpd)) - return ERR_CAST(genpd); - - return &genpd->dev; -} - static int genpd_stop_dev(const struct generic_pm_domain *genpd, struct device *dev) { diff --git a/include/linux/pm_domain.h b/include/linux/pm_domain.h index f24546a3d3db..772d3280d35f 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h @@ -260,7 +260,6 @@ int pm_genpd_remove_subdomain(struct generic_pm_domain *genpd, int pm_genpd_init(struct generic_pm_domain *genpd, struct dev_power_governor *gov, bool is_off); int pm_genpd_remove(struct generic_pm_domain *genpd); -struct device *dev_to_genpd_dev(struct device *dev); int dev_pm_genpd_set_performance_state(struct device *dev, unsigned int state); int dev_pm_genpd_add_notifier(struct device *dev, struct notifier_block *nb); int dev_pm_genpd_remove_notifier(struct device *dev); @@ -308,11 +307,6 @@ static inline int pm_genpd_remove(struct generic_pm_domain *genpd) return -EOPNOTSUPP; } -static inline struct device *dev_to_genpd_dev(struct device *dev) -{ - return ERR_PTR(-EOPNOTSUPP); -} - static inline int dev_pm_genpd_set_performance_state(struct device *dev, unsigned int state) {