Skip to content
  • notro's avatar
    BCM2708: Add core Device Tree support · 292ab07a
    notro authored
    
    
    Add the bare minimum needed to boot BCM2708 from a Device Tree.
    
    Signed-off-by: default avatarNoralf Tronnes <notro@tronnes.org>
    
    BCM2708: DT: change 'axi' nodename to 'soc'
    
    Change DT node named 'axi' to 'soc' so it matches ARCH_BCM2835.
    The VC4 bootloader fills in certain properties in the 'axi' subtree,
    but since this is part of an upstreaming effort, the name is changed.
    
    Signed-off-by: default avatarNoralf Tronnes <notro@tronnes.org>
    
    BCM2708_DT: Correct length of the peripheral space
    
    Use dts-dirs feature for overlays.
    
    The kernel makefiles have a dts-dirs target that is for vendor subdirectories.
    
    Using this fixes the install_dtbs target, which previously did not install the overlays.
    
    BCM270X_DT: configure I2S DMA channels
    
    Signed-off-by: default avatarMatthias Reichl <hias@horus.com>
    
    BCM270X_DT: switch to bcm2835-i2s
    
    I2S soundcard drivers with proper devicetree support (i.e. not linking
    to the cpu_dai/platform via name but to cpu/platform via of_node)
    will work out of the box without any modifications.
    
    When the kernel is compiled without devicetree support the platform
    code will instantiate the bcm2708-i2s driver and I2S soundcard drivers
    will link to it via name, as before.
    
    Signed-off-by: default avatarMatthias Reichl <hias@horus.com>
    
    SDIO-overlay: add poll_once-boolean parameter
    
    Add paramter to toggle sdio-device-polling
    done every second or once at boot-time.
    
    Signed-off-by: default avatarPatrick Boettcher <patrick.boettcher@posteo.de>
    
    BCM270X_DT: Make mmc overlay compatible with current firmware
    
    The original DT overlay logic followed a merge-then-patch procedure,
    i.e. parameters are applied to the loaded overlay before the overlay
    is merged into the base DTB. This sequence has been changed to
    patch-then-merge, in order to support parameterised node names, and
    to protect against bad overlays. As a result, overrides (parameters)
    must only target labels in the overlay, but the overlay can obviously target nodes in the base DTB.
    
    mmc-overlay.dts (that switches back to the original mmc sdcard
    driver) is the only overlay violating that rule, and this patch
    fixes it.
    
    bcm270x_dt: Use the sdhost MMC controller by default
    
    The "mmc" overlay reverts to using the other controller.
    
    squash: Add cprman to dt
    
    BCM270X_DT: Use clk_core for I2C interfaces
    
    BCM270X_DT: Use bcm283x.dtsi, bcm2835.dtsi and bcm2836.dtsi
    
    The mainline Device Tree files are quite close to downstream now.
    Let's use bcm283x.dtsi, bcm2835.dtsi and bcm2836.dtsi as base files
    for our dts files.
    
    Mainline dts files are based on these files:
    
              bcm2835-rpi.dtsi
      bcm2835.dtsi    bcm2836.dtsi
              bcm283x.dtsi
    
    Current downstream are based on these:
    
      bcm2708.dtsi    bcm2709.dtsi    bcm2710.dtsi
                 bcm2708_common.dtsi
    
    This patch introduces this dependency:
    
      bcm2708.dtsi    bcm2709.dtsi
              bcm2708-rpi.dtsi
              bcm270x.dtsi
      bcm2835.dtsi    bcm2836.dtsi
              bcm283x.dtsi
    
    And:
              bcm2710.dtsi
              bcm2708-rpi.dtsi
              bcm270x.dtsi
              bcm283x.dtsi
    
    bcm270x.dtsi contains the downstream bcm283x.dtsi diff.
    bcm2708-rpi.dtsi is the downstream version of bcm2835-rpi.dtsi.
    
    Other changes:
    - The led node has moved from /soc/leds to /leds. This is not a problem
      since the label is used to reference it.
    - The clk_osc reg property changes from 6 to 3.
    - The gpu nodes has their interrupt property set in the base file.
    - the clocks label does not point to the /clocks node anymore, but
      points to the cprman node. This is not a problem since the overlays
      that use the clock node refer to it directly: target-path = "/clocks";
    - some nodes now have 2 labels since mainline and downstream differs in
      this respect: cprman/clocks, spi0/spi, gpu/vc4.
    - some nodes doesn't have an explicit status = "okay" since they're not
      disabled in the base file: watchdog and random.
    - gpiomem doesn't need an explicit status = "okay".
    - bcm2708-rpi-cm.dts got the hpd-gpios property from bcm2708_common.dtsi,
      it's now set directly in that file.
    - bcm2709-rpi-2-b.dts has the timer node moved from /soc/timer to /timer.
    - Removed clock-frequency property on the bcm{2709,2710}.dtsi timer nodes.
    
    Signed-off-by: default avatarNoralf Trønnes <noralf@tronnes.org>
    
    BCM270X_DT: Use raspberrypi-power to turn on USB power
    
    Use the raspberrypi-power driver to turn on USB power.
    
    Signed-off-by: default avatarNoralf Trønnes <noralf@tronnes.org>
    
    BCM270X_DT: Add a .dtbo target, use for overlays
    
    Change the filenames and extensions to keep the pre-DDT style of
    overlay (<name>-overlay.dtb) distinct from new ones that use a
    different style of local fixups (<name>.dtbo), and to match other
    platforms.
    
    The RPi firmware uses the DDTK trailer atom to choose which type of
    overlay to use for each kernel.
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    
    BCM270X_DT: Don't generate "linux,phandle" props
    
    The EPAPR standard says to use "phandle" properties to store phandles,
    rather than the deprecated "linux,phandle" version. By default, dtc
    generates both, but adding "-H epapr" causes it to only generate
    "phandle"s, saving some space and clutter.
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    
    BCM270X_DT: Add overlay for enc28j60 on SPI2
    
    Works on SPI2 for compute module
    
    BCM270X_DT: Add midi-uart0 overlay
    
    MIDI requires 31.25kbaud, a baudrate unsupported by Linux. The
    midi-uart0 overlay configures uart0 (ttyAMA0) to use a fake clock
    so that requesting 38.4kbaud actually gets 31.25kbaud.
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    
    BCM270X_DT: Add i2c-sensor overlay
    
    The i2c-sensor overlay is a container for various pressure and
    temperature sensors, currently bmp085 and bmp280. The standalone
    bmp085_i2c-sensor overlay is now deprecated.
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    
    BCM270X_DT: overlays/*-overlay.dtb -> overlays/*.dtbo (#1752)
    
    We now create overlays as .dtbo files.
    
    build: support for .dtbo files for dtb overlays
    
    Kernel 4.4.6+ on RaspberryPi support .dtbo files for overlays, instead of .dtb.
    Patch the kernel, which has faulty rules to generate .dtbo the way yocto does
    
    Signed-off-by: default avatarHerve Jourdain <herve.jourdain@neuf.fr>
    Signed-off-by: default avatarKhem Raj <raj.khem@gmail.com>
    
    BCM270X: Drop position requirement for CMA in VC4 overlay.
    
    No longer necessary since 2aefcd57
    
    ,
    and will probably let peeople that want to choose a larger CMA
    allocation (particularly on pi0/1).
    
    Signed-off-by: default avatarEric Anholt <eric@anholt.net>
    
    BCM270X_DT: RPi Device Tree tidy
    
    Use the upstream sdhost node, add thermal-zones, and factor out some
    common elements.
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    
    kbuild: Silence unhelpful DTC warnings
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    
    BCM270X_DT: DT build rules no longer arch-specific
    
    Signed-off-by: default avatarPhil Elwell <phil@raspberrypi.org>
    292ab07a