Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp9604197imu; Sun, 30 Dec 2018 00:37:36 -0800 (PST) X-Google-Smtp-Source: ALg8bN5n0hOm3gTj6+6EXjWCFtCvj4DDxXL/RbdYHX1BmTvD1uWGjMPldo4dhpohIzjTiUDmJSDg X-Received: by 2002:a63:4b25:: with SMTP id y37mr4051016pga.181.1546159056631; Sun, 30 Dec 2018 00:37:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546159056; cv=none; d=google.com; s=arc-20160816; b=wX1bd8Jnw+bMh6l5ZZexlUTs/vF3XNz/aRzeKINQx/8w9HFMddEHgioyHkuzRxltWL VHw9Ebt4y2Tk4EzDC9WsBOs7Kk1o9uCQg1JdoRsbObEHkbde2kq/kSpaGYR/ml9b8VyA ezXrd0cixPBgq/8W6DZ0da6ipoBO6r4vss7xxvBKWjavKrqlX+GNobpKdItyM03LPpT8 /i5fCKdomuoELn1mb/EZVrVld+IA/R77DlzFyFUbOsGeS0RWSXIcGMMRMB7NTegp6L4g pmGLxUmwkdDPhhjXaKA804QKFbFD97YbSIaAxBhJAnNJsJeb2WBoDx28jXMck+SrnRxo tYbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=ckjLWp0IHusbeNkYi8J13JE7Kr7Fv3QM+CEDRa+iwIQ=; b=L0nVSOu1Ypksf+TG76DbiDHeBIZN1ZI2mt1RuZmx08TLfLKDlgXDILtdmSbKLeV0no Iy7GIz7QangwMgePVXbo4c8GOdFSr6PVhZHV/MlZqYxZ2UIuFMyhHDcHpHbEU2UOyzXE pMXzJikimoi50oBBPru8lb7rbKIW8R7P8MoQGQcWrVffSx5WctY31Kh7kJSRghSp0UO7 FiumwtMyhXCynAp/oRs5lD0VhAnweg3d7ReR4MKLSTQpr2ztSuazlUWbdC455IMlOtTF wnQp72e+L8Kor6zKHiqqFyu5va5JrvRQNG17q5OJglhEb4TE5w2KXMpBl4VzLt4IYbGe SXcw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@aussec.com header.s=2016 header.b=sDw3GBGJ; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=aussec.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j5si23240440pgq.82.2018.12.30.00.36.59; Sun, 30 Dec 2018 00:37:36 -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; dkim=fail header.i=@aussec.com header.s=2016 header.b=sDw3GBGJ; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=aussec.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726099AbeL3IfH (ORCPT + 99 others); Sun, 30 Dec 2018 03:35:07 -0500 Received: from csm1.csm-office.com.au ([165.228.118.109]:57152 "EHLO sleepy.aussec.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726035AbeL3IfG (ORCPT ); Sun, 30 Dec 2018 03:35:06 -0500 X-Virus-Scanned: amavisd-new at aussec.com Received: from localhost.localdomain ([1.132.227.105]) (authenticated bits=0) by sleepy.aussec.com (8.15.2/8.15.2) with ESMTPSA id wBU8YAfs019893 (version=TLSv1.2 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Sun, 30 Dec 2018 19:34:30 +1100 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=aussec.com; s=2016; t=1546158873; bh=9caEbVgCEdXIcZVbFMDmJKdeGOGZGJEvsco074Bxuf4=; h=From:To:Cc:Subject:Date; b=sDw3GBGJK4luEIDltBcZSQ4WUmE+POurwAIs24gmdowSAJVF9zCA8iGa5snpFBhcf /qVRHBnbSOfbdNINRwsmbrnQZ2zzVehxirBwuKYvzN9FeB5/Y8fkNs0ZBrQAh7TY9g R02GytAXw5w69Eqvm/mJW+e4rczS6TkbMjt5Y37YG/1GuMd5GLr+xCL5zOxwsQo5gs 1trrUgYda/jSQANoxZAtqCT9J+6jLlaKgbXfM8U9dVwpRRqFhR5+/72bJOJnGwqhsF 9wlkDH/6FjQXtVi3B3aKMLZjLb5G88xudiMV5i0eYRSg8mcgLyE6KmViH0t7lE5WDT hmVje6+c120VA== From: Tom Burkart To: Linux kernel mailing list Cc: Tom Burkart , Rodolfo Giometti , Ricardo Martins , James Nuss Subject: [PATCH v14 0/3] PPS: pps-gpio PPS ECHO implementation Date: Sun, 30 Dec 2018 19:33:30 +1100 Message-Id: <20181230083333.27210-1-tom@aussec.com> X-Mailer: git-send-email 2.12.3 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi all, please find attached the PPS-GPIO PPS ECHO implementation patch. The driver claims to have echo functionality in the sysfs interface but this functionality is not present. This patch provides this functionality. Part 1 of the patch change the original driver from the number based GPIO API to the descriptor based API. Parts 2 and 3 then add the PPS ECHO functionality. This is enabled if a "echo-gpios" entry is found in the devicetree. Changes in v10: Changes requested by Philipp Zabel: Mostly cosmetic changes: PATCH 2/4 now reviewed. Thanks a lot, Philipp! (Please note that as of v11 PATCH 1 is gone so this has become PATCH 1/3) Change in v11: Change requested by Rob Herring: All changes in regard to the capture-clear DT entry are gone. Change in v12: Change requested by Rob Herring: Deleted superfluous use of invert-pps-echo Change in v13: Patch 2/3 (DT bindings) now reviewed. Thanks a lot, Rob! Changes in v14: Simplify code enabling PPS ECHO functionality. On the linuxpps mailing list it was suggested to use a hrtimer for resetting the GPIO ECHO active state to the inactive state. Please also comment on whether a hrtimer is necessary/desirable for the purpose of resetting the echo pin active state. I am happy to implement it if this is useful/desirable. Please install, test and comment as it is now a quite major change to the driver. Suggestions for improvement are welcome. Tom Burkart Tom Burkart (3): pps: descriptor-based gpio dt-bindings: pps: pps-gpio PPS ECHO implementation pps: pps-gpio pps-echo implementation Documentation/devicetree/bindings/pps/pps-gpio.txt | 7 + drivers/pps/clients/pps-gpio.c | 154 ++++++++++++++++----- include/linux/pps-gpio.h | 5 +- 3 files changed, 126 insertions(+), 40 deletions(-) -- 2.12.3