Skip to content

Commit 823eb2a

Browse files
Felipe Balbidavem330
authored andcommitted
PTP: add support for one-shot output
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 <[email protected]> Reviewed-by: Richard Cochran <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 4156065 commit 823eb2a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

include/uapi/linux/ptp_clock.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@
3838
/*
3939
* Bits of the ptp_perout_request.flags field:
4040
*/
41-
#define PTP_PEROUT_VALID_FLAGS (0)
42-
41+
#define PTP_PEROUT_ONE_SHOT (1<<0)
42+
#define PTP_PEROUT_VALID_FLAGS (PTP_PEROUT_ONE_SHOT)
4343
/*
4444
* struct ptp_clock_time - represents a time value
4545
*
@@ -77,7 +77,7 @@ struct ptp_perout_request {
7777
struct ptp_clock_time start; /* Absolute start time. */
7878
struct ptp_clock_time period; /* Desired period, zero means disable. */
7979
unsigned int index; /* Which channel to configure. */
80-
unsigned int flags; /* Reserved for future use. */
80+
unsigned int flags;
8181
unsigned int rsv[4]; /* Reserved for future use. */
8282
};
8383

0 commit comments

Comments
 (0)