# HCF modem and x86_64

## error32

As far as I can tell there is no way to get a hcf modem to work when using a x86_64 kernel.

Is there perhaps anyone that could enlighten me how I might be able to do this?

I've been looking all over the place for a solution but all drivers seem to have a lib that is compiled for x86 and thus cannot be linked to x86_64.

----------

## DONAHUE

Have you tried it? As I am amd64 multilib and I see

 *Quote:*   

> oddman ~ # emerge --search hcf
> 
> Searching...   
> 
> [ Results for search key : hcf ]
> ...

 

and I think:

Run 

```
echo "net-dialup/hcfpcimodem **" >> /etc/portage/package.keywords

emerge -av hcfpcimodem
```

and if  ppp or slip (as required by isp) is in the kernel; see if I get lucky.

----------

## error32

I've done that but after I successfully emerge the hcfpcimodem the trouble starts.

Portage tells me to run `hcfpciconfig`

```

Conexant HCF controllerless PCI modem driver, version 1.18full

If you need license keys, assistance or more information, please go to:

        http://www.linuxant.com/

When reporting a problem for the first time, please send

us the file generated by "hcfpciconfig --dumpdiag".

No pre-built modules for: unknown-unknown linux-2.6.28-gentoo x86_64-SMP

Trying to automatically build the driver modules...

(this requires a C compiler and proper kernel sources to be installed)

Where is the linux source build directory that matches your running kernel?

[/lib/modules/2.6.28-gentoo/build] 

Building modules for kernel 2.6.28-gentoo, using source directory

/lib/modules/2.6.28-gentoo/build. Please wait...

ERROR: Module build failed!

Please examine the log file "/tmp/hcfpciconfig-buildlog.txt" to determine why.

```

```

error32@aldebaran ~ $ cat /tmp/hcfpciconfig-buildlog.txt 

Makefile:25: *** WARNING: Trying to compile kernel modules on a GenuineIntel system while the installed hcfpci driver package is for i386, this is likely to fail... ***

(cd /lib/modules/2.6.28-gentoo/build && make "CNXT_KERNELSRC=/lib/modules/2.6.28-gentoo/build" "M=/usr/lib64/hcfpcimodem/modules" "CC=gcc" clean)

make[1]: Entering directory `/usr/src/linux-2.6.28-gentoo'

/usr/lib64/hcfpcimodem/modules/Makefile:25: *** WARNING: Trying to compile kernel modules on a GenuineIntel system while the installed hcfpci driver package is for i386, this is likely to fail... ***

make[1]: Leaving directory `/usr/src/linux-2.6.28-gentoo'

rm -rf *.o GPL/*.o *.ko GPL/*.ko *.mod.c GPL/*.mod.c .*.cmd GPL/.*.cmd .tmp_versions .tmp_versions  /lib/modules/2.6.28-gentoo/build/.tmp_versions/hcfpciosspec.mod  /lib/modules/2.6.28-gentoo/build/.tmp_versions/hcfpciserial.mod  /lib/modules/2.6.28-gentoo/build/.tmp_versions/hcfpciengine.mod  /lib/modules/2.6.28-gentoo/build/.tmp_versions/hcfpcihw.mod Modules.symvers GPL/hda/Modules.symvers Module.symvers GPL/hda/Module.symvers modules.order GPL/hda/modules.order Module.markers GPL/hda/Module.markers

(cd /lib/modules/2.6.28-gentoo/build && make "CNXT_KERNELSRC=/lib/modules/2.6.28-gentoo/build" "M=/usr/lib64/hcfpcimodem/modules" "CC=gcc" modules)

make[1]: Entering directory `/usr/src/linux-2.6.28-gentoo'

/usr/lib64/hcfpcimodem/modules/Makefile:25: *** WARNING: Trying to compile kernel modules on a GenuineIntel system while the installed hcfpci driver package is for i386, this is likely to fail... ***

  CC [M]  /usr/lib64/hcfpcimodem/modules/mod_engine.o

  CC [M]  /usr/lib64/hcfpcimodem/modules/mod_hcfpci.o

  CC [M]  /usr/lib64/hcfpcimodem/modules/mod_osspec.o

In file included from /usr/lib64/hcfpcimodem/modules/mod_osspec.c:323:

/usr/lib64/hcfpcimodem/modules/imported/include/testdebug.h:181:2: warning: #warning FILEIDNUM not defined

  CC [M]  /usr/lib64/hcfpcimodem/modules/osservices.o

In file included from /usr/lib64/hcfpcimodem/modules/osservices.c:44:

/usr/lib64/hcfpcimodem/modules/imported/include/testdebug.h:181:2: warning: #warning FILEIDNUM not defined

