HomeFreeBSD

[pi] Do not attach bcm2835_pwm if DTB node is not enabled

Description

[pi] Do not attach bcm2835_pwm if DTB node is not enabled

Switch to standard FDT-base driver behavior and don't attach
if node "status" property value nn DTS is not set to "okay"

On RPi PWM by default is disabled, to enable it pwm.dtbo
from official repo[1] should be copied to overlays directory
on SD card FAT partition and "dtoverlay=pwm" line added to
config.txt. For more details see pwm overlay documentation[2]

sysutils/rpi-firmware port now includes overlays, so they
can be installed as a part of release image build.

[1] https://github.com/raspberrypi/firmware/tree/master/boot
[2] https://github.com/raspberrypi/firmware/blob/master/boot/overlays/README

No objections from: phk@

Details

Provenance
gonzoAuthored on
Parents
rS332391: MFC r329388, r331441 and r331898, to bring the -CURRENT ck version.
Branches
Unknown
Tags
Unknown