[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAD=FV=V-ARDpRUqPqPp=aSie+1T+ADDk-cO_iNic=JXXvk3u9A@mail.gmail.com>
Date: Thu, 24 Apr 2014 13:23:06 -0700
From: Doug Anderson <dianders@...omium.org>
To: Jonathan Cameron <jic23@...nel.org>,
Naveen Krishna Chatradhi <ch.naveen@...sung.com>
Cc: Lars-Peter Clausen <lars@...afoo.de>, Milo.Kim@...com,
Lee Jones <lee.jones@...aro.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Russ.Dill@...com, alexandre.belloni@...e-electrons.com,
oleksandr.kozaruk@...com, B38611@...escale.com,
johannes.thumshirn@....de, sre@...ian.org,
Sachin Kamat <sachin.kamat@...aro.org>,
linux-iio <linux-iio@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] iio: adc: Nothing in ADC should be a bool CONFIG
Jonathan / Naveen,
On Wed, Apr 23, 2014 at 9:37 PM, Jonathan Cameron <jic23@...nel.org> wrote:
> On 23/04/14 22:54, Doug Anderson wrote:
>>
>> Jonathan,
>>
>> On Wed, Apr 23, 2014 at 1:54 PM, Jonathan Cameron <jic23@...nel.org>
>> wrote:
>>>
>>> On 22/04/14 01:03, Doug Anderson wrote:
>>>>
>>>>
>>>> The whole IIO subsystem can be moved to a module. If you make it a
>>>> module then stuff marked as "Y" in the adc directory simply won't be
>>>> linked in properly.
>>>>
>>>> The two configs that were wrong were EXYNOS_ADC and LP8788_ADC. I
>>>> know for a fact that EXYNOS_ADC will work as a module (though it
>>>> appears to crash when you unload it--that needs to be addressed
>>>> separately).
>>>
>>>
>>> I'd really like to see this pinned down before taking this patch.
>>> I can see you argument that the current approach is clearly wrong,
>>> but swapping one issue for another is not an approach I'd particularly
>>> like to take...
>>>
>>> I can't immediately spot the cause of the crash, but there are certainly
>>> some interesting order issues in this driver. Not enabling the vdd
>>> regulator until after the userspace interfaces are exposed (by the
>>> iio_device_register call) is interesting for a start.
>>>
>>> The remove doesn't run in the reverse of the probe order (see clocks
>>> vs regulators for example.)
>>>
>>> Gah, my reviewing for one clearly missed some things in this driver.
>>
>>
>> OK, fair enough. I took a quick look and couldn't spot anything
>> either. I've requested that Samsung dig into these problems. If they
>> are unable to I will take a crack at it as time permits. ;)
>>
> Cool and good luck (either way ;)
Ah ha! Naveen pointed out that it was the "device_for_each_child"
that was the source of the crash. ...and here's the problem... I
think this is what we want:
- ret = of_platform_populate(np, exynos_adc_match, NULL, &pdev->dev);
+ ret = of_platform_populate(np, exynos_adc_match, NULL, &indio_dev->dev);
- device_for_each_child(&pdev->dev, NULL,
+ device_for_each_child(&indio_dev->dev, NULL,
Naveen has been volunteered to send the patch up. ;) Naveen:
hopefully you can address Jonathan's other concerns as well. ;)
-Doug
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists