LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 09-02-2007, 09:02 AM   #1
jaroobarghi
LQ Newbie
 
Registered: Sep 2007
Distribution: Debian 4.0 (Etch)
Posts: 3

Rep: Reputation: 0
SM56, additional kernel and bad Synaptic!!!


Hi!

My Synaptic is has stopped functioning properly, my system has an additional useless kernel and my modem is totally on vacation!!!

Everything started with the modem. In Windows, it's installed as Motorola SM56 Speakerphone Modem, and I was thinking that that's the chipset of my modem and therefore, I was searching SM56 drivers for Linux. But later, I've downloaded the Scanmodem utility from Linmodems, which recognized it as INTEL537.

When I was searching for SM56 drivers, I found that a driver for 2.6.x kernels could not be easily found, and almost all the drivers are for 2.4.x kernels. Except one which was for fedora, and doesn't fit me. (I use Debian etch, with kernel 2.6.18.) After a lot of searching, I found a program called "projeto-messias-sm56" (from Sourceforge); which allows the installation of SM56 drivers for 2.6.x kernels. Actually, it adds a 2.4 kernel named 2.4.22-6is to system, and installs the driver on it. It leaves the system with two kernels!
Some problems occurred during the installation of the package. I felt that it was frozen at the middle of installation process. So I logged off, shut down and started my system again. I tried to open Synaptic to see whether the package is installed or not, but an error message pops up before showing the packages list; saying that the package need too be reinstalled, but no archives could be found!

------------------------------
An Error occurred

The following details are provided:

E: The package projeto-messias-sm56 needs to be reinstalled, but I can't find an archive for it.
E: Internal error opening cache (1). Please report.

------------------------------

When I pressed OK, the error message closed, but no package list was displayed!
I closed Synaptic and reinstalled the package, which installed with some errors. I opened Synaptic again. This time the list of packages displayed and the projeto-messias-sm56 was also shown as installed. But since its installation was with errors, I decided to remove and then install it again. When I tried to remove the package in Synaptic, it said that first it should be reinstalled. (trying with aptitude itself and dpkg also returns the same error.)


remove:

Code:
dpkg: error processing projeto-messias-sm56 (--remove):
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting a removal.
Errors were encountered while processing:
 projeto-messias-sm56
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:
Press return to continue.

purge:
Code:
dpkg: error processing projeto-messias-sm56 (--purge):
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting a removal.
Errors were encountered while processing:
 projeto-messias-sm56
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:
Press return to continue.

dpkg --force-all didn't work too!


dpkg --force-all -r:

Code:
aitch:/home/sia# dpkg --force-all -r projeto-messias-sm56
dpkg - warning, overriding problem because --force enabled:
 Package is in a very bad inconsistent state - you should
 reinstall it before attempting a removal.
