Re: Some various thoughts on PPP

2007-05-20 Thread Dan Williams
On Fri, 2007-05-18 at 14:27 +0300, Tambet Ingo wrote:
 On 5/18/07, Ulrik Mikaelsson [EMAIL PROTECTED] wrote:
  One of the things that eludes me though; how exactly are you
  envisioning the NM-dialing-connection process? From what I understand,
  you're planning to have NM itself dial, and then hand-over the
  connection to pppd, linked in to NM? Will this be carried out in a
  separate process, with DBUS-connection to the main process? Is this
  somehow supporting the desire to keep network-configuration
  centralized within the distribution, or will it require configuration
  separate from, say /etc/ppp/peers?
 
 NM uses a new device NMDeviceModem to dial out (in process) and starts
 pppd process. The dbus interface will remain the same as for all the
 other devices, just the activation structure will contain modem and
 ppp specific data. If we want (and probably do), we can add a new dbus
 interface for dialup devices (just like wired and wireless devices
 have their own device specific interface in addition to the standard
 device interface) that has additional status signals for better
 progress reporting (like, initializing modem, dialing, ...).
 pppd process will emit dbus signals (with help from a pppd plugin) so
 NM knows what's going on.
 
   That is yet not all, it also turns out HAL doesn't have any notion of
   modems so the best we can do for now is to get a list of HAL devices
   with capability serial and try to send some modem initialization
   strings and see if they respond. That is for the serial devices that
   actually show up in HAL at all. Most of the thinkpads have a modem
   that only works with proprietary HSF modem driver and these do not
   show up in HAL at all.
  Well, perhaps there's another quirk to it, as far as I understand,
  many modems expose several devices, for different uses. Especially,
  the GRPS-datacard I tested had three of them, one for the
  ppp-connection, one for chatting with the card simultaneously with the
  connection, querying signal strength and such, and one for to me
  unknown purposes. Somehow we'll gotta figure which is which. :)
 
 Yeah, this is unfortunate. Pretty much identical to the wireless
 situation until wpa_supplicant provided us with a standard interface.
 I guess for each of these multi-device card we'll have to write a
 NMDeviceModem subclass, ugh.

Most broadband cards I've seen have the first serial interface be the
actual data interface.  But that's not really helpful.  We may have to
create HAL fdi files to tell HAL about the different broadband cards and
phones and such.  But I think this can live in HAL, and we can just have
the .fdi files assign a property to the device to tag it as one we
can/should use, including the serial interface we care about.

Dan

___
NetworkManager-list mailing list
NetworkManager-list@gnome.org
http://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: Some various thoughts on PPP

2007-05-18 Thread Tambet Ingo
Hey,

On 5/17/07, Ulrik Mikaelsson [EMAIL PROTECTED] wrote:
[snip]
 Please jump in with your thoughts and ideas. I'm planning to attempt
 hacking some of this together, but I'd like to get some feedback
 first, to ensure I'm right on track. Also, if you're hacking on
 something related, please let me know so we don't waste a lot of good
 effort.

I am working on exactly that. It's been a very long journey since NM
was written for wired and wireless devices and adding a new device
type (modem) cleanly wasn't really possible (in NM 0.6 branch). After
a lot of rework that's gone in to svn trunk, the devices are more
abstract, the device activation takes an abstract NMConnection
structure for activation info (like IP configuration, wireless
security, modem options, ppp options), etc.

That's not where the pain ends, it turns out there are no modem
dialers that are usable for NM. There actually seem to be only two (at
least popular ones), wvdial and chat. wvdial is C++, has a bunch of
C++ dependencies and has no way to just dial without starting pppd
(which NM will need for general PPP support). chat isn't really a
dialer either. Pretty much all the other dialers seem to be just
frontends for these two. If anyone knows a dialer that would fit for
NM, please let me know, I'd love to throw away what I've come up with
so far.

That is yet not all, it also turns out HAL doesn't have any notion of
modems so the best we can do for now is to get a list of HAL devices
with capability serial and try to send some modem initialization
strings and see if they respond. That is for the serial devices that
actually show up in HAL at all. Most of the thinkpads have a modem
that only works with proprietary HSF modem driver and these do not
show up in HAL at all.

So it all has been surprisingly hard. For this last week I've been
working on the actual modem device and ppp interface for NM. The
current status is that NM is able to dial out and establish a serial
connection that is suitable for ppp. There's a wrapper that turns NM
activation structure NMConnection to PPP command line, starts pppd
with a special pppd plugin that'll report ppp events (like got IP
information, warnings, errors, etc). I'm planning to get all this to
svn next week. If you're interested in helping out, I would love to
answer any questions you have about it!

Tambet
___
NetworkManager-list mailing list
NetworkManager-list@gnome.org
http://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: Some various thoughts on PPP

2007-05-18 Thread Ulrik Mikaelsson
Thanks for the wrap-up. Gave me a great orientation of the current status. :)

One of the things that eludes me though; how exactly are you
envisioning the NM-dialing-connection process? From what I understand,
you're planning to have NM itself dial, and then hand-over the
connection to pppd, linked in to NM? Will this be carried out in a
separate process, with DBUS-connection to the main process? Is this
somehow supporting the desire to keep network-configuration
centralized within the distribution, or will it require configuration
separate from, say /etc/ppp/peers?

 I am working on exactly that. It's been a very long journey since NM
 was written for wired and wireless devices and adding a new device
 type (modem) cleanly wasn't really possible (in NM 0.6 branch). After
 a lot of rework that's gone in to svn trunk, the devices are more
 abstract, the device activation takes an abstract NMConnection
 structure for activation info (like IP configuration, wireless
 security, modem options, ppp options), etc.
I saw things in the commit-log. Great. :)

 That's not where the pain ends, it turns out there are no modem
 dialers that are usable for NM. There actually seem to be only two (at
 least popular ones), wvdial and chat. wvdial is C++, has a bunch of
 C++ dependencies and has no way to just dial without starting pppd
 (which NM will need for general PPP support). chat isn't really a
 dialer either. Pretty much all the other dialers seem to be just
 frontends for these two. If anyone knows a dialer that would fit for
 NM, please let me know, I'd love to throw away what I've come up with
 so far.


 That is yet not all, it also turns out HAL doesn't have any notion of
 modems so the best we can do for now is to get a list of HAL devices
 with capability serial and try to send some modem initialization
 strings and see if they respond. That is for the serial devices that
 actually show up in HAL at all. Most of the thinkpads have a modem
 that only works with proprietary HSF modem driver and these do not
 show up in HAL at all.
Well, perhaps there's another quirk to it, as far as I understand,
many modems expose several devices, for different uses. Especially,
the GRPS-datacard I tested had three of them, one for the
ppp-connection, one for chatting with the card simultaneously with the
connection, querying signal strength and such, and one for to me
unknown purposes. Somehow we'll gotta figure which is which. :)

 So it all has been surprisingly hard. For this last week I've been
 working on the actual modem device and ppp interface for NM. The
 current status is that NM is able to dial out and establish a serial
 connection that is suitable for ppp. There's a wrapper that turns NM
 activation structure NMConnection to PPP command line, starts pppd
 with a special pppd plugin that'll report ppp events (like got IP
 information, warnings, errors, etc). I'm planning to get all this to
 svn next week. If you're interested in helping out, I would love to
 answer any questions you have about it!
Sounds great! I'll definitely check it out.
___
NetworkManager-list mailing list
NetworkManager-list@gnome.org
http://mail.gnome.org/mailman/listinfo/networkmanager-list