Skip to content

Commit

Permalink
Merge tag 'pwm/for-3.19-rc1' of git://git.kernel.org/pub/scm/linux/ke…
Browse files Browse the repository at this point in the history
…rnel/git/thierry.reding/linux-pwm

Pull pwm updates from Thierry Reding:
 "There are two new drivers, one for the BCM2835 (Raspberry Pi) and one
  used in conjunction with the LCD controller on various Atmel SoCs.
  The Samsung PWM driver can now be built for 64-bit ARM (Exynos7).

  A couple of fixes have been applied to the FTM PWM driver and system
  sleep support was added"

* tag 'pwm/for-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry.reding/linux-pwm:
  pwm: atmel-hlcdc: add at91sam9x5 and sama5d3 errata handling
  pwm: ftm: Add Power Management support for FTM PWM
  pwm: ftm: Add regmap rbtree type cache support
  pwm: ftm: Correctly track usage count
  pwm: samsung: Allow Samsung PWM driver to be enabled on Exynos7
  pwm: add DT bindings documentation for atmel-hlcdc-pwm driver
  pwm: add support for atmel-hlcdc-pwm device
  pwm: Add BCM2835 PWM driver
  • Loading branch information
Linus Torvalds committed Dec 17, 2014
2 parents d797da4 + 39e046f commit 0b4954c
Show file tree
Hide file tree
Showing 7 changed files with 646 additions and 5 deletions.
29 changes: 29 additions & 0 deletions Documentation/devicetree/bindings/pwm/atmel-hlcdc-pwm.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
Device-Tree bindings for Atmel's HLCDC (High-end LCD Controller) PWM driver

The Atmel HLCDC PWM is subdevice of the HLCDC MFD device.
See ../mfd/atmel-hlcdc.txt for more details.

Required properties:
- compatible: value should be one of the following:
"atmel,hlcdc-pwm"
- pinctr-names: the pin control state names. Should contain "default".
- pinctrl-0: should contain the pinctrl states described by pinctrl
default.
- #pwm-cells: should be set to 3. This PWM chip use the default 3 cells
bindings defined in pwm.txt in this directory.

Example:

hlcdc: hlcdc@f0030000 {
compatible = "atmel,sama5d3-hlcdc";
reg = <0xf0030000 0x2000>;
clocks = <&lcdc_clk>, <&lcdck>, <&clk32k>;
clock-names = "periph_clk","sys_clk", "slow_clk";

hlcdc_pwm: hlcdc-pwm {
compatible = "atmel,hlcdc-pwm";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_lcd_pwm>;
#pwm-cells = <3>;
};
};
30 changes: 30 additions & 0 deletions Documentation/devicetree/bindings/pwm/pwm-bcm2835.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
BCM2835 PWM controller (Raspberry Pi controller)

Required properties:
- compatible: should be "brcm,bcm2835-pwm"
- reg: physical base address and length of the controller's registers
- clock: This clock defines the base clock frequency of the PWM hardware
system, the period and the duty_cycle of the PWM signal is a multiple of
the base period.
- #pwm-cells: Should be 2. See pwm.txt in this directory for a description of
the cells format.

Examples:

pwm@2020c000 {
compatible = "brcm,bcm2835-pwm";
reg = <0x2020c000 0x28>;
clocks = <&clk_pwm>;
#pwm-cells = <2>;
};

clocks {
....
clk_pwm: pwm {
compatible = "fixed-clock";
reg = <3>;
#clock-cells = <0>;
clock-frequency = <9200000>;
};
....
};
22 changes: 21 additions & 1 deletion drivers/pwm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,17 @@ config PWM_ATMEL
To compile this driver as a module, choose M here: the module
will be called pwm-atmel.

config PWM_ATMEL_HLCDC_PWM
tristate "Atmel HLCDC PWM support"
depends on MFD_ATMEL_HLCDC
help
Generic PWM framework driver for the PWM output of the HLCDC
(Atmel High-end LCD Controller). This PWM output is mainly used
to control the LCD backlight.

To compile this driver as a module, choose M here: the module
will be called pwm-atmel-hlcdc.

config PWM_ATMEL_TCB
tristate "Atmel TC Block PWM support"
depends on ATMEL_TCLIB && OF
Expand All @@ -71,6 +82,15 @@ config PWM_BCM_KONA
To compile this driver as a module, choose M here: the module
will be called pwm-bcm-kona.

config PWM_BCM2835
tristate "BCM2835 PWM support"
depends on ARCH_BCM2835
help
PWM framework driver for BCM2835 controller (Raspberry Pi)

To compile this driver as a module, choose M here: the module
will be called pwm-bcm2835.

config PWM_BFIN
tristate "Blackfin PWM support"
depends on BFIN_GPTIMERS
Expand Down Expand Up @@ -235,7 +255,7 @@ config PWM_ROCKCHIP

config PWM_SAMSUNG
tristate "Samsung PWM support"
depends on PLAT_SAMSUNG
depends on PLAT_SAMSUNG || ARCH_EXYNOS
help
Generic PWM framework driver for Samsung.

Expand Down
2 changes: 2 additions & 0 deletions drivers/pwm/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@ obj-$(CONFIG_PWM) += core.o
obj-$(CONFIG_PWM_SYSFS) += sysfs.o
obj-$(CONFIG_PWM_AB8500) += pwm-ab8500.o
obj-$(CONFIG_PWM_ATMEL) += pwm-atmel.o
obj-$(CONFIG_PWM_ATMEL_HLCDC_PWM) += pwm-atmel-hlcdc.o
obj-$(CONFIG_PWM_ATMEL_TCB) += pwm-atmel-tcb.o
obj-$(CONFIG_PWM_BCM_KONA) += pwm-bcm-kona.o
obj-$(CONFIG_PWM_BCM2835) += pwm-bcm2835.o
obj-$(CONFIG_PWM_BFIN) += pwm-bfin.o
obj-$(CONFIG_PWM_CLPS711X) += pwm-clps711x.o
obj-$(CONFIG_PWM_EP93XX) += pwm-ep93xx.o
Expand Down
Loading

0 comments on commit 0b4954c

Please sign in to comment.