Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp627879pxf; Thu, 8 Apr 2021 09:42:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz/ejD4j6FF6oDzrwbv20HAvwbcjMGFJ61w0YoY49RAtWI9KEXMfohlHKDNyXaIq7SpILqh X-Received: by 2002:a17:906:1519:: with SMTP id b25mr11495746ejd.254.1617900147869; Thu, 08 Apr 2021 09:42:27 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1617900147; cv=pass; d=google.com; s=arc-20160816; b=NC4njboGpAXVyIUySChxp9bdiMIwzsECUKwnJZJzUGk6bW7Lle8PVNCixKc1e33/Cz 5NvN4Hd0PRGuxZkndeACNlo95bUbZqVvBKBtbjMZM9XrYoxwAybtYPnSXJvvUZYwwRJa l6GFpD6sa9hS55Wi3xidYBacnGTejp265HsNoRSHj8VJqCXE0xvNBF3/WukE7plXfBk+ lTNhRxLFrPzlKJHb5iA78MmL6/+QU9oF6kzOd0d2yxRId4DxvjjHcM+KhmjMaNvanD87 53d9s+XBdsRjhVV3RsR7B/anooR/9WD/ltJEcflSnRo/eZ4SKLVtrUfylJSR1qWivhNO 8gew== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=35hfr5ZZ65G5kjr6Uosor2+IgWxXobrsYnF2sOyxmBA=; b=lez3m0dl92wEuE0buKRng7WZbE9dH+zV7Pkrdi/PPfnJHSqkyW0oLWAZMLPKjJpSWr X8uRmKn7i2w+/eUQmP5HSolVt0DraX//bIfa0fpX4QiwDYCK+s4y9Lri0CBGNChVKr28 2tD9TJgeaokofvI6M+6YRX3Xf0YHMF67O0QQAYNOe1E5RiS2KlNO3hN13K7EnEjfg9Qt nGUb+CWlTQhceXpi/Agk1xM1jnduqp6zrP8Z8hFOxsZSH6h9/ka0MK7D51UniXC8qUDQ T568GuXHv3J9L+tKyHz6y0u1/UMIkZ6qTHoEXXOhkG4iGwwUJ2BUL7mWFWuBKzksZeEd ucIQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@Nvidia.com header.s=selector2 header.b=Qk3TeNkN; arc=pass (i=1 spf=pass spfdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); 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=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id zp16si10873757ejb.704.2021.04.08.09.42.04; Thu, 08 Apr 2021 09:42:27 -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=@Nvidia.com header.s=selector2 header.b=Qk3TeNkN; arc=pass (i=1 spf=pass spfdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); 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=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232350AbhDHQk5 (ORCPT + 99 others); Thu, 8 Apr 2021 12:40:57 -0400 Received: from mail-mw2nam12on2074.outbound.protection.outlook.com ([40.107.244.74]:7200 "EHLO NAM12-MW2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S232331AbhDHQkv (ORCPT ); Thu, 8 Apr 2021 12:40:51 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kfPVjA2de2iv5ruBr5VW+xX/AbvqX2gFEWIHiGoSIJUSWzW5tsizDiW4LBcbbuQ/y3Olb+wCc1mxNT5apwJE1St0o2UTRXCDY84WNmaFELAWxJeIOhPlIMgQBBsOpkBhIrlYsJVWxWbaFHJuYlJdQb7nwY/hFI6YsBkhsEseDesHIV1AJLwM3b+QAIKvhX4l3ZOumEEZ585+q98pzzTkLJfDzpqxBBiNMSOovOs6HKVrp8WOrrh6sVsCbXqFJdunwxlsAd1B+LpDP8+rznnWQEvRTqQB968LmtR2EzqeqHyz7s+iPzQJfKUD88pA6VQGSxVKWJwKok5Ttz6LPNQGnQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=35hfr5ZZ65G5kjr6Uosor2+IgWxXobrsYnF2sOyxmBA=; b=nNKV/+2arBjBJy2acE5Ocv16XH15A4O/G3Q9ENgoC16BT0UITxjNu449wr/VRl3dAu0AEsc3f3N0S6I8NY6v7NDZP7S+3ohx4uxjQgBAkDuqXsQoiLa49o2f/6/AsLavd2X65aqXCc40e79sgz7FkDNy8mbjQ81yp/8Cog48m76cxGRdsuXWWZsx8rB8uy3sTOFaj8Ms8OzC21tInVr7SqCVB5Sa8+elf56PjCVi+878aiFmtfOdxAvA8OlfNyA4GMJh6o8igXqX5CCizAOeDGEZG2lri0HGWHeNFrcwdTkiVjbMSz1dNpBh8oujogrMbF5vAleMd091bB6vS+9vNw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.32) smtp.rcpttodomain=vger.kernel.org smtp.mailfrom=nvidia.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=35hfr5ZZ65G5kjr6Uosor2+IgWxXobrsYnF2sOyxmBA=; b=Qk3TeNkNRjdsNz8/oPNxl5SEFZaSjzdE+7FC3eZaGbTVznJZDxItP00FZVz6hFiWUcPFbdbHKjWTC/c4VK/An90oMMd3txgYkzcU0B6VgOo/JV0DMH437unz30GvA9bxj99gRWadbnlLyHE6DDG/LVWlpAiYGVnori9zFa7TxudKhyoP0NXxQK65rsSxVNadycRbtCRgGuwbZ7Rg/E+HbFQ/lkHl9YtLOwXlIZQjJ2ecrc6dYstHnQirZ8S/DFE1GGsLAUH6RXbU6Dim3qNLrLkCZWyqZNQ9SACtaKQTto8nT9zoHakqeTOEwrEDAGvyR2ZB9GY+1AFLUgrjRnxg5w== Received: from BN6PR17CA0011.namprd17.prod.outlook.com (2603:10b6:404:65::21) by BYAPR12MB2631.namprd12.prod.outlook.com (2603:10b6:a03:6b::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3999.28; Thu, 8 Apr 2021 16:40:38 +0000 Received: from BN8NAM11FT006.eop-nam11.prod.protection.outlook.com (2603:10b6:404:65:cafe::a4) by BN6PR17CA0011.outlook.office365.com (2603:10b6:404:65::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4020.17 via Frontend Transport; Thu, 8 Apr 2021 16:40:38 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.32) smtp.mailfrom=nvidia.com; vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 216.228.112.32 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.112.32; helo=mail.nvidia.com; Received: from mail.nvidia.com (216.228.112.32) by BN8NAM11FT006.mail.protection.outlook.com (10.13.177.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4020.17 via Frontend Transport; Thu, 8 Apr 2021 16:40:37 +0000 Received: from HQMAIL107.nvidia.com (172.20.187.13) by HQMAIL109.nvidia.com (172.20.187.15) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Thu, 8 Apr 2021 09:40:37 -0700 Received: from skomatineni-linux.nvidia.com (172.20.145.6) by mail.nvidia.com (172.20.187.13) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Thu, 8 Apr 2021 16:40:36 +0000 From: Sowjanya Komatineni To: , , , CC: , , , Subject: [PATCH v1] ata: ahci_tegra: call tegra_powergate_power_off only when PM domain is not present Date: Thu, 8 Apr 2021 09:40:43 -0700 Message-ID: <1617900043-10506-2-git-send-email-skomatineni@nvidia.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1617900043-10506-1-git-send-email-skomatineni@nvidia.com> References: <1617900043-10506-1-git-send-email-skomatineni@nvidia.com> X-NVConfidentiality: public MIME-Version: 1.0 Content-Type: text/plain X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: bddd10d7-5e71-4022-bf25-08d8faad0a48 X-MS-TrafficTypeDiagnostic: BYAPR12MB2631: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1091; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: RLNnFY7q8xyL1Dc21xjX2lxnlv+RrTNmol2a+0P3Xaej5KDmOqfv0GdTQatkG0Lq7Yh9h3FYufrW7J2LGGfpeFlgYZkYiVsRIvBeThWTPm7B1W3kXwYmK7NXUGIAJYTvuQVNFIN0WWPYEGr/rlEhgZoifP56a4CIi2zIok0uM7aYND0bt+X1yBM2vIFrwtVSho8IGypFae5uuTc4dlg9izbmF45KHuSINb2FiztO7/t+HSLQh7iaklAdZT1mxLnMpPl6uJ2WUbR8AFXnrprBg4tS2MWTQK/Jjj9GPYxmZiesfov8B4XOnNfSW1dM7A9Pl13rNJatcVtt8YO7kEDnjGvmf7NntLiiCuvm76XBqgQqz1DA4cRHG40YpXWg2oMm6a1CjvMastYWVYpnbBh6Eu6XUc+J8ts1vkleyq1ekebuZW7kA6BjfGKNPVPLRYGkk5KcnJJ5pf2DO0+xtEGeYMe9nSdGzvLwqqwM1MTpwL3WVNKJzvXNJWykhV8JKU8mvQEWxluyxh2BNF0K6WOJYH3TEFCE2N9yxgRSK9Y7fP758I2fOD6YefT3e9QOAAe4GIHGGkFd/CEez3ZN2Xnf0cHNjvz+EZyWnxVO9yeRHZgt3bPCWXpqe5lnkcfMV88k/GAlAXXT2bGE58c2zJuJUU1wDSXUUyIz7pzYHejWt9hZ32Z4NOIBoM6scrE7kBXD83tjOHLiQnHzYLyYq8rZvgejmMcv7aY2JuKirp41fN0= X-Forefront-Antispam-Report: CIP:216.228.112.32;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:mail.nvidia.com;PTR:schybrid01.nvidia.com;CAT:NONE;SFS:(4636009)(136003)(346002)(396003)(39860400002)(376002)(46966006)(36840700001)(47076005)(8936002)(54906003)(110136005)(478600001)(8676002)(70206006)(966005)(7636003)(336012)(82740400003)(356005)(186003)(4326008)(26005)(36860700001)(6666004)(316002)(426003)(2616005)(4744005)(5660300002)(82310400003)(36756003)(83380400001)(7696005)(86362001)(2906002)(70586007);DIR:OUT;SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Apr 2021 16:40:37.9902 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: bddd10d7-5e71-4022-bf25-08d8faad0a48 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a;Ip=[216.228.112.32];Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT006.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB2631 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch adds a check on present of PM domain and calls legacy power domain API tegra_powergate_power_off() only when PM domain is not present. This is a follow-up patch to Tegra186 AHCI support patch series https://lore.kernel.org/patchwork/cover/1408752/ Signed-off-by: Sowjanya Komatineni --- drivers/ata/ahci_tegra.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/ata/ahci_tegra.c b/drivers/ata/ahci_tegra.c index 56612af..bd484dd 100644 --- a/drivers/ata/ahci_tegra.c +++ b/drivers/ata/ahci_tegra.c @@ -287,7 +287,8 @@ static void tegra_ahci_power_off(struct ahci_host_priv *hpriv) reset_control_assert(tegra->sata_cold_rst); clk_disable_unprepare(tegra->sata_clk); - tegra_powergate_power_off(TEGRA_POWERGATE_SATA); + if (!tegra->pdev->dev.pm_domain) + tegra_powergate_power_off(TEGRA_POWERGATE_SATA); regulator_bulk_disable(tegra->soc->num_supplies, tegra->supplies); } -- 2.7.4