2009-06-04 15:46:48 +00:00
|
|
|
/*
|
|
|
|
*
|
2010-10-14 12:29:58 +00:00
|
|
|
* oFono - Open Source Telephony
|
2009-06-04 15:46:48 +00:00
|
|
|
*
|
2011-10-10 20:40:08 +00:00
|
|
|
* Copyright (C) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
|
2009-06-04 15:46:48 +00:00
|
|
|
*
|
2010-10-14 12:29:58 +00:00
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
|
|
* published by the Free Software Foundation.
|
2009-06-04 15:46:48 +00:00
|
|
|
*
|
2010-10-14 12:29:58 +00:00
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
2009-06-04 15:46:48 +00:00
|
|
|
*
|
2010-10-14 12:29:58 +00:00
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
2009-06-04 15:46:48 +00:00
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <stdint.h>
|
2009-08-19 12:58:04 +00:00
|
|
|
#include <gisi/modem.h>
|
2011-02-04 12:47:00 +00:00
|
|
|
#include <gisi/common.h>
|
2009-06-04 15:46:48 +00:00
|
|
|
|
2010-11-14 16:28:12 +00:00
|
|
|
#ifndef __GISI_PN_NETLINK_H
|
|
|
|
#define __GISI_PN_NETLINK_H
|
2009-06-04 15:46:48 +00:00
|
|
|
|
2009-06-15 08:17:30 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
2009-06-04 15:46:48 +00:00
|
|
|
#endif
|
2009-06-15 08:17:30 +00:00
|
|
|
|
2010-11-14 16:28:12 +00:00
|
|
|
struct _GIsiPhonetNetlink;
|
|
|
|
typedef struct _GIsiPhonetNetlink GIsiPhonetNetlink;
|
2009-06-15 08:17:30 +00:00
|
|
|
|
2011-02-04 12:47:00 +00:00
|
|
|
enum GIsiPhonetLinkState {
|
2010-04-19 18:27:05 +00:00
|
|
|
PN_LINK_REMOVED,
|
|
|
|
PN_LINK_DOWN,
|
2011-02-04 12:47:00 +00:00
|
|
|
PN_LINK_UP,
|
|
|
|
};
|
2010-04-19 18:27:05 +00:00
|
|
|
|
2011-02-04 12:47:00 +00:00
|
|
|
typedef void (*GIsiPhonetNetlinkFunc)(GIsiModem *modem,
|
|
|
|
enum GIsiPhonetLinkState st,
|
|
|
|
const char *iface, void *data);
|
2010-04-19 18:27:05 +00:00
|
|
|
|
2010-11-14 16:28:12 +00:00
|
|
|
GIsiPhonetNetlink *g_isi_pn_netlink_by_modem(GIsiModem *modem);
|
2009-06-15 08:17:30 +00:00
|
|
|
|
2010-11-14 16:28:12 +00:00
|
|
|
GIsiPhonetNetlink *g_isi_pn_netlink_start(GIsiModem *idx,
|
|
|
|
GIsiPhonetNetlinkFunc cb,
|
|
|
|
void *data);
|
2009-06-15 08:17:30 +00:00
|
|
|
|
2010-11-14 16:28:12 +00:00
|
|
|
void g_isi_pn_netlink_stop(GIsiPhonetNetlink *self);
|
|
|
|
int g_isi_pn_netlink_set_address(GIsiModem *modem, uint8_t local);
|
2010-04-28 13:37:10 +00:00
|
|
|
|
2009-06-15 08:17:30 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2010-11-14 16:28:12 +00:00
|
|
|
#endif /* __GISI_PN_NETLINK_H */
|