[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT + New FC2

2004-06-21 Thread RUAUDEL Frédéric

Hi all,

Following some problems with my ADSL connection, I installed the new 
drivers 1.3 on my FC2. I found a great improvement with this version, so 
thanks Benoit ! :)

After that, I updated my RPM of speedtouch to version 1.3 and take 
advantage of the new improvements.

* Sun Jun 20 2004 Frederic RUAUDEL [EMAIL PROTECTED] 1.3-2.GrumZ
- Patch the speedtouch-start script to clean the mutex created by
modem_run and to skip running modem_run if the firmware is already loaded
- Patch the location of pppd pid in speedtouch-stop
- Remove the startadsl.sh script
- Modify the adsl init script to use speedtouch-start/speedtouch-stop
- Add the configuration file speedtouch.conf with the good values
- Remove the creation of /etc/speedtouch.conf in %post section
- Modify the configure line in the %build section to set the good 
default path
to avoid having the buildroot set in the speedtouch-(start|stop) script

As you can see, I've had to patch the start/stop script to make it works 
smoothly on my FC2. Here are the details :

1) speedtouch_clean_mutex.patch

This patch fix a problem with the new mutex system of modem_run. When 
you stop modem_run, the mutex is not cleaned so when you try to start it 
up again, modem_run just print in /var/log/messages :

modem_run version 1.3 started by root uid 0

and then stop without any clue ! After looking at the code I found that 
it was the mutex deadbeef ;-)
So I had an ipcrm in the speedtouch-start script but this is a dirty 
hack and I think, if this is a bug and not a feature, that benoit will 
certainly find a better solution :)

2) speedtouch_check_firmware_load.patch

this patch check the state of the ADSL line present in the file 
/proc/net/atm/speedtch*, and if the line is reported up and the firmware 
loaded, it skip the launch of modem_run and directly launch pppd instead 
of failing the load of the firmware and quit.

3) speedtouch_fix_pppd_pid.patch

the last one is probably FC2 specific or maybe a missing configuration 
in my pppd package, but my pppd put its PID in /var/run/ppp0.pid and not 
in /var/run/ppp-${PPPD_PEER}.pid. So I made this patch to make it work 
with my current RPMS.
Feel free to tell me where I'm wrong, if I am.

For other changes, I remove my startadsl.sh script and use the 
speedtouch-(start|stop) instead and generate a good default 
speedtouch.conf for the firmware that I provide with my package. The 
hotplug support works very well for me, another great feature added in 
1.3 (I know it's not new, but I never manage to configure it manually ;).

And I added a friendly interface to my RPMs repository with a summary of 
the things to do to installed my RPMS :

http://grumz.dyndns.org/ADSL_FC2

Comments and feedback are welcome !

Have a nice day,

Fred

Benoit PAPILLAULT wrote:

=
PLEASE, read the file INSTALL or INSTALL.fr in the package to know how 
to install it. It is VERY different from previous release (and hopefully 
a lot easier).
==



A i586 rpm package and source package are now available. Those packages 
have been compiled on a Mandrake 10.0 system with a Pentium II processor.

They are available on the Sourceforge Project Filelist:
http://sourceforge.net/project/showfiles.php?group_id=32758

I'd like to have reports from Mandrake users (and other RPM based 
distro) about their success (failure?) to use it.

Benoit PAPILLAULT

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]

   

  



-- Attached file included as plaintext by Listar --
-- File: speedtouch_fix_pppd_pid.patch

diff -ru speedtouch-1.3/src/speedtouch-stop.in speedtouch.new2/src/speedtouch-stop.in
--- speedtouch-1.3/src/speedtouch-stop.in   2004-06-10 18:36:35.0 +0200
+++ speedtouch.new2/src/speedtouch-stop.in  2004-06-20 13:04:42.241448448 +0200
@@ -32,8 +32,10 @@
 fi
 
 
-PID=`head -1 /var/run/ppp-${PPPD_PEER}.pid`
-kill -TERM $PID
+if [ -f /var/run/ppp0.pid ]; then
+PID=`head -1 /var/run/ppp0.pid`
+kill -TERM $PID
+fi
 
 # like we said in speedtouch-start, we don't ever kill modem_run
 # killall modem_run


