[lkml]   [2013]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH v4 1/2] ARM: mach-moxart: add MOXA ART SoC platform files
On 12/14/2013 10:50 AM, Arnd Bergmann wrote:
> On Saturday 14 December 2013, Jonas Jensen wrote:
>>> Conceptually it might be cleaner to write a separate driver, for example
>>> in drivers/power/restart, than plugging the functionality into
>>> the watchdog driver, at least if you don't want it in architecture
>>> or platform code. The xgene restart driver is a good example.
>> Moving it to a new power/restart driver seems reasonable to me, I'm
>> really just looking for a home for it, I would have preferred a
>> hardware with reset in a separate register though.
>> I now plan to remove it for v5 and submit a separate driver.
> I still think it's better to leave it in the watchdog driver: This
> driver attaches to the watchdog device, and adding a separate driver
> for reset means we have to trick the core Linux code into attaching
> two drivers to one device in some way, or the device tree has to fake
> a second device that doesn't exist in hardware but is only needed
> because of Linux implementation details.

Hmm ... not sure I agree. I don't see a problem with something like "arm,moxart-reboot".
There are already vexpress-reboot and xgene-reboot properties which do pretty much
the same.

Actually, you don't even need that; the reset driver could simply re-use the
"moxa,moxart-watchdog" property. After all, all that specifies is that there
is a compatible driver. Look for "samsung,s3c2410-wdt" for an example of another
reset handler doing just that.

Attaching it to the watchdog device seems to be more problematic given the
(currently) optional nature of the watchdog driver and its different scope.


 \ /
  Last update: 2013-12-14 21:21    [W:0.408 / U:0.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site