From patchwork Sun Jan 6 08:37:46 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andreas_F=C3=A4rber?= X-Patchwork-Id: 154834 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp2355232ljp; Sun, 6 Jan 2019 00:38:14 -0800 (PST) X-Google-Smtp-Source: ALg8bN4FuCJIBNQ30coEu+gWM10QmUMREEkyOBK7fHsbOieAJQ1T4xhrRXi48RArNfZivc4lY0Qq X-Received: by 2002:a17:902:bb05:: with SMTP id l5mr58118464pls.230.1546763894150; Sun, 06 Jan 2019 00:38:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546763894; cv=none; d=google.com; s=arc-20160816; b=cm3ZULcGkd+itiPCOKuvsiZWX7lTFmfRvDAUCRizD29eSapLL5flkYR+ruZQbR4Y0m Q7IiDxnTjlHPLpW+Km5B1YeCOyWZn5bomUa17vc3Fw93Yi00nvzeV3mJrrDzlmlJJZjB xv/CWdX1Rc+Sf5bc/C6cQJcpEiJr3yYcjCQWRnzDLdJHaJswYoURG+1NJVmNO5TdD8x9 cOz9OSCcv1PE1w6RjBxSlPntofE/u9yWIM3WLIsWHCUHxhpGi+e+s8FbcHXApreSpYf/ aM2aA1zRXz3mUnkNTb4vGB6/qQZz5wD87vX40YcrpHZgzXVeUhEnuaKqYcjjc20S65yt 2/sg== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=64OZYTuFcBoonqd6t1/+HCakTY7iEILIosGgoo8/AOs=; b=jwjjDb6RT0OiR1G6MdBMrall+5czV81UzRBLcjf0zHyfdqG8nBGJ5YIAVusbE0orUz H3Dy+T5LWyGDrv8psMuphgk7/eY7GRBrQTpWicp5UVnyYdgfAucml//aNY7VqNuslwLG XCAM01Uteb/mOosdpWJdG7vY3VAhJQHz2sV3P9WzE6b9pC6VNbq6qyhxS3tQEaodVk5N IKg2FsIyKNGadgjG5gaA2xhE0hgoiHvKcr7qHHO/Y/pl+Kicqz5Q90UGABFCsQrOD4qJ CZJjvMxggyYdI3B+izvBMFqvGDF32CiNq+RsTY2ELPCC6arF6aRkNoyo8mslDSita8tw pPEA== 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 j20si5654500pgh.224.2019.01.06.00.38.13; Sun, 06 Jan 2019 00:38:14 -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 S1726536AbfAFIiF (ORCPT + 31 others); Sun, 6 Jan 2019 03:38:05 -0500 Received: from mx2.suse.de ([195.135.220.15]:57194 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726477AbfAFIiE (ORCPT ); Sun, 6 Jan 2019 03:38:04 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 61094ACBC; Sun, 6 Jan 2019 08:38:03 +0000 (UTC) From: =?utf-8?q?Andreas_F=C3=A4rber?= To: linux-lpwan@lists.infradead.org Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, =?utf-8?q?Andrea?= =?utf-8?b?cyBGw6RyYmVy?= , Ben Whitten , "David S. Miller" Subject: [PATCH lora-next 03/11] net: lora: sx130x: Revert drop of sx1301_soft_reset() Date: Sun, 6 Jan 2019 09:37:46 +0100 Message-Id: <20190106083754.6004-4-afaerber@suse.de> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20190106083754.6004-1-afaerber@suse.de> References: <20190106083754.6004-1-afaerber@suse.de> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Ben's regmap field conversion patch silently dropped my sx1301_soft_reset() helper. Soft reset is a special operation, so restore this function as sx130x_soft_reset(). To be squashed. Cc: Ben Whitten Signed-off-by: Andreas Färber --- drivers/net/lora/sx130x.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) -- 2.16.4 diff --git a/drivers/net/lora/sx130x.c b/drivers/net/lora/sx130x.c index 21db0ddb101f..7a387d9a75a0 100644 --- a/drivers/net/lora/sx130x.c +++ b/drivers/net/lora/sx130x.c @@ -180,6 +180,11 @@ static int sx130x_field_write(struct sx130x_priv *priv, return regmap_field_write(priv->regmap_fields[field_id], val); } +static int sx130x_soft_reset(struct sx130x_priv *priv) +{ + return sx130x_field_write(priv, F_SOFT_RESET, 1); +} + static int sx130x_agc_ram_read(struct sx130x_priv *priv, u8 addr, unsigned int *val) { int ret; @@ -645,7 +650,7 @@ int sx130x_probe(struct device *dev) return ret; } - ret = sx130x_field_write(priv, F_SOFT_RESET, 1); + ret = sx130x_soft_reset(priv); if (ret) { dev_err(dev, "soft reset failed (%d)\n", ret); return ret;