Skip to content
Commit a294aba1 authored by Silvan Wicki's avatar Silvan Wicki Committed by Wolfram Sang
Browse files

i2c: busses: i2c-bcm2835: limits cdiv to allowed values

Checks if the cdiv value is in between min (0x2) and max (0xFFFE)
supported values by the bcm2835. If not, it returns -ENODEV.

See page 33/34 of BCM2835-ARM-Peripherals.pdf for the DIV register.
https://www.raspberrypi.org/wp-content/uploads/2012/02/BCM2835-ARM-Peripherals.pdf



Signed-off-by: default avatarSilvan Wicki <linux_wi@tinag.ch>
[wsa: resolved a merge conflict]
Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
parent 365322fb
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment