Exemple #1
0
static int ril_disable(struct ofono_modem *modem)
{
	struct ril_data *ril = ofono_modem_get_data(modem);

	DBG("%p", modem);

	ril_send_power(ril, FALSE, NULL, NULL);

	return 0;
}
Exemple #2
0
int ril_disable(struct ofono_modem *modem)
{
	struct ril_data *rd = ofono_modem_get_data(modem);
	struct cb_data *cbd = cb_data_new(NULL, modem, rd);

	DBG("%p", modem);

	ril_send_power(rd, FALSE, power_off_cb, cbd);

	return -EINPROGRESS;
}
Exemple #3
0
void ril_set_online(struct ofono_modem *modem, ofono_bool_t online,
			ofono_modem_online_cb_t callback, void *data)
{
	struct ril_data *rd = ofono_modem_get_data(modem);
	struct cb_data *cbd = cb_data_new(callback, data, rd);

	rd->ofono_online = online;

	DBG("setting rd->ofono_online to: %d", online);

	ril_send_power(rd, online, ril_set_online_cb, cbd);
}
Exemple #4
0
static void ril_set_online(struct ofono_modem *modem, ofono_bool_t online,
			ofono_modem_online_cb_t cb, void *data)
{
	struct ril_data *rd = ofono_modem_get_data(modem);
	struct cb_data *cbd = cb_data_new(cb, data, rd);

	if (ril_send_power(rd->ril, online, ril_set_online_cb, cbd, g_free) > 0)
		return;

	CALLBACK_WITH_FAILURE(cb, cbd->data);
	g_free(cbd);
}
Exemple #5
0
static void ril_connected(struct ril_msg *message, gpointer user_data)
{
	struct ofono_modem *modem = user_data;
	struct ril_data *rd = ofono_modem_get_data(modem);

	DBG("");

	/* Set Modem Offline */
	if (ril_send_power(rd->ril, FALSE, ril_init_power, modem, NULL) > 0)
		return;

	ofono_modem_set_powered(modem, FALSE);
}