]> git.ipfire.org Git - thirdparty/freeswitch.git/commit
[ftmod_misdn] Make misdn_handle_mph_information_ind() cope with hfcsusb-style MPH_INF...
authorStefan Knoblich <stkn@openisdn.net>
Tue, 7 Feb 2012 17:25:29 +0000 (18:25 +0100)
committerStefan Knoblich <stkn@openisdn.net>
Tue, 7 Feb 2012 17:39:11 +0000 (18:39 +0100)
commit810f0d4eaa4c9fc072fe8777a99086f2024d805a
tree3b480d57174a763f590c335b319dbc992bce9baa
parent452c13573d7c7a37fa8d877b51a07e4448d68ccd
[ftmod_misdn] Make misdn_handle_mph_information_ind() cope with hfcsusb-style MPH_INFORMATION_IND messages.

Only two mISDN hardware drivers emit MPH_INFORMATION_IND messages and both use a different payload:

- hfcsusb (HFC-based USB dongle) sends a set of ph_info + ph_info_ch structures
  which contain the complete state information of the port
  (including internal hw-specific state and flags).

- hfcmulti which sends a single integer, a single L1_SIGNAL_* event.

We now try to guess the type of message from the payload length.

The hfcmulti signals are converted to FreeTDM alarm flags; the hfcsusb
state/flags are defined in kernel internal hw-specific headers and are ignored ATM (todo).

Signed-off-by: Stefan Knoblich <stkn@openisdn.net>
libs/freetdm/src/ftmod/ftmod_misdn/ftmod_misdn.c