--- /dev/null
+From 9c65e20b82cfd9e82b849b3140eec7b8c18922dc Mon Sep 17 00:00:00 2001
+From: Chris Dimich <Chris.Dimich@boundarydevices.com>
+Date: Mon, 13 Sep 2021 17:56:02 -0700
+Subject: [PATCH 1/1] start_isp.sh: fix NR_DEVICE_TREE_BASLER variable
+
+Also remove uneeded -lm option from run.sh script.
+
+Signed-off-by: Chris Dimich <Chris.Dimich@boundarydevices.com>
+---
+ imx/start_isp.sh | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/imx/start_isp.sh b/imx/start_isp.sh
+index 6daabc59c..250226935 100755
+--- a/imx/start_isp.sh
++++ b/imx/start_isp.sh
+@@ -7,7 +7,7 @@
+ #
+
+ RUNTIME_DIR="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
+-NR_DEVICE_TREE_BASLER=$(grep basler-camera-vvcam /sys/firmware/devicetree/base/soc@0/*/i2c@*/*/compatible -l | wc -l 2> /dev/null)
++NR_DEVICE_TREE_BASLER=$(grep basler-camera-vvcam `find /sys/firmware/devicetree/base/soc@0/ -name compatible | grep i2c` -l | wc -l 2> /dev/null)
+ NR_DEVICE_TREE_OV5640=$(grep ov5640 /sys/firmware/devicetree/base/soc@0/*/i2c@*/*/compatible -l | wc -l 2> /dev/null)
+
+ # check if the basler device has been enabled in the device tree
+@@ -21,13 +21,13 @@ if [ $NR_DEVICE_TREE_BASLER -eq 1 ]; then
+
+ # Default configuration for Basler daA3840-30mc: basler_4k
+ # Available configurations: basler_4k, basler_1080p60, basler_4khdr, basler_1080p60hdr
+- exec ./run.sh -c basler_4k -lm
++ exec ./run.sh -c basler_4k
+
+ elif [ $NR_DEVICE_TREE_OV5640 -eq 1 ]; then
+
+ # Default configuration for Basler daA3840-30mc: basler_1080p60
+ # Available configurations: basler_1080p60, basler_1080p60hdr
+- exec ./run.sh -c basler_1080p60 -lm
++ exec ./run.sh -c basler_1080p60
+
+ fi
+
+@@ -38,7 +38,7 @@ elif [ $NR_DEVICE_TREE_BASLER -eq 2 ]; then
+ cd $RUNTIME_DIR
+ # Default configuration for Basler daA3840-30mc: dual_basler_1080p60
+ # Available configurations: dual_basler_1080p60, dual_basler_1080p60hdr, dual_basler_1080p25hdr
+- exec ./run.sh -c dual_basler_1080p60 -lm
++ exec ./run.sh -c dual_basler_1080p60
+
+ else
+ # no device tree found exit with code no device or address
+--
+2.31.1
+
+++ /dev/null
-From 708f25cfe522df162c3e2c7c56cbe2f7000cb5e4 Mon Sep 17 00:00:00 2001
-From: Gary Bisson <gary.bisson@boundarydevices.com>
-Date: Mon, 14 Dec 2020 14:26:01 +0100
-Subject: [PATCH] start_isp.sh: fix test to be generic
-
-So that it works on EVK and any other i.MX 8M Plus platform.
-
-Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com>
----
- imx/start_isp.sh | 13 +++++--------
- 1 file changed, 5 insertions(+), 8 deletions(-)
-
-Index: isp-imx-4.2.2.13.0/imx/start_isp.sh
-===================================================================
---- isp-imx-4.2.2.13.0.orig/imx/start_isp.sh
-+++ isp-imx-4.2.2.13.0/imx/start_isp.sh
-@@ -9,6 +9,7 @@
- RUNTIME_DIR="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
- NR_DEVICE_TREE_BASLER=$(grep basler-camera-vvcam /sys/firmware/devicetree/base/soc@0/*/i2c@*/*/compatible -l | wc -l 2> /dev/null)
- NR_DEVICE_TREE_OV5640=$(grep ov5640 /sys/firmware/devicetree/base/soc@0/*/i2c@*/*/compatible -l | wc -l 2> /dev/null)
-+DMESG_BASLER=`dmesg | grep Basler`
-
- # check if the basler device has been enabled in the device tree
- if [ $NR_DEVICE_TREE_BASLER -eq 1 ]; then
-@@ -40,8 +41,15 @@ elif [ $NR_DEVICE_TREE_BASLER -eq 2 ]; t
- # Available configurations: dual_basler_1080p60, dual_basler_1080p60hdr, dual_basler_1080p25hdr
- exec ./run.sh -c dual_basler_1080p60 -lm
-
-+elif [ ! -z "$DMESG_BASLER" ]; then
-+
-+ echo "Starting isp_media_server for generic Basler"
-+
-+ cd $RUNTIME_DIR
-+ exec ./run.sh -c basler_1080p60
-+
- else
- # no device tree found exit with code no device or address
-- echo "No device tree found for Basler, check dtb file!" >&2
-+ echo "Basler camera not found!" >&2
- exit 6
- fi