Adding 'of_platform' bus support to the platform driver
scottwood at freescale.com
Fri Dec 21 04:53:41 EST 2012
On 12/20/2012 02:23:55 AM, R.Patil at mei-india.com wrote:
> We are working on one of the platform drivers for our board (based on
> MPC8313ERDB). Previously, this driver was supporting platform bus but
> now we want to change it to support 'of_platform' bus. While
> supporting platform bus, the platform device structure is initialised
> in board setup file, and platform device is registered using
> 'platform_device_register_simple' call.
> Now if we want to support 'of_platform' bus, the information related
> to the the device will be extracted from device tree in the platform
> driver itself and we would not be required to call
> 'platform_device_register_simple' to register the platform device. Is
> this understanding correct?
What kernel version are you using? The of_platform bus doesn't exist
anymore. The current way is to use a normal platform driver, and
supply an "of_match_table" in the driver struct.
More information about the Linuxppc-dev