1f607739cSSandrine Bailleux# 251d28937SAntonio Nino Diaz# Copyright (c) 2016-2018, ARM Limited and Contributors. All rights reserved. 3f607739cSSandrine Bailleux# 4f607739cSSandrine Bailleux# Redistribution and use in source and binary forms, with or without 5f607739cSSandrine Bailleux# modification, are permitted provided that the following conditions are met: 6f607739cSSandrine Bailleux# 7f607739cSSandrine Bailleux# Redistributions of source code must retain the above copyright notice, this 8f607739cSSandrine Bailleux# list of conditions and the following disclaimer. 9f607739cSSandrine Bailleux# 10f607739cSSandrine Bailleux# Redistributions in binary form must reproduce the above copyright notice, 11f607739cSSandrine Bailleux# this list of conditions and the following disclaimer in the documentation 12f607739cSSandrine Bailleux# and/or other materials provided with the distribution. 13f607739cSSandrine Bailleux# 14f607739cSSandrine Bailleux# Neither the name of ARM nor the names of its contributors may be used 15f607739cSSandrine Bailleux# to endorse or promote products derived from this software without specific 16f607739cSSandrine Bailleux# prior written permission. 17f607739cSSandrine Bailleux# 18f607739cSSandrine Bailleux# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 19f607739cSSandrine Bailleux# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 20f607739cSSandrine Bailleux# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 21f607739cSSandrine Bailleux# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 22f607739cSSandrine Bailleux# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23f607739cSSandrine Bailleux# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24f607739cSSandrine Bailleux# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 25f607739cSSandrine Bailleux# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 26f607739cSSandrine Bailleux# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 27f607739cSSandrine Bailleux# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 28f607739cSSandrine Bailleux# POSSIBILITY OF SUCH DAMAGE. 29f607739cSSandrine Bailleux# 30f607739cSSandrine Bailleux 31f607739cSSandrine Bailleux# 32f607739cSSandrine Bailleux# Configure how the Linux checkpatch script should be invoked in the context of 33f607739cSSandrine Bailleux# the Trusted Firmware source tree. 34f607739cSSandrine Bailleux# 35f607739cSSandrine Bailleux 36f607739cSSandrine Bailleux# This is not Linux so don't expect a Linux tree! 37f607739cSSandrine Bailleux--no-tree 38f607739cSSandrine Bailleux 39*90582e4dSAntonio Nino Diaz# The Linux kernel expects the SPDX license tag in the first line of each file. 40*90582e4dSAntonio Nino Diaz# We don't follow this in the Trusted Firmware. 41*90582e4dSAntonio Nino Diaz--ignore SPDX_LICENSE_TAG 42*90582e4dSAntonio Nino Diaz 43f607739cSSandrine Bailleux# This clarifes the lines indications in the report. 44f607739cSSandrine Bailleux# 45f607739cSSandrine Bailleux# E.g.: 46f607739cSSandrine Bailleux# Without this option, we have the following output: 47f607739cSSandrine Bailleux# #333: FILE: drivers/arm/gic/arm_gic.c:160: 48f607739cSSandrine Bailleux# So we have 2 lines indications (333 and 160), which is confusing. 49f607739cSSandrine Bailleux# We only care about the position in the source file. 50f607739cSSandrine Bailleux# 51f607739cSSandrine Bailleux# With this option, it becomes: 52f607739cSSandrine Bailleux# drivers/arm/gic/arm_gic.c:160: 53f607739cSSandrine Bailleux--showfile 54f607739cSSandrine Bailleux 5551d28937SAntonio Nino Diaz# Don't show some messages like the list of ignored types or the suggestion to 5651d28937SAntonio Nino Diaz# use "--fix" or report changes to the maintainers. 5751d28937SAntonio Nino Diaz--quiet 5851d28937SAntonio Nino Diaz 59f607739cSSandrine Bailleux# 60f607739cSSandrine Bailleux# Ignore the following message types, as they don't necessarily make sense in 61f607739cSSandrine Bailleux# the context of the Trusted Firmware. 62f607739cSSandrine Bailleux# 63f607739cSSandrine Bailleux 64f607739cSSandrine Bailleux# COMPLEX_MACRO generates false positives. 65f607739cSSandrine Bailleux--ignore COMPLEX_MACRO 66f607739cSSandrine Bailleux 67f607739cSSandrine Bailleux# Commit messages might contain a Gerrit Change-Id. 68f607739cSSandrine Bailleux--ignore GERRIT_CHANGE_ID 69f607739cSSandrine Bailleux 70f607739cSSandrine Bailleux# Do not check the format of commit messages, as Github's merge commits do not 71f607739cSSandrine Bailleux# observe it. 72f607739cSSandrine Bailleux--ignore GIT_COMMIT_ID 73f607739cSSandrine Bailleux 74f607739cSSandrine Bailleux# FILE_PATH_CHANGES reports this kind of message: 75f607739cSSandrine Bailleux# "added, moved or deleted file(s), does MAINTAINERS need updating?" 76f607739cSSandrine Bailleux# We do not use this MAINTAINERS file process in TF. 77f607739cSSandrine Bailleux--ignore FILE_PATH_CHANGES 78f607739cSSandrine Bailleux 79f607739cSSandrine Bailleux# AVOID_EXTERNS reports this kind of messages: 80f607739cSSandrine Bailleux# "externs should be avoided in .c files" 81f607739cSSandrine Bailleux# We don't follow this convention in TF. 82f607739cSSandrine Bailleux--ignore AVOID_EXTERNS 83f607739cSSandrine Bailleux 84f607739cSSandrine Bailleux# NEW_TYPEDEFS reports this kind of messages: 85f607739cSSandrine Bailleux# "do not add new typedefs" 86f607739cSSandrine Bailleux# We allow adding new typedefs in TF. 87f607739cSSandrine Bailleux--ignore NEW_TYPEDEFS 88f607739cSSandrine Bailleux 8951d28937SAntonio Nino Diaz# Avoid "Does not appear to be a unified-diff format patch" message 9051d28937SAntonio Nino Diaz--ignore NOT_UNIFIED_DIFF 9151d28937SAntonio Nino Diaz 92f607739cSSandrine Bailleux# VOLATILE reports this kind of messages: 93f607739cSSandrine Bailleux# "Use of volatile is usually wrong: see Documentation/volatile-considered-harmful.txt" 94f607739cSSandrine Bailleux# We allow the usage of the volatile keyword in TF. 95f607739cSSandrine Bailleux--ignore VOLATILE 96