Add checkpatch configuration file

Capture checkpatch.pl command line arguments in .checkpatch The file
assumes some processing when used:
  - Lines starting with # shall be removed.
  - Shell variables have to be evaluated.

The above can be done when using bash like:
  checkpatch.pl $(eval echo $(sed 's/#.*//g; /^$/d' ".checkpatch"))

Note: the eval imposes a security risk as it will execute unknown code
from .checkpatch. A solution can be to replace variables with their
values like:
  sed 's/#.*//g; /^$/d' ".checkpatch"\
    | sed "s#\$CODESPELL_FILE#$CODESPELL_FILE#"

Signed-off-by: Gyorgy Szing <Gyorgy.Szing@arm.com>
Change-Id: I79ba6c2ee4db64acf4c53bb6b1b9731509aa83cc
diff --git a/.checkpatch b/.checkpatch
new file mode 100644
index 0000000..70887c3
--- /dev/null
+++ b/.checkpatch
@@ -0,0 +1,16 @@
+# Copyright (c) 2021-2022, Arm Limited and contributors. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
+
+# Checkpatch configuration for Trusted Services.
+
+--showfile
+#      Please set CODESPELL_FILE in the environment.
+--codespellfile="$CODESPELL_FILE"
+--codespell
+--ignore SPDX_LICENSE_TAG,PREFER_KERNEL_TYPES,USLEEP_RANGE,GERRIT_CHANGE_ID,FILE_PATH_CHANGES
+--no-tree
+--terse
+--strict
+--max-line-length=100