Re: [ptxdist] [PATCH] lowpan-tools: update lowpan-patches
On Sun, May 12, 2013 at 09:29:39PM +0200, Alexander Aring wrote: Currently there is no way to make a new lowpan-tools release. This patch synchronize the patches from version 0.3 with current git master. Signed-off-by: Alexander Aring alex.ar...@gmail.com --- .../0001-Avoid-crashing-in-izcoordinator.patch | 139 - Is this patch no longer relevant? ...0001-izoordinator-Fixes-to-error-handling.patch | 50 ...x-include-dependency-and-remove-redefined.patch | 109 .../0003-configure.ac-check-for-python2.x.patch| 32 + This patch modifies configure.ac. You need to add a link to ../autogen.sh so that ptxdist knows to recreate configure. Michael .../0004-m4-add-py_check_major_version.m4.patch| 44 +++ ...c-Check-that-the-python-version-is-indeed.patch | 27 ...t-PAN-ID-short-address-and-channel-manual.patch | 126 +++ ...z-mac-Handle-return-code-from-set-command.patch | 43 +++ patches/lowpan-tools-0.3/series| 8 +- 9 files changed, 438 insertions(+), 140 deletions(-) delete mode 100644 patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch create mode 100644 patches/lowpan-tools-0.3/0001-izoordinator-Fixes-to-error-handling.patch create mode 100644 patches/lowpan-tools-0.3/0002-addrdb-fix-include-dependency-and-remove-redefined.patch create mode 100644 patches/lowpan-tools-0.3/0003-configure.ac-check-for-python2.x.patch create mode 100644 patches/lowpan-tools-0.3/0004-m4-add-py_check_major_version.m4.patch create mode 100644 patches/lowpan-tools-0.3/0005-configure.ac-Check-that-the-python-version-is-indeed.patch create mode 100644 patches/lowpan-tools-0.3/0006-Allow-to-set-PAN-ID-short-address-and-channel-manual.patch create mode 100644 patches/lowpan-tools-0.3/0007-iz-mac-Handle-return-code-from-set-command.patch diff --git a/patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch b/patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch deleted file mode 100644 index 1b44f55..000 --- a/patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch +++ /dev/null @@ -1,139 +0,0 @@ -From: Alexander Aring alex.ar...@gmail.com -Date: Thu, 28 Feb 2013 13:17:08 +0100 -Subject: [PATCH] Avoid crashing in izcoordinator. - -This patch fixes some logging issues in lowpan-tools to avoid crashing -of izcoordinator. - -Posted on linux-zigbee-devel mailinglist from Tom Carroll: -http://www.mail-archive.com/linux-zigbee-devel@lists.sourceforge.net/msg01224.html - -Signed-off-by: Alexander Aring alex.ar...@gmail.com - lib/logging.c | 6 +- - src/coordinator.c | 32 +++- - 2 files changed, 20 insertions(+), 18 deletions(-) - mode change 100644 = 100755 src/coordinator.c - -diff --git a/lib/logging.c b/lib/logging.c -index 3ec30ee..f37531e 100644 a/lib/logging.c -+++ b/lib/logging.c -@@ -45,8 +45,12 @@ static void log_string(int level, char *s) - void init_log(char * name, int level) - { - #ifdef HAVE_SYSLOG_H -+int option = LOG_PID|LOG_CONS|LOG_NOWAIT; -+ - log_level = level; --openlog(name, LOG_PID|LOG_CONS|LOG_NOWAIT, LOG_DAEMON); -+if (log_level 0) -+option |= LOG_PERROR; -+openlog(name, option, LOG_DAEMON); - #endif - } - -diff --git a/src/coordinator.c b/src/coordinator.c -old mode 100644 -new mode 100755 -index a09633a..3322e3e a/src/coordinator.c -+++ b/src/coordinator.c -@@ -64,10 +64,10 @@ extern int yydebug; - - static void cleanup(int ret); - --static void log_msg_nl_perror(char *s, int err) -+static void log_msg_nl_perror(const char *s, int res) - { --if (err != NLE_SUCCESS) { --log_msg(0, %s: %s, s, nl_geterror(err)); -+if (res 0) { -+log_msg(0, %s: %s, s, nl_geterror(-res)); - cleanup(1); - } - } -@@ -93,8 +93,8 @@ static int mlme_start(uint16_t short_addr, uint16_t pan, uint8_t channel, uint8_ - nla_put_u8(msg, IEEE802154_ATTR_BAT_EXT, 0); - nla_put_u8(msg, IEEE802154_ATTR_COORD_REALIGN, 0); - #endif --int err = nl_send_auto_complete(nl, msg); --log_msg_nl_perror(nl_send_auto_complete, err); -+int res = nl_send_auto_complete(nl, msg); -+log_msg_nl_perror(nl_send_auto_complete, res); - return 0; - } - -@@ -127,9 +127,9 @@ static int coordinator_associate(struct genlmsghdr *ghdr, struct nlattr **attrs) - nla_put_u64(msg, IEEE802154_ATTR_DEST_HW_ADDR, nla_get_u64(attrs[IEEE802154_ATTR_SRC_HW_ADDR])); - nla_put_u16(msg, IEEE802154_ATTR_DEST_SHORT_ADDR, shaddr); - --int err = nl_send_auto_complete(nl, msg); -+int res = nl_send_auto_complete(nl, msg); - --log_msg_nl_perror(nl_send_auto_complete, err); -+log_msg_nl_perror(nl_send_auto_complete, res); - - return 0; - } -@@ -308,7 +308,6 @@ int main(int argc, char
Re: [ptxdist] [PATCH] lowpan-tools: update lowpan-patches
Hi Michael, On Mon, May 13, 2013 at 09:42:04AM +0200, Michael Olbrich wrote: On Sun, May 12, 2013 at 09:29:39PM +0200, Alexander Aring wrote: Currently there is no way to make a new lowpan-tools release. This patch synchronize the patches from version 0.3 with current git master. Signed-off-by: Alexander Aring alex.ar...@gmail.com --- .../0001-Avoid-crashing-in-izcoordinator.patch | 139 - Is this patch no longer relevant? It's now in upstream and replaced by 0001-izoordinator-Fixes-to-error-handling.patch ...0001-izoordinator-Fixes-to-error-handling.patch | 50 ...x-include-dependency-and-remove-redefined.patch | 109 .../0003-configure.ac-check-for-python2.x.patch| 32 + This patch modifies configure.ac. You need to add a link to ../autogen.sh so that ptxdist knows to recreate configure. oh yes, I forgot that. Thanks. Alex -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] lowpan-tools: update lowpan-patches
On Mon, May 13, 2013 at 10:46:49AM +0200, Alexander Aring wrote: Hi Michael, On Mon, May 13, 2013 at 09:42:04AM +0200, Michael Olbrich wrote: On Sun, May 12, 2013 at 09:29:39PM +0200, Alexander Aring wrote: Currently there is no way to make a new lowpan-tools release. This patch synchronize the patches from version 0.3 with current git master. Signed-off-by: Alexander Aring alex.ar...@gmail.com --- .../0001-Avoid-crashing-in-izcoordinator.patch | 139 - Is this patch no longer relevant? It's now in upstream and replaced by 0001-izoordinator-Fixes-to-error-handling.patch That's not obvious from just looking at the patches. Please add a comment in the commit message. Michael ...0001-izoordinator-Fixes-to-error-handling.patch | 50 ...x-include-dependency-and-remove-redefined.patch | 109 .../0003-configure.ac-check-for-python2.x.patch| 32 + This patch modifies configure.ac. You need to add a link to ../autogen.sh so that ptxdist knows to recreate configure. oh yes, I forgot that. Thanks. Alex -- ptxdist mailing list ptxdist@pengutronix.de -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0| Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | -- ptxdist mailing list ptxdist@pengutronix.de
Re: [ptxdist] [PATCH] lowpan-tools: update lowpan-patches
Hi Michael, On Mon, May 13, 2013 at 02:18:59PM +0200, Michael Olbrich wrote: On Mon, May 13, 2013 at 10:46:49AM +0200, Alexander Aring wrote: Hi Michael, On Mon, May 13, 2013 at 09:42:04AM +0200, Michael Olbrich wrote: On Sun, May 12, 2013 at 09:29:39PM +0200, Alexander Aring wrote: Currently there is no way to make a new lowpan-tools release. This patch synchronize the patches from version 0.3 with current git master. Signed-off-by: Alexander Aring alex.ar...@gmail.com --- .../0001-Avoid-crashing-in-izcoordinator.patch | 139 - Is this patch no longer relevant? It's now in upstream and replaced by 0001-izoordinator-Fixes-to-error-handling.patch That's not obvious from just looking at the patches. Please add a comment in the commit message. You are right, I will do that. Sorry :-) Alex -- ptxdist mailing list ptxdist@pengutronix.de
[ptxdist] [PATCH] lowpan-tools: update lowpan-patches
Currently there is no way to make a new lowpan-tools release. This patch synchronize the patches from version 0.3 with current git master. Signed-off-by: Alexander Aring alex.ar...@gmail.com --- .../0001-Avoid-crashing-in-izcoordinator.patch | 139 - ...0001-izoordinator-Fixes-to-error-handling.patch | 50 ...x-include-dependency-and-remove-redefined.patch | 109 .../0003-configure.ac-check-for-python2.x.patch| 32 + .../0004-m4-add-py_check_major_version.m4.patch| 44 +++ ...c-Check-that-the-python-version-is-indeed.patch | 27 ...t-PAN-ID-short-address-and-channel-manual.patch | 126 +++ ...z-mac-Handle-return-code-from-set-command.patch | 43 +++ patches/lowpan-tools-0.3/series| 8 +- 9 files changed, 438 insertions(+), 140 deletions(-) delete mode 100644 patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch create mode 100644 patches/lowpan-tools-0.3/0001-izoordinator-Fixes-to-error-handling.patch create mode 100644 patches/lowpan-tools-0.3/0002-addrdb-fix-include-dependency-and-remove-redefined.patch create mode 100644 patches/lowpan-tools-0.3/0003-configure.ac-check-for-python2.x.patch create mode 100644 patches/lowpan-tools-0.3/0004-m4-add-py_check_major_version.m4.patch create mode 100644 patches/lowpan-tools-0.3/0005-configure.ac-Check-that-the-python-version-is-indeed.patch create mode 100644 patches/lowpan-tools-0.3/0006-Allow-to-set-PAN-ID-short-address-and-channel-manual.patch create mode 100644 patches/lowpan-tools-0.3/0007-iz-mac-Handle-return-code-from-set-command.patch diff --git a/patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch b/patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch deleted file mode 100644 index 1b44f55..000 --- a/patches/lowpan-tools-0.3/0001-Avoid-crashing-in-izcoordinator.patch +++ /dev/null @@ -1,139 +0,0 @@ -From: Alexander Aring alex.ar...@gmail.com -Date: Thu, 28 Feb 2013 13:17:08 +0100 -Subject: [PATCH] Avoid crashing in izcoordinator. - -This patch fixes some logging issues in lowpan-tools to avoid crashing -of izcoordinator. - -Posted on linux-zigbee-devel mailinglist from Tom Carroll: -http://www.mail-archive.com/linux-zigbee-devel@lists.sourceforge.net/msg01224.html - -Signed-off-by: Alexander Aring alex.ar...@gmail.com - lib/logging.c | 6 +- - src/coordinator.c | 32 +++- - 2 files changed, 20 insertions(+), 18 deletions(-) - mode change 100644 = 100755 src/coordinator.c - -diff --git a/lib/logging.c b/lib/logging.c -index 3ec30ee..f37531e 100644 a/lib/logging.c -+++ b/lib/logging.c -@@ -45,8 +45,12 @@ static void log_string(int level, char *s) - void init_log(char * name, int level) - { - #ifdef HAVE_SYSLOG_H -+ int option = LOG_PID|LOG_CONS|LOG_NOWAIT; -+ - log_level = level; -- openlog(name, LOG_PID|LOG_CONS|LOG_NOWAIT, LOG_DAEMON); -+ if (log_level 0) -+ option |= LOG_PERROR; -+ openlog(name, option, LOG_DAEMON); - #endif - } - -diff --git a/src/coordinator.c b/src/coordinator.c -old mode 100644 -new mode 100755 -index a09633a..3322e3e a/src/coordinator.c -+++ b/src/coordinator.c -@@ -64,10 +64,10 @@ extern int yydebug; - - static void cleanup(int ret); - --static void log_msg_nl_perror(char *s, int err) -+static void log_msg_nl_perror(const char *s, int res) - { -- if (err != NLE_SUCCESS) { -- log_msg(0, %s: %s, s, nl_geterror(err)); -+ if (res 0) { -+ log_msg(0, %s: %s, s, nl_geterror(-res)); - cleanup(1); - } - } -@@ -93,8 +93,8 @@ static int mlme_start(uint16_t short_addr, uint16_t pan, uint8_t channel, uint8_ - nla_put_u8(msg, IEEE802154_ATTR_BAT_EXT, 0); - nla_put_u8(msg, IEEE802154_ATTR_COORD_REALIGN, 0); - #endif -- int err = nl_send_auto_complete(nl, msg); -- log_msg_nl_perror(nl_send_auto_complete, err); -+ int res = nl_send_auto_complete(nl, msg); -+ log_msg_nl_perror(nl_send_auto_complete, res); - return 0; - } - -@@ -127,9 +127,9 @@ static int coordinator_associate(struct genlmsghdr *ghdr, struct nlattr **attrs) - nla_put_u64(msg, IEEE802154_ATTR_DEST_HW_ADDR, nla_get_u64(attrs[IEEE802154_ATTR_SRC_HW_ADDR])); - nla_put_u16(msg, IEEE802154_ATTR_DEST_SHORT_ADDR, shaddr); - -- int err = nl_send_auto_complete(nl, msg); -+ int res = nl_send_auto_complete(nl, msg); - -- log_msg_nl_perror(nl_send_auto_complete, err); -+ log_msg_nl_perror(nl_send_auto_complete, res); - - return 0; - } -@@ -308,7 +308,6 @@ int main(int argc, char **argv) - #else - opt = getopt(argc, argv, l:f:d:m:n:i:s:p:c:hv); - #endif -- fprintf(stderr, Opt: %c (%hhx)\n, opt, opt); - if (opt == -1) - break; - -@@ -364,7 +363,6 @@ int main(int argc, char **argv) - usage(pname); -