From 12058f5c95e9dbfddea2c0dc8d1a9f32b6d431b5 Mon Sep 17 00:00:00 2001 From: Tzafrir Cohen Date: Thu, 16 Oct 2008 17:40:22 +0000 Subject: xpp: start migration from procfs to sysfs. * Sysfs representation for XPDs: /sys/bus/xpds/devices/:: * Astribanks sysfs directories now include the XPDs as subdirectories: e.g. /sys/bus/astribanks/devices/xbus-00/00:3:0 * procfs control interface deprecated: conditioned by OLD_PROC (defaults to off). Control functionality moved to sysfs: * xbus attributes: cls connector label status timing waitfor_xpds xbus_state * XPDs can have driver-specific attributes. Common attriubtes: blink chipregs span * PRI-specific attributes: pri_clocking pri_dchan pri_cas pri_alarms pri_layer1 pri_localloop pri_protocol * The Astribank attribute "xbus_state" is read/write. Reading it shows the current state of the Astribank. Writing "start" or "stop" allows a software equivalent of connect or disconnect respectively. * When an Astribank is ready it sends an "online" event. Whenever its not ready (e.g. at the time of disconnect) it sends an "offline" event. Use astribank_hook.sample to handle those. git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@5097 a0bf4364-ded3-4de4-8d8a-66a801d63aff --- drivers/dahdi/xpp/xpp_dahdi.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'drivers/dahdi/xpp/xpp_dahdi.h') diff --git a/drivers/dahdi/xpp/xpp_dahdi.h b/drivers/dahdi/xpp/xpp_dahdi.h index 74a12c8..7b5695a 100644 --- a/drivers/dahdi/xpp/xpp_dahdi.h +++ b/drivers/dahdi/xpp/xpp_dahdi.h @@ -25,12 +25,13 @@ #include "xpd.h" #include "xproto.h" -void xpd_disconnect(xpd_t *xpd); -int xpd_common_init(xbus_t *xbus, xpd_t *xpd, int unit, int subunit, int subtype, int subunits); +int dahdi_register_xpd(xpd_t *xpd); +int dahdi_unregister_xpd(xpd_t *xpd); +void xpd_unreg_request(xpd_t *xpd); int create_xpd(xbus_t *xbus, const xproto_table_t *proto_table, int unit, int subunit, byte type, byte subtype, int subunits, byte port_dir); void xpd_post_init(xpd_t *xpd); -xpd_t *xpd_alloc(size_t privsize, const xproto_table_t *proto_table, int channels); +xpd_t *xpd_alloc(xbus_t *xbus, int unit, int subunit, int subtype, int subunits, size_t privsize, const xproto_table_t *proto_table, int channels); void xpd_free(xpd_t *xpd); void xpd_remove(xpd_t *xpd); void update_xpd_status(xpd_t *xpd, int alarm_flag); -- cgit v1.2.3