lkml.org 
[lkml]   [2014]   [Jul]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCHv5 05/15] hwspinlock/omap: add support for dt nodes
Hi Ohad,

On 07/01/2014 07:48 AM, Ohad Ben-Cohen wrote:
> Hi Suman,
>
> On Thu, May 1, 2014 at 3:34 AM, Suman Anna <s-anna@ti.com> wrote:
>> static int omap_hwspinlock_probe(struct platform_device *pdev)
>> {
>> - struct hwspinlock_pdata *pdata = pdev->dev.platform_data;
>> + struct device_node *node = pdev->dev.of_node;
>> struct hwspinlock_device *bank;
>> struct hwspinlock *hwlock;
>> struct resource *res;
>> void __iomem *io_base;
>> int num_locks, i, ret;
>> + int base_id = 0;
>
> We shouldn't implicitly assume base_id is zero: let's explicitly
> protect against potential subsequent invocations of
> omap_hwspinlock_probe.
>

Yeah, I did this since we only had 1 instance, and used the same value
as used in the non-DT legacy code. Once I fold back Patch 8 that adds
the hwlock-base-id property, this will be assigned by reading that property.

regards
Suman



\
 
 \ /
  Last update: 2014-07-02 23:21    [W:0.105 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site