From patchwork Thu Aug 22 22:45:42 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 13774321 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 B92EBC5321D for ; Thu, 22 Aug 2024 22:50:46 +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=9IgtH0skR0e3C63jmvkIAtxr085sHyospA98t+tzDJI=; b=rngxYJDgJpB941GdpL+u/5NXO8 gBo3PB0V45HoB9WvhoNla0NNJhY8dK2VrOt/vCyW6qjPtRpgiXIoMR0WmfC+b+UsU2NcdiNGJ09pZ y0/BB1VstoQ6Sr2dlCoX+GuEfX8Qd0fLbIokXFqVrbKMbVb4c0hwesMCAvhO5pHi5Qw87TKQyobxA cCUsmAyJiL758WFO8D3D81FWg7O70sbJkZFBfOK1C2g9xi1MZyMQekHqkuq0EjdcainAYIcLJKIKe VZKm8vzs7KxnXZCoPrYfsrKZwzKnnuCy4+3syFfVAYbsb2KOGK2Y677WOAglI06Wm3+DoVNBtvqCe v+aYLqtA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1shGdZ-0000000EWjE-2Zw1; Thu, 22 Aug 2024 22:50:37 +0000 Received: from mail-lf1-x131.google.com ([2a00:1450:4864:20::131]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1shGZJ-0000000EVe7-2NYV for linux-arm-kernel@lists.infradead.org; Thu, 22 Aug 2024 22:46:14 +0000 Received: by mail-lf1-x131.google.com with SMTP id 2adb3069b0e04-534366c194fso639182e87.0 for ; Thu, 22 Aug 2024 15:46:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1724366771; x=1724971571; 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=9IgtH0skR0e3C63jmvkIAtxr085sHyospA98t+tzDJI=; b=N6ACWyxNTenwRKseBWPBLrf7jTnOTcHl6753m6JcLe9KH1oiAb37uLXWafE1dNVpHU /47KJunXNWeYuGXx9rHVI+GCLl8Hl00QFMfp0EpkA7H89DgMqaNvD8tpm3BNycEcUSzU fsgBgyammLkc3yOhLQ0wn6SnraySuLLAuRYge4YMz2676wjWjId1rcWeIMqQXeS5OWsM Q+pUysvYnF+ybuhAdvDu1lyybr0rnFTqLcUL5RnKYLzkzPeWTWxLCVWkmonoElwQMYdz ho4jpE2VdGl02/oYpHa7oIFjKzJcboi44ywn+E56yI6AczsLYdK8xn9EcUVs+IOJMBhW gZlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724366771; x=1724971571; 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=9IgtH0skR0e3C63jmvkIAtxr085sHyospA98t+tzDJI=; b=u3Y3nkJCs4vZZ82NwlNKhfsTXcynG4IEg1WOwj35IQXF5H3yNXr88bba4xOJV1qO34 eWo4/2wSISTp6yehg3Kj1yOqdzTll5Ov7UEkm80d2VqbD5d8SOtnECWcnFc1M57nscI2 LJ6y3w3axm37NvSaZrko+pKCbPd0DdggaJgrrgbN46iHaYdngKfzGXoXAv2bZb4red/1 kFmv7Y5g7c8ohXIbjLyHjVaJ7qAHOJYRdgR5kztA6qMahOBman2gdA0kH8+pNfqNaAYR BApoWMsfLjOUsvQubJ1HuaeUCkcZKAmAPsSg9KXfroEM/0Yqq8bKnlPHj9GJS2Ck6dJ1 Ik5g== X-Forwarded-Encrypted: i=1; AJvYcCXaYdG4HdHZptn6vJVEhHeiw5wJ5dDgMSBkkohhQI2en/kUwhRCQRhY7shMu5B7cf3hwIyvCrOv0YXL2pq1BZZU@lists.infradead.org X-Gm-Message-State: AOJu0YzwNIFiUusXAJwJ53I7NTAiEVxKVjz8XPuLxO4cvdNqI9ng/b5/ 4UauIfa5PGqYcD3gaoZLQyp7VqTjEOfwyKovAsj84Po53QZVFNROEXs5Pn8NR9Q= X-Google-Smtp-Source: AGHT+IFNgxeohcK9pIDV2zZdHATDKL7WYCEymR2r9L2dWkQ/5MOeAMKb0NrqhPaC3r++lSrG4socBw== X-Received: by 2002:a05:6512:3c87:b0:52c:d905:9645 with SMTP id 2adb3069b0e04-534387786ebmr208252e87.13.1724366771338; Thu, 22 Aug 2024 15:46:11 -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-5334ea362a4sm379443e87.66.2024.08.22.15.46.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Aug 2024 15:46:10 -0700 (PDT) From: Ulf Hansson To: Viresh Kumar , Nishanth Menon , Stephen Boyd Cc: Bjorn Andersson , Konrad Dybcio , Nikunj Kela , Bryan O'Donoghue , Thierry Reding , Mikko Perttunen , Jonathan Hunter , Stephan Gerhold , Ilia Lin , Stanimir Varbanov , Vikash Garodia , Ulf Hansson , linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 05/10] pmdomain: core: Drop the redundant dev_to_genpd_dev() Date: Fri, 23 Aug 2024 00:45:42 +0200 Message-Id: <20240822224547.385095-6-ulf.hansson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240822224547.385095-1-ulf.hansson@linaro.org> References: <20240822224547.385095-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-20240822_154613_626019_D7313774 X-CRM114-Status: GOOD ( 11.04 ) 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 v3: - None. 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 0749da94624f..edef1a520110 100644 --- a/drivers/pmdomain/core.c +++ b/drivers/pmdomain/core.c @@ -226,16 +226,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 b637ec14025f..f6d26cd81096 100644 --- a/include/linux/pm_domain.h +++ b/include/linux/pm_domain.h @@ -268,7 +268,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); @@ -318,11 +317,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) {