-- Attached file included as plaintext by Listar --
-- File: speedtouch_clean_mutex.patch

diff -ru speedtouch-1.3/src/speedtouch-start.in 
speedtouch-1.3.new/src/speedtouch-start.in
--- speedtouch-1.3/src/speedtouch-start.in  2004-06-10 18:36:35.0 +0200
+++ speedtouch-1.3.new/src/speedtouch-start.in  2004-06-20 12:30:16.679461600 +0200
@@ -18,6 +18,12 @@
   exit -1
 fi
 
+# cleaning the mutex
+ipcs -a | grep 0xdeadbeef /dev/null 21
+if [ $? = 0 ]; then
+   ipcrm -S 0xdeadbeef
+fi
+
 echo Starting ADSL connection...
 
 # load usbcore if needed


-- Attached file included as plaintext by Listar --
-- File: speedtouch_check_firmware_load.patch

diff -ru speedtouch-1.3.new/src/speedtouch-start.in 

[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT + New FC2

2004-06-21 Thread Benoit PAPILLAULT

Hi Frédéric!

RUAUDEL Frédéric a écrit :

 Hi all,
 
 Following some problems with my ADSL connection, I installed the new 
 drivers 1.3 on my FC2. I found a great improvement with this version, so 
 thanks Benoit ! :)
 
 After that, I updated my RPM of speedtouch to version 1.3 and take 
 advantage of the new improvements.
 
 * Sun Jun 20 2004 Frederic RUAUDEL [EMAIL PROTECTED] 1.3-2.GrumZ
 - Patch the speedtouch-start script to clean the mutex created by
 modem_run and to skip running modem_run if the firmware is already loaded
 - Patch the location of pppd pid in speedtouch-stop
 - Remove the startadsl.sh script
 - Modify the adsl init script to use speedtouch-start/speedtouch-stop
 - Add the configuration file speedtouch.conf with the good values
 - Remove the creation of /etc/speedtouch.conf in %post section
 - Modify the configure line in the %build section to set the good 
 default path
 to avoid having the buildroot set in the speedtouch-(start|stop) script
 
 As you can see, I've had to patch the start/stop script to make it works 
 smoothly on my FC2. Here are the details :
 
 1) speedtouch_clean_mutex.patch
 
 This patch fix a problem with the new mutex system of modem_run. When 
 you stop modem_run, the mutex is not cleaned so when you try to start it 
 up again, modem_run just print in /var/log/messages :

You undo my change in a way. The mutex is designed to be kept in memory 
forever (you can remove it if the modem is unplugged, but this currently 
lead to some race conditions, so it's never removed). If you remove it, 
speedtouch-start will not work properly (if your stop the connection 
with speedtouch-stop and start it again using speedtouch-start, the 
mutex prevents modem_run from loading the firmware again).

 
 modem_run version 1.3 started by root uid 0
 
 and then stop without any clue ! After looking at the code I found that 
 it was the mutex deadbeef ;-)
 So I had an ipcrm in the speedtouch-start script but this is a dirty 
 hack and I think, if this is a bug and not a feature, that benoit will 
 certainly find a better solution :)

What is important is the exit code from modem_run, 0 indicates that the 
line is OK and -1 indicates that there is some problem.

 2) speedtouch_check_firmware_load.patch
 
 this patch check the state of the ADSL line present in the file 
 /proc/net/atm/speedtch*, and if the line is reported up and the firmware 
 loaded, it skip the launch of modem_run and directly launch pppd instead 
 of failing the load of the firmware and quit.

Redundant with the modem_run's mutex.

 
 3) speedtouch_fix_pppd_pid.patch
 
 the last one is probably FC2 specific or maybe a missing configuration 
 in my pppd package, but my pppd put its PID in /var/run/ppp0.pid and not 
 in /var/run/ppp-${PPPD_PEER}.pid. So I made this patch to make it work 
 with my current RPMS.
 Feel free to tell me where I'm wrong, if I am.

Two pid files are generated by pppd:
/var/run/pppN.pid
/var/run/ppp-${PPPD_PEER}.pid [only if you use the link option in your 
peer file).

