}
return IRQ_HANDLED;
}
-int modem_poweron_off(int on_off)
+static int modem_poweron_off(int on_off)
{
struct rk29_mt6229_data *pdata = gpdata;
if(on_off)
int new_state = simple_strtoul(_buf, NULL, 16);
if(new_state == modem_status) return _count;
if (new_state == 1){
- printk("%s, c(%d), modem resume \n", __FUNCTION__, new_state);
- gpio_set_value(gpdata->modem_usb_en, GPIO_HIGH);
- gpio_set_value(gpdata->modem_uart_en,GPIO_LOW);
+ // printk("%s, c(%d), modem resume \n", __FUNCTION__, new_state);
+ // gpio_set_value(gpdata->modem_usb_en, GPIO_HIGH);
+ // gpio_set_value(gpdata->modem_uart_en,GPIO_LOW);
+ printk("%s, c(%d), open modem \n", __FUNCTION__, new_state);
+ modem_poweron_off(1);
}else if(new_state == 0){
- printk("%s, c(%d), modem suspend \n", __FUNCTION__, new_state);
- gpio_set_value(gpdata->modem_usb_en, GPIO_LOW);
- gpio_set_value(gpdata->modem_uart_en,GPIO_HIGH);
+ // printk("%s, c(%d), modem suspend \n", __FUNCTION__, new_state);
+ // gpio_set_value(gpdata->modem_usb_en, GPIO_LOW);
+ // gpio_set_value(gpdata->modem_uart_en,GPIO_HIGH);
+ printk("%s, c(%d), close modem \n", __FUNCTION__, new_state);
+ modem_poweron_off(0);
}else{
printk("%s, invalid parameter \n", __FUNCTION__);
}
return 0;
}
-int mt6229_suspend(struct platform_device *pdev, pm_message_t state)
+static int mt6229_suspend(struct platform_device *pdev, pm_message_t state)
{
do_wakeup_irq = 1;
ap_wakeup_bp(pdev, 0);
return 0;
}
-int mt6229_resume(struct platform_device *pdev)
+static int mt6229_resume(struct platform_device *pdev)
{
gpio_set_value(gpdata->modem_uart_en,GPIO_LOW);
schedule_delayed_work(&wakeup_work, 2*HZ);
return 0;
}
-void mt6229_shutdown(struct platform_device *pdev)
+static void mt6229_shutdown(struct platform_device *pdev)
{
struct rk29_mt6229_data *pdata = pdev->dev.platform_data;
struct modem_dev *mt6229_data = platform_get_drvdata(pdev);
}
return IRQ_HANDLED;
}
-int modem_poweron_off(int on_off)
+static int modem_poweron_off(int on_off)
{
struct rk29_mu509_data *pdata = gpdata;
if(on_off)
return 0;
}
-int mu509_suspend(struct platform_device *pdev, pm_message_t state)
+static int mu509_suspend(struct platform_device *pdev, pm_message_t state)
{
suspend_int = 1;
do_wakeup_irq = 1;
return 0;
}
-int mu509_resume(struct platform_device *pdev)
+static int mu509_resume(struct platform_device *pdev)
{
#if defined(CONFIG_ARCH_RK29)
rk29_mux_api_set(GPIO1C1_UART0RTSN_SDMMC1WRITEPRT_NAME, GPIO1H_UART0_RTS_N);
return 0;
}
-void mu509_shutdown(struct platform_device *pdev)
+static void mu509_shutdown(struct platform_device *pdev)
{
struct rk29_mu509_data *pdata = pdev->dev.platform_data;
struct modem_dev *mu509_data = platform_get_drvdata(pdev);
return 0;
}
-int mw100_suspend(struct platform_device *pdev, pm_message_t state)
+static int mw100_suspend(struct platform_device *pdev, pm_message_t state)
{
struct rk29_mw100_data *pdata = pdev->dev.platform_data;
return 0;
}
-int mw100_resume(struct platform_device *pdev)
+static int mw100_resume(struct platform_device *pdev)
{
struct rk29_mw100_data *pdata = pdev->dev.platform_data;
int irq;
return 0;
}
-void mw100_shutdown(struct platform_device *pdev)
+static void mw100_shutdown(struct platform_device *pdev)
{
struct rk29_mw100_data *pdata = pdev->dev.platform_data;
struct modem_dev *mw100_data = platform_get_drvdata(pdev);
}
return IRQ_HANDLED;
}
-int modem_poweron_off(int on_off)
+static int modem_poweron_off(int on_off)
{
struct rk30_sew868_data *pdata = gpdata;
if(on_off)
return 0;
}
-int sew868_suspend(struct platform_device *pdev, pm_message_t state)
+static int sew868_suspend(struct platform_device *pdev, pm_message_t state)
{
do_wakeup_irq = 1;
return 0;
}
-int sew868_resume(struct platform_device *pdev)
+static int sew868_resume(struct platform_device *pdev)
{
return 0;
}
-void sew868_shutdown(struct platform_device *pdev)
+static void sew868_shutdown(struct platform_device *pdev)
{
struct rk30_sew868_data *pdata = pdev->dev.platform_data;
struct modem_dev *sew868_data = platform_get_drvdata(pdev);