Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp5008709ybe; Mon, 9 Sep 2019 19:09:37 -0700 (PDT) X-Google-Smtp-Source: APXvYqyigQ/bWHKSrZJOzOhLLCnYXcWU+jvoVNoEFKhsRfduS7N6/dpbDrv7gE+OS13bA/NaSGpO X-Received: by 2002:a50:cc46:: with SMTP id n6mr2185797edi.7.1568081377470; Mon, 09 Sep 2019 19:09:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568081377; cv=none; d=google.com; s=arc-20160816; b=aTjxyGu3krc6+RnJO3dWpU9uuwkcXe50dW7pgjSMsCgI0Ow8vbjZSpNlofWiOj0p4r pPkwe0KiO6MQBTfJDbCyQN72loHNcZvzLzgTDAKiDnv6E6fErenMcJ0hh4s9n8CrtGd5 49Gd/sAAOAcvbrx/o/taMXfO4ORmaSpdk690lquaI0Ab5AFCHXghXxBFtuhiaq/AoiEO xsjOpLzPkuhtCPyP6UJ4JhH94AfKWkIOjHiQMHaQDBiEgpZM9bcM0/hIWt2pisP6xRiU EMo529Jn8U2QK57GhAW/TIBDdT8se766oBTiHGvPxRuaWBr/OP1ahA/noAU5iS4J5LbU i0uw== 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=s2943fT/7pSmYbGBT7ywpWTZ+Meu8Ue219cG3n+jT+o=; b=RlMu+2X+yMRkC3ioao/zRw6OZq1PEKD8jazjVi2MTOke5VE0GrsUXYBINc4BzDVsoN P2NzeX+ytn5+KEMiMRhDyln7k8BLD4lu4GPUfRb0wEHh2NxONC7NiEjsqnOuRHzn7PKH xzy8d6Q7yqGDv5GbHY6Z24CKxeH2eiuMiyEcJre7hi+N+T3h+Yr9inVuPzndt4UWw7wy A04seHUd2L0C14G9z8ox0Ss1ycNqA5QCfl+Nx6TSU0LBOzPRoNBAM5Y89uCx1+vobnm0 ESpATiZapfklGUsLNIHfo9pMqHI8f5f3llX5aykeYu1iqO/vOoigOiVCGHbAIe7fV7r7 hhFQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b42si9589490edb.11.2019.09.09.19.09.02; Mon, 09 Sep 2019 19:09:37 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388712AbfIIH7s (ORCPT + 99 others); Mon, 9 Sep 2019 03:59:48 -0400 Received: from mga03.intel.com ([134.134.136.65]:35724 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725999AbfIIH7q (ORCPT ); Mon, 9 Sep 2019 03:59:46 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Sep 2019 00:59:46 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,484,1559545200"; d="scan'208";a="335516815" Received: from pipin.fi.intel.com ([10.237.72.175]) by orsmga004.jf.intel.com with ESMTP; 09 Sep 2019 00:59:44 -0700 From: Felipe Balbi To: Richard Cochran Cc: Christopher S Hall , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Felipe Balbi Subject: [PATCH v3 2/2] PTP: add support for one-shot output Date: Mon, 9 Sep 2019 10:59:40 +0300 Message-Id: <20190909075940.12843-2-felipe.balbi@linux.intel.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20190909075940.12843-1-felipe.balbi@linux.intel.com> References: <20190909075940.12843-1-felipe.balbi@linux.intel.com> 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 Some controllers allow for a one-shot output pulse, in contrast to periodic output. Now that we have extensible versions of our IOCTLs, we can finally make use of the 'flags' field to pass a bit telling driver that if we want one-shot pulse output. Signed-off-by: Felipe Balbi --- Changes since v2: - Add _PEROUT_ to bit macro Changes since v1: - remove comment from .flags field include/uapi/linux/ptp_clock.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/uapi/linux/ptp_clock.h b/include/uapi/linux/ptp_clock.h index 12911785991b..cbdc0d97b471 100644 --- a/include/uapi/linux/ptp_clock.h +++ b/include/uapi/linux/ptp_clock.h @@ -38,8 +38,8 @@ /* * Bits of the ptp_perout_request.flags field: */ -#define PTP_PEROUT_VALID_FLAGS (~0) - +#define PTP_PEROUT_ONE_SHOT (1<<0) +#define PTP_PEROUT_VALID_FLAGS (~PTP_PEROUT_ONE_SHOT) /* * struct ptp_clock_time - represents a time value * @@ -77,7 +77,7 @@ struct ptp_perout_request { struct ptp_clock_time start; /* Absolute start time. */ struct ptp_clock_time period; /* Desired period, zero means disable. */ unsigned int index; /* Which channel to configure. */ - unsigned int flags; /* Reserved for future use. */ + unsigned int flags; unsigned int rsv[4]; /* Reserved for future use. */ }; -- 2.23.0