1#!/vendor/bin/sh
2modules_dir=
3
4for f in /vendor/lib/modules/*/modules.dep /vendor/lib/modules/modules.dep; do
5  if [[ -f "$f" ]]; then
6    modules_dir="$(dirname "$f")"
7    break
8  fi
9done
10
11if [[ -z "${modules_dir}" ]]; then
12  echo "Unable to locate kernel modules directory" 2>&1
13  exit 1
14fi
15
16panel_drv=`getprop ro.boot.primary_panel_drv`
17if [[ -z "$panel_drv" ]]; then
18  panel_drv="panel-samsung-emul"
19fi
20modprobe -d "${modules_dir}" exynos-drm.ko
21modprobe -d "${modules_dir}" $panel_drv.ko
22
23