在为嵌入式系统编译 Linux 内核时如何理解和修复错误

How do I understand and fix error while compiling Linux kernel for embedded system

在尝试编译以下文件时:

/*
 *  linux/arch/arm/mm/proc-syms.c
 *
 *  Copyright (C) 2000-2002 Russell King
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
 */
#include <linux/module.h>
#include <linux/mm.h>

#include <asm/cacheflush.h>
#include <asm/proc-fns.h>
#include <asm/tlbflush.h>
#include <asm/page.h>

#ifndef MULTI_CPU
EXPORT_SYMBOL(cpu_dcache_clean_area);
EXPORT_SYMBOL(cpu_set_pte_ext);
EXPORT_SYMBOL(cpu_tima_set_pte_ext);
#else
EXPORT_SYMBOL(processor);
#endif

#ifndef MULTI_CACHE
EXPORT_SYMBOL(__cpuc_flush_kern_all);
EXPORT_SYMBOL(__cpuc_flush_user_all);
EXPORT_SYMBOL(__cpuc_flush_user_range);
EXPORT_SYMBOL(__cpuc_coherent_kern_range);
EXPORT_SYMBOL(__cpuc_flush_dcache_area);
#else
EXPORT_SYMBOL(cpu_cache);
#endif

#ifdef CONFIG_MMU
#ifndef MULTI_USER
EXPORT_SYMBOL(__cpu_clear_user_highpage);
EXPORT_SYMBOL(__cpu_copy_user_highpage);
#else
EXPORT_SYMBOL(cpu_user);
#endif
#endif

/*
 * No module should need to touch the TLB (and currently
 * no modules do.  We export this for "loadkernel" support
 * (booting a new kernel from within a running kernel.)
 */
#ifdef MULTI_TLB
EXPORT_SYMBOL(cpu_tlb);
#endif

我收到以下错误:

arch/arm/mm/proc-syms.c:21:1: error: 'cpu_tima_set_pte_ext' undeclared here (not in a function)
make[1]: *** [arch/arm/mm/proc-syms.o] Error 1
make: *** [arch/arm/mm] Error 2

我真的很惊讶我收到这个错误。这是我从供应商那里下载的代码,我认为它不会有错误。有什么办法可以绕过这个错误吗?这是一个真正的错误,还是会在 link 阶段修复的错误?

@user58697 - 你这个家伙。谢谢。太感谢了。这是最快的答复和正确的。

根据要求:

这是一个已知问题。存在补丁(参见示例 here