summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-extended
diff options
context:
space:
mode:
authorwangmy <wangmy@fujitsu.com>2022-01-19 09:42:34 +0800
committerKhem Raj <raj.khem@gmail.com>2022-01-19 09:01:04 -0800
commite3929a60d65b6cddc5ef3b5c5f17036c4bfe33c8 (patch)
treec488de1a06e985226a75c50fe92ebded7b52acc7 /meta-oe/recipes-extended
parent3ec0b14aa4547d5c844114d0f5a39272d0e0dd1a (diff)
downloadmeta-openembedded-e3929a60d65b6cddc5ef3b5c5f17036c4bfe33c8.tar.gz
libmodbus: upgrade 3.1.6 -> 3.1.7
Fix-typo.patch f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d.patch removed since they're included in 3.1.7 Changelog: ========= modbus_reply: fix copy & paste error in sanity check Add SECURITY.md Fix typo in comment Replace obsolete AC_PROG_CC_STDC by AC_PROG_CC Fix position of CC flags in documentation Remove duplicate ';' Add the baud rate of 256k for Windows cosmetic changes in man page standardizing itemization Fix many typos Replace .dir-locals.el (Emacs) by .editorconfig Include the test LICENSE in tarball Install the NEWS and AUTHORS files Update README.md docs: fix simple typo, reponse -> response Add modbus_[get|set]_indication_timeout to doc build Fix warning issues Move malloc before starting unit tests Fixed MODBUS_GET_* macros in case of negative values SPDX: change LGPL-2.1+ to LGPL-2.1-or-later Signed-off-by: Wang Mingyu <wangmy@fujitsu.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe/recipes-extended')
-rw-r--r--meta-oe/recipes-extended/libmodbus/libmodbus/Fix-typo.patch52
-rw-r--r--meta-oe/recipes-extended/libmodbus/libmodbus/f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d.patch32
-rw-r--r--meta-oe/recipes-extended/libmodbus/libmodbus_3.1.6.bb12
-rw-r--r--meta-oe/recipes-extended/libmodbus/libmodbus_3.1.7.bb9
4 files changed, 9 insertions, 96 deletions
diff --git a/meta-oe/recipes-extended/libmodbus/libmodbus/Fix-typo.patch b/meta-oe/recipes-extended/libmodbus/libmodbus/Fix-typo.patch
deleted file mode 100644
index 384a4a40b..000000000
--- a/meta-oe/recipes-extended/libmodbus/libmodbus/Fix-typo.patch
+++ /dev/null
@@ -1,52 +0,0 @@
1From: =?utf-8?b?IlNaIExpbiAo5p6X5LiK5pm6KSI=?= <szlin@debian.org>
2Date: Thu, 27 Sep 2018 14:51:32 +0800
3Subject: Fix typo
4
5---
6 doc/modbus_mapping_new_start_address.txt | 4 ++--
7 doc/modbus_reply.txt | 2 +-
8 doc/modbus_reply_exception.txt | 2 +-
9 3 files changed, 4 insertions(+), 4 deletions(-)
10
11diff --git a/doc/modbus_mapping_new_start_address.txt b/doc/modbus_mapping_new_start_address.txt
12index 4fa196a..94a81fb 100644
13--- a/doc/modbus_mapping_new_start_address.txt
14+++ b/doc/modbus_mapping_new_start_address.txt
15@@ -21,9 +21,9 @@ The _modbus_mapping_new_start_address()_ function shall allocate four arrays to
16 store bits, input bits, registers and inputs registers. The pointers are stored
17 in modbus_mapping_t structure. All values of the arrays are initialized to zero.
18
19-The different starting adresses make it possible to place the mapping at any
20+The different starting addresses make it possible to place the mapping at any
21 address in each address space. This way, you can give access to values stored
22-at high adresses without allocating memory from the address zero, for eg. to
23+at high addresses without allocating memory from the address zero, for eg. to
24 make available registers from 10000 to 10009, you can use:
25
26 [source,c]
27diff --git a/doc/modbus_reply.txt b/doc/modbus_reply.txt
28index 0b29d6f..6b71d11 100644
29--- a/doc/modbus_reply.txt
30+++ b/doc/modbus_reply.txt
31@@ -3,7 +3,7 @@ modbus_reply(3)
32
33 NAME
34 ----
35-modbus_reply - send a reponse to the received request
36+modbus_reply - send a response to the received request
37
38
39 SYNOPSIS
40diff --git a/doc/modbus_reply_exception.txt b/doc/modbus_reply_exception.txt
41index 7e6324f..b2170be 100644
42--- a/doc/modbus_reply_exception.txt
43+++ b/doc/modbus_reply_exception.txt
44@@ -3,7 +3,7 @@ modbus_reply_exception(3)
45
46 NAME
47 ----
48-modbus_reply_exception - send an exception reponse
49+modbus_reply_exception - send an exception response
50
51
52 SYNOPSIS
diff --git a/meta-oe/recipes-extended/libmodbus/libmodbus/f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d.patch b/meta-oe/recipes-extended/libmodbus/libmodbus/f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d.patch
deleted file mode 100644
index 7fae34e7d..000000000
--- a/meta-oe/recipes-extended/libmodbus/libmodbus/f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d.patch
+++ /dev/null
@@ -1,32 +0,0 @@
1From f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d Mon Sep 17 00:00:00 2001
2From: i-ky <gl.ivanovsky@gmail.com>
3Date: Tue, 10 Jul 2018 15:58:45 +0300
4Subject: [PATCH] Fixed MODBUS_GET_* macros in case of negative values
5
6In case resulting value should be negative it is incorrect to use '+' operator to construct it from pieces, because highest bytes will result in negative number after bitwise shift while others will stay positive. Replacing addition with '|' should solve the issue.
7---
8 src/modbus.h | 10 +++++-----
9 1 file changed, 5 insertions(+), 5 deletions(-)
10
11diff --git a/src/modbus.h b/src/modbus.h
12index f6e9a5f5..c63f5ceb 100644
13--- a/src/modbus.h
14+++ b/src/modbus.h
15@@ -245,12 +245,12 @@ MODBUS_API int modbus_reply_exception(modbus_t *ctx, const uint8_t *req,
16 #define MODBUS_GET_HIGH_BYTE(data) (((data) >> 8) & 0xFF)
17 #define MODBUS_GET_LOW_BYTE(data) ((data) & 0xFF)
18 #define MODBUS_GET_INT64_FROM_INT16(tab_int16, index) \
19- (((int64_t)tab_int16[(index) ] << 48) + \
20- ((int64_t)tab_int16[(index) + 1] << 32) + \
21- ((int64_t)tab_int16[(index) + 2] << 16) + \
22+ (((int64_t)tab_int16[(index) ] << 48) | \
23+ ((int64_t)tab_int16[(index) + 1] << 32) | \
24+ ((int64_t)tab_int16[(index) + 2] << 16) | \
25 (int64_t)tab_int16[(index) + 3])
26-#define MODBUS_GET_INT32_FROM_INT16(tab_int16, index) ((tab_int16[(index)] << 16) + tab_int16[(index) + 1])
27-#define MODBUS_GET_INT16_FROM_INT8(tab_int8, index) ((tab_int8[(index)] << 8) + tab_int8[(index) + 1])
28+#define MODBUS_GET_INT32_FROM_INT16(tab_int16, index) ((tab_int16[(index)] << 16) | tab_int16[(index) + 1])
29+#define MODBUS_GET_INT16_FROM_INT8(tab_int8, index) ((tab_int8[(index)] << 8) | tab_int8[(index) + 1])
30 #define MODBUS_SET_INT16_TO_INT8(tab_int8, index, value) \
31 do { \
32 tab_int8[(index)] = (value) >> 8; \
diff --git a/meta-oe/recipes-extended/libmodbus/libmodbus_3.1.6.bb b/meta-oe/recipes-extended/libmodbus/libmodbus_3.1.6.bb
deleted file mode 100644
index 8e42fdc5d..000000000
--- a/meta-oe/recipes-extended/libmodbus/libmodbus_3.1.6.bb
+++ /dev/null
@@ -1,12 +0,0 @@
1require libmodbus.inc
2
3SRC_URI += "file://f1eb4bc7ccb09cd8d19ab641ee37637f8c34d16d.patch \
4 file://Fix-float-endianness-issue-on-big-endian-arch.patch \
5 file://Fix-typo.patch"
6SRC_URI[md5sum] = "15c84c1f7fb49502b3efaaa668cfd25e"
7SRC_URI[sha256sum] = "d7d9fa94a16edb094e5fdf5d87ae17a0dc3f3e3d687fead81835d9572cf87c16"
8
9# this file has been created one minute after the configure file, so it doesn't get recreated during configure step
10do_configure:prepend() {
11 rm -rf ${S}/tests/unit-test.h
12}
diff --git a/meta-oe/recipes-extended/libmodbus/libmodbus_3.1.7.bb b/meta-oe/recipes-extended/libmodbus/libmodbus_3.1.7.bb
new file mode 100644
index 000000000..6c0e315d7
--- /dev/null
+++ b/meta-oe/recipes-extended/libmodbus/libmodbus_3.1.7.bb
@@ -0,0 +1,9 @@
1require libmodbus.inc
2
3SRC_URI += "file://Fix-float-endianness-issue-on-big-endian-arch.patch"
4SRC_URI[sha256sum] = "7dfe958431d0570b271e1a5b329b76a658e89c614cf119eb5aadb725c87f8fbd"
5
6# this file has been created one minute after the configure file, so it doesn't get recreated during configure step
7do_configure:prepend() {
8 rm -rf ${S}/tests/unit-test.h
9}