3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-11-22 06:29:23 +01:00

agent: Initial agent support

Init, setup and exit functions.
This commit is contained in:
Jukka Rissanen 2015-02-27 16:01:06 +02:00 committed by Denis Kenzior
parent a2865f014a
commit b46f06a9ad
3 changed files with 95 additions and 0 deletions

View File

@ -54,6 +54,7 @@ src_iwd_SOURCES = src/main.c linux/nl80211.h linux/kdbus.h \
src/eapol.h src/eapol.c \
src/scan.h src/scan.c \
src/util.h src/util.c \
src/agent.h src/agent.c \
iwd.h
src_iwd_LDADD = ell/libell-internal.la

67
src/agent.c Normal file
View File

@ -0,0 +1,67 @@
/*
*
* Wireless daemon for Linux
*
* Copyright (C) 2015 Intel Corporation. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <errno.h>
#include <ell/ell.h>
#include "src/dbus.h"
#include "src/agent.h"
static struct l_dbus_message *agent_register(struct l_dbus *dbus,
struct l_dbus_message *message,
void *user_data)
{
return NULL;
}
static struct l_dbus_message *agent_unregister(struct l_dbus *dbus,
struct l_dbus_message *message,
void *user_data)
{
return NULL;
}
bool agent_setup(struct l_dbus_interface *interface)
{
l_dbus_interface_method(interface, "RegisterAgent", 0,
agent_register,
"", "o", "path");
l_dbus_interface_method(interface, "UnregisterAgent", 0,
agent_unregister,
"", "o", "path");
return true;
}
bool agent_init(void)
{
return true;
}
void agent_exit(void)
{
return;
}

27
src/agent.h Normal file
View File

@ -0,0 +1,27 @@
/*
*
* Wireless daemon for Linux
*
* Copyright (C) 2015 Intel Corporation. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
#include <stdbool.h>
bool agent_init(void);
void agent_exit(void);
bool agent_setup(struct l_dbus_interface *interface);