Re: [PATCH v3 4/5] OMAP: hwmod data: Add dev_attr and use in the host driver

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

 



On Thu, Feb 24, 2011 at 11:30 AM, Varadarajan, Charulatha <charu@xxxxxx> wrote:
> Kishore,
>
> On Wed, Feb 23, 2011 at 23:17, Kishore Kadiyala <kishore.kadiyala@xxxxxx> wrote:
>> Add a device attribute to hwmod data of omap2430, omap3, omap4.
>> Currently the device attribute holds information regarding dual volt MMC card
>> support by the controller which will be later passed to the host driver via
>> platform data.
>>
>> Signed-off-by: Kevin Hilman <khilman@xxxxxxxxxxxxxxxxxxx>
>> Signed-off-by: Kishore Kadiyala <kishore.kadiyala@xxxxxx>
>> Cc: Benoit Cousson <b-cousson@xxxxxx>
>> Cc: Paul Walmsley <paul@xxxxxxxxx>
>> ---
>>  arch/arm/mach-omap2/omap_hwmod_2430_data.c |    9 +++++++++
>>  arch/arm/mach-omap2/omap_hwmod_3xxx_data.c |   12 ++++++++++++
>>  arch/arm/mach-omap2/omap_hwmod_44xx_data.c |   16 ++++++++++++++++
>>  arch/arm/plat-omap/include/plat/mmc.h      |   10 ++++++++++
>>  drivers/mmc/host/omap_hsmmc.c              |    4 ++--
>>  5 files changed, 49 insertions(+), 2 deletions(-)
>>
>
> <<snip>>
>
>>
>> diff --git a/arch/arm/plat-omap/include/plat/mmc.h b/arch/arm/plat-omap/include/plat/mmc.h
>> index e5de5d4..7853130 100644
>> --- a/arch/arm/plat-omap/include/plat/mmc.h
>> +++ b/arch/arm/plat-omap/include/plat/mmc.h
>> @@ -43,6 +43,13 @@
>>
>>  #define OMAP_MMC_MAX_SLOTS     2
>>
>> +/* omap_hwmod integration data */
>
> What is omap_hwmod integration data ? Pls clarify.
>
>> +#define OMAP_HSMMC_SUPPORTS_DUAL_VOLT  BIT(1)
>> +
>> +struct mmc_dev_attr {
>> +       u8 flags;
>> +};
>> +
>>  struct omap_mmc_platform_data {
>>        /* back-link to device */
>>        struct device *dev;
>> @@ -71,6 +78,9 @@ struct omap_mmc_platform_data {
>>
>>        u64 dma_mask;
>>
>> +       /* Integrating attributes from the omap_hwmod layer */
>> +       u8 controller_dev_attr;
>> +
>>        /* Register offset deviation */
>>        u16 reg_offset;
>>
>> diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c
>> index 078fdf1..160cc95 100644
>> --- a/drivers/mmc/host/omap_hsmmc.c
>> +++ b/drivers/mmc/host/omap_hsmmc.c
>> @@ -1555,7 +1555,7 @@ static void omap_hsmmc_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
>>                break;
>>        }
>>
>> -       if (host->id == OMAP_MMC1_DEVID) {
>> +       if (host->pdata->controller_dev_attr & OMAP_HSMMC_SUPPORTS_DUAL_VOLT) {
>
> Where is pdata->controller_dev_attr getting populated? I don't see the
> dev_attr from the
> hwmod database used anywhere in this patch.

good catch ,
the changes in the driver should be part of last patch.

>
>>                /* Only MMC1 can interface at 3V without some flavor
>>                 * of external transceiver; but they all handle 1.8V.
>>                 */
>> @@ -1647,7 +1647,7 @@ static void omap_hsmmc_conf_bus_power(struct omap_hsmmc_host *host)
>>        u32 hctl, capa, value;
>>
>>        /* Only MMC1 supports 3.0V */
>> -       if (host->id == OMAP_MMC1_DEVID) {
>> +       if (host->pdata->controller_dev_attr & OMAP_HSMMC_SUPPORTS_DUAL_VOLT) {
>
> Ditto.
>
>>                hctl = SDVS30;
>>                capa = VS30 | VS18;
>>        } else {
>> --
>> 1.7.1
>>
>
--
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


[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux