Re: [PATCH 1/2]: Add support for Dallas/Maxim DS1685/1687 RTC

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

 



On Thu, Feb 17, 2011 at 9:17 AM, Kumba <kumba@xxxxxxxxxx> wrote:
> On 02/17/2011 02:31, Manuel Lauss wrote:
>>
>> Have a look at i2c-ocores.c:    Basically you use platform_data to specify
>> register spacing on the bus.
>>
>> Manuel
>
> I think I get most of it here.  i2c-ocores.c defines `struct ocores_i2c`,
> which has regstep in it.  I assume the equivalent to this in the RTC driver
> is going to be ds1685_priv.  But in i2c_ocores.h, `struct
> ocores_i2c_platform_data` is defined, which also carries a regstep.  In
> i2c-ocores.c, this struct becomes *pdata while ocores_i2c becomes *i2c, and
> *i2c is used to access the registers.
>
> I don't think I have an equivalent to either of these two with the way the
> driver was originally written and how I modified it.  The ds1685_priv kinda
> does both right now.  I assume platform_data is not really defined...I have
> to implement one specific to this RTC driver, giving it specific variables
> that need to be customizable at the platform level, and then set those in
> the machine-specific areas, i.e., somewhere in IP32's platform file.
>
> Sound correct?

Yep.

Manuel



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux