Skip to content
Snippets Groups Projects
  • Simon Glass's avatar
    b5220bc6
    fdt: add decode helper library · b5220bc6
    Simon Glass authored
    
    This library provides useful functions to drivers which want to use
    the fdt to control their operation. Functions are provided to:
    
    - look up and enumerate a device type (for example assigning i2c bus 0,
         i2c bus 1, etc.)
    - decode basic types from the fdt, like addresses and integers
    
    While this library is not strictly necessary, it helps to minimise the
    changes to a driver, in order to make it work under fdt control. Less
    code is required, and so the barrier to switch drivers over is lower.
    
    Additional functions to read arrays and GPIOs could be made available
    here also.
    
    Signed-off-by: default avatarSimon Glass <sjg@chromium.org>
    b5220bc6
    History
    fdt: add decode helper library
    Simon Glass authored
    
    This library provides useful functions to drivers which want to use
    the fdt to control their operation. Functions are provided to:
    
    - look up and enumerate a device type (for example assigning i2c bus 0,
         i2c bus 1, etc.)
    - decode basic types from the fdt, like addresses and integers
    
    While this library is not strictly necessary, it helps to minimise the
    changes to a driver, in order to make it work under fdt control. Less
    code is required, and so the barrier to switch drivers over is lower.
    
    Additional functions to read arrays and GPIOs could be made available
    here also.
    
    Signed-off-by: default avatarSimon Glass <sjg@chromium.org>