Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package arm-trusted-firmware for
openSUSE:Factory checked in at 2022-02-17 00:30:26
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/arm-trusted-firmware (Old)
and /work/SRC/openSUSE:Factory/.arm-trusted-firmware.new.1956 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "arm-trusted-firmware"
Thu Feb 17 00:30:26 2022 rev:11 rq:955163 version:2.6
Changes:
--------
---
/work/SRC/openSUSE:Factory/arm-trusted-firmware/arm-trusted-firmware.changes
2022-02-02 22:45:02.774054565 +0100
+++
/work/SRC/openSUSE:Factory/.arm-trusted-firmware.new.1956/arm-trusted-firmware.changes
2022-02-17 00:31:45.405420619 +0100
@@ -1,0 +2,8 @@
+Tue Feb 8 09:29:53 UTC 2022 - Matwey Kornilov <[email protected]>
+
+- Update A3700-utils-marvell version:
+ Fix build SATA bootloader for A3700 boards
+ Drop fix-A3700-gcc11.patch: upstreamed
+ Enable %fdupes which is particularly useful for a3700 flavour
+
+-------------------------------------------------------------------
Old:
----
fix-A3700-gcc11.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ arm-trusted-firmware.spec ++++++
--- /var/tmp/diff_new_pack.aRL0tY/_old 2022-02-17 00:31:46.049420509 +0100
+++ /var/tmp/diff_new_pack.aRL0tY/_new 2022-02-17 00:31:46.053420507 +0100
@@ -66,7 +66,7 @@
Source3: binaries-marvell-%{mv_bin_ver}.tar.gz
Patch1: atf-allow-non-git-dir.patch
Patch150: A3700_utils-drop-git.patch
-Patch151: fix-A3700-gcc11.patch
+BuildRequires: fdupes
%if "%{platform}" != ""
#!BuildIgnore: gcc-PIE
%endif
@@ -217,13 +217,10 @@
pushd A3700-utils-marvell-%{a3700_utils_ver}
# git repo or branch.txt file are expected
echo "%{a3700_utils_ver}" > branch.txt
-# Remove any pre-built x86 Linux binaries
-rm -f wtptp/linux/*
%if "%{platform}" != ""
-install -m 0755 %{_bindir}/TBB wtptp/linux/tbb_linux
+install -D -m 0755 %{_bindir}/TBB wtptp/linux/tbb_linux
%endif
%patch150 -p1
-%patch151 -p1
popd
%endif
%patch1 -p1
@@ -249,7 +246,7 @@
%else
%if "%{platform}" == "a3700"
export CROSS_CM3=arm-none-eabi-
-%define variants ebin_512M_spinor ebin_v3_1G_spinor ebin_v5_2G_spinor
ebin_v7_1G_spinor ebin_v7_2G_spinor
+%define variants ebin_512M_spinor ebin_v3_1G_spinor ebin_v5_2G_spinor
ebin_v7_1G_spinor ebin_v7_2G_spinor ebin_512M_sata ebin_v3_1G_sata
ebin_v5_2G_sata ebin_v7_1G_sata ebin_v7_2G_sata
for variant in %{variants}; do
partnum=0
case "${variant}" in
@@ -470,6 +467,8 @@
%endif
+%fdupes %{buildroot}%{_prefix}
+
%if "%{platform}" == "rpi3" || "%{platform}" == "rpi4"
%post
if mountpoint -q /boot/efi; then
++++++ A3700-utils-marvell-master.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/A3700-utils-marvell-master/.gitignore
new/A3700-utils-marvell-master/.gitignore
--- old/A3700-utils-marvell-master/.gitignore 2021-05-23 07:51:21.000000000
+0200
+++ new/A3700-utils-marvell-master/.gitignore 1970-01-01 01:00:00.000000000
+0100
@@ -1,15 +0,0 @@
-#ignore target directory
-wtmi/build/*
-#ignore all intermediate files
-*.[oad]
-*.elf
-*.dis
-*.bin
-#ignore specific files
-clocks_ddr.txt
-ddr_static.txt
-ddr_static.txt.info
-autoconf.h
-tim/ddr/ddr_tool
-tim/ddr/ddr_tool.verstr
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/A3700-utils-marvell-master/tim/ddr/clocks-ddr3.txt
new/A3700-utils-marvell-master/tim/ddr/clocks-ddr3.txt
--- old/A3700-utils-marvell-master/tim/ddr/clocks-ddr3.txt 2021-05-23
07:51:21.000000000 +0200
+++ new/A3700-utils-marvell-master/tim/ddr/clocks-ddr3.txt 2022-02-13
07:39:32.000000000 +0100
@@ -18,7 +18,7 @@
DELAY: 0x00000100
; Set clocks to DDR300 preset
-WRITE: 0xC0013014 0x07032018
+WRITE: 0xC0013014 0x05032010
WRITE: 0xC0013004 0x2326202A
WRITE: 0xC0013008 0x1A09AAA9
WRITE: 0xC001300C 0x208B3482
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/A3700-utils-marvell-master/tim/ddr/clocks-ddr4.txt
new/A3700-utils-marvell-master/tim/ddr/clocks-ddr4.txt
--- old/A3700-utils-marvell-master/tim/ddr/clocks-ddr4.txt 2021-05-23
07:51:21.000000000 +0200
+++ new/A3700-utils-marvell-master/tim/ddr/clocks-ddr4.txt 2022-02-13
07:39:32.000000000 +0100
@@ -18,7 +18,7 @@
DELAY: 0x00000100
; Set clocks to DDR400 preset
-WRITE: 0xC0013014 0x07032018
+WRITE: 0xC0013014 0x05032010
WRITE: 0xC0013004 0x1296202C
WRITE: 0xC0013008 0x21061AA9
WRITE: 0xC001300C 0x20543084
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/A3700-utils-marvell-master/wtmi/fuse/main.c
new/A3700-utils-marvell-master/wtmi/fuse/main.c
--- old/A3700-utils-marvell-master/wtmi/fuse/main.c 2021-05-23
07:51:21.000000000 +0200
+++ new/A3700-utils-marvell-master/wtmi/fuse/main.c 2022-02-13
07:39:32.000000000 +0100
@@ -132,7 +132,7 @@
{
u32 cmd, args[MAILBOX_MAX_ARGS];
u32 status, nargs;
- enum mbox_status mb_stat = MB_STAT_SUCCESS;
+ enum mbox_status mb_stat;
if (exception != 0) {
exception_handler(exception);
@@ -154,6 +154,8 @@
if (status != NO_ERROR) {
nargs = 0;
mb_stat = args[0];
+ } else {
+ mb_stat = MB_STAT_SUCCESS;
}
/* Send the results back */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/A3700-utils-marvell-master/wtmi/sys_init/Makefile
new/A3700-utils-marvell-master/wtmi/sys_init/Makefile
--- old/A3700-utils-marvell-master/wtmi/sys_init/Makefile 2021-05-23
07:51:21.000000000 +0200
+++ new/A3700-utils-marvell-master/wtmi/sys_init/Makefile 2022-02-13
07:39:32.000000000 +0100
@@ -85,6 +85,8 @@
WTMI_CLOCK = 2
else ifeq ($(CLOCKSPRESET), CPU_1200_DDR_750)
WTMI_CLOCK = 3
+else
+$(error "CLOCKSPRESET=$(CLOCKSPRESET) is invalid")
endif
START_ADDR_DEC := $(shell printf %d 0x1fff0000)
Binary files old/A3700-utils-marvell-master/wtptp/linux/WtpDownload_linux and
new/A3700-utils-marvell-master/wtptp/linux/WtpDownload_linux differ
Binary files old/A3700-utils-marvell-master/wtptp/linux/tbb_linux and
new/A3700-utils-marvell-master/wtptp/linux/tbb_linux differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/inc/CryptoPP_L_interface.h
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/inc/CryptoPP_L_interface.h
---
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/inc/CryptoPP_L_interface.h
2021-05-23 07:51:21.000000000 +0200
+++
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/inc/CryptoPP_L_interface.h
2022-02-13 07:39:32.000000000 +0100
@@ -121,7 +121,9 @@
#include INCLUDE_FILE(files.h)
#include INCLUDE_FILE(secblock.h)
+#ifdef CRYPTOPP_NO_GLOBAL_BYTE
using CryptoPP::byte;
+#endif
namespace CryptoPP {
@@ -167,7 +169,11 @@
// Struct RSASS_Hash inherits this class..
// This class contains the modified signer instance
+#if defined(CRYPTOPP_VERSION) && CRYPTOPP_VERSION >= 600
template <class STANDARD, class H, class KEYS, class ALG_INFO = TF_SS<KEYS,
STANDARD, H, int> >
+#else
+template <class STANDARD, class H, class KEYS, class ALG_INFO =
TF_SS<STANDARD, H, KEYS, int> >
+#endif
class TF_SS_Hash : public KEYS
{
public:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/CTIM.cpp
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/CTIM.cpp
--- old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/CTIM.cpp
2021-05-23 07:51:21.000000000 +0200
+++ new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/CTIM.cpp
2022-02-13 07:39:32.000000000 +0100
@@ -100,6 +100,7 @@
#include <time.h>
CCTIM::CCTIM() {
+ memset((void *) &this->m_TimHeader, 0, sizeof(this->m_TimHeader));
}
CCTIM::~CCTIM() {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TimDescriptorParser.cpp
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TimDescriptorParser.cpp
---
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TimDescriptorParser.cpp
2021-05-23 07:51:21.000000000 +0200
+++
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TimDescriptorParser.cpp
2022-02-13 07:39:32.000000000 +0100
@@ -2682,7 +2682,7 @@
}
if (m_TimDescriptor.ImagesList().size() > 0) {
CImageDescription* pImage =
(*(m_TimDescriptor.ImagesList().begin()));
- if (pImage > 0
+ if (pImage != 0
&& ((Translate(pImage->ImageIdTag()) & TYPEMASK)
== (TIMIDENTIFIER & TYPEMASK)))
{
if (pImage->ImageSizeToHash() == pImage->ImageSize())
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TrustedImageBuilder.cpp
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TrustedImageBuilder.cpp
---
old/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TrustedImageBuilder.cpp
2021-05-23 07:51:21.000000000 +0200
+++
new/A3700-utils-marvell-master/wtptp/src/TBB_Linux/src/TrustedImageBuilder.cpp
2022-02-13 07:39:32.000000000 +0100
@@ -2536,10 +2536,10 @@
CDigS.DigSFromArray((UINT *) sign, CDigS.KeySize() / 32);
}
- delete RSA_D; //Private Exponent
- delete RSA_E; //Public Exponent
- delete RSA_N; //Public Modulus
- delete sign;
+ delete[] RSA_D; //Private Exponent
+ delete[] RSA_E; //Public Exponent
+ delete[] RSA_N; //Public Modulus
+ delete[] sign;
return retVal;
}
@@ -2635,11 +2635,11 @@
} else
retVal = false;
- delete RSA_D; //Private Exponent
- delete RSA_E; //Public Exponent
- delete RSA_N; //Public Modulus
- delete sign;
- delete signReversed;
+ delete[] RSA_D; //Private Exponent
+ delete[] RSA_E; //Public Exponent
+ delete[] RSA_N; //Public Modulus
+ delete[] sign;
+ delete[] signReversed;
return retVal;
}
@@ -2759,8 +2759,8 @@
CDigS.DigSFromArray((UINT *) signReversed, keySize);
}
- delete ECDSA_Public; //Private Exponent
- delete ECDSA_Private; //Public Exponent
+ delete[] ECDSA_Public; //Private Exponent
+ delete[] ECDSA_Private; //Public Exponent
return retVal;
}
@@ -2884,7 +2884,7 @@
else
cerr << "Failed to verify signature on message" << endl;
- delete ECDSA_Public;
+ delete[] ECDSA_Public;
return retVal;
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/makefile.mk
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/makefile.mk
--- old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/makefile.mk
2021-05-23 07:51:21.000000000 +0200
+++ new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/makefile.mk
2022-02-13 07:39:32.000000000 +0100
@@ -11,15 +11,17 @@
OBJECTS = WtpStatus.o WtpCommand.o Misc.o WtpException.o WtpImage.o Port.o
ProtocolManager.o USBPortLinux.o UARTPortLinux.o TimParser.o
CommandlineParser.o TimLib.o WtpDownloadApp.o \
-CXXFLAGS = -Wno-deprecated -D LINUX=1 -D TOOLS_GUI=0 -D IPPV6=1 -D TRUSTED=1
-D DEV_DEBUG=0 -I $(COMMON_SRC)
+CXXFLAGS = -std=c++11 -Wno-deprecated -D LINUX=1 -D TOOLS_GUI=0 -D IPPV6=1 -D
TRUSTED=1 -D DEV_DEBUG=0 -I $(COMMON_SRC)
WTP_CXXFLAGS = $(CXXFLAGS) -I $(WTP_INCLUDE)
#LIBS = $(IPP_STATIC_LIB_DIR)/libippcpmerged.a
$(IPP_STATIC_LIB_DIR)/libippcore.a
-WtpDownload: $(OBJECTS)
+WtpDownload_linux: $(OBJECTS)
$(CXX) $(WTP_CXXFLAGS) -o WtpDownload_linux $(OBJECTS) $(LIBS)
- -rm *.o
+
+clean:
+ -rm -f WtpDownload_linux $(OBJECTS)
WtpDownloadApp.o: $(WTP_SRC)/WtpDownloadApp.cpp $(WTP_INCLUDE)/WtpDownloadApp.h
$(CXX) $(WTP_CXXFLAGS) -o WtpDownloadApp.o -c
$(WTP_SRC)/WtpDownloadApp.cpp
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/ProtocolManager.cpp
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/ProtocolManager.cpp
---
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/ProtocolManager.cpp
2021-05-23 07:51:21.000000000 +0200
+++
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/ProtocolManager.cpp
2022-02-13 07:39:32.000000000 +0100
@@ -197,10 +197,10 @@
stringstream Message;
unsigned int LoopTimeout = 0;
- char * sendbuffer_escape = new char[8];
- char * sendbuffer_response = new char[1];
- char * recbuffer_escape = new char[8];
- char * recbuffer_3e_or_nack = new char[1];
+ char sendbuffer_escape[8];
+ char sendbuffer_response[1];
+ char recbuffer_escape[8];
+ char recbuffer_3e_or_nack[1];
int i = 0;
int nullcount = 0;
int incount = 0;
@@ -231,7 +231,7 @@
//cout << recbuffer_3e_or_nack[0] << recbuffer_3e_or_nack[1] <<
recbuffer_3e_or_nack[2] << recbuffer_3e_or_nack[3] << endl;
- if(recbuffer_3e_or_nack[0] == 0x3e && incount == 1) {
+ if(incount == 1 && recbuffer_3e_or_nack[0] == 0x3e) {
//cout << "I see a 3e" << endl;
LoopTimeout = 10000; // force exit from while
loop because we have seen a response
@@ -241,13 +241,13 @@
- } else if (recbuffer_3e_or_nack[0] == 0x00 && incount
== 1 ) {
+ } else if (incount == 1 && recbuffer_3e_or_nack[0] ==
0x00) {
nullcount++;
for (i = 0; i< 3; i++) {
//cout << "I see " << nullcount << "
characters of a NACK..." << endl;
incount =
Port->ReadRaw(recbuffer_3e_or_nack, 1);
- if (recbuffer_3e_or_nack[0] == 0x00 &&
incount == 1) {
+ if (incount == 1 &&
recbuffer_3e_or_nack[0] == 0x00) {
//cout <<
recbuffer_3e_or_nack[0] << endl;
nullcount++;
if (nullcount == 4) {
@@ -295,10 +295,10 @@
stringstream Message;
unsigned int LoopTimeout = 0;
- char * sendbuffer_escape = new char[8];
- char * sendbuffer_response = new char[1];
- char * recbuffer_escape = new char[8];
- char * recbuffer_3e_or_nack = new char[1];
+ char sendbuffer_escape[8];
+ char sendbuffer_response[1];
+ char recbuffer_escape[8];
+ char recbuffer_3e_or_nack[1];
int i = 0;
int nullcount = 0;
int incount = 0;
@@ -329,7 +329,7 @@
//cout << recbuffer_3e_or_nack[0] << recbuffer_3e_or_nack[1] <<
recbuffer_3e_or_nack[2] << recbuffer_3e_or_nack[3] << endl;
- if (recbuffer_3e_or_nack[0] == 0x3e && incount == 1) {
+ if (incount == 1 && recbuffer_3e_or_nack[0] == 0x3e) {
//cout << "I see a 3e" << endl;
LoopTimeout = 1000000; // force exit from while loop
because we have seen a response
@@ -340,13 +340,13 @@
}
- else if (recbuffer_3e_or_nack[0] == 0x00 && incount == 1) {
+ else if (incount == 1 && recbuffer_3e_or_nack[0] == 0x00) {
nullcount++;
for (i = 0; i< 3; i++) {
//cout << "I see " << nullcount << " characters
of a NACK..." << endl;
incount = Port->ReadRaw(recbuffer_3e_or_nack,
1);
- if (recbuffer_3e_or_nack[0] == 0x00 && incount
== 1) {
+ if (incount == 1 && recbuffer_3e_or_nack[0] ==
0x00) {
//cout << recbuffer_3e_or_nack[0] <<
endl;
nullcount++;
if (nullcount == 4) {
@@ -395,10 +395,10 @@
stringstream Message;
unsigned int LoopTimeout = 0;
- char * sendbuffer_escape = new char[8];
- char * sendbuffer_response = new char[1];
- char * recbuffer_escape = new char[8];
- char * recbuffer_3e_or_nack = new char[1];
+ char sendbuffer_escape[8];
+ char sendbuffer_response[1];
+ char recbuffer_escape[8];
+ char recbuffer_3e_or_nack[1];
int i = 0;
int nullcount = 0;
int incount = 0;
@@ -424,7 +424,7 @@
//cout << recbuffer_3e_or_nack[0] << recbuffer_3e_or_nack[1] <<
recbuffer_3e_or_nack[2] << recbuffer_3e_or_nack[3] << endl;
- if (recbuffer_3e_or_nack[0] == 0x3e && incount == 1) {
+ if (incount == 1 && recbuffer_3e_or_nack[0] == 0x3e) {
//cout << "I see a 3e" << endl;
LoopTimeout = 1000000; // force exit from while loop
because we have seen a response
@@ -435,13 +435,13 @@
}
- else if (recbuffer_3e_or_nack[0] == 0x00 && incount == 1) {
+ else if (incount == 1 && recbuffer_3e_or_nack[0] == 0x00) {
nullcount++;
for (i = 0; i< 3; i++) {
//cout << "I see " << nullcount << " characters
of a NACK..." << endl;
incount = Port->ReadRaw(recbuffer_3e_or_nack,
1);
- if (recbuffer_3e_or_nack[0] == 0x00 && incount
== 1) {
+ if (incount == 1 && recbuffer_3e_or_nack[0] ==
0x00) {
//cout << recbuffer_3e_or_nack[0] <<
endl;
nullcount++;
if (nullcount == 4) {
@@ -492,10 +492,10 @@
unsigned int waitLoop = 0;
int nullcount = 0;
int i = 0;
- char * sendbuffer_escape = new char[8];
- char * sendbuffer_response = new char[1];
- char * recbuffer_escape = new char[8];
- char * recbuffer_3e = new char[1];
+ char sendbuffer_escape[8];
+ char sendbuffer_response[1];
+ char recbuffer_escape[8];
+ char recbuffer_3e[1];
sendbuffer_response[0] = 0xd;
int incount = 0;
Message << "HOST:: Sending 0xDD112233 and 0x44556677 ..." << endl;
@@ -517,7 +517,7 @@
incount = Port->ReadRaw(recbuffer_3e, 1);
- if (recbuffer_3e[0] == 0x3e) {
+ if (incount == 1 && recbuffer_3e[0] == 0x3e) {
//cout << "I see a 3e" << endl;
LoopTimeout = 1000000; // force exit from while
loop because we have seen a response
@@ -526,13 +526,13 @@
//cout << "Sending a response" << endl;
//Port->WriteRaw(sendbuffer_response, 1);
- } else if (recbuffer_3e[0] == 0x00 && incount == 1) {
+ } else if (incount == 1 && recbuffer_3e[0] == 0x00) {
nullcount++;
for (i = 0; i< 3; i++) {
//cout << "I see " << nullcount << "
characters of a NACK..." << endl;
incount = Port->ReadRaw(recbuffer_3e,
1);
- if (recbuffer_3e[0] == 0x00 && incount
== 1) {
+ if (incount == 1 && recbuffer_3e[0] ==
0x00) {
//cout << recbuffer_3e[0] <<
endl;
nullcount++;
if (nullcount == 4) {
@@ -715,8 +715,8 @@
throw CWtpException(CWtpException::NACK_SELECTIMAGE);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -756,8 +756,8 @@
throw CWtpException(CWtpException::NACK_VERIFYIMAGE);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -802,8 +802,8 @@
HandlePendingMessages();
throw CWtpException(CWtpException::NACK_DATAHEADER);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
#if USE_USB_DELAY_SWITCHES == 1
// this sleep is requested by Mike and Bruce to address an issue with the
USB/BootROM terminating a transfer
@@ -860,8 +860,8 @@
throw CWtpException(CWtpException::NACK_DATA);
}
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
@@ -900,8 +900,8 @@
HandlePendingMessages();
throw CWtpException(CWtpException::NACK_DONE);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -948,6 +948,8 @@
else
throw;
}
+ delete Port->WtpCmd;
+ Port->WtpCmd = 0;
if (Port->WtpStatus.GetStatus() == ACK)
break;
@@ -961,14 +963,11 @@
else
retry++;
- if (retry < 2)
- delete Port->WtpCmd;
} while (retry < 2);
#if DEV_DEBUG
if(theApp.bVerbose)
{
- Port->WtpCmd->print();
Port->WtpStatus.print();
}
#endif
@@ -978,10 +977,8 @@
if (Port->WtpStatus.GetDLEN() > 0)
Port->GetWtpRemainingMessage();
HandlePendingMessages();
- delete Port->WtpCmd;
throw CWtpException(CWtpException::NACK_DISCONNECT);
}
- delete Port->WtpCmd;
}
}
@@ -1034,8 +1031,8 @@
Message << "Build:" << TargetPV.Build << endl;
misc.UserMessagePrintStr(true,Message.str());
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -1151,8 +1148,8 @@
{
Message << endl << "GetParameters returned LEN is not correct!
LEN = 0x" << hex << (int)Port->WtpStatus.GetDLEN() << endl;
misc.UserMessagePrintStr(true,Message.str());
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
throw CWtpException(CWtpException::NACK_GETPARAMETERS);
}
@@ -1218,12 +1215,12 @@
{
if(Port->WtpStatus.GetDLEN() > 0)
Port->GetWtpRemainingMessage();
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
throw CWtpException(CWtpException::NACK_UPLOADDATAHEADER);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -1254,12 +1251,12 @@
{
if(Port->WtpStatus.GetDLEN() > 0)
Port->GetWtpRemainingMessage();
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
throw CWtpException(CWtpException::NACK_UPLOADDATA);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
@@ -1321,8 +1318,8 @@
misc.UserMessagePrintStr(true,Message.str());
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -1353,12 +1350,12 @@
if (Port->WtpStatus.GetDLEN() > 0)
Port->GetWtpRemainingMessage();
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
throw CWtpException(CWtpException::NACK_PUBLICKEY);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -1388,12 +1385,12 @@
{
if (Port->WtpStatus.GetDLEN() > 0)
Port->GetWtpRemainingMessage();
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
throw CWtpException(CWtpException::NACK_PASSWORD);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
@@ -1425,12 +1422,12 @@
if (Port->WtpStatus.GetDLEN() > 0)
Port->GetWtpRemainingMessage();
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
throw CWtpException(CWtpException::NACK_SIGNEDPASSWORD);
}
- HandlePendingMessages();
delete Port->WtpCmd;
+ HandlePendingMessages();
}
/**
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/UARTPortLinux.cpp
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/UARTPortLinux.cpp
---
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/UARTPortLinux.cpp
2021-05-23 07:51:21.000000000 +0200
+++
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/UARTPortLinux.cpp
2022-02-13 07:39:32.000000000 +0100
@@ -127,14 +127,14 @@
UARTDeviceName ="/dev/ttyUSB" ;
UARTDeviceName.append(portNumber.str());
cout << endl << UARTDeviceName << endl;
- uartLinuxFileDesc = open(UARTDeviceName.c_str(),O_RDWR|O_NOCTTY);
+ uartLinuxFileDesc =
open(UARTDeviceName.c_str(),O_RDWR|O_NOCTTY|O_NONBLOCK);
if(uartLinuxFileDesc < 0)
{
cout << endl << " ERROR: Open UART driver failed:" << endl;
throw
CWtpException(CWtpException::OPENUARTPORT,0,UARTDeviceName);
}
- fcntl(uartLinuxFileDesc,F_SETFL,0);
memset(&options, 0, sizeof(options));
+ tcgetattr(uartLinuxFileDesc, &options);
cfsetispeed(&options, B115200);
cfsetospeed(&options, B115200);
options.c_iflag &=
~(IGNBRK|BRKINT|PARMRK|ISTRIP|INLCR|IGNCR|ICRNL|IXON);
@@ -142,9 +142,10 @@
options.c_oflag &= ~OPOST;
options.c_cc[VMIN] = 0;
options.c_cc[VTIME] = 0;
- options.c_cflag &= ~(CSIZE|PARENB);
- options.c_cflag |= CS8;
+ options.c_cflag &= ~(CSIZE|PARENB|CSTOPB|HUPCL|CRTSCTS);
+ options.c_cflag |= CS8|CLOCAL|CREAD;
tcsetattr(uartLinuxFileDesc, TCSANOW, &options);
+ fcntl(uartLinuxFileDesc,F_SETFL,fcntl(uartLinuxFileDesc, F_GETFL) &
~O_NONBLOCK);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore'
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/WtpDownloadApp.cpp
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/WtpDownloadApp.cpp
---
old/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/WtpDownloadApp.cpp
2021-05-23 07:51:21.000000000 +0200
+++
new/A3700-utils-marvell-master/wtptp/src/Wtpdownloader_Linux/src/WtpDownloadApp.cpp
2022-02-13 07:39:32.000000000 +0100
@@ -503,11 +503,11 @@
stringstream Message;
CMisc misc;
//CUARTPort UartPort;
- char * dummybuffer = new char[8];
- char * dummybuffer1 = new char[1]; // a single byte buffer
- char * response = new char[1];
+ char dummybuffer[8];
+ char dummybuffer1[1]; // a single byte buffer
+ char response[1];
response[0] = 0x0d;
- char * response4 = new char[4];
+ char response4[4];
response4[0] = 0x0d;
response4[1] = 0x0d;
response4[2] = 0x0d;
@@ -534,11 +534,7 @@
printf( "Start time: %s\n", tmpbuf );
//Message << "Download Start Time: " <<
ctime(&theApp.downloadStartTime) << endl;
-#if X64_BUILD
- Message << "WtpDownload for 64-bit Host (Target Images Downloading
Tool)" << endl;
-#else
- Message << "WtpDownload for 32-bit Host (Target Images Downloading
Tool)" << endl;
-#endif
+ Message << "WtpDownload for " << 8*sizeof(void*) << "-bit Host (Target
Images Downloading Tool)" << endl;
#if TRUSTED
Message << endl << "Trusted version for TIM and NTIM" << endl;
@@ -893,7 +889,7 @@
printf( "\nFinish time: %s\n", tmpbuf );
double timetaken = difftime(endtime,starttime);
- Message <<"Download Time:" <<
theApp.ConvertSecondsToTimeString(timetaken) ;
+ Message <<"Download Time:" <<
theApp.ConvertSecondsToTimeString(timetaken) << endl;
misc.UserMessagePrintStr(true,Message.str());
if(bIsOk)
return 0;
++++++ _service ++++++
--- /var/tmp/diff_new_pack.aRL0tY/_old 2022-02-17 00:31:46.461420437 +0100
+++ /var/tmp/diff_new_pack.aRL0tY/_new 2022-02-17 00:31:46.469420436 +0100
@@ -28,7 +28,7 @@
<param name="scm">git</param>
<param name="filename">A3700-utils-marvell</param>
<param name="versionformat">master</param>
- <param name="revision">2efdb10f3524c534d276002adf81fec06e0f1cf2</param>
+ <param name="revision">e733e9f139ff23c1b0346c6e89f5530a4c24db3b</param>
</service>
<service name="recompress" mode="disabled">
<param name="file">*A3700-utils-marvell*.tar</param>