(Reading database ... 320356 files and directories currently installed.)
Removing projeto-messias-sm56 ...
mv: cannot stat `/etc/X11/XF86Config-4-backup': No such file or directory
dpkg: error processing projeto-messias-sm56 (--remove):
 subprocess pre-removal script returned error exit status 1
Voc  tem o dialog instalado.





dpkg: error while cleaning up:
 subprocess post-installation script returned error exit status 255
Errors were encountered while processing:
 projeto-messias-sm56

Now when I try to reinstall it...:


dpkg -i:

Code:
aitch:/mnt/temp/Download/linux# dpkg -i projeto-messias-sm56_0.4beta5.deb
Selecting previously deselected package projeto-messias-sm56.
(Reading database ... 320357 files and directories currently installed.)
Preparing to replace projeto-messias-sm56 0.4beta5 (using projeto-messias-sm56_0.4beta5.deb) ...
mv: cannot stat `/etc/X11/XF86Config-4-backup': No such file or directory
dpkg: warning - old pre-removal script returned error exit status 1
dpkg - trying script from the new package instead ...
mv: cannot stat `/etc/X11/XF86Config-4-backup': No such file or directory
dpkg: error processing projeto-messias-sm56_0.4beta5.deb (--install):
 subprocess new pre-removal script returned error exit status 1
Voc  tem o dialog instalado.





dpkg: error while cleaning up:
 subprocess post-installation script returned error exit status 255
Errors were encountered while processing:
 projeto-messias-sm56_0.4beta5.deb

(dpkg --force-all -i returns the same)

Does anyone have an idea how do I get rid of this package? or at least fix the Synaptic?
The more important for me, is the problem of Synaptic; which seems that can't be used anymore. Because everytime I open it, that annoying error of "The package projeto-messias-sm56 needs to be reinstalled..." appears, and even after closing it, the packages list isn't displayed. The Search also doesn't find anything. When I click Refresh, a page shows up with progressbar that says it's downloading the list of packages, but even after that I can't see any packages, and the Search also doesn't work. When I click Refresh again, another error is displayed saying the package index or repository isn't available!

------------------------------
Could not download all repository indexes

The repository might be no longer available or could not be contacted because of network problems. If available an older version of the failed index will be used. Otherwise the repository will be ignored. Check your network connection and the correct writing of the repository address in the preferences.

------------------------------

And when I click on OK...

------------------------------
An Error occurred

The following details are provided:

E: The package projeto-messias-sm56 needs to be reinstalled, but I can't find an archive for it.
E: Internal error opening cache (1). Please report.
E: Unable to lock the list directory

------------------------------
(Similar to the first error)

But when I open software-properties program, all the mediums of packages are checked.

Why doesn't Synaptic find the packages? Is there some way to make it ignore that error? I really don't understand why doesn't it display the other packager just because of one package being corrupted!
and another thing! Does the additional kernel installed with the package make my system unstable? how do I remove it? Is it loaded during booting? Can this be the reason for problems in uninstallation of the package? (...since the kernel comes with that package, and can't be removed when it's loaded, or something like this?) Is there any way to disable and prevent it from booting?...

Here is the list of fies installed by the package projeto-messias-sm56_0.4beta5.deb:

/boot/config-2.4.22-6is
/boot/initrd-sm56.gz
/boot/module-info-2.4.22-6is
/boot/System.map-2.4.22-6is
/boot/vmlinuz-2.4.22-6is
/dev/modem -> /dev/sm56
/dev/sm56
/initrd/sysroot/
/lib/modules/2.4.22-6is/
/lib/modules/2.4.22-6is/[...]
/usr/bin/aterm-pm
/usr/bin/dialog-pm
/usr/bin/nedit-pm
/usr/bin/sndconfig-pm
/usr/bin/Xdialog-pm
/usr/include/dialog.h-pm
/usr/local/bin/projeto_messias/
/usr/local/bin/projeto_messias/[...]
/usr/local/bin/sudo-verificar_2
/usr/share/applnk/Internet/Projeto Messias/
/usr/share/applnk/Internet/Projeto Messias/[...]
/usr/share/gnome/apps/Internet/Projeto Messias/
/usr/share/gnome/apps/Internet/Projeto Messias/[...]
/var/projeto-messias/
/var/projeto-messias/[...]

Any solution?

I had another problem, and that was during compiling the INTEL537 driver. Since there was no precompiled version of the driver for Debian on the Intel's site, I had to compile the driver from source myself. The instructions say that after extracting the package, you should run "make clean", "make 537", and "make install" respectively in the created directory in order to compile and install the driver.

The first step seems to be done without any errors:


make clean:

Code:
aitch:/home/sia/intel-537EP_secure-2.60.80.1# make clean
cd coredrv; make clean
make[1]: Entering directory `/home/sia/intel-537EP_secure-2.60.80.1/coredrv'
rm -f *.ko *.o *~ core
make[1]: Leaving directory `/home/sia/intel-537EP_secure-2.60.80.1/coredrv'
rm -f *.o *.ko

But the second step failes and returns: "Failed to build driver."


make 537:

Code:
aitch:/home/sia/intel-537EP_secure-2.60.80.1# make 537
   Module precompile check
   Current running kernel is: 2.6.18-4-686
   /lib/modules...   autoconf.h exists
diff: /boot/vmlinuz.autoconf.h: No such file or directory
   autoconf.h matches running kernel
diff: /boot/vmlinuz.version.h: No such file or directory
   version.h matches running kernel
2.6.18-4-686
make[1]: Entering directory `/home/sia/intel-537EP_secure-2.60.80.1/coredrv'
make -C /lib/modules/2.6.18-4-686/build SUBDIRS=/home/sia/intel-537EP_secure-2.60.80.1/coredrv modules
make[2]: Entering directory `/usr/src/linux-headers-2.6.18-4-686'
  CC [M]  /home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.o
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:70: warning: data definition has no type or storage class
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:70: warning: type defaults to ‘int’ in declaration of 

‘EXPORT_SYMBOL_NOVERS’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:70: warning: parameter names (without types) in function 

declaration
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘softcore_init_struct’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:336: warning: assignment from incompatible pointer type
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘open’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:394: warning: implicit declaration of function 

‘pm_register’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:395: warning: assignment makes pointer from integer 

without a cast
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘close’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:416: warning: implicit declaration of function 

‘pm_unregister’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘send_data_to_user’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:563: error: ‘struct tty_struct’ has no member named 

‘flip’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:568: error: ‘struct tty_struct’ has no member named 

‘flip’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:569: error: ‘struct tty_struct’ has no member named 

‘flip’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:571: error: ‘struct tty_struct’ has no member named 

‘flip’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:572: error: ‘struct tty_struct’ has no member named 

‘flip’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:573: error: ‘struct tty_struct’ has no member named 

‘flip’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: At top level:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:641: error: expected ‘)’ before string constant
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘hamproc_write’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:660: warning: ignoring return value of ‘copy_from_user’, 

declared with attribute warn_unused_result
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: At top level:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:754: warning: initialization from incompatible pointer 

type
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:755: warning: initialization from incompatible pointer 

type
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘kScheduleDPC’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:861: warning: implicit declaration of function 

‘pm_access’
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c: In function ‘dspdrv_CommRamISR’:
/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.c:877: warning: function declaration isn’t a prototype
make[3]: *** [/home/sia/intel-537EP_secure-2.60.80.1/coredrv/coredrv.o] Error 1
make[2]: *** [_module_/home/sia/intel-537EP_secure-2.60.80.1/coredrv] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-2.6.18-4-686'
make[1]: *** [537core_26] Error 2
make[1]: Leaving directory `/home/sia/intel-537EP_secure-2.60.80.1/coredrv'
2.6.18-4-686
Failed to build driver

