RE: [PATCH 4/9] ARM: OMAP2+: gpmc-tusb6010: Adapt to use gpmc driver

2012-06-13 Thread Mohammed, Afzal
Hi Tony,

On Wed, Jun 13, 2012 at 17:57:48, Tony Lindgren wrote:

> We can drop the old interface for non-mainline cases. In this case
> tusb6010 is only used by board-n8x0.c, so it's best to just convert
> it all to use the new interface.

Right, I will do accordingly

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


Re: [PATCH 4/9] ARM: OMAP2+: gpmc-tusb6010: Adapt to use gpmc driver

2012-06-13 Thread Tony Lindgren
* Afzal Mohammed  [120611 08:19]:
> @@ -106,7 +123,14 @@ static int tusb_set_async_mode(unsigned sysclk_ps, 
> unsigned fclk_ps)
>   tmp = t.cs_wr_off * 1000 + 7000 /* t_acsn_rdy_z */;
>   t.wr_cycle = next_clk(t.cs_wr_off, tmp, fclk_ps);
>  
> - return gpmc_cs_set_timings(async_cs, &t);
> + /* gpmc driver interface */
> + if (gpmc_tusb_data.pdata != NULL) {
> + gpmc_tusb_cs_data[CS_ASYNC_IDX].time_ctrl.type = has_period;
> + gpmc_tusb_cs_data[CS_ASYNC_IDX].time_ctrl.timings = t;
> + return 0;
> + /* old interface */
> + } else
> + return gpmc_cs_set_timings(async_cs, &t);
>  }
>  
>  static int tusb_set_sync_mode(unsigned sysclk_ps, unsigned fclk_ps)
> @@ -174,7 +198,16 @@ static int tusb_set_sync_mode(unsigned sysclk_ps, 
> unsigned fclk_ps)
>   tmp = t.cs_wr_off * 1000 + 7000 /* t_scsn_rdy_z */;
>   t.wr_cycle = next_clk(t.cs_wr_off, tmp, fclk_ps);
>  
> - return gpmc_cs_set_timings(sync_cs, &t);
> + t.clk_activation = gpmc_ticks_to_ns(1);
> +
> + /* gpmc driver interface */
> + if (gpmc_tusb_data.pdata != NULL) {
> + gpmc_tusb_cs_data[CS_SYNC_IDX].time_ctrl.type = has_period;
> + gpmc_tusb_cs_data[CS_SYNC_IDX].time_ctrl.timings = t;
> + return 0;
> + /* old interface */
> + } else
> + return gpmc_cs_set_timings(sync_cs, &t);
>  }

We can drop the old interface for non-mainline cases. In this case
tusb6010 is only used by board-n8x0.c, so it's best to just convert
it all to use the new interface.

Regards,

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