RE: [PATCH v6 9/9] mmc: dw_mmc: add support for exynos specific implementation of dw-mshc

2012-09-20 Thread Seungwon Jeon
On Thursday, September 20, 2012, Thomas Abraham  
wrote:
> On 19 September 2012 19:12, Seungwon Jeon  wrote:
> > On Tuesday, September 18, 2012, Thomas Abraham  
> > wrote:
> >> +int dw_mci_exynos_probe(struct platform_device *pdev)
> >> +{
> >> + struct dw_mci_drv_data *drv_data;
> >> + const struct of_device_id *match;
> >> +
> >> + match = of_match_node(dw_mci_exynos_match, pdev->dev.of_node);
> >> + drv_data = match->data;
> > In non-dt case, match has NULL.
> > Needed to check "pdev->dev.of_node"
> 
> Since all current users in mainline of this driver on Exynos platforms
> are device tree based, and since Exynos4 and Exynos5 have device tree
> support, I have mainly been adding device tree support here. Only for
> non-exynos portions of the code, I have ensured that both dt and
> legacy modes are supported.
Yes. I know, then dw_mmc-exynos.c should have a dependency of CONFIG_OF?
It needs to prevent kernel panic at least.

Thanks,
Seungwon Jeon
Thanks,
Seungwon Jeon
> 
> Thanks,
> Thomas.
> 
> [...]
> --
> To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 9/9] mmc: dw_mmc: add support for exynos specific implementation of dw-mshc

2012-09-19 Thread Thomas Abraham
On 19 September 2012 19:12, Seungwon Jeon  wrote:
> On Tuesday, September 18, 2012, Thomas Abraham  
> wrote:
>> +int dw_mci_exynos_probe(struct platform_device *pdev)
>> +{
>> + struct dw_mci_drv_data *drv_data;
>> + const struct of_device_id *match;
>> +
>> + match = of_match_node(dw_mci_exynos_match, pdev->dev.of_node);
>> + drv_data = match->data;
> In non-dt case, match has NULL.
> Needed to check "pdev->dev.of_node"

Since all current users in mainline of this driver on Exynos platforms
are device tree based, and since Exynos4 and Exynos5 have device tree
support, I have mainly been adding device tree support here. Only for
non-exynos portions of the code, I have ensured that both dt and
legacy modes are supported.

Thanks,
Thomas.

[...]
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [PATCH v6 9/9] mmc: dw_mmc: add support for exynos specific implementation of dw-mshc

2012-09-19 Thread Seungwon Jeon
On Tuesday, September 18, 2012, Thomas Abraham  
wrote:
> +int dw_mci_exynos_probe(struct platform_device *pdev)
> +{
> + struct dw_mci_drv_data *drv_data;
> + const struct of_device_id *match;
> +
> + match = of_match_node(dw_mci_exynos_match, pdev->dev.of_node);
> + drv_data = match->data;
In non-dt case, match has NULL.
Needed to check "pdev->dev.of_node"

Thanks,
Seungwon Jeon
> + return dw_mci_pltfm_register(pdev, drv_data);
> +}
> +
> +static struct platform_driver dw_mci_exynos_pltfm_driver = {
> + .probe  = dw_mci_exynos_probe,
> + .remove = __exit_p(dw_mci_pltfm_remove),
> + .driver = {
> + .name   = "dwmmc_exynos",
> + .of_match_table = of_match_ptr(dw_mci_exynos_match),
> + .pm = &dw_mci_pltfm_pmops,
> + },
> +};
> +
> +module_platform_driver(dw_mci_exynos_pltfm_driver);
> +
> +MODULE_DESCRIPTION("Samsung Specific DW-MSHC Driver Extension");
> +MODULE_AUTHOR("Thomas Abraham  +MODULE_LICENSE("GPL v2");
> +MODULE_ALIAS("platform:dwmmc-exynos");
> diff --git a/include/linux/mmc/dw_mmc.h b/include/linux/mmc/dw_mmc.h
> index 6cb043e..7c6a113 100644
> --- a/include/linux/mmc/dw_mmc.h
> +++ b/include/linux/mmc/dw_mmc.h
> @@ -227,7 +227,7 @@ struct dw_mci_board {
>   u32 num_slots;
> 
>   u32 quirks; /* Workaround / Quirk flags */
> - unsigned int bus_hz; /* Bus speed */
> + unsigned int bus_hz; /* Clock speed at the cclk_in pad */
> 
>   unsigned int caps;  /* Capabilities */
>   unsigned int caps2; /* More capabilities */
> --
> 1.6.6.rc2

--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html