Hi: Thanks to your previous help, I have been able to get my winmodem Smartlink SM56 to work at least partially on my x86_64 laptop (with a 64 bit kernel). However, some tweaks were necessary : 1. The slmodem package fails to compile properly from scratch because * the Makefile forgets to uses the -m32 option to force compilation in 32 bit (necessary because of needed ld with 32 bit blobs) * the slamr driver which is pure 32 bit cannot be compiled on a a 64 bit machine, and so the Makefile should disable this automatically. I enclose a Makefile which includes this test. 2. After tweaking as in 1), compilation of slmodemd in 32bit mode is successful and I could call slmodem -c FRANCE --alsa hw:0,6 (as this seems to be appropriate in my case). Then device /dev/ttySL0 is created However, when trying using to use the modem, I first got an error period size 48 not supported by playback (64) (already reported by many people). Things improved a lot by using the "Hell labs patch" enclosed - it seems that a test fax (class 1) was succesfully sent. Maybe the change should be implemented in the next iteration of slmodemd and enabled/disabled through the use of an ad hoc option. I also got French Minitel (V23 mode) almost working - the initializing escape code is probably still not OK as the echo of keys was garbled. In addition, there is not sound on dialing - maybe the hell labs patch simply disables error after failure of using ALSA. Alsa support obviously has to be fixed for SM56 on 64 bit machines. Here is where I am - it seems pretty close to be made to work, but not there yet ! Regards, Jean-Pierre Demailly
########################################################################### # # # Makefile -- modem kernel drivers Makefile. # # Copyright(c) 2003, Smart Link Ltd. (www.smlink.com) # All rights reserved. # # Author: Sasha K (sashak@xxxxxxxxxx) # # ########################################################################### # ########################################################################### #KBUILD_VERBOSE=1 #export KBUILD_VERBOSE KERNEL_DIR:=/lib/modules/$(shell uname -r)/build EXTRA_CFLAGS = -I$(obj) -I$(obj)/../modem ARCH64:=$(shell uname -m | sed -e '/amd64/s//x86_64/' | grep -c x86_64) ifeq ($(ARCH64), 0) obj-m:= slamr.o slusb.o else obj-m:= slusb.o endif slamr-objs:= amrmo_init.o sysdep_amr.o amrlibs.o slusb-objs:= st7554.o ifndef KERNELRELEASE ifndef KERNEL_VER all install uninstall: kernel-ver $(MAKE) $@ KERNEL_VER=$(shell ./kernel-ver) install: install-devices uninstall: remove-devices kernel-ver:: $(CC) -I$(KERNEL_DIR)/include -o $@ $@.c dep: clean: $(RM) kernel-ver $(obj-m) $(obj-m:.o=.ko) *st7554.o amrmo_init.o sysdep_amr.o *.mod.* .*.cmd *~ $(RM) -r .tmp_versions install-devices: mkdir -p ${DESTDIR}/dev $(foreach minor,0 1 2 3, \ mknod -m 600 ${DESTDIR}/dev/slamr$(minor) c 242 $(minor) ; ) echo -n $(foreach minor,0 1 2 3, \ mknod -m 600 ${DESTDIR}/dev/slusb$(minor) c 243 $(minor) ; ) echo -n remove-devices: $(foreach minor,0 1 2 3, \ $(RM) ${DESTDIR}/dev/slamr$(minor) ; ) echo -n $(foreach minor,0 1 2 3, \ $(RM) ${DESTDIR}/dev/slusb$(minor) ; ) echo -n else ifeq ($(findstring 2.4,$(KERNEL_VER)),2.4) slusb-objs:= old_st7554.o obj:=. module-dir:=${DESTDIR}/lib/modules/$(KERNEL_VER)/misc CFLAGS:= -Wall -pipe -O3 -fomit-frame-pointer -D__KERNEL__ -DMODULE -DEXPORT_SYMTAB -DMODVERSIONS --include $(KERNEL_DIR)/include/linux/modversions.h -I$(KERNEL_DIR)/include all: $(obj-m) slamr.o: $(slamr-objs) slusb.o: $(slusb-objs) slamr.o slusb.o: $(LD) -r -o $@ $^ install: uninstall-old ifeq ($(ARCH64), 0) install -D -m 644 slamr.o $(module-dir)/slamr.o endif install -D -m 644 slusb.o $(module-dir)/slusb.o cp /etc/modules.conf /etc/modules.conf.slamr && \ echo 'alias char-major-242 slamr' >> /etc/modules.conf && \ echo 'alias char-major-243 slusb' >> /etc/modules.conf /sbin/depmod -a uninstall: /sbin/modprobe -r slamr slusb cp /etc/modules.conf /etc/modules.conf.slamr && \ egrep -ve 'alias char-major-242 slamr|alias char-major-243 slusb' /etc/modules.conf.slamr > /etc/modules.conf $(RM) $(module-dir)/slamr.o $(RM) $(module-dir)/slusb.o /sbin/depmod -a uninstall-old: $(RM) $(module-dir)/slmdm.o \ $(module-dir)/slfax.o \ $(module-dir)/slusb.o \ $(module-dir)/slamrmo.o \ $(module-dir)/slmodem.o # remove old 2.7,2.8 version %.o: %.c $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -o $@ -c $< else module-dir:=${DESTDIR}/lib/modules/$(KERNEL_VER)/extra all: $(MAKE) modules -C $(KERNEL_DIR) SUBDIRS=$(shell pwd) install: ifeq ($(ARCH64), 0) install -D -m 644 slamr.ko $(module-dir)/slamr.ko endif install -D -m 644 slusb.ko $(module-dir)/slusb.ko /sbin/depmod -a uninstall: ifeq ($(ARCH64), 0) modprobe -r slamr ; echo -n endif modprobe -r slusb ; echo -n $(RM) $(module-dir)/slamr.ko $(RM) $(module-dir)/slusb.ko /sbin/depmod -a endif endif endif $(obj)/amrlibs.o: echo "$@ done"
diff -rud slmodem-2.9.11-20060727-orig/modem/modem_main.c slmodem-2.9.11-20060727/modem/modem_main.c --- slmodem-2.9.11-20060727-orig/modem/modem_main.c 2005-09-22 10:05:27.000000000 -0300 +++ slmodem-2.9.11-20060727/modem/modem_main.c 2007-07-10 14:37:33.000000000 -0300 @@ -379,7 +379,7 @@ ERR("cannot set periods for %s: %s\n", stream_name, snd_strerror(err)); return err; } - if ( rsize != size ) { + if ( rsize < size ) { ERR("period size %ld is not supported by %s (%ld).\n", size, stream_name, rsize); return -1;