The kernel sources are installed on my system.

I took a look at the makefile; which returns this error, but I can't understand much of it!


makefile:

Code:
all:
	@echo usage: make [clean] or [install] or [check] or [config_sync] or [uninstall] or [537]

clean:
	cd coredrv; make clean
	rm -f *.o *.ko

install:
	rm -f /etc/hamregistry.bin
	bash 537_inst

uninstall:
	@echo Uninstalling on system V boot like only.
	@rm -f /etc/init.d/537_boot
	@rm -f /etc/hamregistry.bin
	@rm -f /usr/sbin/usrsound
	@rm -f /usr/sbin/hamregistry
	@rmmod Intel537 || echo
	@rmmod 537.o >/dev/null 2>&1 || echo
	@rmmod 537_core.o >/dev/null 2>&1 || echo
	@rm -f `find /lib/modules -name Intel537.o`
	@rm -f `find /lib/modules -name Intel537.ko`
	@killall usrsound || echo
	@echo Uninstalling done.

check:
	@bash config_check

config_sync:
	mv /lib/modules/`uname -r`/build/include/linux/version.h version.bak
	mv /lib/modules/`uname -r`/build/include/linux/autoconf.h autoconf.bak
	cp /boot/vmlinuz.version.h /lib/modules/`uname -r`/build/include/linux/version.h
	cp /boot/vmlinuz.autoconf.h /lib/modules/`uname -r`/build/include/linux/autoconf.h

537: check
	@uname -r|grep "2.6" && \
	cd coredrv && make 537core_26 && \
	cp Intel537.ko .. && cd .. && \
	strip --strip-debug Intel537.ko && \
	exit; \
	ls Intel537.ko >/dev/null 2>&1 || uname -r | grep "2.6" && echo "Failed to build driver" && exit; \
	if [ $(KERNEL_SOURCE_PATH) ]; then \
	cd coredrv; make TARGET=TARGET_CATAWBA KERNEL_SOURCE_PATH=$(KERNEL_SOURCE_PATH) "PSTN_DEF=-DTARGET_CATAWBA 

-DTARGET_LINUX -DLINUX" 537core; \
	else \
	cd coredrv; make TARGET=TARGET_CATAWBA KERNEL_INCLUDES=/lib/modules/`uname -r`/build/include \
       "PSTN_DEF=-DTARGET_CATAWBA -DTARGET_LINUX -DLINUX" 537core; \
        fi ; \
	cp Intel537.o .. ; \
	if [ -a /boot/vmlinuz.version.h ]; then \
        cp /boot/vmlinuz.version.h /lib/modules/`uname -r`/build/include/linux/version.h;\
        fi

