I am having some difficulty in a power file, and I can't see to resolve the issue. I am very new to programming, since I haven't done it since high school with VB. I am helping someone out with a android kernel development under 2.6.39 and most things are going well except we (and by that I mean me) are stuck on this
Error
CC arch/arm/mach-tegra/board-ventana-power.o
arch/arm/mach-tegra/board-ventana-power.c:110: error: variable 'sm0_config' has initializer but incomplete type
arch/arm/mach-tegra/board-ventana-power.c:111: error: unknown field 'sm_pwm_mode' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:111: error: 'PWM_DEFAULT_VALUE' undeclared here (not in a function)
arch/arm/mach-tegra/board-ventana-power.c:111: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:111: warning: (near initialization for 'sm0_config')
arch/arm/mach-tegra/board-ventana-power.c:112: error: unknown field 'slew_rate' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:112: error: 'SLEW_RATE_3520UV_PER_SEC' undeclared here (not in a function)
arch/arm/mach-tegra/board-ventana-power.c:112: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:112: warning: (near initialization for 'sm0_config')
arch/arm/mach-tegra/board-ventana-power.c:115: error: variable 'sm1_config' has initializer but incomplete type
arch/arm/mach-tegra/board-ventana-power.c:120: error: unknown field 'sm_pwm_mode' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:120: error: 'PWM_ONLY' undeclared here (not in a function)
arch/arm/mach-tegra/board-ventana-power.c:120: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:120: warning: (near initialization for 'sm1_config')
arch/arm/mach-tegra/board-ventana-power.c:121: error: unknown field 'slew_rate' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:121: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:121: warning: (near initialization for 'sm1_config')
arch/arm/mach-tegra/board-ventana-power.c:161: error: unknown field 'start' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:161: error: extra brace group at end of initializer
arch/arm/mach-tegra/board-ventana-power.c:161: error: (near initialization for 'rtc_data')
arch/arm/mach-tegra/board-ventana-power.c:165: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:165: warning: (near initialization for 'rtc_data')
arch/arm/mach-tegra/board-ventana-power.c:166: error: unknown field 'cl_sel' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:166: error: 'TPS6586X_RTC_CL_SEL_1_5PF' undeclared here (not in a function)
arch/arm/mach-tegra/board-ventana-power.c:167: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:167: warning: (near initialization for 'rtc_data')
arch/arm/mach-tegra/board-ventana-power.c:198: error: 'TPS6586X_INT_BASE' undeclared here (not in a function)
arch/arm/mach-tegra/board-ventana-power.c:201: error: 'TPS6586X_GPIO_BASE' undeclared here (not in a function)
arch/arm/mach-tegra/board-ventana-power.c:212: warning: 'enum suspend_stage' declared inside parameter list
arch/arm/mach-tegra/board-ventana-power.c:212: warning: its scope is only this definition or declaration, which is probably not what you want
arch/arm/mach-tegra/board-ventana-power.c:212: error: parameter 2 ('stg') has incomplete type
arch/arm/mach-tegra/board-ventana-power.c: In function 'ventana_board_suspend':
arch/arm/mach-tegra/board-ventana-power.c:214: error: 'TEGRA_SUSPEND_BEFORE_CPU' undeclared (first use in this function)
arch/arm/mach-tegra/board-ventana-power.c:214: error: (Each undeclared identifier is reported only once
arch/arm/mach-tegra/board-ventana-power.c:214: error: for each function it appears in.)
arch/arm/mach-tegra/board-ventana-power.c:215: error: implicit declaration of function 'tegra_console_uart_suspend'
arch/arm/mach-tegra/board-ventana-power.c: At top level:
arch/arm/mach-tegra/board-ventana-power.c:218: warning: 'enum resume_stage' declared inside parameter list
arch/arm/mach-tegra/board-ventana-power.c:218: error: parameter 2 ('stg') has incomplete type
arch/arm/mach-tegra/board-ventana-power.c: In function 'ventana_board_resume':
arch/arm/mach-tegra/board-ventana-power.c:220: error: 'TEGRA_RESUME_AFTER_CPU' undeclared (first use in this function)
arch/arm/mach-tegra/board-ventana-power.c:221: error: implicit declaration of function 'tegra_console_uart_resume'
arch/arm/mach-tegra/board-ventana-power.c: At top level:
arch/arm/mach-tegra/board-ventana-power.c:236: error: unknown field 'board_suspend' specified in initializer
#'error_mark' not supported by pp_c_direct_abstract_declarator#)'arch/arm/mach-tegra/board-ventana-power.c:236: error: incompatible types when initializing type 'enum tegra_suspend_mode' using type
arch/arm/mach-tegra/board-ventana-power.c:237: error: unknown field 'board_resume' specified in initializer
arch/arm/mach-tegra/board-ventana-power.c:237: warning: excess elements in struct initializer
arch/arm/mach-tegra/board-ventana-power.c:237: warning: (near initialization for 'ventana_suspend_data')
arch/arm/mach-tegra/board-ventana-power.c: In function 'ventana_regulator_init':
arch/arm/mach-tegra/board-ventana-power.c:249: error: implicit declaration of function 'tegra_spare_fuse'
arch/arm/mach-tegra/board-ventana-power.c: At top level:
arch/arm/mach-tegra/board-ventana-power.c:273: error: 'AC_PRESENT_GPIO' undeclared here (not in a function)
make[1]: *** [arch/arm/mach-tegra/board-ventana-power.o] Error 1
make: *** [arch/arm/mach-tegra] Error 2
And here is the code
http://pastebin.com/0V752tu7
Related
I am trying the static compilation with Python3.6.2 and cross-compiling for android. And nmake threw following exceptions when running:
Python\formatter_unicode.c: In function 'get_locale_info':
Python\formatter_unicode.c:711:53: error: 'struct lconv' has no member named 'decimal_point'
locale_data->decimal_point,
^
Python\formatter_unicode.c:716:53: error: 'struct lconv' has no member named 'thousands_sep'
locale_data->thousands_sep,
^
Python\formatter_unicode.c:720:44: error: 'struct lconv' has no member named 'grouping'
locale_info->grouping = locale_data->grouping;
^
Makefile:14273: recipe for target '.obj\formatter_unicode.obj' failed
nmake: *** [.obj\formatter_unicode.obj] Error 1
I've googled a lot but almost nothing practical was found so far. I didn't understand what happened at all although I saw the source code(I just knew a little about C/C++).
Could anyone give some of suggestions to me?
Thank you in advance.
whenever i try to compile the samsung stock 4.4.2 kernel i m getting this error
CC arch/arm/mach-msm/board-8930-display.o
arch/arm/mach-msm/board-8930-display.c: In function 'mipi_dsi2lvds_cdp_panel_power':
arch/arm/mach-msm/board-8930-display.c:577:3: error: implicit declaration of function 'msm_xo_get' [-Werror=implicit-function-declaration]
arch/arm/mach-msm/board-8930-display.c:577:26: error: 'MSM_XO_TCXO_A1' undeclared (first use in this function)
arch/arm/mach-msm/board-8930-display.c:577:26: note: each undeclared identifier is reported only once for each function it appears in
arch/arm/mach-msm/board-8930-display.c:663:3: error: implicit declaration of function 'msm_xo_mode_vote' [-Werror=implicit-function-declaration]
arch/arm/mach-msm/board-8930-display.c:663:31: error: 'MSM_XO_MODE_ON' undeclared (first use in this function)
arch/arm/mach-msm/board-8930-display.c:671:31: error: 'MSM_XO_MODE_OFF' undeclared (first use in this function)
cc1: some warnings being treated as errors
make[1]: *** [arch/arm/mach-msm/board-8930-display.o] Error 1
make: *** [arch/arm/mach-msm] Error 2 }
this is the lines the terminal pointed to in board-8930-display.c
rfa_clock = msm_xo_get (MSM_XO_TCXO_A1, id); /create a handle for Aq buffer of XO/
msm_xo_mode_vote(rfa_clock, MSM_XO_MODE_ON); /Vote to turn ON the clock buffer/
3.msm_xo_mode_vote(rfa_clock, MSM_XO_MODE_OFF); /Vote to turn OFF the clock buffer/
how can this be fixed ?
I made a port from a kernel from 4.1 to 4.4, but I get this errors, I know that this error is by the linker, but I have no idea about where find the error because these files are already compiled, sorry for my bad english, this is the comand and the result in the terminal, thanks in advance:
richy#richy-Aspire-V5-572P:~/Lollipop/kernel/mt_4.4$ make -k ARCH=arm zImage
CHK include/linux/version.h
CHK include/generated/utsrelease.h
make[1]: 'include/generated/mach-types.h' is up to date.
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
GEN .version
CHK include/generated/compile.h
UPD include/generated/compile.h
CC init/version.o
LD init/built-in.o
LD .tmp_vmlinux1
drivers/built-in.o:felica_gpio.c:function felica_remove: warning: relocation refers to discarded section
drivers/built-in.o:felica_gpio.c:function felica_remove: warning: relocation refers to discarded section
arch/arm/mach-k3v2/built-in.o:iomux.c:function get_active_block_table.part.0: error: undefined reference to 'g_current_board_id'
arch/arm/mach-k3v2/built-in.o:k3v2_clocks_init_data_cs_60M.c:function iomux_debug_show: error: undefined reference to 'g_current_board_id'
arch/arm/mach-k3v2/built-in.o:k3v2_clocks_init_data_cs_60M.c:function iomux_debug_set: error: undefined reference to 'g_current_board_id'
arch/arm/mach-k3v2/built-in.o:k3v2_clocks_init_data_cs_60M.c:function pmulowpower: error: undefined reference to 'get_battery_removable'
arch/arm/mach-k3v2/built-in.o:k3v2_clocks_init_data_cs_60M.c:function pmulowpower: error: undefined reference to 'get_battery_removable'
arch/arm/mach-k3v2/built-in.o:k3v2_clocks_init_data_cs_60M.c:function pmulowpowerall: error: undefined reference to 'get_battery_removable'
arch/arm/mach-k3v2/built-in.o:k3v2_clocks_init_data_cs_60M.c:function pmulowpowerall: error: undefined reference to 'get_battery_removable'
arch/arm/mach-k3v2/built-in.o:board-k3v2oem1.c:wl18xx_device: error: undefined reference to 'wilink_pdata'
drivers/built-in.o:mipi_jdi_OTM1282B.c:function mipi_jdi_panel_off: error: undefined reference to 'rmi_f01_glove_switch_read'
drivers/built-in.o:mipi_jdi_OTM1282B.c:function mipi_jdi_panel_off: error: undefined reference to 'rmi_fc'
drivers/built-in.o:es305.c:function es305_set_pathid: error: undefined reference to 'is_smartpa_support'
drivers/built-in.o:synaptics_SO340010.c:function synaptics_thread_irq_handler: error: undefined reference to 'time_finger_up'
drivers/built-in.o:synaptics_SO340010.c:function synaptics_thread_irq_handler: error: undefined reference to 'touch_is_pressed'
drivers/built-in.o:felica_gpio.c:function felica_remove: warning: relocation refers to discarded section
drivers/built-in.o:modemctl.c:function modemctl_init: error: undefined reference to 'is_modem_switch_support'
drivers/built-in.o:mipi_jdi_OTM1282B.c:function jdi_probe: error: undefined reference to 'get_touchkey_enable'
drivers/built-in.o:hi6421-regulator.c:function hi6421_regulator_probe: error: undefined reference to 'get_pmu_out26m_enable'
drivers/built-in.o:synaptics_SO340010.c:function touchkey_probe: error: undefined reference to 'get_touchkey_enable'
Makefile:907: recipe for target '.tmp_vmlinux1' failed
make: *** [.tmp_vmlinux1] Error 1
make: Target 'zImage' not remade because of errors.
I read somewhere about this and I fix it, just I've added the definition of these variables or functions, cause the "extern"s don't works for itselfs, i.e.
for the line:
arch/arm/mach-k3v2/built-in.o:iomux.c:function get_active_block_table.part.0: error: undefined reference to 'g_current_board_id'
just is add to the file iomux.c the global
"type" g_current_board_id;
or in the case of functions:
"type" functionname(type args) {}
and that is all
i am new in android ndk and i m making connection of java and c/c++ code and at last moment when i use ndk-build command then i got this error.
please help me to clear this problem.
I am working on ubuntu 12.04. and i got same error on both linux and windows and on windows i use using cygwin.
Error-
/home/saicomputer/android-ndk-r8e/build/core/add-application.mk:128: Android NDK: WARNING: APP_PLATFORM android-14 is larger than android:minSdkVersion 8 in ./AndroidManifest.xml
Compile thumb : myjni <= native.c
jni/native.c: In function 'Java_com_example_demo_MainActivity_hello':
jni/native.c:4:3: error: parameter name omitted
jni/native.c:4:3: error: parameter name omitted
jni/native.c:5:10: error: 'env' undeclared (first use in this function)
jni/native.c:5:10: note: each undeclared identifier is reported only once for each function it appears in
jni/native.c: In function 'Java_com_example_demo_MainActivity_add':
jni/native.c:9:3: error: parameter name omitted
jni/native.c:9:3: error: parameter name omitted
jni/native.c:9:3: error: parameter name omitted
jni/native.c:9:3: error: parameter name omitted
jni/native.c:10:9: error: 'value1' undeclared (first use in this function)
jni/native.c:10:18: error: 'value2' undeclared (first use in this function)
make: *** [obj/local/armeabi/objs/myjni/native.o] Error 1
please help me out to overcome this problem.
thanks.
something i should mention that i add fuse support to the kernel,and it prompt such error duing make:
CC drivers/char/goldfish_tty.o
drivers/char/goldfish_tty.c: In function 'goldfish_tty_probe':
drivers/char/goldfish_tty.c:233: error: 'IO_START' undeclared (first use in this function)
drivers/char/goldfish_tty.c:233: error: (Each undeclared identifier is reported only once
drivers/char/goldfish_tty.c:233: error: for each function it appears in.)
make[2]: * [drivers/char/goldfish_tty.o] Error 1
make[1]: [drivers/char] Error 2
make: ** [drivers] Error 2