From patchwork Sat Dec 2 16:24:42 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jorge Ramirez-Ortiz X-Patchwork-Id: 120428 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp2510444qgn; Sat, 2 Dec 2017 08:24:57 -0800 (PST) X-Google-Smtp-Source: AGs4zMZlTaJz44ckJeIsZCsHg9tu7paQQ3tyP7UTx/9+gXlTeucrQhcPfYHF6Pn5I35o7/znFGOr X-Received: by 10.80.145.3 with SMTP id e3mr23106173eda.273.1512231897004; Sat, 02 Dec 2017 08:24:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1512231896; cv=none; d=google.com; s=arc-20160816; b=LTc/uB77e+djOi18psLMCf1oB2/fe7LdP/7JLxNynokv+PKvCi1hRbWkdlN1aaCkpb JcxI4Rxw2qa0ai66fn1UriKesk2sI+Gg6MFmnDaiU2KqGcRGNdrEiIRs5TmiivkkBIKt X0bfNFNp0Y5aOfCphMalLaRuy/u4I2JjxunQXZXdz93mwOsi/NMmly9XNUfqms8bhKl/ 4qwWLBNAiMfVx2Q7xftD+PJit7BJb6poXya/azu00arq5nACT20+N9d8YWpEIsUX9giK uyvHglTYhWa2f7WD7hBTbw71mkqR7SyPg3w+YGk4cj2NPI4HkIB7US91EkTQwpA6Dj2j 0Q/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:message-id:date:to:from:dkim-signature :arc-authentication-results; bh=UiSVcI7FKuoJauPgbS7DpBZOVTPvK5YeEcpl9pgeZUw=; b=cnUQSczJDy3ZOfAOyxSTkfFLy3MTJdwchIs/UFzI00hKhlH2Xb09t4lixjJHOGyenE FVtkn8AVZwHf69B35g1jhxeJg3qRCwj9V2c7IQyeOq1G/7ELTDk6/nQcLJnqZsMNVprq eXzdvR0J/Py6G0mErR6h6ehoJ/2ir76J9Ax07Dy6DLiWqDpbHwowFhtukJ+KHY8j101m t11jqhJrbMrvRcTmvSXSDUNJYUl4d9EzyS617gMCPyDFjp4UsstpCbEmBAcEyaWCYtlv 5RNqZ5NvrYTiWkvAvO7TZNAzEMbaNVgg2b8581CHlWKHriaHBHL2IDZN5ZM+llmUqNH0 7cjQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=AIiViwEV; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id k61si317227edc.509.2017.12.02.08.24.56; Sat, 02 Dec 2017 08:24:56 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=AIiViwEV; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.denx.de (Postfix, from userid 105) id 6520EC21F2B; Sat, 2 Dec 2017 16:24:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_IN_MSPIKE_H2, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 6A988C21ECC; Sat, 2 Dec 2017 16:24:50 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 06B4DC21ECC; Sat, 2 Dec 2017 16:24:48 +0000 (UTC) Received: from mail-wr0-f196.google.com (mail-wr0-f196.google.com [209.85.128.196]) by lists.denx.de (Postfix) with ESMTPS id A624CC21E76 for ; Sat, 2 Dec 2017 16:24:48 +0000 (UTC) Received: by mail-wr0-f196.google.com with SMTP id x49so12998969wrb.13 for ; Sat, 02 Dec 2017 08:24:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id; bh=4hC8Hpzn4VUnOngEr5l5yrsiAQnLtgwOsl+TIUPNk7A=; b=AIiViwEVodgpMKh7+HdU1R+qWrgb5HB35dFlwmJSCwKQDy+KUF+THFUHdAmMTyP4eL bc68r9N+OBUocXlXNHkTUCsW+vP+54w+HlZwjt5I6Asz4tIDTFgle2RIYdimArGncH2O o5vKDHIMyPtvdLbARcMZnBgyIR1ZIixmGldfA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id; bh=4hC8Hpzn4VUnOngEr5l5yrsiAQnLtgwOsl+TIUPNk7A=; b=WL5XumRJHMwFcnX/Olq/7buXi4Rg/B6HLLNxvvAdx1tqZnilaa9yBckp5H1kTGTxuk MtYzsTKCBRYdJTwCHFqjqpecCnv5lAVuPPmGD+qMVwEevPQFMd2dx5xJ2kDfjAlxgZzq tWaWW/u3Jri9IMH46vsKCQghqnXjP/c9UMHon1BZK/A2FQaP+g3xr0y5yvhnWWQG6dOB V/5ZhHkp5egAISSD3HbvOVGbCbtdW5B4vyTA5VQoUp3sB3RYTIwRKzt3O2AFGgxK5m5s LEmcEu4nU/Z48f65vmeA6VeRbrq8GfXhqj36lnnQZa5RU/U0n7G/VC8idPorU43nGFM2 YlSQ== X-Gm-Message-State: AJaThX49Y2xqCOx+uNdG0+/agjBuL5+qAvb1VqCZjFqvTqCyXhbefThM KOm2lvcN3WtUuy0EB0JqoSqr3w== X-Received: by 10.223.134.1 with SMTP id 1mr8179740wrv.213.1512231887959; Sat, 02 Dec 2017 08:24:47 -0800 (PST) Received: from igloo.80.58.61.254 (141.pool85-51-114.dynamic.orange.es. [85.51.114.141]) by smtp.gmail.com with ESMTPSA id r19sm7393724wrg.83.2017.12.02.08.24.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 02 Dec 2017 08:24:47 -0800 (PST) From: Jorge Ramirez-Ortiz To: jorge.ramirez-ortiz@linaro.org, u-boot@lists.denx.de Date: Sat, 2 Dec 2017 17:24:42 +0100 Message-Id: <1512231882-5284-1-git-send-email-jorge.ramirez-ortiz@linaro.org> X-Mailer: git-send-email 2.7.4 Subject: [U-Boot] [PATCH] drivers: spmi-msm: fix scanning for peripherals X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" A typo in the probe function causes not all peripherals to be scanned (in the case of the Dragonboard820c - work in progress - it wont find pmic0). --- drivers/spmi/spmi-msm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spmi/spmi-msm.c b/drivers/spmi/spmi-msm.c index ca27ee5..c226913 100644 --- a/drivers/spmi/spmi-msm.c +++ b/drivers/spmi/spmi-msm.c @@ -161,7 +161,7 @@ static int msm_spmi_probe(struct udevice *dev) return -EINVAL; /* Scan peripherals connected to each SPMI channel */ - for (i = 0; i < SPMI_MAX_CHANNELS ; i++) { + for (i = 0; i < SPMI_MAX_PERIPH ; i++) { uint32_t periph = readl(priv->arb_chnl + ARB_CHANNEL_OFFSET(i)); uint8_t slave_id = (periph & 0xf0000) >> 16; uint8_t pid = (periph & 0xff00) >> 8;