mps module compilation issue on FreeBSD-9 amd64

From: Desai, Kashyap <Kashyap.Desai_at_lsi.com>
Date: Mon, 30 Jan 2012 14:45:10 +0530
Hi,

I am seeing some uncommon problem while doing compilation of mps driver (this is a latest driver from LSI).

Here are the steps I followed.

CASE-1 

1. remove mps directory from sys/dev and sys/module and overwrite those two directories with my latest code.
2. go to sys/module/mps and run "make". [Things works fine.]

CASE-2.
1. remove mps directory from sys/dev and sys/module and overwrite those two directories with my latest code.
2. go to main directory ( In my case it is "/usr/trees/9.0.0")
3. Run below command 
make -j8 buildkernel KERNCONF=GENERIC MODULES_OVERRIDE=mps TARGET_ARCH=amd64 SYSDIR=/usr/trees/9.0.0/sys -DNO_CLEAN -DNO_KERNELCONFIG -DNO_KERNELCLEAN -DNO_KERNELDEPEND

Here I am seeing mps.ko file is generated, but it is failing at <linking kernel.debug> steps. (this step is only seen in CASE-1).
Any Idea How to resolve this issue ?

INFO: I am using FreeBSD-8.2-Release amd64.case-1 and case-2 both passes for i386. \\\\

--- Compilation failure log for CASE-2 ----

ld  -d -warn-common -r -d -o mpslsi.ko.debug mps_pci.o mps.o mps_sas.o mps_table.o mps_user.o mps_config.o mps_mapping.o mps_sas_lsi.o
:> export_syms
awk -f /usr/trees/9.0.0/sys/conf/kmod_syms.awk mpslsi.ko.debug  export_syms | xargs -J% objcopy % mpslsi.ko.debug
/usr/local/bin/svnversion
objcopy --only-keep-debug mpslsi.ko.debug mpslsi.ko.symbols
objcopy --strip-debug --add-gnu-debuglink=mpslsi.ko.symbols mpslsi.ko.debug mpslsi.ko
cc -c -O2 -frename-registers -pipe -fno-strict-aliasing  -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes  -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual  -Wundef -Wno-pointer-sign -fformat-extensions  -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc  -I. -I/usr/trees/9.0.0/sys -I/usr/trees/9.0.0/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=8000 --param inline-unit-growth=100 --param large-function-growth=1000  -fno-omit-frame-pointer -mno-sse -mcmodel=kernel -mno-red-zone -mno-mmx -msoft-float  -fno-asynchronous-unwind-tables -ffreestanding -fstack-protector -Werror  vers.c
linking kernel.debug
mps.o: In function `mps_startup':
/usr/trees/9.0.0/sys/dev/mps/mps.c:1249: undefined reference to `mps_mapping_initialize'
mps.o: In function `mps_free':
/usr/trees/9.0.0/sys/dev/mps/mps.c:1410: undefined reference to `mps_mapping_free_memory'
mps.o: In function `mps_attach':
/usr/trees/9.0.0/sys/dev/mps/mps.c:1204: undefined reference to `mps_base_static_config_pages'
/usr/trees/9.0.0/sys/dev/mps/mps.c:1224: undefined reference to `mpssas_ir_shutdown'
mps_sas.o: In function `mps_attach_sas':
/usr/trees/9.0.0/sys/dev/mps/mps_sas.c:614: undefined reference to `mpssas_firmware_event_work'
mps_sas.o: In function `mpssas_register_events':
/usr/trees/9.0.0/sys/dev/mps/mps_sas.c:576: undefined reference to `mpssas_evt_handler'
mps_sas.o: In function `mpssas_portenable_complete':
/usr/trees/9.0.0/sys/dev/mps/mps_sas.c:3069: undefined reference to `mps_wd_config_pages'
mps_user.o: In function `mps_user_btdh':
/usr/trees/9.0.0/sys/dev/mps/mps_user.c:2038: undefined reference to `mps_mapping_get_sas_id_from_handle'
mps_user.o: In function `mps_user_get_adapter_data':
/usr/trees/9.0.0/sys/dev/mps/mps_user.c:1101: undefined reference to `mps_config_get_bios_pg3'
*** Error code 1
1 error
*** Error code 2
1 error
*** Error code 2
1 error
Failed : make -j8 buildkernel KERNCONF=GENERIC MODULES_OVERRIDE=mps TARGET_ARCH=amd64 SYSDIR=/usr/trees/9.0.0/sys -DNO_CLEAN -DNO_KERNELCONFIG -DNO_KERNELCLEAN -DNO_KERNELDEPEND
Received on Mon Jan 30 2012 - 08:26:16 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:23 UTC