The later is easier to locate if you have multiple PPP connections at 
the same time.

 
 For other changes, I remove my startadsl.sh script and use the 
 speedtouch-(start|stop) instead and generate a good default 
 speedtouch.conf for the firmware that I provide with my package. The 
 hotplug support works very well for me, another great feature added in 
 1.3 (I know it's not new, but I never manage to configure it manually ;).

Yes. The hotplug is really a nice feature :-)
I impressed some of my friends... since it's not possible to have such 
feature under Windows (for instance).

 
 And I added a friendly interface to my RPMs repository with a summary of 
 the things to do to installed my RPMS :
 
 http://grumz.dyndns.org/ADSL_FC2
 
 Comments and feedback are welcome !
 
 Have a nice day,
 
 Fred

Benoit PAPILLAULT

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]




[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT + New FC2

2004-06-21 Thread RUAUDEL Frédéric


Thanks for your feedback.

Benoit PAPILLAULT wrote:

 Hi Frédéric!

 RUAUDEL Frédéric a écrit :

*snip*

 
 1) speedtouch_clean_mutex.patch

 This patch fix a problem with the new mutex system of modem_run. When
 you stop modem_run, the mutex is not cleaned so when you try to start it
 up again, modem_run just print in /var/log/messages :


You undo my change in a way. The mutex is designed to be kept in memory 
forever (you can remove it if the modem is unplugged, but this currently 
lead to some race conditions, so it's never removed). If you remove it, 
speedtouch-start will not work properly (if your stop the connection 
with speedtouch-stop and start it again using speedtouch-start, the 
mutex prevents modem_run from loading the firmware again).
  


So, it's a feature ;-)

Maybe it could be helpful to had a message indicating that modem_run 
found that the firmware was already loaded and skip its work. After 
reflexion, I maybe found this solution following a false problem, 
because my first RPM have replaced my peer file so my login wasn't set 
and the connection failed. As I didn't notice that first, maybe I was 
disturbed by this behavior. If I have time, I will try to investigate on 
this problem to see if it was a false issue or not.

But my solution works thanks to the redundant patch :)

modem_run version 1.3 started by root uid 0

and then stop without any clue ! After looking at the code I found that 
it was the mutex deadbeef ;-)
So I had an ipcrm in the speedtouch-start script but this is a dirty 
hack and I think, if this is a bug and not a feature, that benoit will 
certainly find a better solution :)



What is important is the exit code from modem_run, 0 indicates that the 
line is OK and -1 indicates that there is some problem.

  

2) speedtouch_check_firmware_load.patch

this patch check the state of the ADSL line present in the file 
/proc/net/atm/speedtch*, and if the line is reported up and the firmware 
loaded, it skip the launch of modem_run and directly launch pppd instead 
of failing the load of the firmware and quit.



Redundant with the modem_run's mutex.

  

3) speedtouch_fix_pppd_pid.patch

the last one is probably FC2 specific or maybe a missing configuration 
in my pppd package, but my pppd put its PID in /var/run/ppp0.pid and not 
in /var/run/ppp-${PPPD_PEER}.pid. So I made this patch to make it work 
with my current RPMS.
Feel free to tell me where I'm wrong, if I am.



Two pid files are generated by pppd:
/var/run/pppN.pid
/var/run/ppp-${PPPD_PEER}.pid [only if you use the link option in your 
peer file).

The later is easier to locate if you have multiple PPP connections at 
the same time.

  

I didn't know this link option that's why I made this patch, but I was 
conscious of the problem with multiple PPP connections. So you just had 
to put 'link' alone on a new line in the peer file to make it works ?
If its the case I will fix my RPM ASAP.

*snip*

Benoit PAPILLAULT

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]

   
  

Fred

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]




[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT + New FC2

2004-06-21 Thread Gilles Espinasse

Selon RUAUDEL Frédéric [EMAIL PROTECTED]:
snip
 3) speedtouch_fix_pppd_pid.patch
 
 the last one is probably FC2 specific or maybe a missing configuration 
 in my pppd package, but my pppd put its PID in /var/run/ppp0.pid and not 
 in /var/run/ppp-${PPPD_PEER}.pid. So I made this patch to make it work 
 with my current RPMS.
 Feel free to tell me where I'm wrong, if I am.
 
 
 
 Two pid files are generated by pppd:
 /var/run/pppN.pid
 /var/run/ppp-${PPPD_PEER}.pid [only if you use the link option in your 
 peer file).
 
 The later is easier to locate if you have multiple PPP connections at 
 the same time.
 
   
 
 I didn't know this link option that's why I made this patch, but I was 
 conscious of the problem with multiple PPP connections. So you just had 
 to put 'link' alone on a new line in the peer file to make it works ?
 If its the case I will fix my RPM ASAP.
 
