aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2020-06-19clk: bcm2835: Allow custom CCF flags for the PLLsMaxime Ripard1-1/+2
While some clock types allow for each clock to specify its own custom flags, the PLLs can't. We will need this for the PLLB, so let's add it. Acked-by: Nicolas Saenz Julienne <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/ae8bd505d8851f6646e244cd76b6b289346973c8.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19Revert "clk: bcm2835: remove pllb"Maxime Ripard1-4/+26
This reverts commit 2256d89333bd17b8b56b42734a7e1046d52f7fc3. Since we will be expanding the firmware clock driver, we'll need to remove the quirks to deal with the PLLB. However, we still want to expose the clock tree properly, so having that clock in the MMIO driver will allow that. Acked-by: Nicolas Saenz Julienne <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/5d26a4c58248f5be7760a7f2f720a1310baea5dd.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Give firmware clocks a nameMaxime Ripard1-1/+20
We've registered the firmware clocks using their ID as name, but it's much more convenient to register them using their proper name. Since the firmware doesn't provide it, we have to duplicate it. Acked-by: Nicolas Saenz Julienne <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/a52a5f5768cd33716cdd35237c6613f26ad75013.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Discover the firmware clocksMaxime Ripard1-12/+141
The RaspberryPi4 firmware actually exposes more clocks than are currently handled by the driver and we will need to change some of them directly based on the pixel rate for the display related clocks, or the load for the GPU. Since the firmware implements DVFS, this rate change can have a number of side-effects, including adjusting the various PLL voltages or the PLL parents. The firmware also implements thermal throttling, so even some thermal pressure can change those parameters behind Linux back. DVFS is currently implemented on the arm, core, h264, v3d, isp and hevc clocks, so updating any of them using the MMIO driver (and thus behind the firmware's back) can lead to troubles, the arm clock obviously being the most problematic. In order to make Linux play as nice as possible with those constraints, it makes sense to rely on the firmware clocks as much as possible. However, the firmware doesn't seem to provide some equivalents to their MMIO counterparts, so we can't really replace that driver entirely. Fortunately, the firmware has an interface to discover the clocks it exposes. Let's use it to discover, register the clocks in the clocks framework and then expose them through the device tree for consumers to use them. Cc: Michael Turquette <[email protected]> Cc: Stephen Boyd <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/438d73962741a8c5f7c689319b7443b930a87fde.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Add an enum for the firmware clocksMaxime Ripard1-4/+19
While the firmware allows us to discover the available clocks, we need to discriminate those clocks to only register the ones meaningful to Linux. The firmware also doesn't provide a clock name, so having a list of the ID will help us to give clocks a proper name later on. Acked-by: Nicolas Saenz Julienne <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/4738f77ee7de9b48a3bb1c558ead958d0cc064d9.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Add DT provider for the clocksMaxime Ripard1-0/+16
For the upcoming registration of the clocks provided by the firmware, make sure it's exposed to the device tree providers. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/4d8dbe4aaae98b3d3812ad7c3dba53d645cadbaf.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Make the PLLB registration function return a clk_hwMaxime Ripard1-22/+24
The raspberrypi_register_pllb has been returning an integer so far to notify whether the functions has exited successfully or not. However, the OF provider functions in the clock framework require access to the clk_hw structure so that we can expose those clocks to device tree consumers. Since we'll want that for the future clocks, let's return a clk_hw pointer instead of the return code. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/97218559db643e62fdd2b5e3046a2a05b8c2e769.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Split pllb clock hooksMaxime Ripard1-8/+22
The driver only supports the pllb for now and all the clock framework hooks are a mix of the generic firmware interface and the specifics of the pllb. Since we will support more clocks in the future let's split the generic and specific hooks Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/fdc21962fdc7de5c46232f198672d5d5c868ec74.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Rename is_prepared functionMaxime Ripard1-2/+2
The raspberrypi_fw_pll_is_on function doesn't only apply to PLL registered in the driver, but any clock exposed by the firmware. Since we also implement the is_prepared hook, make the function consistent with the other function names. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/ac93cc4e245316bb7e7426ac5ab0de8f3d919731.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Pass the clocks data to the firmware functionMaxime Ripard1-15/+14
The raspberry_clock_property only takes the clock ID as an argument, but now that we have a clock data structure it makes more sense to just pass that structure instead. Cc: Michael Turquette <[email protected]> Cc: Stephen Boyd <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/d7a3b4df3ca23feb6e0d9c7ae2d232bfb913f926.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Add clock id to dataMaxime Ripard1-9/+9
The driver has really only supported one clock so far and has hardcoded the ID used in communications with the firmware in all the functions implementing the clock framework hooks. Let's store that in the clock data structure so that we can support more clocks later on. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/e23c37961b97b027e21efa3b818578970f88527a.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Create a data structure for the clocksMaxime Ripard1-10/+21
So far the driver has really only been providing a single clock, and stored both the data associated to that clock in particular with the data associated to the "controller". Since we will change that in the future, let's decouple the clock data from the provider data. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/ee7f508db226214fab4add7f93a351f4137c86a1.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Use CCF boundaries instead of rolling our ownMaxime Ripard1-10/+8
The raspberrypi firmware clock driver has a min_rate / max_rate clamping by storing the info it needs in a private structure. However, the CCF already provides such a facility, so we can switch to it to remove the boilerplate. Reviewed-by: Nicolas Saenz Julienne <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/d4c53dab6de5d5f70743d9c139d0117589530e62.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Make sure the clkdev lookup is removedMaxime Ripard1-2/+3
The clkdev lookup created for the cpufreq device is never removed if there's an issue later in probe or at module removal time. Let's convert to the managed variant of the clk_hw_register_clkdev function to make sure it happens. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/075e2c6d315eccdaf8fb72b320712b86e6c25b22.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Switch to clk_hw_register_clkdevMaxime Ripard1-6/+5
Since we don't care about retrieving the clk_lookup structure pointer returned by clkdev_hw_create, we can just use the clk_hw_register_clkdev function. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/59f6208b6fe3367e735b0cca4f65c2c937639af9.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Remove pllb_arm_lookup global pointerMaxime Ripard1-4/+4
The pllb_arm_lookup pointer in the struct raspberrypi_clk is not used for anything but to store the returned pointer to clkdev_hw_create, and is not used anywhere else in the driver. Let's remove that global pointer from the structure. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/189407f54906d2b07c91de7a4eeb6d8c8934280f.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Make sure pllb_arm is removedMaxime Ripard1-2/+1
The pllb_arm clock was created at probe time, but was never removed if something went wrong later in probe, or if the driver was ever removed from the system. Now that we are using clk_hw_register(), we can just use its managed variant to take care of that for us. Cc: Michael Turquette <[email protected]> Cc: Stephen Boyd <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/34254ed1556614658e5dad5cca4cf4fe617df7fc.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Remove global pllb_arm clock pointerMaxime Ripard1-4/+3
The pllb_arm clk_hw pointer in the raspberry_clk structure isn't used anywhere but in the raspberrypi_register_pllb_arm. Let's remove it, this will make our lives easier in future patches. Cc: Michael Turquette <[email protected]> Cc: Stephen Boyd <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/842859cf1a77478620f45049178a588448202858.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Use clk_hw_register for pllb_armMaxime Ripard1-6/+18
The pllb_arm clock is defined as a fixed factor clock with the pllb clock as a parent. However, all its configuration is entirely static, and thus we don't really need to call clk_hw_register_fixed_factor() but can simply call clk_hw_register() with a static clk_fixed_factor structure. Cc: Michael Turquette <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/1146177664999eeda65856d28ce94025021dd85e.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Statically init clk_init_dataMaxime Ripard1-2/+1
Instead of declaring the clk_init_data and then calling memset on it, just initialise properly. Cc: Michael Turquette <[email protected]> Cc: Stephen Boyd <[email protected]> Cc: [email protected] Acked-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/0342572daa561dc1bb4c9fd10641b2016493e32b.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: rpi: Allow the driver to be probed by DTMaxime Ripard1-2/+17
The current firmware clock driver for the RaspberryPi can only be probed by manually registering an associated platform_device. While this works fine for cpufreq where the device gets attached a clkdev lookup, it would be tedious to maintain a table of all the devices using one of the clocks exposed by the firmware. Since the DT on the other hand is the perfect place to store those associations, make the firmware clocks driver probe-able through the device tree so that we can represent it as a node. Cc: Michael Turquette <[email protected]> Cc: [email protected] Reviewed-by: Nicolas Saenz Julienne <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/cb8203b862e386ac6c3df3eff0bb5a238b6ec97a.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19firmware: rpi: Only create clocks device if we don't have a node for itMaxime Ripard1-0/+14
The firmware clocks driver was previously probed through a platform_device created by the firmware driver. Since we will now have a node for that clocks driver, we need to create the device only in the case where there's no node for it already. Reviewed-by: Nicolas Saenz Julienne <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/72114c4287ebda2dbd952ea238d4489d359897e5.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19dt-bindings: clock: Add a binding for the RPi Firmware clocksMaxime Ripard1-0/+24
The firmware running on the RPi VideoCore can be used to discover and change the various clocks running in the BCM2711. Since devices will need to use them through the DT, let's add a pretty simple binding. Cc: Michael Turquette <[email protected]> Cc: [email protected] Cc: [email protected] Reviewed-by: Stephen Boyd <[email protected]> Reviewed-by: Rob Herring <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/f6105207e7ef5a5ea8d7a1774faf989d341a25f5.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19dt-bindings: arm: bcm: Convert BCM2835 firmware binding to YAMLFlorian Fainelli2-14/+35
Convert the Raspberry Pi BCM2835 firmware binding document to YAML. Verified with dt_binding_check and dtbs_check. Signed-off-by: Florian Fainelli <[email protected]> Tested-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/5bc0b9be8544b07300fccab4d4f26e5e5d8e62b2.1592210452.git-series.maxime@cerno.tech Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm: Add BCM2711 DVP driverMaxime Ripard3-0/+132
The HDMI block has a block that controls clocks and reset signals to the HDMI0 and HDMI1 controllers. Let's expose that through a clock driver implementing a clock and reset provider. Cc: Michael Turquette <[email protected]> Cc: Stephen Boyd <[email protected]> Cc: Rob Herring <[email protected]> Cc: [email protected] Cc: [email protected] Reviewed-by: Stephen Boyd <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/bb60d97fc76b61c2eabef5a02ebd664c0f57ede0.1591867332.git-series.maxime@cerno.tech Acked-by: Stefan Wahren <[email protected]> Reviewed-by: Nicolas Saenz Julienne <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19dt-bindings: clock: Add BCM2711 DVP bindingMaxime Ripard1-0/+47
The BCM2711 has a unit controlling the HDMI0 and HDMI1 clock and reset signals. Let's add a binding for it. Cc: Philipp Zabel <[email protected]> Cc: Rob Herring <[email protected]> Cc: [email protected] Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Link: https://lore.kernel.org/r/0b8f09baff1ff3c471631e6f523e2b2cd773ec47.1591867332.git-series.maxime@cerno.tech Acked-by: Stefan Wahren <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19Merge branch 'reset/simple' of git://git.pengutronix.de/git/pza/linux into ↵Stephen Boyd5-8/+31
clk-bcm Pull immutable reset branch to get reset-simple header. * 'reset/simple' of git://git.pengutronix.de/git/pza/linux: reset: simple: Add reset callback reset: Move reset-simple header out of drivers/reset
2020-06-19clk: bcm63xx-gate: switch to dt-bindings definitionsÁlvaro Fernández Rojas1-141/+439
Now that there are header files for each SoC, let's use them in the bcm63xx-gate controller driver. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM63268 clock definitionsÁlvaro Fernández Rojas1-0/+30
Add header with BCM63268 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM6368 clock definitionsÁlvaro Fernández Rojas1-0/+24
Add header with BCM6368 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM6362 clock definitionsÁlvaro Fernández Rojas1-0/+26
Add header with BCM6362 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM6358 clock definitionsÁlvaro Fernández Rojas1-0/+18
Add header with BCM6358 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM6328 clock definitionsÁlvaro Fernández Rojas1-0/+19
Add header with BCM6328 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM6318 clock definitionsÁlvaro Fernández Rojas1-0/+42
Add header with BCM6318 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19mips: bmips: add BCM3368 clock definitionsÁlvaro Fernández Rojas1-0/+24
Add header with BCM3368 definitions in order to be able to include it from device tree files. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm63xx-gate: add BCM6318 supportÁlvaro Fernández Rojas1-0/+44
Add support for the gated clock controllers found on the BCM6318. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Reviewed-by: Florian Fainelli <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19dt-bindings: clock: bcm63xx: add 6318 gated clock bindingsÁlvaro Fernández Rojas1-0/+2
Add BCM6318 to the binding documentation for the gated clock controllers found on BCM63xx SoCs. Signed-off-by: Álvaro Fernández Rojas <[email protected]> Reviewed-by: Florian Fainelli <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: Rob Herring <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: bcm63xx-gate: fix last clock availabilityÁlvaro Fernández Rojas1-0/+1
In order to make the last clock available, maxbit has to be set to the highest bit value plus 1. Fixes: 1c099779c1e2 ("clk: add BCM63XX gated clock controller driver") Signed-off-by: Álvaro Fernández Rojas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Florian Fainelli <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
2020-06-19clk: meson: g12a: Add support for NNA CLK source clocksDmitry Shmidt2-1/+125
This adds the Neural Network Accelerator source clocks hierarchy, it's 2 simple composite clocks to feed the AXI interface and the Core of the Neural Network Accelerator IP. This IP is only present on the Amlogic SM1 SoCs family. Signed-off-by: Dmitry Shmidt <[email protected]> Signed-off-by: Neil Armstrong <[email protected]> Signed-off-by: Jerome Brunet <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2020-06-19dt-bindings: clk: g12a-clkc: Add NNA CLK Source clock IDsDmitry Shmidt1-0/+2
This adds the Neural Network Accelerator IP source clocks. Signed-off-by: Dmitry Shmidt <[email protected]> Signed-off-by: Neil Armstrong <[email protected]> Signed-off-by: Jerome Brunet <[email protected]> Acked-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2020-06-17dt-bindings: clocks: add rk3288w variant compatibleMylène Josserand1-1/+7
Add the possible compatible "rockchip,rk3288w-cru" that handles the difference between the rk3288 and the new revision rk3288w. This compatible will be added by bootloaders. Signed-off-by: Mylène Josserand <[email protected]> Acked-by: Rob Herring <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Heiko Stuebner <[email protected]>
2020-06-17clk: rockchip: Handle clock tree for rk3288w variantMylène Josserand1-2/+18
The revision rk3288w has a different clock tree about "hclk_vio" clock, according to the BSP kernel code. This patch handles this difference by detecting which device-tree we are using. If it is a "rockchip,rk3288-cru", let's register the clock tree as it was before. If the device-tree node is "rockchip,rk3288w-cru", we will apply the difference with this version of this SoC. Noticed that this new device-tree compatible must be handled in bootloader such as u-boot. Signed-off-by: Mylène Josserand <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Heiko Stuebner <[email protected]>
2020-06-16reset: simple: Add reset callbackMaxime Ripard2-0/+27
The reset-simple code lacks a reset callback that is still pretty easy to implement. The only real thing to consider is the delay needed for a device to be reset, so let's expose that as part of the reset-simple driver data. Reviewed-by: Philipp Zabel <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Signed-off-by: Philipp Zabel <[email protected]>
2020-06-16reset: Move reset-simple header out of drivers/resetMaxime Ripard5-8/+4
The reset-simple code can be useful for drivers outside of drivers/reset that have a few reset controls as part of their features. Let's move it to include/linux/reset. Reviewed-by: Philipp Zabel <[email protected]> Signed-off-by: Maxime Ripard <[email protected]> Signed-off-by: Philipp Zabel <[email protected]>
2020-06-15clk: rockchip: convert rk3036 pll type to use internal lock statusHeiko Stuebner1-3/+23
The rk3036 pll type exposes its lock status in both its pllcon registers as well as the General Register Files. To remove one dependency convert it to the "internal" lock status, similar to how rk3399 handles it. Signed-off-by: Heiko Stuebner <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2020-06-15clk: rockchip: convert basic pll lock_wait to use regmap_read_poll_timeoutHeiko Stuebner1-15/+6
Instead of open coding the polling of the lock status, use the handy regmap_read_poll_timeout for this. As the pll locking is normally blazingly fast and we don't want to incur additional delays, we're not doing any sleeps similar to for example the imx clk-pllv4 and define a very safe but still short timeout of 1ms. Suggested-by: Stephen Boyd <[email protected]> Signed-off-by: Heiko Stuebner <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2020-06-15clk: rockchip: convert rk3399 pll type to use readl_relaxed_poll_timeoutHeiko Stuebner1-11/+12
Instead of open coding the polling of the lock status, use the handy readl_relaxed_poll_timeout for this. As the pll locking is normally blazingly fast and we don't want to incur additional delays, we're not doing any sleeps similar to for example the imx clk-pllv4 and define a very safe but still short timeout of 1ms. Suggested-by: Stephen Boyd <[email protected]> Signed-off-by: Heiko Stuebner <[email protected]> Reviewed-by: Stephen Boyd <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2020-06-15dt-bindings: clock: renesas: cpg: Convert to json-schemaGeert Uytterhoeven7-258/+241
Convert the Renesas Clock Pulse Generator (CPG) Device Tree binding documentation to json-schema, combining support for: - R-Mobile APE6 (R8A73A4) and A1 (R8A7740), - R-Car M1 (R8A7778) and H1 (R8A7779), - RZ/A1 (R7S72100), - SH-Mobile AG5 (SH73A0). Keep the example for R-Mobile A1, which shows most properties. Drop the consumer examples, as they do not belong here. Signed-off-by: Geert Uytterhoeven <[email protected]> Reviewed-by: Rob Herring <[email protected]> Acked-by: Stephen Boyd <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2020-06-14Linux 5.8-rc1Linus Torvalds1-2/+2
2020-06-14Merge tag 'LSM-add-setgid-hook-5.8-author-fix' of ↵Linus Torvalds5-1/+40
git://github.com/micah-morton/linux Pull SafeSetID update from Micah Morton: "Add additional LSM hooks for SafeSetID SafeSetID is capable of making allow/deny decisions for set*uid calls on a system, and we want to add similar functionality for set*gid calls. The work to do that is not yet complete, so probably won't make it in for v5.8, but we are looking to get this simple patch in for v5.8 since we have it ready. We are planning on the rest of the work for extending the SafeSetID LSM being merged during the v5.9 merge window" * tag 'LSM-add-setgid-hook-5.8-author-fix' of git://github.com/micah-morton/linux: security: Add LSM hooks to set*gid syscalls