This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The annotated tag, v1.19.0.0_tigermoth has been created
at fea17c996d047d2f2d0c1de06d7d10613ab9763d (tag)
tagging e828b4d6f503ff94c40e30b1d8babf0dcbecde91 (commit)
replaces v1.18.0.1_tigermoth_rc3
tagged by Maxim Uvarov
on Thu Apr 19 18:01:15 2018 +0300
- Log -----------------------------------------------------------------
Tiger Moth LTS
Bill Fischofer (9):
doc: userguide: typo corrections
doc: userguide: change pool queue to plain queue
doc: userguide: shm corrections
doc: userguide: change sched type none to parallel
doc: userguide: refresh pktio code examples
doc: userguide: add packet checksum and parsing info
doc: userguide: add pktio capability and config info
example: l2fwd: update readme regarding ordered queue usage
changelog: updates for odp v1.19.0.0
Bogdan Pricope (3):
linux-gen: pktio: dpdk: accept UDPv4 packets with all-zero csum
linux-gen: pktio: dpdk: fix IPv4 csum calculation when l4 offset is not set
linux-gen: dpdk: fix runtime/default config read order
Dmitry Eremin-Solenikov (20):
performance: fix sched_latency test with huge cpu count
shippable: reenable non-ABI-compat build for GCC
test: misc: use C++ I/O instead of C
tests: add IPsec performance test
performance: ipsec: add AH measurements
performance: ipsec: add more algorithms
performance: crypto: add more algorithms
linux-gen: crypto: add IV length checks
linux-gen: ipsec: add proper support for AES-CCM
build: move odp scheduler setting to common m4 file
build: another DPDK-linking fix
build: don't use xxd to hexdump config file
build: fix autoconf error caused by double-registering config item
linux-gen: packet: IPv4 checksum insertion
linux-gen: packet: l4 checksum insertion support
linux-gen: pktio: loop: support IPv4/TCP/UDP checksum generation
validation: verify IPv4 and UDP checksum validation and generation
validation: ipsec: fix packet checksums
linux-gen: ipsec: implement outbound checksumming support
validation: ipsec: validate outbound checksumming support
Josep Puigdemont (8):
fdserver: handle interruption by signal in accept
linux-gen: shm: fill data used in do_map before the call
linux-gen: shm: do not close provided file descriptors
linux-gen: shm: be consistent with rest of the code
fdserver: change session ID after fork
linux-gen: fdserver: mask signals we don't need
linux-gen: shm: check return value when registering fds
fdserver: handle signal interruption in connect()
Juha-Matti Tilli (1):
linux-gen: netmap: ring configuration for VALE
Matias Elo (2):
linux-gen: dpdk: bump supported dpdk version to v17.11
linux-gen: dpdk: allocate huge page memory for all numa nodes
Maxim Uvarov (9):
shippable: simplify test execution
add odp_ipsec to .gitignore
linux-gen: clean up ishm file naming
linux-gen: hide debug prints from fd server
linux-gen: ishm: remove useless debug print
travis: use -M option for generated patches
linux-gen: fix clang on aarch64 build
shippable: reenable clang with disable abi compat options
configure.ac: update version to v1.19.0.0
Petri Savolainen (11):
linux-gen: queue: configurable default size
linux-gen: queue: configurable max size
linux-gen: sched: configurable priority spread
linux-gen: sched: decouple spread and group table sizes
linux-gen: sched: increase max spread
linux-gen: pktio: add error prints
linux-gen: pktio: add index to pktio print
test: sched_pktio: new scheduler performance test with pktio
test: sched_pktio: add option to collect statistics
test: sched_pktio: run in validation test suite
api: packet: UDP checksum value of zero
yhe (2):
linux-gen:crypto:implement AES-XCBC-MAC and SHA384-HMAC
validation:crypto:implement AES-XCBC-MAC and SHA384-HMAC
-----------------------------------------------------------------------
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, tigermoth_lts has been created
at e828b4d6f503ff94c40e30b1d8babf0dcbecde91 (commit)
- Log -----------------------------------------------------------------
-----------------------------------------------------------------------
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via e828b4d6f503ff94c40e30b1d8babf0dcbecde91 (commit)
from 1e0ac11c75eee10959d1fa674a05e746476271b3 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit e828b4d6f503ff94c40e30b1d8babf0dcbecde91
Author: Maxim Uvarov <maxim.uvarov(a)linaro.org>
Date: Wed Apr 18 17:50:47 2018 +0300
configure.ac: update version to v1.19.0.0
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
Reviewed-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov(a)linaro.org>
diff --git a/configure.ac b/configure.ac
index 904e8197..d3f02665 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3,9 +3,9 @@ AC_PREREQ([2.5])
# Set correct API version
##########################################################################
m4_define([odpapi_generation_version], [1])
-m4_define([odpapi_major_version], [18])
+m4_define([odpapi_major_version], [19])
m4_define([odpapi_minor_version], [0])
-m4_define([odpapi_point_version], [1])
+m4_define([odpapi_point_version], [0])
m4_define([odpapi_version],
[odpapi_generation_version.odpapi_major_version.odpapi_minor_version.odpapi_point_version])
AC_INIT([OpenDataPlane],[odpapi_version],[lng-odp(a)lists.linaro.org])
-----------------------------------------------------------------------
Summary of changes:
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The annotated tag, v1.19.0.0 has been created
at 200122ffa31e4cf5367edb528138d277a1f5da1e (tag)
tagging e828b4d6f503ff94c40e30b1d8babf0dcbecde91 (commit)
replaces v1.18.0.1_tigermoth_rc3
tagged by Maxim Uvarov
on Thu Apr 19 17:56:01 2018 +0300
- Log -----------------------------------------------------------------
== OpenDataPlane (1.19.0.0)
=== Summary of Changes
ODP v1.19.0.0 is the official Tiger Moth final release. It incorporates final
implementation changes and bug fixes and completes the Tiger Moth ODP
development cycle.
==== APIs
No functional changes for this release. The Tiger Moth API was frozen in ODP
v1.18.0.0.
===== API Documentation Update
The specification for the `odp_packet_l4_chksum_status()` API has been
clarified to reflect that in IPv4 UDP checksums are optional. As a result, a
zero (nonexistent) checksum will be reported as `ODP_PACKET_CHKSUM_OK`.
==== C++ Test Improvements
The {cpp} test included in the ODP validation suite now uses `cout` instead
of `printf()` to ensure that {cpp} is being used to compile it.
==== Queue and Scheduler Configuration
For the ODP Reference Implementation, The `config/odp-linux-generic.conf` file
is extended with sections to control the default and maximum sizes for basic
queues, and the priority spread used by the scheduler for scheduled queues.
The configuration file is a template named `platform/odp-$platform.conf` so
this can be easily inherited by other ODP implementations.
==== Runtime Default `config` File Read Order Improvements
For the ODP Reference Implementation, the default values of the
application-provided `config` file (if used) override the values provided by
the built-in `config/odp-linux-generic.conf` file.
=== Implementation Improvements
The `odp-linux` reference implementation is improved in a number of areas:
==== Netmap Ring Configuration for VALE
PktIO netmap support now uses the ODP config file to allow rings used for VALE
processing to be specified. The supplied defaults provide optimal performance
in typical settings.
==== AES-XCBC-MAC and SHA384-HMAC
These crypto/authentication algorithms are now implemented.
==== Packet Checksum Validation and Insertion
Proper packet checksum validation and insertion, in conformance with the
relevant ODP APIs, is now provided.
=== Dependency Changes
==== DPDK 17.11 Support
The Tiger Moth LTS release is synchronized with the most recent DPDK LTS
release for DPDK pktio support.
==== Removal of dependency on `xxd` package.
This dependency is removed. The Reference Implementation build tools now use
the standard `od` tool rather than the optional `xxd` package.
=== Performance Tests
==== `odp_sched_pktio`
A new test has been added to test the performance of PktIO operations in
scheduled mode. Scheduled PktIO is inherently more scalable and simpler from
an application standpoint than direct (polled) I/O, but depending on the
efficiency of the scheduler implementation can incur additional levels of
overhead. This test can give insight into a given platform's scheduler
efficiency. For the `odp-linux` reference implementation, this test has shown
scheduled I/O to be within 10% of rates achievable via direct I/O, meaning
that for many applications the simplicity and scalability of the event model
is preferable.
==== `odp_ipsec`
A new test has been added that measures outbound (TX) IPsec performance with
a variety of cipher and authentication algorithms.
=== Example Changes
==== `l2fwd` Example
The `README` file associated with this example has been clarified to explain
that this example is a throughput test and as a result does not preserve
packet order under all conditions.
=== Bug Fixes
==== https://bugs.linaro.org/show_bug.cgi?id=3611[Bug 3611]
ODP linux-generic fails on AArch64 in non-ABI-compat mode.
==== https://bugs.linaro.org/show_bug.cgi?id=3657[Bug 3657]
PktIO does not work with Mellanox Interfaces
==== https://bugs.linaro.org/show_bug.cgi?id=3685[Bug 3685]
RX UDP checksum offload drops valid UDP packets with Niantic
==== https://bugs.linaro.org/show_bug.cgi?id=3686[Bug 3686]
IP header checksum not inserted if L4 offset not set
==== https://bugs.linaro.org/show_bug.cgi?id=3690[Bug 3690]
fdserver process interferes with signal handling
==== https://bugs.linaro.org/show_bug.cgi?id=3736[Bug 3736]
return value not checked for some fdserver interface functions
=== Known Issues
==== https://bugs.linaro.org/show_bug.cgi?id=2988[Bug 2988]
ODP exposes symbols outside of odp*/_odp* namespace
Bill Fischofer (9):
doc: userguide: typo corrections
doc: userguide: change pool queue to plain queue
doc: userguide: shm corrections
doc: userguide: change sched type none to parallel
doc: userguide: refresh pktio code examples
doc: userguide: add packet checksum and parsing info
doc: userguide: add pktio capability and config info
example: l2fwd: update readme regarding ordered queue usage
changelog: updates for odp v1.19.0.0
Bogdan Pricope (3):
linux-gen: pktio: dpdk: accept UDPv4 packets with all-zero csum
linux-gen: pktio: dpdk: fix IPv4 csum calculation when l4 offset is not set
linux-gen: dpdk: fix runtime/default config read order
Dmitry Eremin-Solenikov (20):
performance: fix sched_latency test with huge cpu count
shippable: reenable non-ABI-compat build for GCC
test: misc: use C++ I/O instead of C
tests: add IPsec performance test
performance: ipsec: add AH measurements
performance: ipsec: add more algorithms
performance: crypto: add more algorithms
linux-gen: crypto: add IV length checks
linux-gen: ipsec: add proper support for AES-CCM
build: move odp scheduler setting to common m4 file
build: another DPDK-linking fix
build: don't use xxd to hexdump config file
build: fix autoconf error caused by double-registering config item
linux-gen: packet: IPv4 checksum insertion
linux-gen: packet: l4 checksum insertion support
linux-gen: pktio: loop: support IPv4/TCP/UDP checksum generation
validation: verify IPv4 and UDP checksum validation and generation
validation: ipsec: fix packet checksums
linux-gen: ipsec: implement outbound checksumming support
validation: ipsec: validate outbound checksumming support
Josep Puigdemont (8):
fdserver: handle interruption by signal in accept
linux-gen: shm: fill data used in do_map before the call
linux-gen: shm: do not close provided file descriptors
linux-gen: shm: be consistent with rest of the code
fdserver: change session ID after fork
linux-gen: fdserver: mask signals we don't need
linux-gen: shm: check return value when registering fds
fdserver: handle signal interruption in connect()
Juha-Matti Tilli (1):
linux-gen: netmap: ring configuration for VALE
Matias Elo (2):
linux-gen: dpdk: bump supported dpdk version to v17.11
linux-gen: dpdk: allocate huge page memory for all numa nodes
Maxim Uvarov (9):
shippable: simplify test execution
add odp_ipsec to .gitignore
linux-gen: clean up ishm file naming
linux-gen: hide debug prints from fd server
linux-gen: ishm: remove useless debug print
travis: use -M option for generated patches
linux-gen: fix clang on aarch64 build
shippable: reenable clang with disable abi compat options
configure.ac: update version to v1.19.0.0
Petri Savolainen (11):
linux-gen: queue: configurable default size
linux-gen: queue: configurable max size
linux-gen: sched: configurable priority spread
linux-gen: sched: decouple spread and group table sizes
linux-gen: sched: increase max spread
linux-gen: pktio: add error prints
linux-gen: pktio: add index to pktio print
test: sched_pktio: new scheduler performance test with pktio
test: sched_pktio: add option to collect statistics
test: sched_pktio: run in validation test suite
api: packet: UDP checksum value of zero
yhe (2):
linux-gen:crypto:implement AES-XCBC-MAC and SHA384-HMAC
validation:crypto:implement AES-XCBC-MAC and SHA384-HMAC
-----------------------------------------------------------------------
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 1e0ac11c75eee10959d1fa674a05e746476271b3 (commit)
from 8caae505c35444706cff8815c41821d80e791403 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 1e0ac11c75eee10959d1fa674a05e746476271b3
Author: Bill Fischofer <bill.fischofer(a)linaro.org>
Date: Sun Apr 8 20:30:18 2018 -0500
changelog: updates for odp v1.19.0.0
Add updates for ODP v1.19.0.0 (Tiger Moth Final Release)
Signed-off-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Reviewed-by: Bogdan Pricope <bogdan.pricope(a)linaro.org>
Reviewed-by: Dmitry Eremin-Solenikov <dmitry.ereminsolenikov(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/CHANGELOG b/CHANGELOG
index 1dfdd0e7..5af1777c 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,3 +1,108 @@
+== OpenDataPlane (1.19.0.0)
+=== Summary of Changes
+ODP v1.19.0.0 is the official Tiger Moth final release. It incorporates final
+implementation changes and bug fixes and completes the Tiger Moth ODP
+development cycle.
+
+==== APIs
+No functional changes for this release. The Tiger Moth API was frozen in ODP
+v1.18.0.0.
+
+===== API Documentation Update
+The specification for the `odp_packet_l4_chksum_status()` API has been
+clarified to reflect that in IPv4 UDP checksums are optional. As a result, a
+zero (nonexistent) checksum will be reported as `ODP_PACKET_CHKSUM_OK`.
+
+==== C++ Test Improvements
+The {cpp} test included in the ODP validation suite now uses `cout` instead
+of `printf()` to ensure that {cpp} is being used to compile it.
+
+==== Queue and Scheduler Configuration
+For the ODP Reference Implementation, The `config/odp-linux-generic.conf` file
+is extended with sections to control the default and maximum sizes for basic
+queues, and the priority spread used by the scheduler for scheduled queues.
+
+The configuration file is a template named `platform/odp-$platform.conf` so
+this can be easily inherited by other ODP implementations.
+
+==== Runtime Default `config` File Read Order Improvements
+For the ODP Reference Implementation, the default values of the
+application-provided `config` file (if used) override the values provided by
+the built-in `config/odp-linux-generic.conf` file.
+
+=== Implementation Improvements
+The `odp-linux` reference implementation is improved in a number of areas:
+
+==== Netmap Ring Configuration for VALE
+PktIO netmap support now uses the ODP config file to allow rings used for VALE
+processing to be specified. The supplied defaults provide optimal performance
+in typical settings.
+
+==== AES-XCBC-MAC and SHA384-HMAC
+These crypto/authentication algorithms are now implemented.
+
+==== Packet Checksum Validation and Insertion
+Proper packet checksum validation and insertion, in conformance with the
+relevant ODP APIs, is now provided.
+
+=== Dependency Changes
+
+==== DPDK 17.11 Support
+The Tiger Moth LTS release is synchronized with the most recent DPDK LTS
+release for DPDK pktio support.
+
+==== Removal of dependency on `xxd` package.
+This dependency is removed. The Reference Implementation build tools now use
+the standard `od` tool rather than the optional `xxd` package.
+
+=== Performance Tests
+
+==== `odp_sched_pktio`
+A new test has been added to test the performance of PktIO operations in
+scheduled mode. Scheduled PktIO is inherently more scalable and simpler from
+an application standpoint than direct (polled) I/O, but depending on the
+efficiency of the scheduler implementation can incur additional levels of
+overhead. This test can give insight into a given platform's scheduler
+efficiency. For the `odp-linux` reference implementation, this test has shown
+scheduled I/O to be within 10% of rates achievable via direct I/O, meaning
+that for many applications the simplicity and scalability of the event model
+is preferable.
+
+==== `odp_ipsec`
+A new test has been added that measures outbound (TX) IPsec performance with
+a variety of cipher and authentication algorithms.
+
+=== Example Changes
+
+==== `l2fwd` Example
+The `README` file associated with this example has been clarified to explain
+that this example is a throughput test and as a result does not preserve
+packet order under all conditions.
+
+=== Bug Fixes
+==== https://bugs.linaro.org/show_bug.cgi?id=3611[Bug 3611]
+ODP linux-generic fails on AArch64 in non-ABI-compat mode.
+
+==== https://bugs.linaro.org/show_bug.cgi?id=3657[Bug 3657]
+PktIO does not work with Mellanox Interfaces
+
+==== https://bugs.linaro.org/show_bug.cgi?id=3685[Bug 3685]
+RX UDP checksum offload drops valid UDP packets with Niantic
+
+==== https://bugs.linaro.org/show_bug.cgi?id=3686[Bug 3686]
+IP header checksum not inserted if L4 offset not set
+
+==== https://bugs.linaro.org/show_bug.cgi?id=3690[Bug 3690]
+fdserver process interferes with signal handling
+
+==== https://bugs.linaro.org/show_bug.cgi?id=3736[Bug 3736]
+return value not checked for some fdserver interface functions
+
+=== Known Issues
+
+==== https://bugs.linaro.org/show_bug.cgi?id=2988[Bug 2988]
+ODP exposes symbols outside of odp*/_odp* namespace
+
== OpenDataPlane (1.18.0.1)
=== Summary of Changes
ODP v1.18.0.1 is a fix level for Tiger Moth Release Candidate 2 (RC 2).
-----------------------------------------------------------------------
Summary of changes:
CHANGELOG | 105 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 105 insertions(+)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 88ba35773c76c871a222fe48a0dac05765c39936 (commit)
from 2e96afe0b7c4e7e41fb03bcda605ab704f538ca1 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 88ba35773c76c871a222fe48a0dac05765c39936
Author: Josep Puigdemont <josep.puigdemont(a)linaro.org>
Date: Wed Apr 11 14:40:53 2018 +0200
fdserver: handle signal interruption in connect()
Signed-off-by: Josep Puigdemont <josep.puigdemont(a)linaro.org>
Reviewed-by: Janne Peltonen <janne.peltonen(a)nokia.com>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/odp_fdserver.c b/platform/linux-generic/odp_fdserver.c
index c88c71cd..0e9fb0e4 100644
--- a/platform/linux-generic/odp_fdserver.c
+++ b/platform/linux-generic/odp_fdserver.c
@@ -265,7 +265,9 @@ static int get_socket(void)
remote.sun_family = AF_UNIX;
strcpy(remote.sun_path, sockpath);
len = strlen(remote.sun_path) + sizeof(remote.sun_family);
- if (connect(s_sock, (struct sockaddr *)&remote, len) == -1) {
+ while (connect(s_sock, (struct sockaddr *)&remote, len) == -1) {
+ if (errno == EINTR)
+ continue;
ODP_ERR("cannot connect to server: %s\n", strerror(errno));
close(s_sock);
return -1;
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/odp_fdserver.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 2e96afe0b7c4e7e41fb03bcda605ab704f538ca1 (commit)
from 52ea8d51d522d7013f746748bf84bfc2e9bc042c (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 2e96afe0b7c4e7e41fb03bcda605ab704f538ca1
Author: Josep Puigdemont <josep.puigdemont(a)linaro.org>
Date: Fri Apr 13 13:50:21 2018 +0200
linux-gen: shm: check return value when registering fds
fdserver functions such as that for registering a new fd may
fail. In this case we need to check the return value and do
a cleanup of any allocated blocks and fragments.
If it fails on deregistering, just return the error code.
Signed-off-by: Josep Puigdemont <josep.puigdemont(a)linaro.org>
Reviewed-by: Bill Fischofer <bill.fischofer(a)linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/odp_ishm.c b/platform/linux-generic/odp_ishm.c
index a1a90424..babf51b9 100644
--- a/platform/linux-generic/odp_ishm.c
+++ b/platform/linux-generic/odp_ishm.c
@@ -767,6 +767,65 @@ static void procsync(void)
ishm_proctable->nb_entries = last;
}
+/*
+ * Free a block as described in block_free(), but
+ * considering whether to close the file descriptor or not, and
+ * whether to deregister from the fdserver.
+ */
+static int block_free_internal(int block_index, int close_fd, int deregister)
+{
+ int proc_index;
+ ishm_block_t *block; /* entry in the main block table*/
+ int last;
+ int ret = 0;
+
+ if ((block_index < 0) ||
+ (block_index >= ISHM_MAX_NB_BLOCKS) ||
+ (ishm_tbl->block[block_index].len == 0)) {
+ ODP_ERR("Request to free an invalid block\n");
+ return -1;
+ }
+
+ block = &ishm_tbl->block[block_index];
+
+ proc_index = procfind_block(block_index);
+ if (proc_index >= 0) {
+ /* remove the mapping and possible fragment */
+ do_unmap(ishm_proctable->entry[proc_index].start,
+ block->len,
+ ishm_proctable->entry[proc_index].flags,
+ block_index);
+
+ /* close the related fd */
+ if (close_fd)
+ close(ishm_proctable->entry[proc_index].fd);
+
+ /* remove entry from process local table: */
+ last = ishm_proctable->nb_entries - 1;
+ ishm_proctable->entry[proc_index] = ishm_proctable->entry[last];
+ ishm_proctable->nb_entries = last;
+ } else {
+ /* just possibly free the fragment as no mapping exist here: */
+ do_unmap(NULL, 0, block->flags, block_index);
+ }
+
+ /* remove all files related to this block: */
+ if (close_fd)
+ delete_file(block);
+
+ /* deregister the file descriptor from the file descriptor server. */
+ if (deregister)
+ ret = _odp_fdserver_deregister_fd(FD_SRV_CTX_ISHM, block_index);
+
+ /* mark the block as free in the main block table: */
+ block->len = 0;
+
+ /* mark the change so other processes see this entry as obsolete: */
+ block->seq++;
+
+ return ret;
+}
+
/*
* Allocate and map internal shared memory, or other objects:
* If a name is given, check that this name is not already in use.
@@ -928,7 +987,10 @@ int _odp_ishm_reserve(const char *name, uint64_t size, int fd,
ishm_proctable->entry[new_proc_entry].fd = fd;
/* register the file descriptor to the file descriptor server. */
- _odp_fdserver_register_fd(FD_SRV_CTX_ISHM, new_index, fd);
+ if (_odp_fdserver_register_fd(FD_SRV_CTX_ISHM, new_index, fd) == -1) {
+ block_free_internal(new_index, !new_block->external_fd, 0);
+ new_index = -1;
+ }
odp_spinlock_unlock(&ishm_tbl->lock);
return new_index;
@@ -1034,53 +1096,7 @@ error_exp_file:
*/
static int block_free(int block_index)
{
- int proc_index;
- ishm_block_t *block; /* entry in the main block table*/
- int last;
-
- if ((block_index < 0) ||
- (block_index >= ISHM_MAX_NB_BLOCKS) ||
- (ishm_tbl->block[block_index].len == 0)) {
- ODP_ERR("Request to free an invalid block\n");
- return -1;
- }
-
- block = &ishm_tbl->block[block_index];
-
- proc_index = procfind_block(block_index);
- if (proc_index >= 0) {
- /* close the related fd */
- close(ishm_proctable->entry[proc_index].fd);
-
- /* remove the mapping and possible fragment */
- do_unmap(ishm_proctable->entry[proc_index].start,
- block->len,
- ishm_proctable->entry[proc_index].flags,
- block_index);
-
- /* remove entry from process local table: */
- last = ishm_proctable->nb_entries - 1;
- ishm_proctable->entry[proc_index] =
- ishm_proctable->entry[last];
- ishm_proctable->nb_entries = last;
- } else {
- /* just possibly free the fragment as no mapping exist here: */
- do_unmap(NULL, 0, block->flags, block_index);
- }
-
- /* remove all files related to this block: */
- delete_file(block);
-
- /* deregister the file descriptor from the file descriptor server. */
- _odp_fdserver_deregister_fd(FD_SRV_CTX_ISHM, block_index);
-
- /* mark the block as free in the main block table: */
- block->len = 0;
-
- /* mark the change so other processes see this entry as obsolete: */
- block->seq++;
-
- return 0;
+ return block_free_internal(block_index, 1, 1);
}
/*
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/odp_ishm.c | 112 ++++++++++++++++++++++----------------
1 file changed, 64 insertions(+), 48 deletions(-)
hooks/post-receive
--
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "".
The branch, master has been updated
via 52ea8d51d522d7013f746748bf84bfc2e9bc042c (commit)
from b7ee13d765e5d8da1ef68f0c0777cb5e40fffbf7 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 52ea8d51d522d7013f746748bf84bfc2e9bc042c
Author: Josep Puigdemont <josep.puigdemont(a)linaro.org>
Date: Wed Apr 11 10:35:22 2018 +0200
linux-gen: fdserver: mask signals we don't need
Make fdserver block all signals except those we are interested in, or
those that can't be masked, and set default handlers for those left,
thus preventing fdserver from executing any signal handlers that the
application may have installed prior to forking this process.
Signed-off-by: Josep Puigdemont <josep.puigdemont(a)linaro.org>
Reviewed-by: Janne Peltonen <janne.peltonen(a)nokia.com>
Signed-off-by: Maxim Uvarov <maxim.uvarov(a)linaro.org>
diff --git a/platform/linux-generic/odp_fdserver.c b/platform/linux-generic/odp_fdserver.c
index 9562ea0c..c88c71cd 100644
--- a/platform/linux-generic/odp_fdserver.c
+++ b/platform/linux-generic/odp_fdserver.c
@@ -647,6 +647,34 @@ int _odp_fdserver_init_global(void)
}
if (server_pid == 0) { /*child */
+ sigset_t sigset;
+ struct sigaction action;
+
+ sigfillset(&sigset);
+ /* undefined if these are ignored, as per POSIX */
+ sigdelset(&sigset, SIGFPE);
+ sigdelset(&sigset, SIGILL);
+ sigdelset(&sigset, SIGSEGV);
+ /* can not be masked */
+ sigdelset(&sigset, SIGKILL);
+ sigdelset(&sigset, SIGSTOP);
+ /* these we want to handle */
+ sigdelset(&sigset, SIGTERM);
+ if (sigprocmask(SIG_SETMASK, &sigset, NULL) == -1) {
+ ODP_ERR("Could not set signal mask");
+ exit(1);
+ }
+
+ /* set default handlers for those signals we can handle */
+ memset(&action, 0, sizeof(action));
+ action.sa_handler = SIG_DFL;
+ sigemptyset(&action.sa_mask);
+ action.sa_flags = 0;
+ sigaction(SIGFPE, &action, NULL);
+ sigaction(SIGILL, &action, NULL);
+ sigaction(SIGSEGV, &action, NULL);
+ sigaction(SIGTERM, &action, NULL);
+
/* TODO: pin the server on appropriate service cpu mask */
/* when (if) we can agree on the usage of service mask */
-----------------------------------------------------------------------
Summary of changes:
platform/linux-generic/odp_fdserver.c | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
hooks/post-receive
--