Revert "[Feature][T8TSK-250][ADBD]add adb debug patch"
This reverts commit 0300fcc023c83b5b569b0c0799aff58cfd65dd39.
Reason for revert: <INSERT REASONING HERE>
Change-Id: I82e92daf5003f885c4732744291c57425ef27642
diff --git a/src/devtools/adb/transport_pcie.c b/src/devtools/adb/transport_pcie.c
index e06ff2b..d677587 100644
--- a/src/devtools/adb/transport_pcie.c
+++ b/src/devtools/adb/transport_pcie.c
@@ -103,17 +103,18 @@
static void remote_close(atransport *t)
{
- D("remote_close\n");
+ struct pcie_handle *pcie = t->pcie;
+
+ unix_close(pcie->fd);
+ pcie->fd = -1;
}
static void remote_kick(atransport *t)
{
struct pcie_handle *pcie = t->pcie;
- if (pcie->kick) {
- D("Enter pcie->kick\n");
+ if (pcie->kick)
pcie->kick(pcie);
- }
}
void init_pcie_transport(atransport *t, struct pcie_handle *h, const char *devpath, int state)
@@ -163,6 +164,7 @@
{
struct pcie_handle *pcie = (struct pcie_handle *)x;
int fd = -1;
+ char *banner = "Start PCIe port\n";
while (1) {
adb_mutex_lock(&pcie->lock);
@@ -170,16 +172,15 @@
adb_cond_wait(&pcie->notify, &pcie->lock);
adb_mutex_unlock(&pcie->lock);
- D("Try open pcie adbd port~\n");
do {
fd = unix_open(PCIE_ADB_PATH, O_RDWR);
if (fd < 0) {
adb_sleep_ms(1000);
}
} while (fd < 0);
- D("Open pcie adbd port success~\n");
pcie->fd = fd;
+ adb_write(fd, banner, strlen(banner));
/* Get PCIe config information */
fd = unix_open(PCIE_INFO_ADB_PATH, O_RDONLY);