Commit fe233b9d authored by Shawn Guo's avatar Shawn Guo

video: mxsfb: adopt pinctrl support

Cc: linux-fbdev@vger.kernel.org
Cc: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Signed-off-by: default avatarShawn Guo <shawn.guo@linaro.org>
parent f755865f
...@@ -45,6 +45,7 @@ ...@@ -45,6 +45,7 @@
#include <linux/clk.h> #include <linux/clk.h>
#include <linux/dma-mapping.h> #include <linux/dma-mapping.h>
#include <linux/io.h> #include <linux/io.h>
#include <linux/pinctrl/consumer.h>
#include <mach/mxsfb.h> #include <mach/mxsfb.h>
#define REG_SET 4 #define REG_SET 4
...@@ -756,6 +757,7 @@ static int __devinit mxsfb_probe(struct platform_device *pdev) ...@@ -756,6 +757,7 @@ static int __devinit mxsfb_probe(struct platform_device *pdev)
struct mxsfb_info *host; struct mxsfb_info *host;
struct fb_info *fb_info; struct fb_info *fb_info;
struct fb_modelist *modelist; struct fb_modelist *modelist;
struct pinctrl *pinctrl;
int i, ret; int i, ret;
if (!pdata) { if (!pdata) {
...@@ -793,6 +795,12 @@ static int __devinit mxsfb_probe(struct platform_device *pdev) ...@@ -793,6 +795,12 @@ static int __devinit mxsfb_probe(struct platform_device *pdev)
host->devdata = &mxsfb_devdata[pdev->id_entry->driver_data]; host->devdata = &mxsfb_devdata[pdev->id_entry->driver_data];
pinctrl = devm_pinctrl_get_select_default(&pdev->dev);
if (IS_ERR(pinctrl)) {
ret = PTR_ERR(pinctrl);
goto error_getpin;
}
host->clk = clk_get(&host->pdev->dev, NULL); host->clk = clk_get(&host->pdev->dev, NULL);
if (IS_ERR(host->clk)) { if (IS_ERR(host->clk)) {
ret = PTR_ERR(host->clk); ret = PTR_ERR(host->clk);
...@@ -848,6 +856,7 @@ static int __devinit mxsfb_probe(struct platform_device *pdev) ...@@ -848,6 +856,7 @@ static int __devinit mxsfb_probe(struct platform_device *pdev)
error_pseudo_pallette: error_pseudo_pallette:
clk_put(host->clk); clk_put(host->clk);
error_getclock: error_getclock:
error_getpin:
iounmap(host->base); iounmap(host->base);
error_ioremap: error_ioremap:
framebuffer_release(fb_info); framebuffer_release(fb_info);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment