Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp4528734imj; Tue, 12 Feb 2019 18:37:02 -0800 (PST) X-Google-Smtp-Source: AHgI3IbwPreiMfja+LBO09PEDLCSJbDU7P5oXuuaJXjg1ZVH3yhBC74sSaWBM+O/XTT0ajamJms6 X-Received: by 2002:a17:902:e307:: with SMTP id cg7mr7289929plb.255.1550025422213; Tue, 12 Feb 2019 18:37:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550025422; cv=none; d=google.com; s=arc-20160816; b=fO4XV0RTadBB9wQBhbAcNHNtkI3qhZh1xYd4JAmfoJVReazv+cOA6J0yiuhbgX9vt1 Hy1B8ClK/USKgMe5CsWeTY696QrgY+D8r7qhgaEhrmnR5wKQ/EQO1lEcZho1QE+otatf /4GlaH+sqZZHJJQH1/xIE6nGwLyWcOmCQ6v/lB0Zac+q91E6vSNRhS3IUpjPenjssRUm ZBFCGHk8/QGvNIqbv2r38Qxl+X8BZmhEnKbZgS19rVlh6HYPkQHTTb6cH2M6bkAhFP0/ 8ohPRM2dHwGgLko/Y5Uy9BJkTXxcgVHzbtR46FfWntsbS0miOe4JUM5ckznZouERNP36 RA7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=YBaxyza2NV9CVpf3tiHGSaoxrtGy64aKd5Vw5kUUcZE=; b=ghsz8Xy0NYzpWOCeEum0T8y7UifCLp3yyKNYm7p1RGh4q75PkQF+dNH8FXQR2MplLF S6B7RmSSNnSEG2lsXzhzHbarS9nXqh6I3PL3WZSf2NJhx+pWu0whDBSBT1GU6vuItPwJ UNN/9u/iw3LOdY/tcjWiob3NcBYx5C2s6HXvYL8KHLZIZEt5IGsMz6jnPgErS6BZWe4x bMP3Whl0xPlZkNK7C/6knScSbJVRRM/fqzj8LM33zvVn44nrijMaZnhTjh3NOzIiusHE rMGkuXCKihlZFcAs9NXqZOyapMZJrD0XYgZ7tVVwr8yv8R+32LQkJeVeP/LxaxTGqsMJ krFQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t14si12487821pfh.107.2019.02.12.18.36.46; Tue, 12 Feb 2019 18:37:02 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732588AbfBMAd2 (ORCPT + 99 others); Tue, 12 Feb 2019 19:33:28 -0500 Received: from anholt.net ([50.246.234.109]:60722 "EHLO anholt.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726685AbfBMAd1 (ORCPT ); Tue, 12 Feb 2019 19:33:27 -0500 Received: from localhost (localhost [127.0.0.1]) by anholt.net (Postfix) with ESMTP id 4B29510A2C62; Tue, 12 Feb 2019 16:33:27 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at anholt.net Received: from anholt.net ([127.0.0.1]) by localhost (kingsolver.anholt.net [127.0.0.1]) (amavisd-new, port 10024) with LMTP id uL1FAlm98rbK; Tue, 12 Feb 2019 16:33:25 -0800 (PST) Received: from eliezer.anholt.net (localhost [127.0.0.1]) by anholt.net (Postfix) with ESMTP id 964AF10A2C5C; Tue, 12 Feb 2019 16:33:25 -0800 (PST) Received: by eliezer.anholt.net (Postfix, from userid 1000) id D931E2FE464C; Tue, 12 Feb 2019 16:33:24 -0800 (PST) From: Eric Anholt To: Florian Fainelli Cc: linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Stefan Wahren , bcm-kernel-feedback-list@broadcom.com, Eric Anholt Subject: [PATCH 1/2] soc: bcm: bcm2835-pm: Fix PM_IMAGE_PERI power domain support. Date: Tue, 12 Feb 2019 16:33:23 -0800 Message-Id: <20190213003324.15224-1-eric@anholt.net> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We don't have ASB master/slave regs for this domain, so just skip that step. Signed-off-by: Eric Anholt Fixes: 670c672608a1 ("soc: bcm: bcm2835-pm: Add support for power domains under a new binding.") --- drivers/soc/bcm/bcm2835-power.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/drivers/soc/bcm/bcm2835-power.c b/drivers/soc/bcm/bcm2835-power.c index 48412957ec7a..4a1b99b773c0 100644 --- a/drivers/soc/bcm/bcm2835-power.c +++ b/drivers/soc/bcm/bcm2835-power.c @@ -150,7 +150,12 @@ struct bcm2835_power { static int bcm2835_asb_enable(struct bcm2835_power *power, u32 reg) { - u64 start = ktime_get_ns(); + u64 start; + + if (!reg) + return 0; + + start = ktime_get_ns(); /* Enable the module's async AXI bridges. */ ASB_WRITE(reg, ASB_READ(reg) & ~ASB_REQ_STOP); @@ -165,7 +170,12 @@ static int bcm2835_asb_enable(struct bcm2835_power *power, u32 reg) static int bcm2835_asb_disable(struct bcm2835_power *power, u32 reg) { - u64 start = ktime_get_ns(); + u64 start; + + if (!reg) + return 0; + + start = ktime_get_ns(); /* Enable the module's async AXI bridges. */ ASB_WRITE(reg, ASB_READ(reg) | ASB_REQ_STOP); -- 2.20.1