Re: [PATCH v6 6/9] mmc: dw_mmc: add device tree support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>>>> +#else /* CONFIG_OF */
>>>> +static struct dw_mci_board *dw_mci_parse_dt(struct dw_mci *host)
>>>> +{
>>>> +     return ERR_PTR(-EINVAL);
>>>> +}
>>>> +#endif /* CONFIG_OF */
>>>> +
>>>>  int dw_mci_probe(struct dw_mci *host)
>>>>  {
>>>>       int width, i, ret = 0;
>>>>       u32 fifo_size;
>>>>       int init_slots = 0;
>>>>
>>>> -     if (!host->pdata || !host->pdata->init) {
>>> "!host->pdata->init" is removed.
>>> Please check it.
>>
>> I have checked again in mmc-next branch and "init" is still there.
> I mean that there is no condition whether "host->pdata->init" is present or not, unlike origin code.
> In this patch this condition is removed. We don't need it anymore?
Actually i didn't know why need the pdata->init.
Why need host->pdata->init? In case of exynos, just return 1.
I didn't know how use this at other-soc.

Best Regards,
Jaehoon Chung
> 
>>
>> Thanks,
>> Thomas.
>>
>>
>>>
>>> Thanks,
>>> Seungwon Jeon
>>>
>>>> -             dev_err(host->dev,
>>>> -                     "Platform data must supply init function\n");
>>>> -             return -ENODEV;
>>>> +     if (!host->pdata) {
>>>> +             host->pdata = dw_mci_parse_dt(host);
>>>> +             if (IS_ERR(host->pdata)) {
>>>> +                     dev_err(host->dev, "platform data not available\n");
>>>> +                     return -EINVAL;
>>>> +             }
>>>>       }
>>>>
>>>>       if (!host->pdata->select_slot && host->pdata->num_slots > 1) {
>>>> --
>>>> 1.6.6.rc2
>>>>
>>>> --
>>>> To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
>>>> the body of a message to majordomo@xxxxxxxxxxxxxxx
>>>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>>
>>
>> [...]
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
>> the body of a message to majordomo@xxxxxxxxxxxxxxx
>> 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 majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux SoC Development]     [Linux Rockchip Development]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Linux SCSI]     [Yosemite News]

  Powered by Linux