/usr/lib64/hcfpcimodem/modules/osservices.c: In function 'OsInit':

/usr/lib64/hcfpcimodem/modules/osservices.c:1283: warning: format '%d' expects type 'int', but argument 2 has type 'long unsigned int'

/usr/lib64/hcfpcimodem/modules/osservices.c:1283: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'

/usr/lib64/hcfpcimodem/modules/osservices.c:1283: warning: format '%d' expects type 'int', but argument 2 has type 'long unsigned int'

/usr/lib64/hcfpcimodem/modules/osservices.c:1283: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'

  CC [M]  /usr/lib64/hcfpcimodem/modules/osstdio.o

In file included from /usr/lib64/hcfpcimodem/modules/osstdio.c:18:

/usr/lib64/hcfpcimodem/modules/include/osstdio.h:18:7: warning: "UK_MODE" is not defined

/usr/lib64/hcfpcimodem/modules/include/osstdio.h:18:18: warning: "UK_KERNEL" is not defined

In file included from /usr/lib64/hcfpcimodem/modules/osstdio.c:19:

/usr/lib64/hcfpcimodem/modules/imported/include/testdebug.h:181:2: warning: #warning FILEIDNUM not defined

  CC [M]  /usr/lib64/hcfpcimodem/modules/osnvm.o

In file included from /usr/lib64/hcfpcimodem/modules/osnvm.c:13:

/usr/lib64/hcfpcimodem/modules/include/osstdio.h:18:7: warning: "UK_MODE" is not defined

/usr/lib64/hcfpcimodem/modules/include/osstdio.h:18:18: warning: "UK_KERNEL" is not defined

In file included from /usr/lib64/hcfpcimodem/modules/osnvm.c:18:

/usr/lib64/hcfpcimodem/modules/imported/include/testdebug.h:181:2: warning: #warning FILEIDNUM not defined

/usr/lib64/hcfpcimodem/modules/osnvm.c: In function 'cnxthcf_NVM_Read':

/usr/lib64/hcfpcimodem/modules/osnvm.c:1005: warning: cast from pointer to integer of different size

  CC [M]  /usr/lib64/hcfpcimodem/modules/osresour.o

  CC [M]  /usr/lib64/hcfpcimodem/modules/osstring.o

  CC [M]  /usr/lib64/hcfpcimodem/modules/osmemory.o

  CC [M]  /usr/lib64/hcfpcimodem/modules/osdiag.o

  CC [M]  /usr/lib64/hcfpcimodem/modules/GPL/serial_cnxt.o

  LD [M]  /usr/lib64/hcfpcimodem/modules/hcfpciosspec.o

ld: Relocatable linking with relocations from format elf32-i386 (/usr/lib64/hcfpcimodem/modules/imported/hcfblam-i386.O) to format elf64-x86-64 (/usr/lib64/hcfpcimodem/modules/hcfpciosspec.o) is not supported

make[2]: *** [/usr/lib64/hcfpcimodem/modules/hcfpciosspec.o] Error 1

make[1]: *** [_module_/usr/lib64/hcfpcimodem/modules] Error 2

make[1]: Leaving directory `/usr/src/linux-2.6.28-gentoo'

make: *** [all] Error 2

```

----------

## gilcu3

first I run hsfconfig

```

rey-pc ~ # hsfconfig

Conexant HSF softmodem driver, version 7.80.02.04x86_64full

If you need license keys, assistance or more information, please go to:

   http://www.linuxant.com/

When reporrey-pc ~ # hsfconfig

Conexant HSF softmodem driver, version 7.80.02.04x86_64full

If you need license keys, assistance or more information, please go to:

   http://www.linuxant.com/

When reporting a problem for the first time, please send

us the file generated by "hsfconfig --dumpdiag".

No pre-built modules for: unknown-unknown linux-3.1.6-gentoo x86_64-SMP

Trying to automatically build the driver modules...

(this requires a C compiler and proper kernel sources to be installed)

Where is the linux source build directory that matches your running kernel?

[/lib/modules/3.1.6-gentoo/build] 

Building modules for kernel 3.1.6-gentoo, using source directory

/lib/modules/3.1.6-gentoo/build. Please wait...

ERROR: Module build failed!

Please examine the log file "/etc/hsfmodem/log/buildlog-20120126084113.txt" to determine why.

```

in the file /etc/hsfmodem/log/buildlog-20120126084113.txt

