Commit Graph

25 Commits

Author SHA1 Message Date
Knud Baastrup ba27819221 Applied base-0024-Sdo-directory-now-only-fetched-on-request
Sdo directory now only fetched on request.

The time-consuming SDO directory fetch during slave scan can now be
skipped by setting the EC_SKIP_SDO_DICT in globals.h. The directory
will now instead be fethed the first time an ethercat sdos command
is executed with the ethercat tool.
2023-08-29 14:38:54 +02:00
Florian Pose b1945b7bdc Always define EoE handler count. 2023-07-20 13:11:10 +02:00
Florian Pose fa96b8fcb0 Merge branch 'lock-fixes' into 'master'
Various locking fixes and improvements

See merge request etherlab.org/ethercat!58
2022-09-05 09:41:16 +00:00
Esben Haabendal 81758004fd Improve synchronization of master->domains list
Introduce a new lock for synchronization of the master->domains list, and use
that instead of the big master_sem lock, improving real-time performance of
fx. ecrt_domain_process() when EoE thread is being shut down (or other
use-cases where master_sem is held for extended periods).

The following locking order is used:

* master->master_sem
* master->domains_lock
* master->io_sem
* domain->datagram_pairs_lock

Meaning that it is allowed to take domains_lock while holding master_sem, and
it is allowed to hold domains_lock while locking io_sem and
datagram_pairs_lock.

[RV: For now, the lockdep_assert_held() annotations are commented out,
since they don't compile with CONFIG_PROVE_LOCKING and (the default)
--disable-rtmutex.]
2022-09-01 15:38:01 +02:00
Esben Haabendal 2372382259 Acquire master->io_sem lock where needed
With this, we should have in place so that master->io_sem is always held when
accessing master->datagram_queue.

Note, the use of master->master_sem in ec_ioctl_send() and
ec_ioctl_receive() were wrong (introduced in commit cef602586c). The
only thing needing to be synchronized there is the access to
master->datagram_queue, which is protected by master->io_sem.

This corresponds roughly to the fixes for stable-1.5 that are seen in
https://gitlab.com/etherlab.org/ethercat/-/merge_requests/36 .
2022-09-01 15:37:54 +02:00
Rasmus Villemoes 624872fcdb fix direct uses of up()/down()
When converting to the ec_lock_t abstraction, these were missed,
making building with --enable-rtmutex broken.

Fixes: 9955855f7e (Applied 0016-If-enable-rtmutex-use-rtmutexes-instead-of-semaphore.patch)
2022-08-31 15:21:23 +02:00
Florian Pose 44c6c3d1da Merge branch 'master' of ../git 2022-06-23 11:55:13 +02:00
Florian Pose 429ba9356e Applied 0018-Use-call-back-functions.patch 2022-06-23 11:27:28 +02:00
Florian Pose cef602586c Applied 0017-Master-locks-to-avoid-corrupted-datagram-queue.patch 2022-06-23 11:26:20 +02:00
Florian Pose 9955855f7e Applied 0016-If-enable-rtmutex-use-rtmutexes-instead-of-semaphore.patch 2022-06-23 11:21:51 +02:00
Florian Pose 57342c99ca Applied 0011-Reduced-printing-to-avoid-syslog-spam.patch 2022-06-23 10:55:57 +02:00
Florian Pose 225af9f787 Applied 0008-read-reference-slave-clock-64bit-time.patch 2022-06-23 10:45:16 +02:00
Florian Pose 405c88f6d6 Applied 0005-disable-eoe.patch 2022-06-23 10:25:36 +02:00
Florian Pose b4f8c0e750 Added 0001-Distributed-Clock-fixes-and-helpers.patch 2022-06-23 10:07:34 +02:00
Shi Qiyao 29919ef8b7 Add support for FoE with password.
Patch originally from https://github.com/ribalda/ethercat which adds the
support for FoE command tool with password.
2022-04-19 11:54:16 +02:00
Florian Pose 2ee65b6387 Added feature flags to API. 2021-08-24 17:47:15 +02:00
Florian Pose fffbeb4ba5 Added ecrt_master_sync_reference_clock_to() method. 2021-08-24 16:56:23 +02:00
Florian Pose 9d733cb1a9 Renamed app_start_time to dc_ref_time; output via command-line tool. 2021-08-24 16:48:07 +02:00
Florian Pose ef9517e7c3 Improved buffer overflow messages. 2021-08-24 16:33:05 +02:00
Dave Page 45839e8666 16-ethercat-1.5-frame-corruption.patch
from ethercat-1.5.0-patches-v2.tar.bz2
by Frank Heckenbach f.heckenbach@ at fh-soft.de
Ref: http://lists.etherlab.org/pipermail/etherlab-dev/2014/000404.html
with some additional edits.
2015-04-14 16:25:44 -04:00
Gavin Lambert d9a93ffa24 Mark download data as const.
Remove redundant code.
[07-sdo-up-download]
2014-05-31 18:08:27 +12:00
Dave Page 7beb81207d Refactor fmmu->logical_start_address to fmmu->logical_domain_offset 2015-03-26 17:41:57 -04:00
Dave Page b8c5ff836d Integrate skeleton of allow_overlapping_pdos from af21f0bdc7c9
Overlapping PDO API added, but not active/working.
No more changes than required to build.
EC_IOCTL_VERSION_MAGIC now 30
2015-03-26 15:16:21 -04:00
Florian Pose a03d091ac0 Implemented EoE Set IP parameter request via command-line tool. 2014-11-12 14:42:17 +01:00
Florian Pose 99418519bd Reverted default branch to stable-1.5. 2014-11-03 15:20:05 +01:00