Removing watchdog and reset

Removing watchdog and firmware reset as a preparations for the
migrations to rpmsg.

Change-Id: Ic1053e3f4301ecadbde8c59dbaed437625a0a5ea
diff --git a/kernel/ethosu_mailbox.c b/kernel/ethosu_mailbox.c
index b5cde0d..870a4ef 100644
--- a/kernel/ethosu_mailbox.c
+++ b/kernel/ethosu_mailbox.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2020-2022 Arm Limited.
+ * Copyright 2020-2023 Arm Limited and/or its affiliates
  *
  * This program is free software and is provided to you under the terms of the
  * GNU General Public License version 2 as published by the Free Software
@@ -27,7 +27,6 @@
 #include "ethosu_buffer.h"
 #include "ethosu_core_interface.h"
 #include "ethosu_device.h"
-#include "ethosu_watchdog.h"
 
 #include <linux/jiffies.h>
 #include <linux/resource.h>
@@ -49,36 +48,6 @@
  * Functions
  ****************************************************************************/
 
-static void ethosu_wd_inc(struct ethosu_mailbox *mbox,
-			  enum ethosu_core_msg_type type)
-{
-	switch (type) {
-	case ETHOSU_CORE_MSG_PING:
-		mbox->ping_count++;
-		fallthrough;
-	case ETHOSU_CORE_MSG_INFERENCE_REQ:
-		ethosu_watchdog_inc(mbox->wdog);
-		break;
-	default:
-		break;
-	}
-}
-
-static void ethosu_wd_dec(struct ethosu_mailbox *mbox,
-			  enum ethosu_core_msg_type type)
-{
-	switch (type) {
-	case ETHOSU_CORE_MSG_PONG:
-		mbox->ping_count--;
-		fallthrough;
-	case ETHOSU_CORE_MSG_INFERENCE_RSP:
-		ethosu_watchdog_dec(mbox->wdog);
-		break;
-	default:
-		break;
-	}
-}
-
 static void ethosu_core_set_size(struct ethosu_buffer *buf,
 				 struct ethosu_core_buffer *cbuf)
 {
@@ -164,8 +133,6 @@
 	if (ret)
 		return ret;
 
-	ethosu_wd_inc(mbox, type);
-
 	return 0;
 }
 
@@ -278,8 +245,6 @@
 		return -EBADMSG;
 	}
 
-	ethosu_wd_dec(mbox, header->type);
-
 	return 0;
 }
 
@@ -321,22 +286,6 @@
 	}
 }
 
-void ethosu_mailbox_resend(struct ethosu_mailbox *mbox)
-{
-	struct ethosu_mailbox_msg *cur;
-	int id;
-	int ret;
-
-	idr_for_each_entry(&mbox->msg_idr, cur, id) {
-		ret = cur->resend(cur);
-		if (ret) {
-			dev_warn(mbox->dev, "Failed to resend msg. ret=%d",
-				 ret);
-			cur->fail(cur);
-		}
-	}
-}
-
 int ethosu_mailbox_ping(struct ethosu_mailbox *mbox)
 {
 	return ethosu_queue_write_msg(mbox, ETHOSU_CORE_MSG_PING, NULL, 0);
@@ -481,16 +430,13 @@
 			struct resource *in_queue,
 			struct resource *out_queue,
 			ethosu_mailbox_cb callback,
-			void *user_arg,
-			struct ethosu_watchdog *wdog)
+			void *user_arg)
 {
 	int ret;
 
 	mbox->dev = dev;
 	mbox->callback = callback;
 	mbox->user_arg = user_arg;
-	mbox->wdog = wdog;
-	mbox->ping_count = 0;
 	idr_init(&mbox->msg_idr);
 
 	mbox->client.dev = dev;