From 12efc4bad60d197754df29080c2de66d98041e5a Mon Sep 17 00:00:00 2001 From: Tzafrir Cohen Date: Sun, 30 Jan 2011 14:14:14 +0000 Subject: xpp: phonedev: Cleanup method macros * Caller to CALL_XMETHOD() no longer need to explicitly pass xbus (calculate xpd->xbus) * Create CALL_PHONE_METHOD() similar to CALL_XMETHOD() -- inlining the extra parameters (more readable) * Reverse parameter order in PHONE_METHOD() and CALL_PHONE_METHOD() to be consistent with XMETHOD() and CALL_XMETHOD() * Rename XPD_STATE phonedev method to card_state: - Consistency with other phonedev methods. - These calls now Wrap internal calls to XPD_STATE protocol HOSTCMD in PRI, BRI, FXS, FXO Signed-off-by: Oron Peled Acked-by: Tzafrir Cohen git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9706 a0bf4364-ded3-4de4-8d8a-66a801d63aff --- drivers/dahdi/xpp/xbus-core.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'drivers/dahdi/xpp/xbus-core.c') diff --git a/drivers/dahdi/xpp/xbus-core.c b/drivers/dahdi/xpp/xbus-core.c index 55c00f6..9feaeaa 100644 --- a/drivers/dahdi/xpp/xbus-core.c +++ b/drivers/dahdi/xpp/xbus-core.c @@ -900,14 +900,13 @@ static int xpd_initialize(xpd_t *xpd) { int ret = -ENODEV; - if(CALL_XMETHOD(card_init, xpd->xbus, xpd) < 0) { + if(CALL_XMETHOD(card_init, xpd) < 0) { XPD_ERR(xpd, "Card Initialization failed\n"); goto out; } - //CALL_XMETHOD(XPD_STATE, xpd->xbus, xpd, 0); /* Turn off all channels */ xpd->card_present = 1; if (IS_PHONEDEV(xpd)) { - PHONE_METHOD(xpd, XPD_STATE)(xpd->xbus, xpd, 1); /* Turn on all channels */ + CALL_PHONE_METHOD(card_state, xpd, 1); /* Turn on all channels */ } if(!xpd_setstate(xpd, XPD_STATE_READY)) { goto out; -- cgit v1.2.3