コード例 #1
0
/**
* omap_hsi_wakeup_enable - Enable HSI wakeup feature from RET/OFF mode
*
* @hsi_port - reference to the HSI port onto which enable wakeup feature.
*
*/
static int omap_hsi_wakeup_enable(struct hsi_dev *hsi_ctrl, int hsi_port)
{
	dev_dbg(hsi_ctrl->dev, "%s\n", __func__);

	if (omap_hsi_is_io_pad_hsi())
		omap_mux_enable_wakeup(OMAP_HSI_PADCONF_CAWAKE_PIN);
	else
		dev_warn(hsi_ctrl->dev, "Trying to enable HSI IO wakeup on non "
					"HSI board\n");

	/* TODO: handle hsi_port param and use it to find the correct Pad */
	return 0;
}
コード例 #2
0
ファイル: omap_hsi.c プロジェクト: travistabbal/kindle-kernel
/**
* omap_hsi_wakeup_enable - Enable HSI wakeup feature from RET/OFF mode
*
* @hsi_port - reference to the HSI port onto which enable wakeup feature.
*	      Range [0, 1]
*
* Return value :* 0 if CAWAKE has been configured to wakeup platform
*		* -ENODEV if CAWAKE is not muxed on padconf
*/
static int omap_hsi_wakeup_enable(int hsi_port)
{
	int ret = -ENODEV;

	if (omap_hsi_is_io_pad_hsi())
		ret = omap_mux_enable_wakeup(OMAP_HSI_PADCONF_CAWAKE_PIN);
	else
		pr_debug("Trying to enable HSI IO wakeup on non HSI board\n");


	/* TODO: handle hsi_port param and use it to find the correct Pad */
	return ret;
}
コード例 #3
0
ファイル: omap_hsi.c プロジェクト: greenromproj/kb
/**
* omap_hsi_wakeup_disable - Disable HSI wakeup feature from RET/OFF mode
*
* @hsi_port - reference to the HSI port onto which disable wakeup feature.
*	      Range [1, 2]
*
* Return value :* 0 if CAWAKE has been configured to not wakeup platform
*		* -ENODEV if CAWAKE is not muxed on padconf
*/
static int omap_hsi_wakeup_disable(int hsi_port)
{
	struct hsi_port_ctx *port_ctx;
	int ret = -ENODEV;

	if (omap_hsi_is_io_pad_hsi(hsi_port)) {
		port_ctx = hsi_get_hsi_port_ctx_data(hsi_port);
		ret = omap_mux_disable_wakeup(port_ctx->cawake_padconf_name);
		omap4_trigger_ioctrl();
	} else {
		pr_debug("HSI port %d not muxed, failed to disable IO wakeup\n",
			 hsi_port);
	}

	return ret;
}