Currently, there's a limit of MAX_PORTS ports (8 by default). This patchset
removes this limitation by using linked lists instead of fixed size arrays.

The core patches are 3/6 and 6/6, the rest are prerequisites: patch 1/6 is
moving per-port fields from struct clock to individual ports in order not to
have to maintain several linked lists, patch 2/6 moves the uds port from the
port array, as having it a part of linked list would make the various checks
for uds port unnecessary complicated, patch 5/6 replaces the port numbering
that is based on array of interface names by a per clock counter. The
remaining patch, 4/6, is a follow up optimization to 3/6.

Changes in v5: rebased. Addressed Richard's comments (comment in
clock_remove_port, calloc and cleanup of iface config).

Changes in v4: rebased on top of the current git.

Changes in v3: used the BSD implementation of LIST_FOREACH_SAFE, using the
system one where available.

Changes in v2: rebased on top of the current git, resolved warnings reported
by Richard.

Jiri Benc (6):
  Put fault_fd into struct port
  Make uds port a separate field in struct clock
  Dynamic port allocation
  Lazy regeneration of pollfd
  Remember last used port number
  Dynamic allocation of interface config entries

 clock.c  | 310 ++++++++++++++++++++++++++++++++++++++-------------------------
 clock.h  |  20 ++---
 config.c |  72 ++++++++-------
 config.h |  11 ++-
 port.c   |  89 ++++++++++++++----
 port.h   |  45 ++++++++++
 ptp4l.c  |  41 ++++-----
 7 files changed, 380 insertions(+), 208 deletions(-)

-- 
1.8.3.1


------------------------------------------------------------------------------
_______________________________________________
Linuxptp-devel mailing list
Linuxptp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel

Reply via email to