This is 
linkname myname
It will create /var/run/ppp-myname.pid 

Gilles

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]




[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT + New FC2

2004-06-21 Thread RUAUDEL Frédéric

*snip*

This is 
linkname myname
It will create /var/run/ppp-myname.pid 

  

Ok thanks ! I will fix this in my RPM and discard the patch

Gilles

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]

   

  


Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]




[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT

2004-06-18 Thread Le Banni

- Original Message - 
From: Benoit PAPILLAULT [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, June 15, 2004 2:32 PM
Subject: [speedtouch] Re: New driver version 1.3: ANNOUNCEMENT


 Right. A new driver has been released. There are still some minor bugs
 (like yours) and the http://speedtouch.sourceforge.net/ site has not
 been updated yet.

Hello,
Just to say I installed from last CVS on Slackware-current with a Speedtouch
USB modem (the green skate) and everything went fine.
Eric.


Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]




[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT

2004-06-16 Thread Benoit PAPILLAULT

 =
 PLEASE, read the file INSTALL or INSTALL.fr in the package to know how 
 to install it. It is VERY different from previous release (and hopefully 
 a lot easier).
 ==

A i586 rpm package and source package are now available. Those packages 
have been compiled on a Mandrake 10.0 system with a Pentium II processor.

They are available on the Sourceforge Project Filelist:
http://sourceforge.net/project/showfiles.php?group_id=32758

I'd like to have reports from Mandrake users (and other RPM based 
distro) about their success (failure?) to use it.

Benoit PAPILLAULT

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]




[speedtouch] Re: New driver version 1.3: ANNOUNCEMENT

2004-06-15 Thread Benoit PAPILLAULT

Jorge -Educanet- a écrit :
 Hello speedtouch,
 
   i found a new driver version 1.3 for SpeedTouch USB ADSL
 
   http://sourceforge.net/project/showfiles.php?group_id=32758package_id=28264
 
   Trying install in Fedora Core 2 i found a minibug in the speedtouch-setup
 script.

Right. A new driver has been released. There are still some minor bugs 
(like yours) and the http://speedtouch.sourceforge.net/ site has not 
been updated yet.

=
PLEASE, read the file INSTALL or INSTALL.fr in the package to know how 
to install it. It is VERY different from previous release (and hopefully 
a lot easier).
==

The following changes have been made:

- Linux hotplug support: you can now connect/disconnect to the Internet 
simply by pluging in the modem or unplugging it.

- Easier setup: You can still manually configure all files, however 
there is a script speedtouch-setup which take care of everything (nearly).

- PPPoE support : The driver had support for PPPoE, but now the 
configuration script can be use to configure it! Simply run : 
speedtouch-setup --pppoe

- Compilation can be done in directories containing spaces.

- The -e 1 option to pppoa3 is no longer needed since it's done by 
default. This option is harmless on older revision of speedtouch modem. 
So, from now on, all the modem revision can be used in the same way!

- Firmwares are now easily downloadable from the Thomson site in one 
.zip file. Look at : http://www.speedtouch.com/driver_upgrade_lx_3.0.1.2.htm

- Man pages have been updated and section renamed according to Debian 
policy. The following man pages are available : modem_run(8), pppoa2(8), 
pppoa3(8), speedtouch-setup(1), speedtouch-start(1) and speedtouch-stop(1).

Known bugs:

- All the scripts have not been tested under BSD! So, under those OS, 
you can still use the manual method. If you are using BSD, please 
contact the developpers for beta testing!

Happy SpeedTouch!

Benoit PAPILLAULT

PS: Jorge, thanks for your report. Your patch will be modified and 
integrated in CVS.

Liste de diffusion modem ALCATEL SpeedTouch USB
Pour se désinscrire : mailto:[EMAIL PROTECTED]