--- zzzz-none-000/linux-4.9.279/drivers/mtd/ubi/attach.c 2021-08-08 06:38:54.000000000 +0000 +++ puma7-arm-6591-750/linux-4.9.279/drivers/mtd/ubi/attach.c 2023-02-08 10:58:13.000000000 +0000 @@ -19,6 +19,11 @@ */ /* + * Includes Intel Corporation's changes/modifications dated: 2017. + * Changed/modified portions - Copyright (c) 2017, Intel Corporation. + */ + +/* * UBI attaching sub-system. * * This sub-system is responsible for attaching MTD devices and it also @@ -89,7 +94,11 @@ #include #include "ubi.h" +#ifdef CONFIG_MTD_UBI_DEBUG static int self_check_ai(struct ubi_device *ubi, struct ubi_attach_info *ai); +#else +#define self_check_ai(ubi, ai) 0 +#endif #define AV_FIND BIT(0) #define AV_ADD BIT(1) @@ -1659,6 +1668,7 @@ return err; } +#ifdef CONFIG_MTD_UBI_DEBUG /** * self_check_ai - check the attaching information. * @ubi: UBI device description object @@ -1933,3 +1943,4 @@ dump_stack(); return -EINVAL; } +#endif /* CONFIG_MTD_UBI_DEBUG */