```

driver version 7.80.02.04x86_64full

Makefile:25: *** WARNING: Trying to compile kernel modules on a GenuineIntel system while the installed hsf driver package is for x86_64, this is likely to fail... ***

(cd /lib/modules/3.1.6-gentoo/build && make "CNXT_KERNELSRC=/lib/modules/3.1.6-gentoo/build" "M=/usr/lib64/hsfmodem/modules" "CC=gcc-4.4.4" clean)

make[1]: Entering directory `/usr/src/linux-3.1.6-gentoo'

/usr/lib64/hsfmodem/modules/Makefile:25: *** WARNING: Trying to compile kernel modules on a GenuineIntel system while the installed hsf driver package is for x86_64, this is likely to fail... ***

make[1]: Leaving directory `/usr/src/linux-3.1.6-gentoo'

(cd /lib/modules/3.1.6-gentoo/build && make "CNXT_KERNELSRC=/lib/modules/3.1.6-gentoo/build" "M=/usr/lib64/hsfmodem/modules/GPL/hda" "CC=gcc-4.4.4" "HDA_CFLAGS=-DFOUND_KZALLOC  -DFOUND_TLV   -DFOUND_IRQ_HANDLER_T -DFOUND_DELAYED_WORK  -DFOUND_NO_CTL_ELEM_RW" clean)

make[1]: Entering directory `/usr/src/linux-3.1.6-gentoo'

make[1]: Leaving directory `/usr/src/linux-3.1.6-gentoo'

rm -rf *.o GPL/*.o *.ko GPL/*.ko *.mod.c GPL/*.mod.c .*.cmd GPL/.*.cmd .tmp_versions .tmp_versions  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfosspec.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfserial.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfengine.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfpcibasic2.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfpcibasic3.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfmc97ich.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfmc97via.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfmc97ali.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfmc97ati.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfmc97sis.mod  /lib/modules/3.1.6-gentoo/build/.tmp_versions/hsfsoar.mod Modules.symvers GPL/hda/Modules.symvers Module.symvers GPL/hda/Module.symvers modules.order GPL/hda/modules.order Module.markers GPL/hda/Module.markers

(cd /lib/modules/3.1.6-gentoo/build && make "CNXT_KERNELSRC=/lib/modules/3.1.6-gentoo/build" "M=/usr/lib64/hsfmodem/modules" "CC=gcc-4.4.4" modules)

make[1]: Entering directory `/usr/src/linux-3.1.6-gentoo'

/usr/lib64/hsfmodem/modules/Makefile:25: *** WARNING: Trying to compile kernel modules on a GenuineIntel system while the installed hsf driver package is for x86_64, this is likely to fail... ***

  CC [M]  /usr/lib64/hsfmodem/modules/mod_engine.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_hda.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_mc97ali.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_mc97ati.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_mc97ich.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_mc97sis.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_mc97via.o

  CC [M]  /usr/lib64/hsfmodem/modules/mod_osspec.o

  CC [M]  /usr/lib64/hsfmodem/modules/osservices.o

In file included from /usr/lib64/hsfmodem/modules/osservices.c:20:

/usr/lib64/hsfmodem/modules/GPL/oscompat.h:201: error: 'SPIN_LOCK_UNLOCKED' undeclared here (not in a function)

/usr/lib64/hsfmodem/modules/osservices.c:51:28: error: linux/smp_lock.h: No such file or directory

/usr/lib64/hsfmodem/modules/osservices.c: In function 'cnxthsf_7800204x86_64full_OsAtomicCompareAndSwapEx':

/usr/lib64/hsfmodem/modules/osservices.c:307: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:307: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:309: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:309: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:311: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:311: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:313: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c:313: warning: initialization makes integer from pointer without a cast

/usr/lib64/hsfmodem/modules/osservices.c: In function 'cnxt_thread':

/usr/lib64/hsfmodem/modules/osservices.c:464: error: implicit declaration of function 'lock_kernel'

/usr/lib64/hsfmodem/modules/osservices.c:498: error: implicit declaration of function 'unlock_kernel'

/usr/lib64/hsfmodem/modules/osservices.c: In function 'OsInit':

/usr/lib64/hsfmodem/modules/osservices.c:1283: warning: format '%d' expects type 'int', but argument 2 has type 'long unsigned int'

/usr/lib64/hsfmodem/modules/osservices.c:1283: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int'

make[2]: *** [/usr/lib64/hsfmodem/modules/osservices.o] Error 1

make[1]: *** [_module_/usr/lib64/hsfmodem/modules] Error 2

make[1]: Leaving directory `/usr/src/linux-3.1.6-gentoo'

make: *** [all] Error 2

```

this is what hsfconfig --dumpdiag says

 *Quote:*   

> 
> 
> + hsfstop
> 
> + modprobe -v /dev/ttySHSF
> ...

 

----------

