From patchwork Tue Jan 15 07:52:59 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 155634 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp4588080jaa; Mon, 14 Jan 2019 23:53:49 -0800 (PST) X-Google-Smtp-Source: ALg8bN7k+gfjr6sNcjAvk22hL6Rc9ixqwSVh5ftYzCexzsrh+2LrcB11Xot4YZ55GoXSlepG6hl/ X-Received: by 2002:a17:902:5601:: with SMTP id h1mr2826375pli.160.1547538829073; Mon, 14 Jan 2019 23:53:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547538829; cv=none; d=google.com; s=arc-20160816; b=tAtMtV9XNIT+OLza/ewB6CsNQnfzh7ubaYp+gyuzTPKHnEX4Naxfqq9P8xhJiGW/2d PbdYasIc1ofkNaDoWOytsumrRJu0uIkKQk1C3QYTl2GdroFd+dhxIX8R4i233SaSO1K7 mLgay13cSbAjHNhtyEP7Qvhjee82gvKQPPMkEaAe9S0WS3/bqDkgHJGrchNcddA66fKE vxZ4SvYKMeu7Ll6W8cqSVnUpKASrza9dKnZpRckjrpI6yK8CPyaBMMRZ3rT77M9TNp3q KbKBrmnZwSn8DIcD0whEc5GOS4hNTbO/15RvD+7XdBAN9/PPIWsSmmxPryK9DLTuG8Xy lvOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=AEvLBlZn/8mftg4VajuyVnyyVBSF5IJc0mJx1Fn5t0c=; b=Q0dGaN7MduWzKdDjhGJMH2ICAGNhWEUPzuotcPMggWGRTQEhlK/lhSdgCPYljpNYwT 5XcfDsmkk63v0ZcY8C1yXQqMalfnuGCgVVjt7+oCDPHV7cknYfqALkKGTOx2QnsRMgDs z1g8QkEHHdE/mxegrsNmwubeP1rlfEgY25iZFDfbjmCWGF/Ldj0yXlLq75LlsikXa3vx RxT1ce/e/poSbnIiDy/2BHPfx9B16DxiGARIFtlMvUP6PB6NUYxWtoZjnPIlanxVrCP3 Id2A9jal1jqOVWfRPiFnOb5SkAdRfpXEi8Qtp7lA7c+dKq0dQ2zvnRGVCwRFJ+xFxLPF bziQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PWGTla8x; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k135si2599888pgc.574.2019.01.14.23.53.48; Mon, 14 Jan 2019 23:53:49 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PWGTla8x; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728295AbfAOHxm (ORCPT + 5 others); Tue, 15 Jan 2019 02:53:42 -0500 Received: from mail-pl1-f196.google.com ([209.85.214.196]:37071 "EHLO mail-pl1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728286AbfAOHxm (ORCPT ); Tue, 15 Jan 2019 02:53:42 -0500 Received: by mail-pl1-f196.google.com with SMTP id b5so910507plr.4 for ; Mon, 14 Jan 2019 23:53:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=AEvLBlZn/8mftg4VajuyVnyyVBSF5IJc0mJx1Fn5t0c=; b=PWGTla8xPXHZJhFLEVc9niJ+2Y0vhunlWfEtSRRf0qSvZsrk4vGOPKU8et9lXEm1LK vJFGBEiho6XLF6aBtpR8XyRge9bNVDVbgzWimmGMJpgxnux8wngnmuDXqcLuDqaXywRt Ny4WtHmxE4ET3qp3wtpSFInOLiAhM8uXDQ1O0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=AEvLBlZn/8mftg4VajuyVnyyVBSF5IJc0mJx1Fn5t0c=; b=YBdO6Nofx4sJozCoz9TzLuLWyQ5RceJKqPmuvmeanGSgQj/6WnZQk7Sd2v/2RacVtm vqAmy5WdO3C8zP5nCc7j0qeGBHBx0etY1kWIbO6TuulboDKANlR2AiUCVHtzpT9uHoFA 25tQqJ/I2l4p5UKn+a4s16tPiW2irP8M2+CYgG5pRfG36Q6tHHTQqn/T2fzxxAuhc+TX MKSD39a2Ot7pCGVjdxa917xukb/WVra4ybKZ+6/h7C1jSUWOClHjcb4ENcJRW/WZr1Qu K6VKQ6gj6FBopEYhgKSdopSy9v2tdF02rXFPxmXY1pW1N60iqfxv0CDGv5hi0SbUZ2qi ZLAw== X-Gm-Message-State: AJcUukdY/EOhuiHEsBk59VTj/DwFa8PBLpzfp+j7Wio+BSQ3tVzofWru fI6Bcyi3BKoJNtl6oPrKTtPiew== X-Received: by 2002:a17:902:2006:: with SMTP id n6mr2812113pla.66.1547538821635; Mon, 14 Jan 2019 23:53:41 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id g3sm4340093pfe.37.2019.01.14.23.53.38 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 14 Jan 2019 23:53:40 -0800 (PST) From: Baolin Wang To: linus.walleij@linaro.org, bgolaszewski@baylibre.com, orsonzhai@gmail.com, zhang.lyra@gmail.com Cc: baolin.wang@linaro.org, neo.hou@unisoc.com, broonie@kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/2] gpio: sprd: Fix incorrect irq type setting for the async EIC Date: Tue, 15 Jan 2019 15:52:59 +0800 Message-Id: <3dd0a29b2f42d41ddfa5b30b68926eb58ebfc3a9.1547538574.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <732ea4f8ff1bf3ad28bda543ae8e1727c78f8b3b.1547538574.git.baolin.wang@linaro.org> References: <732ea4f8ff1bf3ad28bda543ae8e1727c78f8b3b.1547538574.git.baolin.wang@linaro.org> In-Reply-To: <732ea4f8ff1bf3ad28bda543ae8e1727c78f8b3b.1547538574.git.baolin.wang@linaro.org> References: <732ea4f8ff1bf3ad28bda543ae8e1727c78f8b3b.1547538574.git.baolin.wang@linaro.org> Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org From: Neo Hou When setting async EIC as IRQ_TYPE_EDGE_BOTH type, we missed to set the SPRD_EIC_ASYNC_INTMODE register to 0, which means detecting edge signals. Thus this patch fixes the issue. Signed-off-by: Neo Hou Signed-off-by: Baolin Wang --- drivers/gpio/gpio-eic-sprd.c | 1 + 1 file changed, 1 insertion(+) -- 1.7.9.5 diff --git a/drivers/gpio/gpio-eic-sprd.c b/drivers/gpio/gpio-eic-sprd.c index 257df59..e41223c 100644 --- a/drivers/gpio/gpio-eic-sprd.c +++ b/drivers/gpio/gpio-eic-sprd.c @@ -379,6 +379,7 @@ static int sprd_eic_irq_set_type(struct irq_data *data, unsigned int flow_type) irq_set_handler_locked(data, handle_edge_irq); break; case IRQ_TYPE_EDGE_BOTH: + sprd_eic_update(chip, offset, SPRD_EIC_ASYNC_INTMODE, 0); sprd_eic_update(chip, offset, SPRD_EIC_ASYNC_INTBOTH, 1); irq_set_handler_locked(data, handle_edge_irq); break;