[PATCH 2/4] rtc: sa1100: convert to run-time register mapping

Russell King - ARM Linux linux at arm.linux.org.uk
Thu Feb 5 15:37:16 PST 2015


On Thu, Feb 05, 2015 at 08:18:05PM +0100, Robert Jarzmik wrote:
> As a consequence, I'm pretty much in favor of :
>  - making rtc-pxa and rtc-sa1100 exclusive
>  - adding to rtc-pxa driver :
>    - a new rtc device (ie. it will register 2 rtc devices, one of the sa1100
>      kind, one of the pxa specific kind)
> 
> This has flaws :
>  - a bit of code will be duplicated between rtc-pxa and rtc-sa1100
>  - the ordering in rtc-pxa between the 2 rtc devices will be important, as if I
>  remember correctly /dev/rtc points to the first /dev/rtc0 registered
> 
> But it opens up :
>  - DT path to both drivers
>  - isolation between sa1100 architecture changes and pxa architecture changes
>  - Rob's current patches can remain almost the same

Or you make one export a set of "library" calls which are referenced
by the other driver, and only declare one platform device.  Not
_particularly_ nice but would avoid the code duplication issue (but
has the benefit of not eating up module space, especially when the
strict rw/execute protections are in effect.)

-- 
FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up
according to speedtest.net.



More information about the linux-arm-kernel mailing list