...and here is the "config_check" file. (which is referred to in the "check" section of the file above):
(I'm not sure whether it's useful or not, but I put it here to be available if needed.)


config_check:

Code:
KERNVER=`uname -r`

echo "   Module precompile check"
echo "   Current running kernel is: $KERNVER"


if [ -a /lib/modules/$KERNVER/build/include/linux/autoconf.h ]; then
   echo "   /lib/modules...   autoconf.h exists"
else
   echo "   /lib/modules...   autoconf.h does not exist"
   echo "   please install kernel source"
   exit 1
fi

if [ "`diff /boot/vmlinuz.autoconf.h /lib/modules/$KERNVER/build/include/linux/autoconf.h`" \
    == "" ]; then
   echo "   autoconf.h matches running kernel"
else
   echo "***************  WARNING *************************"
   echo  The autoconf.h file you are about to compile with 
   echo  is different than the configuration               
   echo  of the current running kernel: $KERNVER
   echo  Modules compiled and loaded with a configuration 
   echo  different than then current running kernel may 
   echo  cause your system to CRASH!
   echo "**************************************************"
   echo " "
   echo  You will need to syncronize the kernel and build 
   echo  configurations to create a functional driver for this kernel.
   echo  call \"make config_sync\" and this script will
   echo  copy the file /boot/vmlinuz.autoconf.h to 
   echo  /lib/modules/$KERNVER/build/include/linux/autoconf.h
   echo  and backup the original autoconf.h as autoconf.bak
   echo  The same will be done for version.h
   echo  Then repeat the build and installation procedure over again.
   exit 2
fi

if [ "`diff /boot/vmlinuz.version.h /lib/modules/$KERNVER/build/include/linux/version.h`" == "" \
 ]; then
   echo "   version.h matches running kernel"
else
   echo "***************** WARNING ************************"
   echo  The version.h file you are about to compile with
   echo  is different than the version of the current
   echo  running kernel: $KERNVER
   echo  Modules compiled and loaded with a different
   echo  version of kernel headers than the current running
   echo  kernel may cause your system to CRASH!
   echo "**************************************************"
   echo " "
   echo  You will need to syncronize the kernel and build 
   echo  configurations to create a functional driver for this kernel.
   echo  call \"make config_sync\" and this script will
   echo  copy the file /boot/vmlinuz.version.h to 
   echo  /lib/modules/$KERNVER/build/include/linux/version.h
   echo  and backup the original version.h as version.bak
   echo  The same will be done for autoconf.h
   echo  Then repeat the build and installation procedure over again.
   exit 3
fi

exit 0

Please tell me if more information is needed.
Thanks again in advance to anyone who helps me with any of these problems.
And finally, execuse my English if it wasn't't so fluent.
 
Old 09-05-2007, 08:36 AM   #2
jaroobarghi
LQ Newbie
 
Registered: Sep 2007
Distribution: Debian 4.0 (Etch)
Posts: 3

Original Poster
Rep: Reputation: 0
I'm still waiting for the reply...
Someone please help! (at list with the Synaptic problem!)

Excuse me for posting twice and probably spamming!
 
Old 04-07-2008, 03:33 PM   #4
jaroobarghi
LQ Newbie
 
Registered: Sep 2007
Distribution: Debian 4.0 (Etch)
Posts: 3

Original Poster
Rep: Reputation: 0
Thanks anyway for the reply; but I have already tried that link, and none of them do support 2.6.x kernels.
 
  


Reply

Tags
intel, modem, motorola, sm56, synaptic, winmodem


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
custom kernel -- additional driver deadlinx Ubuntu 2 09-14-2006 04:36 AM
'Bad' signatures on additional repositories very irritating Mad Malc Suse/Novell 3 09-09-2006 12:05 PM
Motorola SM56 PCI Modem Driver for Fedora Core 2(Kernel-2.6.5) ppvinod Linux - Hardware 3 03-22-2005 12:54 PM
synaptic crashes when 'marking additional changes' nadroj Linux - Software 2 03-14-2005 12:07 AM
SM56 Modem drivers from www.sm56.tk voodoochild117 Linux - Hardware 1 06-19-2003 05:35 PM


All times are GMT -5. The time now is 05:04 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration