* [PATCH v7 0/7] Initial Device Tree support for S3C64xx @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This series adds Device Tree support for Samsung S3C64xx SoC series. It fixes several problems preventing from booting an S3C64xx-based system using Device Tree, adds all the infrastructure for Device Tree-based board support, including mach-s3c64xx-dt and dts include files for S3C64xx SoCs, and basic device tree source for FriendlyARM Mini6410 and SAMSUNG SMDK6410 boards. Current support is somewhat limite, but should be fine as a start and will be extended in future, hopefully with help of S3C64xx board maintainers. Depends on: - [PATCH v2 0/8] Common Clock Framework support for Samsung S3C64xx http://thread.gmane.org/gmane.linux.usb.general/90493 On Samsung S3C6410-based Mini6410 and SMDK6410 boards: Tested-by: Tomasz Figa <tomasz.figa@gmail.com> Changes since v6: - Rebased onto current for-next branch of Kgene's tree, - Dropped the idea of .init_platform() machine callback, - Added support for i2c controllers, - Replaced separate apb and ahb nodes with a single common soc node, - Updated cpus node according to CPU bindings, - Updated fixed rate clock nodes to use generic bindings, - Added support for PWM buzzer and I2C EEPROM on Mini6410 board, - Simplified the condition of skipping legacy GPIO initialization. Changes since v5: - Rebased onto current for-next branch of Kgene's tree, - Added support for new Common Clock Framework based clock driver, - Introduced hierarchical structure of device nodes (representing physical AHB and APB buses), - Bypassed most of legacy initialization when booting with DT, - Used preprocessor macros in dts files to improve readabilty, - Added support for SMDK6410 board. Changes since v4: - Rebased onto current for-next branch of Kgene's tree - Added support for pinctrl (driver merged through pinctrl tree) - Added labels to all nodes that can be overridden from board dts - Modified board dts to use the &label syntax to reference device nodes Changes since v3: - Rebased onto current for-next branch of Kgene's tree - Updated timer node for next version of samsung-time patches - Replaced local s3c64xx_dt_init_irq with irqchip_init Changes since v2: - Updated timer node for next version of samsung-time patches Changes since v1: - Dropped two VIC-related patches that are no longer necessary - Added Device Tree-based instantation of system timers - Corrected VIC interrupt specifiers - Adjusted CPU compatible values and dropped @id Tomasz Figa (7): ARM: common: vic: Parse interrupt and resume masks from device tree ARM: s3c64xx: Bypass legacy initialization when booting with DT gpio: samsung: Skip initialization if device tree is present ARM: s3c64xx: Add board file for boot using Device Tree ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs ARM: dts: Add dts file for S3C6410-based Mini6410 board ARM: dts: Add dts file for S3C6410-based SMDK6410 board Documentation/devicetree/bindings/arm/vic.txt | 6 + arch/arm/boot/dts/Makefile | 2 + arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410-mini6410.dts | 228 +++++++++ arch/arm/boot/dts/s3c6410-smdk6410.dts | 103 ++++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 ++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++ arch/arm/mach-s3c64xx/Kconfig | 16 + arch/arm/mach-s3c64xx/Makefile | 1 + arch/arm/mach-s3c64xx/common.c | 12 + arch/arm/mach-s3c64xx/dma.c | 9 + arch/arm/mach-s3c64xx/irq-pm.c | 9 + arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 85 ++++ arch/arm/mach-s3c64xx/s3c6400.c | 9 + arch/arm/mach-s3c64xx/s3c6410.c | 9 + arch/arm/plat-samsung/init.c | 12 +- drivers/gpio/gpio-samsung.c | 34 +- drivers/irqchip/irq-vic.c | 7 +- 19 files changed, 1497 insertions(+), 29 deletions(-) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410-mini6410.dts create mode 100644 arch/arm/boot/dts/s3c6410-smdk6410.dts create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi create mode 100644 arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c -- 1.8.3.2 ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 0/7] Initial Device Tree support for S3C64xx @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This series adds Device Tree support for Samsung S3C64xx SoC series. It fixes several problems preventing from booting an S3C64xx-based system using Device Tree, adds all the infrastructure for Device Tree-based board support, including mach-s3c64xx-dt and dts include files for S3C64xx SoCs, and basic device tree source for FriendlyARM Mini6410 and SAMSUNG SMDK6410 boards. Current support is somewhat limite, but should be fine as a start and will be extended in future, hopefully with help of S3C64xx board maintainers. Depends on: - [PATCH v2 0/8] Common Clock Framework support for Samsung S3C64xx http://thread.gmane.org/gmane.linux.usb.general/90493 On Samsung S3C6410-based Mini6410 and SMDK6410 boards: Tested-by: Tomasz Figa <tomasz.figa@gmail.com> Changes since v6: - Rebased onto current for-next branch of Kgene's tree, - Dropped the idea of .init_platform() machine callback, - Added support for i2c controllers, - Replaced separate apb and ahb nodes with a single common soc node, - Updated cpus node according to CPU bindings, - Updated fixed rate clock nodes to use generic bindings, - Added support for PWM buzzer and I2C EEPROM on Mini6410 board, - Simplified the condition of skipping legacy GPIO initialization. Changes since v5: - Rebased onto current for-next branch of Kgene's tree, - Added support for new Common Clock Framework based clock driver, - Introduced hierarchical structure of device nodes (representing physical AHB and APB buses), - Bypassed most of legacy initialization when booting with DT, - Used preprocessor macros in dts files to improve readabilty, - Added support for SMDK6410 board. Changes since v4: - Rebased onto current for-next branch of Kgene's tree - Added support for pinctrl (driver merged through pinctrl tree) - Added labels to all nodes that can be overridden from board dts - Modified board dts to use the &label syntax to reference device nodes Changes since v3: - Rebased onto current for-next branch of Kgene's tree - Updated timer node for next version of samsung-time patches - Replaced local s3c64xx_dt_init_irq with irqchip_init Changes since v2: - Updated timer node for next version of samsung-time patches Changes since v1: - Dropped two VIC-related patches that are no longer necessary - Added Device Tree-based instantation of system timers - Corrected VIC interrupt specifiers - Adjusted CPU compatible values and dropped @id Tomasz Figa (7): ARM: common: vic: Parse interrupt and resume masks from device tree ARM: s3c64xx: Bypass legacy initialization when booting with DT gpio: samsung: Skip initialization if device tree is present ARM: s3c64xx: Add board file for boot using Device Tree ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs ARM: dts: Add dts file for S3C6410-based Mini6410 board ARM: dts: Add dts file for S3C6410-based SMDK6410 board Documentation/devicetree/bindings/arm/vic.txt | 6 + arch/arm/boot/dts/Makefile | 2 + arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410-mini6410.dts | 228 +++++++++ arch/arm/boot/dts/s3c6410-smdk6410.dts | 103 ++++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 ++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++ arch/arm/mach-s3c64xx/Kconfig | 16 + arch/arm/mach-s3c64xx/Makefile | 1 + arch/arm/mach-s3c64xx/common.c | 12 + arch/arm/mach-s3c64xx/dma.c | 9 + arch/arm/mach-s3c64xx/irq-pm.c | 9 + arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 85 ++++ arch/arm/mach-s3c64xx/s3c6400.c | 9 + arch/arm/mach-s3c64xx/s3c6410.c | 9 + arch/arm/plat-samsung/init.c | 12 +- drivers/gpio/gpio-samsung.c | 34 +- drivers/irqchip/irq-vic.c | 7 +- 19 files changed, 1497 insertions(+), 29 deletions(-) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410-mini6410.dts create mode 100644 arch/arm/boot/dts/s3c6410-smdk6410.dts create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi create mode 100644 arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c -- 1.8.3.2 ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This patch extends vic_of_init to parse valid interrupt sources and resume sources masks from device tree. If mask values are not specified in device tree, all sources are assumed to be valid, as before this patch. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- Documentation/devicetree/bindings/arm/vic.txt | 6 ++++++ drivers/irqchip/irq-vic.c | 7 ++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt index 266716b..bb7137c 100644 --- a/Documentation/devicetree/bindings/arm/vic.txt +++ b/Documentation/devicetree/bindings/arm/vic.txt @@ -18,6 +18,9 @@ Required properties: Optional properties: - interrupts : Interrupt source for parent controllers if the VIC is nested. +- interrupt-mask : Bit mask of valid interrupt sources (defaults to all valid) +- wakeup-mask : Bit mask of interrupt sources that can wake up the system + (defaults to all allowed) Example: @@ -26,4 +29,7 @@ Example: interrupt-controller; #interrupt-cells = <1>; reg = <0x60000 0x1000>; + + interrupt-mask = <0xffffff7f>; + wakeup-mask = <0x0000ff7f>; }; diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c index 2bbb004..d56750eb 100644 --- a/drivers/irqchip/irq-vic.c +++ b/drivers/irqchip/irq-vic.c @@ -469,6 +469,8 @@ void __init vic_init(void __iomem *base, unsigned int irq_start, int __init vic_of_init(struct device_node *node, struct device_node *parent) { void __iomem *regs; + u32 interrupt_mask = ~0; + u32 wakeup_mask = ~0; if (WARN(parent, "non-root VICs are not supported")) return -EINVAL; @@ -477,10 +479,13 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) if (WARN_ON(!regs)) return -EIO; + of_property_read_u32(node, "interrupt-mask", &interrupt_mask); + of_property_read_u32(node, "wakeup-mask", &wakeup_mask); + /* * Passing 0 as first IRQ makes the simple domain allocate descriptors */ - __vic_init(regs, 0, ~0, ~0, node); + __vic_init(regs, 0, interrupt_mask, wakeup_mask, node); return 0; } -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This patch extends vic_of_init to parse valid interrupt sources and resume sources masks from device tree. If mask values are not specified in device tree, all sources are assumed to be valid, as before this patch. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- Documentation/devicetree/bindings/arm/vic.txt | 6 ++++++ drivers/irqchip/irq-vic.c | 7 ++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt index 266716b..bb7137c 100644 --- a/Documentation/devicetree/bindings/arm/vic.txt +++ b/Documentation/devicetree/bindings/arm/vic.txt @@ -18,6 +18,9 @@ Required properties: Optional properties: - interrupts : Interrupt source for parent controllers if the VIC is nested. +- interrupt-mask : Bit mask of valid interrupt sources (defaults to all valid) +- wakeup-mask : Bit mask of interrupt sources that can wake up the system + (defaults to all allowed) Example: @@ -26,4 +29,7 @@ Example: interrupt-controller; #interrupt-cells = <1>; reg = <0x60000 0x1000>; + + interrupt-mask = <0xffffff7f>; + wakeup-mask = <0x0000ff7f>; }; diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c index 2bbb004..d56750eb 100644 --- a/drivers/irqchip/irq-vic.c +++ b/drivers/irqchip/irq-vic.c @@ -469,6 +469,8 @@ void __init vic_init(void __iomem *base, unsigned int irq_start, int __init vic_of_init(struct device_node *node, struct device_node *parent) { void __iomem *regs; + u32 interrupt_mask = ~0; + u32 wakeup_mask = ~0; if (WARN(parent, "non-root VICs are not supported")) return -EINVAL; @@ -477,10 +479,13 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) if (WARN_ON(!regs)) return -EIO; + of_property_read_u32(node, "interrupt-mask", &interrupt_mask); + of_property_read_u32(node, "wakeup-mask", &wakeup_mask); + /* * Passing 0 as first IRQ makes the simple domain allocate descriptors */ - __vic_init(regs, 0, ~0, ~0, node); + __vic_init(regs, 0, interrupt_mask, wakeup_mask, node); return 0; } -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* Re: [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 23:19 ` Linus Walleij -1 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-21 23:19 UTC (permalink / raw) To: Tomasz Figa Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > +++ b/Documentation/devicetree/bindings/arm/vic.txt > @@ -18,6 +18,9 @@ Required properties: > Optional properties: > > - interrupts : Interrupt source for parent controllers if the VIC is nested. > +- interrupt-mask : Bit mask of valid interrupt sources (defaults to all valid) > +- wakeup-mask : Bit mask of interrupt sources that can wake up the system > + (defaults to all allowed) The "interrupt-mask" is called "valid-mask" on the FPGA IRQ controller See Documentation/devicetree/bindings/arm/versatile-fpga-irq.txt Example: reg = <0x10000040 0x100>; clear-mask = <0xffffffff>; valid-mask = <0x00000007>; Please use the same name. (wakeup-mask is fine). Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree @ 2013-08-21 23:19 ` Linus Walleij 0 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-21 23:19 UTC (permalink / raw) To: linux-arm-kernel On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > +++ b/Documentation/devicetree/bindings/arm/vic.txt > @@ -18,6 +18,9 @@ Required properties: > Optional properties: > > - interrupts : Interrupt source for parent controllers if the VIC is nested. > +- interrupt-mask : Bit mask of valid interrupt sources (defaults to all valid) > +- wakeup-mask : Bit mask of interrupt sources that can wake up the system > + (defaults to all allowed) The "interrupt-mask" is called "valid-mask" on the FPGA IRQ controller See Documentation/devicetree/bindings/arm/versatile-fpga-irq.txt Example: reg = <0x10000040 0x100>; clear-mask = <0xffffffff>; valid-mask = <0x00000007>; Please use the same name. (wakeup-mask is fine). Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree 2013-08-21 23:19 ` Linus Walleij @ 2013-08-22 7:57 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 7:57 UTC (permalink / raw) To: Linus Walleij Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Thursday 22 of August 2013 01:19:34 Linus Walleij wrote: > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > > +++ b/Documentation/devicetree/bindings/arm/vic.txt > > > > @@ -18,6 +18,9 @@ Required properties: > > Optional properties: > > > > - interrupts : Interrupt source for parent controllers if the VIC is > > nested.> > > +- interrupt-mask : Bit mask of valid interrupt sources (defaults to > > all valid) +- wakeup-mask : Bit mask of interrupt sources that can > > wake up the system + (defaults to all allowed) > > The "interrupt-mask" is called "valid-mask" on the FPGA IRQ controller > See > Documentation/devicetree/bindings/arm/versatile-fpga-irq.txt > > Example: > > reg = <0x10000040 0x100>; > clear-mask = <0xffffffff>; > valid-mask = <0x00000007>; > > Please use the same name. Oh, I haven't noticed that. Thanks for the information. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree @ 2013-08-22 7:57 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 7:57 UTC (permalink / raw) To: linux-arm-kernel On Thursday 22 of August 2013 01:19:34 Linus Walleij wrote: > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > > +++ b/Documentation/devicetree/bindings/arm/vic.txt > > > > @@ -18,6 +18,9 @@ Required properties: > > Optional properties: > > > > - interrupts : Interrupt source for parent controllers if the VIC is > > nested.> > > +- interrupt-mask : Bit mask of valid interrupt sources (defaults to > > all valid) +- wakeup-mask : Bit mask of interrupt sources that can > > wake up the system + (defaults to all allowed) > > The "interrupt-mask" is called "valid-mask" on the FPGA IRQ controller > See > Documentation/devicetree/bindings/arm/versatile-fpga-irq.txt > > Example: > > reg = <0x10000040 0x100>; > clear-mask = <0xffffffff>; > valid-mask = <0x00000007>; > > Please use the same name. Oh, I haven't noticed that. Thanks for the information. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-22 23:22 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 23:22 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown This patch extends vic_of_init to parse valid interrupt sources and resume sources masks from device tree. If mask values are not specified in device tree, all sources are assumed to be valid, as before this patch. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- Documentation/devicetree/bindings/arm/vic.txt | 6 ++++++ drivers/irqchip/irq-vic.c | 7 ++++++- 2 files changed, 12 insertions(+), 1 deletion(-) Changes since v7: - Renamed interrupt-mask property to valid-mask, for consistency with bindings of other interrupt controllers. diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt index 266716b..3379666 100644 --- a/Documentation/devicetree/bindings/arm/vic.txt +++ b/Documentation/devicetree/bindings/arm/vic.txt @@ -18,6 +18,9 @@ Required properties: Optional properties: - interrupts : Interrupt source for parent controllers if the VIC is nested. +- valid-mask : Bit mask of valid interrupt sources (defaults to all valid) +- wakeup-mask : Bit mask of interrupt sources that can wake up the system + (defaults to all allowed) Example: @@ -26,4 +29,7 @@ Example: interrupt-controller; #interrupt-cells = <1>; reg = <0x60000 0x1000>; + + valid-mask = <0xffffff7f>; + wakeup-mask = <0x0000ff7f>; }; diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c index 2bbb004..6437b18 100644 --- a/drivers/irqchip/irq-vic.c +++ b/drivers/irqchip/irq-vic.c @@ -469,6 +469,8 @@ void __init vic_init(void __iomem *base, unsigned int irq_start, int __init vic_of_init(struct device_node *node, struct device_node *parent) { void __iomem *regs; + u32 interrupt_mask = ~0; + u32 wakeup_mask = ~0; if (WARN(parent, "non-root VICs are not supported")) return -EINVAL; @@ -477,10 +479,13 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) if (WARN_ON(!regs)) return -EIO; + of_property_read_u32(node, "valid-mask", &interrupt_mask); + of_property_read_u32(node, "wakeup-mask", &wakeup_mask); + /* * Passing 0 as first IRQ makes the simple domain allocate descriptors */ - __vic_init(regs, 0, ~0, ~0, node); + __vic_init(regs, 0, interrupt_mask, wakeup_mask, node); return 0; } -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-22 23:22 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 23:22 UTC (permalink / raw) To: linux-arm-kernel This patch extends vic_of_init to parse valid interrupt sources and resume sources masks from device tree. If mask values are not specified in device tree, all sources are assumed to be valid, as before this patch. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- Documentation/devicetree/bindings/arm/vic.txt | 6 ++++++ drivers/irqchip/irq-vic.c | 7 ++++++- 2 files changed, 12 insertions(+), 1 deletion(-) Changes since v7: - Renamed interrupt-mask property to valid-mask, for consistency with bindings of other interrupt controllers. diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt index 266716b..3379666 100644 --- a/Documentation/devicetree/bindings/arm/vic.txt +++ b/Documentation/devicetree/bindings/arm/vic.txt @@ -18,6 +18,9 @@ Required properties: Optional properties: - interrupts : Interrupt source for parent controllers if the VIC is nested. +- valid-mask : Bit mask of valid interrupt sources (defaults to all valid) +- wakeup-mask : Bit mask of interrupt sources that can wake up the system + (defaults to all allowed) Example: @@ -26,4 +29,7 @@ Example: interrupt-controller; #interrupt-cells = <1>; reg = <0x60000 0x1000>; + + valid-mask = <0xffffff7f>; + wakeup-mask = <0x0000ff7f>; }; diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c index 2bbb004..6437b18 100644 --- a/drivers/irqchip/irq-vic.c +++ b/drivers/irqchip/irq-vic.c @@ -469,6 +469,8 @@ void __init vic_init(void __iomem *base, unsigned int irq_start, int __init vic_of_init(struct device_node *node, struct device_node *parent) { void __iomem *regs; + u32 interrupt_mask = ~0; + u32 wakeup_mask = ~0; if (WARN(parent, "non-root VICs are not supported")) return -EINVAL; @@ -477,10 +479,13 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) if (WARN_ON(!regs)) return -EIO; + of_property_read_u32(node, "valid-mask", &interrupt_mask); + of_property_read_u32(node, "wakeup-mask", &wakeup_mask); + /* * Passing 0 as first IRQ makes the simple domain allocate descriptors */ - __vic_init(regs, 0, ~0, ~0, node); + __vic_init(regs, 0, interrupt_mask, wakeup_mask, node); return 0; } -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-22 23:22 ` Tomasz Figa @ 2013-08-23 18:12 ` Linus Walleij -1 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-23 18:12 UTC (permalink / raw) To: Tomasz Figa Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Fri, Aug 23, 2013 at 1:22 AM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > This patch extends vic_of_init to parse valid interrupt sources > and resume sources masks from device tree. > > If mask values are not specified in device tree, all sources > are assumed to be valid, as before this patch. > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > --- > Documentation/devicetree/bindings/arm/vic.txt | 6 ++++++ > drivers/irqchip/irq-vic.c | 7 ++++++- > 2 files changed, 12 insertions(+), 1 deletion(-) > > Changes since v7: > - Renamed interrupt-mask property to valid-mask, for consistency with > bindings of other interrupt controllers. Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-23 18:12 ` Linus Walleij 0 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-23 18:12 UTC (permalink / raw) To: linux-arm-kernel On Fri, Aug 23, 2013 at 1:22 AM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > This patch extends vic_of_init to parse valid interrupt sources > and resume sources masks from device tree. > > If mask values are not specified in device tree, all sources > are assumed to be valid, as before this patch. > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > --- > Documentation/devicetree/bindings/arm/vic.txt | 6 ++++++ > drivers/irqchip/irq-vic.c | 7 ++++++- > 2 files changed, 12 insertions(+), 1 deletion(-) > > Changes since v7: > - Renamed interrupt-mask property to valid-mask, for consistency with > bindings of other interrupt controllers. Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-22 23:22 ` Tomasz Figa @ 2013-08-23 22:11 ` Stephen Warren -1 siblings, 0 replies; 64+ messages in thread From: Stephen Warren @ 2013-08-23 22:11 UTC (permalink / raw) To: Tomasz Figa Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On 08/22/2013 05:22 PM, Tomasz Figa wrote: > This patch extends vic_of_init to parse valid interrupt sources > and resume sources masks from device tree. > > If mask values are not specified in device tree, all sources > are assumed to be valid, as before this patch. Can you explain further why the VIC needs this information up-front? Presumably it can accumulate it as devices request interrupts. > diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt > +- valid-mask : Bit mask of valid interrupt sources (defaults to all valid) Until a device requests an interrupt, it can be left disabled. Once something does request it, it gets enabled. If nothing requests it, it never gets enabled. Doesn't the result of that logic end up being the same thing as valid-mask represents? The only difference would be if some device requests an invalid interrupt source, but then why not just fix the interrupt client instead of adding this property to reject the request? > +- wakeup-mask : Bit mask of interrupt sources that can wake up the system > + (defaults to all allowed) Shouldn't drivers for end-devices request interrupts, and then set wake enable on those interrupts, which would then trickle up the IRQ chain to tell the VIC which interrupts to enable wakeup on? ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-23 22:11 ` Stephen Warren 0 siblings, 0 replies; 64+ messages in thread From: Stephen Warren @ 2013-08-23 22:11 UTC (permalink / raw) To: linux-arm-kernel On 08/22/2013 05:22 PM, Tomasz Figa wrote: > This patch extends vic_of_init to parse valid interrupt sources > and resume sources masks from device tree. > > If mask values are not specified in device tree, all sources > are assumed to be valid, as before this patch. Can you explain further why the VIC needs this information up-front? Presumably it can accumulate it as devices request interrupts. > diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt > +- valid-mask : Bit mask of valid interrupt sources (defaults to all valid) Until a device requests an interrupt, it can be left disabled. Once something does request it, it gets enabled. If nothing requests it, it never gets enabled. Doesn't the result of that logic end up being the same thing as valid-mask represents? The only difference would be if some device requests an invalid interrupt source, but then why not just fix the interrupt client instead of adding this property to reject the request? > +- wakeup-mask : Bit mask of interrupt sources that can wake up the system > + (defaults to all allowed) Shouldn't drivers for end-devices request interrupts, and then set wake enable on those interrupts, which would then trickle up the IRQ chain to tell the VIC which interrupts to enable wakeup on? ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-23 22:11 ` Stephen Warren @ 2013-08-23 23:04 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:04 UTC (permalink / raw) To: Stephen Warren Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > On 08/22/2013 05:22 PM, Tomasz Figa wrote: > > This patch extends vic_of_init to parse valid interrupt sources > > and resume sources masks from device tree. > > > > If mask values are not specified in device tree, all sources > > are assumed to be valid, as before this patch. > > Can you explain further why the VIC needs this information up-front? > Presumably it can accumulate it as devices request interrupts. It does not need this information just for operation, but this makes the hardware description more detailed and allows better sanity checking of interrupts being requested. To clarify, this is a mask of valid interrupt sources of the VIC, where set bit indicates that given signal is wired and clear bit that it is not. > > diff --git a/Documentation/devicetree/bindings/arm/vic.txt > > b/Documentation/devicetree/bindings/arm/vic.txt > > > > +- valid-mask : Bit mask of valid interrupt sources (defaults to all > > valid) > Until a device requests an interrupt, it can be left disabled. Once > something does request it, it gets enabled. If nothing requests it, it > never gets enabled. Doesn't the result of that logic end up being the > same thing as valid-mask represents? The only difference would be if > some device requests an invalid interrupt source, but then why not just > fix the interrupt client instead of adding this property to reject the > request? This property does not have anything to do with enabling or disabling (aka unmasking/masking) of interrupts. It just lists valid interrupt signals of given VIC. > > +- wakeup-mask : Bit mask of interrupt sources that can wake up the > > system + (defaults to all allowed) > > Shouldn't drivers for end-devices request interrupts, and then set wake > enable on those interrupts, which would then trickle up the IRQ chain to > tell the VIC which interrupts to enable wakeup on? This is the same as previous property. It does not have anything to do with requesting particular signal to wake up the system, but rather indicating that particular signal _can_ be requested to do so. Again, this is not strictly needed for correct operation, but this way you wouldn't get any sanity check over wake up signals being requested. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-23 23:04 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:04 UTC (permalink / raw) To: linux-arm-kernel On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > On 08/22/2013 05:22 PM, Tomasz Figa wrote: > > This patch extends vic_of_init to parse valid interrupt sources > > and resume sources masks from device tree. > > > > If mask values are not specified in device tree, all sources > > are assumed to be valid, as before this patch. > > Can you explain further why the VIC needs this information up-front? > Presumably it can accumulate it as devices request interrupts. It does not need this information just for operation, but this makes the hardware description more detailed and allows better sanity checking of interrupts being requested. To clarify, this is a mask of valid interrupt sources of the VIC, where set bit indicates that given signal is wired and clear bit that it is not. > > diff --git a/Documentation/devicetree/bindings/arm/vic.txt > > b/Documentation/devicetree/bindings/arm/vic.txt > > > > +- valid-mask : Bit mask of valid interrupt sources (defaults to all > > valid) > Until a device requests an interrupt, it can be left disabled. Once > something does request it, it gets enabled. If nothing requests it, it > never gets enabled. Doesn't the result of that logic end up being the > same thing as valid-mask represents? The only difference would be if > some device requests an invalid interrupt source, but then why not just > fix the interrupt client instead of adding this property to reject the > request? This property does not have anything to do with enabling or disabling (aka unmasking/masking) of interrupts. It just lists valid interrupt signals of given VIC. > > +- wakeup-mask : Bit mask of interrupt sources that can wake up the > > system + (defaults to all allowed) > > Shouldn't drivers for end-devices request interrupts, and then set wake > enable on those interrupts, which would then trickle up the IRQ chain to > tell the VIC which interrupts to enable wakeup on? This is the same as previous property. It does not have anything to do with requesting particular signal to wake up the system, but rather indicating that particular signal _can_ be requested to do so. Again, this is not strictly needed for correct operation, but this way you wouldn't get any sanity check over wake up signals being requested. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-23 23:04 ` Tomasz Figa @ 2013-08-23 23:19 ` Stephen Warren -1 siblings, 0 replies; 64+ messages in thread From: Stephen Warren @ 2013-08-23 23:19 UTC (permalink / raw) To: Tomasz Figa Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On 08/23/2013 05:04 PM, Tomasz Figa wrote: > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: >>> This patch extends vic_of_init to parse valid interrupt sources >>> and resume sources masks from device tree. >>> >>> If mask values are not specified in device tree, all sources >>> are assumed to be valid, as before this patch. >> >> Can you explain further why the VIC needs this information up-front? >> Presumably it can accumulate it as devices request interrupts. > > It does not need this information just for operation, but this makes the > hardware description more detailed and allows better sanity checking of > interrupts being requested. Ah, OK. It may be worth mentioning the intent of the properties. I suppose this is purely a representation of HW then, so it's reasonable to include it in the binding. I'm not sure /quite/ how useful it is; after all the error-checking that it enables will never trigger assuming the rest of the DT is written to "request" the correct interrupts. However, I guess there is little harm in allowing these properties. Bikeshedding a bit, but perhaps rename wakeup-mask to valid-wakeup-mask (and perhaps valid-mask to valid-source-mask for consistency, although I see you already renamed that to be consistent with other bindings...)? To me, wakeup-mask sounds like a configuration of which sources should be configured to wakeup the system; something to do with configuration/policy rather than HW capabilities. Either way, the binding, Acked-by: Stephen Warren <swarren@nvidia.com> (I assume those 2 new properties always have 1 cell since the controller can only support up to 32 IRQ sources? If not, then perhaps add wording to describe how long the properties should be). ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-23 23:19 ` Stephen Warren 0 siblings, 0 replies; 64+ messages in thread From: Stephen Warren @ 2013-08-23 23:19 UTC (permalink / raw) To: linux-arm-kernel On 08/23/2013 05:04 PM, Tomasz Figa wrote: > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: >>> This patch extends vic_of_init to parse valid interrupt sources >>> and resume sources masks from device tree. >>> >>> If mask values are not specified in device tree, all sources >>> are assumed to be valid, as before this patch. >> >> Can you explain further why the VIC needs this information up-front? >> Presumably it can accumulate it as devices request interrupts. > > It does not need this information just for operation, but this makes the > hardware description more detailed and allows better sanity checking of > interrupts being requested. Ah, OK. It may be worth mentioning the intent of the properties. I suppose this is purely a representation of HW then, so it's reasonable to include it in the binding. I'm not sure /quite/ how useful it is; after all the error-checking that it enables will never trigger assuming the rest of the DT is written to "request" the correct interrupts. However, I guess there is little harm in allowing these properties. Bikeshedding a bit, but perhaps rename wakeup-mask to valid-wakeup-mask (and perhaps valid-mask to valid-source-mask for consistency, although I see you already renamed that to be consistent with other bindings...)? To me, wakeup-mask sounds like a configuration of which sources should be configured to wakeup the system; something to do with configuration/policy rather than HW capabilities. Either way, the binding, Acked-by: Stephen Warren <swarren@nvidia.com> (I assume those 2 new properties always have 1 cell since the controller can only support up to 32 IRQ sources? If not, then perhaps add wording to describe how long the properties should be). ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-23 23:19 ` Stephen Warren @ 2013-08-23 23:33 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:33 UTC (permalink / raw) To: Stephen Warren Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Friday 23 of August 2013 17:19:50 Stephen Warren wrote: > On 08/23/2013 05:04 PM, Tomasz Figa wrote: > > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: > >>> This patch extends vic_of_init to parse valid interrupt sources > >>> and resume sources masks from device tree. > >>> > >>> If mask values are not specified in device tree, all sources > >>> are assumed to be valid, as before this patch. > >> > >> Can you explain further why the VIC needs this information up-front? > >> Presumably it can accumulate it as devices request interrupts. > > > > It does not need this information just for operation, but this makes > > the hardware description more detailed and allows better sanity > > checking of interrupts being requested. > > Ah, OK. It may be worth mentioning the intent of the properties. Right, a bit more detailed description will be nice indeed. I didn't think such thing like this is so uncommon to need such. > I > suppose this is purely a representation of HW then, so it's reasonable > to include it in the binding. I'm not sure /quite/ how useful it is; > after all the error-checking that it enables will never trigger assuming > the rest of the DT is written to "request" the correct interrupts. > However, I guess there is little harm in allowing these properties. Well, the valid-mask is indeed a bit redundant (although might let you spot errors in interrupt specification in your device tree faster), but wakeup-mask is something that prevents drivers from incorrectly thinking that an interrupt can wake the system up, while it can't. Otherwise enable_irq_wake() wouldn't know when to return an error. > Bikeshedding a bit, but perhaps rename wakeup-mask to valid-wakeup-mask > (and perhaps valid-mask to valid-source-mask for consistency, although I > see you already renamed that to be consistent with other bindings...)? > To me, wakeup-mask sounds like a configuration of which sources should > be configured to wakeup the system; something to do with > configuration/policy rather than HW capabilities. Yes, valid-wakeup-mask sounds reasonably to me. The valid-mask property has been taken from bindings/arm/versatile-fpga-irq.txt, as suggested by Linus Walleij. > Either way, the binding, > Acked-by: Stephen Warren <swarren@nvidia.com> Thanks. > (I assume those 2 new properties always have 1 cell since the controller > can only support up to 32 IRQ sources? If not, then perhaps add wording > to describe how long the properties should be). Correct, one VIC can support up to 32 interrupt sources. A word on this in binding description will be nice indeed. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-23 23:33 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:33 UTC (permalink / raw) To: linux-arm-kernel On Friday 23 of August 2013 17:19:50 Stephen Warren wrote: > On 08/23/2013 05:04 PM, Tomasz Figa wrote: > > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: > >>> This patch extends vic_of_init to parse valid interrupt sources > >>> and resume sources masks from device tree. > >>> > >>> If mask values are not specified in device tree, all sources > >>> are assumed to be valid, as before this patch. > >> > >> Can you explain further why the VIC needs this information up-front? > >> Presumably it can accumulate it as devices request interrupts. > > > > It does not need this information just for operation, but this makes > > the hardware description more detailed and allows better sanity > > checking of interrupts being requested. > > Ah, OK. It may be worth mentioning the intent of the properties. Right, a bit more detailed description will be nice indeed. I didn't think such thing like this is so uncommon to need such. > I > suppose this is purely a representation of HW then, so it's reasonable > to include it in the binding. I'm not sure /quite/ how useful it is; > after all the error-checking that it enables will never trigger assuming > the rest of the DT is written to "request" the correct interrupts. > However, I guess there is little harm in allowing these properties. Well, the valid-mask is indeed a bit redundant (although might let you spot errors in interrupt specification in your device tree faster), but wakeup-mask is something that prevents drivers from incorrectly thinking that an interrupt can wake the system up, while it can't. Otherwise enable_irq_wake() wouldn't know when to return an error. > Bikeshedding a bit, but perhaps rename wakeup-mask to valid-wakeup-mask > (and perhaps valid-mask to valid-source-mask for consistency, although I > see you already renamed that to be consistent with other bindings...)? > To me, wakeup-mask sounds like a configuration of which sources should > be configured to wakeup the system; something to do with > configuration/policy rather than HW capabilities. Yes, valid-wakeup-mask sounds reasonably to me. The valid-mask property has been taken from bindings/arm/versatile-fpga-irq.txt, as suggested by Linus Walleij. > Either way, the binding, > Acked-by: Stephen Warren <swarren@nvidia.com> Thanks. > (I assume those 2 new properties always have 1 cell since the controller > can only support up to 32 IRQ sources? If not, then perhaps add wording > to describe how long the properties should be). Correct, one VIC can support up to 32 interrupt sources. A word on this in binding description will be nice indeed. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-23 23:04 ` Tomasz Figa @ 2013-08-24 15:25 ` Rob Herring -1 siblings, 0 replies; 64+ messages in thread From: Rob Herring @ 2013-08-24 15:25 UTC (permalink / raw) To: Tomasz Figa Cc: Stephen Warren, Mark Rutland, devicetree, linux-samsung-soc, Russell King, Ian Campbell, Pawel Moll, Marc Zyngier, Linus Walleij, Rob Herring, linux-gpio, Kukjin Kim, Arnd Bergmann, Mark Brown, Olof Johansson, Thomas Gleixner, linux-arm-kernel On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: >> > This patch extends vic_of_init to parse valid interrupt sources >> > and resume sources masks from device tree. >> > >> > If mask values are not specified in device tree, all sources >> > are assumed to be valid, as before this patch. >> >> Can you explain further why the VIC needs this information up-front? >> Presumably it can accumulate it as devices request interrupts. > > It does not need this information just for operation, but this makes the > hardware description more detailed and allows better sanity checking of > interrupts being requested. > > To clarify, this is a mask of valid interrupt sources of the VIC, where > set bit indicates that given signal is wired and clear bit that it is not. I agree with Stephen here. The valid interrupts are the ones in the DT. The reserved ones are the ones not present. If it is not needed for the operation of the VIC, then remove it. The argument of sanity checking could apply to all interrupt controllers. Rob ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-24 15:25 ` Rob Herring 0 siblings, 0 replies; 64+ messages in thread From: Rob Herring @ 2013-08-24 15:25 UTC (permalink / raw) To: linux-arm-kernel On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: >> > This patch extends vic_of_init to parse valid interrupt sources >> > and resume sources masks from device tree. >> > >> > If mask values are not specified in device tree, all sources >> > are assumed to be valid, as before this patch. >> >> Can you explain further why the VIC needs this information up-front? >> Presumably it can accumulate it as devices request interrupts. > > It does not need this information just for operation, but this makes the > hardware description more detailed and allows better sanity checking of > interrupts being requested. > > To clarify, this is a mask of valid interrupt sources of the VIC, where > set bit indicates that given signal is wired and clear bit that it is not. I agree with Stephen here. The valid interrupts are the ones in the DT. The reserved ones are the ones not present. If it is not needed for the operation of the VIC, then remove it. The argument of sanity checking could apply to all interrupt controllers. Rob ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-24 15:25 ` Rob Herring @ 2013-08-24 15:31 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-24 15:31 UTC (permalink / raw) To: Rob Herring Cc: Stephen Warren, Mark Rutland, devicetree, linux-samsung-soc, Russell King, Ian Campbell, Pawel Moll, Marc Zyngier, Linus Walleij, Rob Herring, linux-gpio, Kukjin Kim, Arnd Bergmann, Mark Brown, Olof Johansson, Thomas Gleixner, linux-arm-kernel On Saturday 24 of August 2013 10:25:26 Rob Herring wrote: > On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: > >> > This patch extends vic_of_init to parse valid interrupt sources > >> > and resume sources masks from device tree. > >> > > >> > If mask values are not specified in device tree, all sources > >> > are assumed to be valid, as before this patch. > >> > >> Can you explain further why the VIC needs this information up-front? > >> Presumably it can accumulate it as devices request interrupts. > > > > It does not need this information just for operation, but this makes > > the hardware description more detailed and allows better sanity > > checking of interrupts being requested. > > > > To clarify, this is a mask of valid interrupt sources of the VIC, > > where > > set bit indicates that given signal is wired and clear bit that it is > > not. > I agree with Stephen here. The valid interrupts are the ones in the > DT. The reserved ones are the ones not present. If it is not needed > for the operation of the VIC, then remove it. The argument of sanity > checking could apply to all interrupt controllers. Sorry, but I don't get what's wrong in having a more detailed description than required just for operation of the hardware. The feature of sanity checks based on interrupt_mask (here now called valid-mask) has been present in the VIC driver since a long time already (if not from the beginning of existence of this driver) and before we started using DT, the mask was being passed from platform code as VIC init function argument. I'd prefer this feature to be available when using DT as well, unless we really want to move things backwards, just because we want to use DT... Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-24 15:31 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-24 15:31 UTC (permalink / raw) To: linux-arm-kernel On Saturday 24 of August 2013 10:25:26 Rob Herring wrote: > On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > > On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > >> On 08/22/2013 05:22 PM, Tomasz Figa wrote: > >> > This patch extends vic_of_init to parse valid interrupt sources > >> > and resume sources masks from device tree. > >> > > >> > If mask values are not specified in device tree, all sources > >> > are assumed to be valid, as before this patch. > >> > >> Can you explain further why the VIC needs this information up-front? > >> Presumably it can accumulate it as devices request interrupts. > > > > It does not need this information just for operation, but this makes > > the hardware description more detailed and allows better sanity > > checking of interrupts being requested. > > > > To clarify, this is a mask of valid interrupt sources of the VIC, > > where > > set bit indicates that given signal is wired and clear bit that it is > > not. > I agree with Stephen here. The valid interrupts are the ones in the > DT. The reserved ones are the ones not present. If it is not needed > for the operation of the VIC, then remove it. The argument of sanity > checking could apply to all interrupt controllers. Sorry, but I don't get what's wrong in having a more detailed description than required just for operation of the hardware. The feature of sanity checks based on interrupt_mask (here now called valid-mask) has been present in the VIC driver since a long time already (if not from the beginning of existence of this driver) and before we started using DT, the mask was being passed from platform code as VIC init function argument. I'd prefer this feature to be available when using DT as well, unless we really want to move things backwards, just because we want to use DT... Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-24 15:31 ` Tomasz Figa @ 2013-08-24 16:35 ` Rob Herring -1 siblings, 0 replies; 64+ messages in thread From: Rob Herring @ 2013-08-24 16:35 UTC (permalink / raw) To: Tomasz Figa Cc: Stephen Warren, Mark Rutland, devicetree, linux-samsung-soc, Russell King, Ian Campbell, Pawel Moll, Marc Zyngier, Linus Walleij, Rob Herring, linux-gpio, Kukjin Kim, Arnd Bergmann, Mark Brown, Olof Johansson, Thomas Gleixner, linux-arm-kernel On 08/24/2013 10:31 AM, Tomasz Figa wrote: > On Saturday 24 of August 2013 10:25:26 Rob Herring wrote: >> On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> > wrote: >>> On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: >>>> On 08/22/2013 05:22 PM, Tomasz Figa wrote: >>>>> This patch extends vic_of_init to parse valid interrupt sources >>>>> and resume sources masks from device tree. >>>>> >>>>> If mask values are not specified in device tree, all sources >>>>> are assumed to be valid, as before this patch. >>>> >>>> Can you explain further why the VIC needs this information up-front? >>>> Presumably it can accumulate it as devices request interrupts. >>> >>> It does not need this information just for operation, but this makes >>> the hardware description more detailed and allows better sanity >>> checking of interrupts being requested. >>> >>> To clarify, this is a mask of valid interrupt sources of the VIC, >>> where >>> set bit indicates that given signal is wired and clear bit that it is >>> not. >> I agree with Stephen here. The valid interrupts are the ones in the >> DT. The reserved ones are the ones not present. If it is not needed >> for the operation of the VIC, then remove it. The argument of sanity >> checking could apply to all interrupt controllers. > > Sorry, but I don't get what's wrong in having a more detailed description > than required just for operation of the hardware. > > The feature of sanity checks based on interrupt_mask (here now called > valid-mask) has been present in the VIC driver since a long time already > (if not from the beginning of existence of this driver) and before we > started using DT, the mask was being passed from platform code as VIC init > function argument. So we should base the binding on the Linux software design? > I'd prefer this feature to be available when using DT as well, unless we > really want to move things backwards, just because we want to use DT... As I mentioned all these arguments apply to ALL interrupt controllers except ones which a mask does not work. So IF this makes sense, then this should be a generic property and generic code to support. You simply have the same information twice. One is distributed and one is centralized. While it adds a way to validate things it also adds a way to introduce errors. Suppose someone writes a dts such that valid-mask matches the irq lines present in that dts (simply because they were lazy or don't have documentation of all interrupt lines). Then you go add a node with a new interrupt (because the initial dts was not complete). Updating the valid-mask could very easily be forgotten. Yes, this should all be found by testing, but people don't always have access to all the h/w. This issue would also not likely be obvious in a review. Rob ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-24 16:35 ` Rob Herring 0 siblings, 0 replies; 64+ messages in thread From: Rob Herring @ 2013-08-24 16:35 UTC (permalink / raw) To: linux-arm-kernel On 08/24/2013 10:31 AM, Tomasz Figa wrote: > On Saturday 24 of August 2013 10:25:26 Rob Herring wrote: >> On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> > wrote: >>> On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: >>>> On 08/22/2013 05:22 PM, Tomasz Figa wrote: >>>>> This patch extends vic_of_init to parse valid interrupt sources >>>>> and resume sources masks from device tree. >>>>> >>>>> If mask values are not specified in device tree, all sources >>>>> are assumed to be valid, as before this patch. >>>> >>>> Can you explain further why the VIC needs this information up-front? >>>> Presumably it can accumulate it as devices request interrupts. >>> >>> It does not need this information just for operation, but this makes >>> the hardware description more detailed and allows better sanity >>> checking of interrupts being requested. >>> >>> To clarify, this is a mask of valid interrupt sources of the VIC, >>> where >>> set bit indicates that given signal is wired and clear bit that it is >>> not. >> I agree with Stephen here. The valid interrupts are the ones in the >> DT. The reserved ones are the ones not present. If it is not needed >> for the operation of the VIC, then remove it. The argument of sanity >> checking could apply to all interrupt controllers. > > Sorry, but I don't get what's wrong in having a more detailed description > than required just for operation of the hardware. > > The feature of sanity checks based on interrupt_mask (here now called > valid-mask) has been present in the VIC driver since a long time already > (if not from the beginning of existence of this driver) and before we > started using DT, the mask was being passed from platform code as VIC init > function argument. So we should base the binding on the Linux software design? > I'd prefer this feature to be available when using DT as well, unless we > really want to move things backwards, just because we want to use DT... As I mentioned all these arguments apply to ALL interrupt controllers except ones which a mask does not work. So IF this makes sense, then this should be a generic property and generic code to support. You simply have the same information twice. One is distributed and one is centralized. While it adds a way to validate things it also adds a way to introduce errors. Suppose someone writes a dts such that valid-mask matches the irq lines present in that dts (simply because they were lazy or don't have documentation of all interrupt lines). Then you go add a node with a new interrupt (because the initial dts was not complete). Updating the valid-mask could very easily be forgotten. Yes, this should all be found by testing, but people don't always have access to all the h/w. This issue would also not likely be obvious in a review. Rob ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-24 16:35 ` Rob Herring @ 2013-08-24 16:57 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-24 16:57 UTC (permalink / raw) To: Rob Herring Cc: Stephen Warren, Mark Rutland, devicetree, linux-samsung-soc, Russell King, Ian Campbell, Pawel Moll, Marc Zyngier, Linus Walleij, Rob Herring, linux-gpio, Kukjin Kim, Arnd Bergmann, Mark Brown, Olof Johansson, Thomas Gleixner, linux-arm-kernel On Saturday 24 of August 2013 11:35:03 Rob Herring wrote: > On 08/24/2013 10:31 AM, Tomasz Figa wrote: > > On Saturday 24 of August 2013 10:25:26 Rob Herring wrote: > >> On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> > > > > wrote: > >>> On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > >>>> On 08/22/2013 05:22 PM, Tomasz Figa wrote: > >>>>> This patch extends vic_of_init to parse valid interrupt sources > >>>>> and resume sources masks from device tree. > >>>>> > >>>>> If mask values are not specified in device tree, all sources > >>>>> are assumed to be valid, as before this patch. > >>>> > >>>> Can you explain further why the VIC needs this information > >>>> up-front? > >>>> Presumably it can accumulate it as devices request interrupts. > >>> > >>> It does not need this information just for operation, but this makes > >>> the hardware description more detailed and allows better sanity > >>> checking of interrupts being requested. > >>> > >>> To clarify, this is a mask of valid interrupt sources of the VIC, > >>> where > >>> set bit indicates that given signal is wired and clear bit that it > >>> is > >>> not. > >> > >> I agree with Stephen here. The valid interrupts are the ones in the > >> DT. The reserved ones are the ones not present. If it is not needed > >> for the operation of the VIC, then remove it. The argument of sanity > >> checking could apply to all interrupt controllers. > > > > Sorry, but I don't get what's wrong in having a more detailed > > description than required just for operation of the hardware. > > > > The feature of sanity checks based on interrupt_mask (here now called > > valid-mask) has been present in the VIC driver since a long time > > already (if not from the beginning of existence of this driver) and > > before we started using DT, the mask was being passed from platform > > code as VIC init function argument. > > So we should base the binding on the Linux software design? I would put it different way: The binding should provide information detailed enough to allow any features allowed by Linux software design. Well, anyway, I don't believe that existing, pre-ARM, bindings wasn't influenced by how things worked on PowerPC platforms and software running on them (including OpenFirmware and OS'es like Linux). > > I'd prefer this feature to be available when using DT as well, unless > > we really want to move things backwards, just because we want to use > > DT... > As I mentioned all these arguments apply to ALL interrupt controllers > except ones which a mask does not work. So IF this makes sense, then > this should be a generic property and generic code to support. Isn't a binding of particular device free to define a private property? Anyway, I wouldn't be opposed to making it generic. > You simply have the same information twice. One is distributed Assuming you have it specified correctly under client nodes. > and one > is centralized. While it adds a way to validate things it also adds a > way to introduce errors. Suppose someone writes a dts such that > valid-mask matches the irq lines present in that dts (simply because > they were lazy or don't have documentation of all interrupt lines). That's why this property is optional. If you don't know how this is set up on your hardware then you don't fill it with a random value, but just skip it instead. > Then > you go add a node with a new interrupt (because the initial dts was not > complete). Updating the valid-mask could very easily be forgotten. Yes, > this should all be found by testing, but people don't always have > access to all the h/w. Adding a node with a new interrupt usually means adding support for new hardware. This is something I wouldn't really want to see submitted untested... Anyway, since I'd like this series to be merged ASAP and this patch is not strictly necessary, especially this optional sanity check, let me just drop this property and move on with other things... Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v8 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-24 16:57 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-24 16:57 UTC (permalink / raw) To: linux-arm-kernel On Saturday 24 of August 2013 11:35:03 Rob Herring wrote: > On 08/24/2013 10:31 AM, Tomasz Figa wrote: > > On Saturday 24 of August 2013 10:25:26 Rob Herring wrote: > >> On Fri, Aug 23, 2013 at 6:04 PM, Tomasz Figa <tomasz.figa@gmail.com> > > > > wrote: > >>> On Friday 23 of August 2013 16:11:18 Stephen Warren wrote: > >>>> On 08/22/2013 05:22 PM, Tomasz Figa wrote: > >>>>> This patch extends vic_of_init to parse valid interrupt sources > >>>>> and resume sources masks from device tree. > >>>>> > >>>>> If mask values are not specified in device tree, all sources > >>>>> are assumed to be valid, as before this patch. > >>>> > >>>> Can you explain further why the VIC needs this information > >>>> up-front? > >>>> Presumably it can accumulate it as devices request interrupts. > >>> > >>> It does not need this information just for operation, but this makes > >>> the hardware description more detailed and allows better sanity > >>> checking of interrupts being requested. > >>> > >>> To clarify, this is a mask of valid interrupt sources of the VIC, > >>> where > >>> set bit indicates that given signal is wired and clear bit that it > >>> is > >>> not. > >> > >> I agree with Stephen here. The valid interrupts are the ones in the > >> DT. The reserved ones are the ones not present. If it is not needed > >> for the operation of the VIC, then remove it. The argument of sanity > >> checking could apply to all interrupt controllers. > > > > Sorry, but I don't get what's wrong in having a more detailed > > description than required just for operation of the hardware. > > > > The feature of sanity checks based on interrupt_mask (here now called > > valid-mask) has been present in the VIC driver since a long time > > already (if not from the beginning of existence of this driver) and > > before we started using DT, the mask was being passed from platform > > code as VIC init function argument. > > So we should base the binding on the Linux software design? I would put it different way: The binding should provide information detailed enough to allow any features allowed by Linux software design. Well, anyway, I don't believe that existing, pre-ARM, bindings wasn't influenced by how things worked on PowerPC platforms and software running on them (including OpenFirmware and OS'es like Linux). > > I'd prefer this feature to be available when using DT as well, unless > > we really want to move things backwards, just because we want to use > > DT... > As I mentioned all these arguments apply to ALL interrupt controllers > except ones which a mask does not work. So IF this makes sense, then > this should be a generic property and generic code to support. Isn't a binding of particular device free to define a private property? Anyway, I wouldn't be opposed to making it generic. > You simply have the same information twice. One is distributed Assuming you have it specified correctly under client nodes. > and one > is centralized. While it adds a way to validate things it also adds a > way to introduce errors. Suppose someone writes a dts such that > valid-mask matches the irq lines present in that dts (simply because > they were lazy or don't have documentation of all interrupt lines). That's why this property is optional. If you don't know how this is set up on your hardware then you don't fill it with a random value, but just skip it instead. > Then > you go add a node with a new interrupt (because the initial dts was not > complete). Updating the valid-mask could very easily be forgotten. Yes, > this should all be found by testing, but people don't always have > access to all the h/w. Adding a node with a new interrupt usually means adding support for new hardware. This is something I wouldn't really want to see submitted untested... Anyway, since I'd like this series to be merged ASAP and this patch is not strictly necessary, especially this optional sanity check, let me just drop this property and move on with other things... Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v9 1/7] irqchip: vic: Parse interrupt and resume masks from device tree 2013-08-22 23:22 ` Tomasz Figa @ 2013-08-23 23:54 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:54 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown This patch extends vic_of_init to parse valid interrupt sources and resume sources masks from device tree. If mask values are not specified in device tree, all sources are assumed to be valid, as before this patch. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> Acked-by: Stephen Warren <swarren@nvidia.com> --- Documentation/devicetree/bindings/arm/vic.txt | 12 ++++++++++++ drivers/irqchip/irq-vic.c | 7 ++++++- 2 files changed, 18 insertions(+), 1 deletion(-) Changes since v8: - Renamed wakeup-mask property to valid-wakeup-mask. - Extended description of valid-mask and valid-wakeup-mask properties. diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt index 266716b..dd52721 100644 --- a/Documentation/devicetree/bindings/arm/vic.txt +++ b/Documentation/devicetree/bindings/arm/vic.txt @@ -18,6 +18,15 @@ Required properties: Optional properties: - interrupts : Interrupt source for parent controllers if the VIC is nested. +- valid-mask : A one cell big bit mask of valid interrupt sources. Each bit + represents single interrupt source, starting from source 0 at LSb and ending + at source 31 at MSb. A bit that is set means that the source is wired and + clear means otherwise. If unspecified, defaults to all valid. +- valid-wakeup-mask : A one cell big bit mask of interrupt sources that can be + configured as wake up source for the system. Order of bits is the same as for + valid-mask property. A set bit means that this interrupt source can be + configured as a wake up source for the system. If unspecied, defaults to all + interrupt sources configurable as wake up sources. Example: @@ -26,4 +35,7 @@ Example: interrupt-controller; #interrupt-cells = <1>; reg = <0x60000 0x1000>; + + valid-mask = <0xffffff7f>; + valid-wakeup-mask = <0x0000ff7f>; }; diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c index 2bbb004..8e21ae0 100644 --- a/drivers/irqchip/irq-vic.c +++ b/drivers/irqchip/irq-vic.c @@ -469,6 +469,8 @@ void __init vic_init(void __iomem *base, unsigned int irq_start, int __init vic_of_init(struct device_node *node, struct device_node *parent) { void __iomem *regs; + u32 interrupt_mask = ~0; + u32 wakeup_mask = ~0; if (WARN(parent, "non-root VICs are not supported")) return -EINVAL; @@ -477,10 +479,13 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) if (WARN_ON(!regs)) return -EIO; + of_property_read_u32(node, "valid-mask", &interrupt_mask); + of_property_read_u32(node, "valid-wakeup-mask", &wakeup_mask); + /* * Passing 0 as first IRQ makes the simple domain allocate descriptors */ - __vic_init(regs, 0, ~0, ~0, node); + __vic_init(regs, 0, interrupt_mask, wakeup_mask, node); return 0; } -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v9 1/7] irqchip: vic: Parse interrupt and resume masks from device tree @ 2013-08-23 23:54 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:54 UTC (permalink / raw) To: linux-arm-kernel This patch extends vic_of_init to parse valid interrupt sources and resume sources masks from device tree. If mask values are not specified in device tree, all sources are assumed to be valid, as before this patch. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> Acked-by: Stephen Warren <swarren@nvidia.com> --- Documentation/devicetree/bindings/arm/vic.txt | 12 ++++++++++++ drivers/irqchip/irq-vic.c | 7 ++++++- 2 files changed, 18 insertions(+), 1 deletion(-) Changes since v8: - Renamed wakeup-mask property to valid-wakeup-mask. - Extended description of valid-mask and valid-wakeup-mask properties. diff --git a/Documentation/devicetree/bindings/arm/vic.txt b/Documentation/devicetree/bindings/arm/vic.txt index 266716b..dd52721 100644 --- a/Documentation/devicetree/bindings/arm/vic.txt +++ b/Documentation/devicetree/bindings/arm/vic.txt @@ -18,6 +18,15 @@ Required properties: Optional properties: - interrupts : Interrupt source for parent controllers if the VIC is nested. +- valid-mask : A one cell big bit mask of valid interrupt sources. Each bit + represents single interrupt source, starting from source 0 at LSb and ending + at source 31 at MSb. A bit that is set means that the source is wired and + clear means otherwise. If unspecified, defaults to all valid. +- valid-wakeup-mask : A one cell big bit mask of interrupt sources that can be + configured as wake up source for the system. Order of bits is the same as for + valid-mask property. A set bit means that this interrupt source can be + configured as a wake up source for the system. If unspecied, defaults to all + interrupt sources configurable as wake up sources. Example: @@ -26,4 +35,7 @@ Example: interrupt-controller; #interrupt-cells = <1>; reg = <0x60000 0x1000>; + + valid-mask = <0xffffff7f>; + valid-wakeup-mask = <0x0000ff7f>; }; diff --git a/drivers/irqchip/irq-vic.c b/drivers/irqchip/irq-vic.c index 2bbb004..8e21ae0 100644 --- a/drivers/irqchip/irq-vic.c +++ b/drivers/irqchip/irq-vic.c @@ -469,6 +469,8 @@ void __init vic_init(void __iomem *base, unsigned int irq_start, int __init vic_of_init(struct device_node *node, struct device_node *parent) { void __iomem *regs; + u32 interrupt_mask = ~0; + u32 wakeup_mask = ~0; if (WARN(parent, "non-root VICs are not supported")) return -EINVAL; @@ -477,10 +479,13 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) if (WARN_ON(!regs)) return -EIO; + of_property_read_u32(node, "valid-mask", &interrupt_mask); + of_property_read_u32(node, "valid-wakeup-mask", &wakeup_mask); + /* * Passing 0 as first IRQ makes the simple domain allocate descriptors */ - __vic_init(regs, 0, ~0, ~0, node); + __vic_init(regs, 0, interrupt_mask, wakeup_mask, node); return 0; } -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 2/7] ARM: s3c64xx: Bypass legacy initialization when booting with DT 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This patch allows bypassing most of legacy initialization when booting an S3C64xx-based board using device tree, by adding conditional checks for DT presence to initcalls which are no longer necessary when booting with DT.. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/mach-s3c64xx/common.c | 12 ++++++++++++ arch/arm/mach-s3c64xx/dma.c | 9 +++++++++ arch/arm/mach-s3c64xx/irq-pm.c | 9 +++++++++ arch/arm/mach-s3c64xx/s3c6400.c | 9 +++++++++ arch/arm/mach-s3c64xx/s3c6410.c | 9 +++++++++ arch/arm/plat-samsung/init.c | 12 +++++++++++- 6 files changed, 59 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-s3c64xx/common.c b/arch/arm/mach-s3c64xx/common.c index 7d3cb58..7a3ce4c 100644 --- a/arch/arm/mach-s3c64xx/common.c +++ b/arch/arm/mach-s3c64xx/common.c @@ -14,6 +14,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/init.h> #include <linux/module.h> @@ -203,6 +207,10 @@ void __init s3c64xx_init_io(struct map_desc *mach_desc, int size) static __init int s3c64xx_dev_init(void) { + /* Not applicable when using DT. */ + if (of_have_populated_dt()) + return 0; + subsys_system_register(&s3c64xx_subsys, NULL); return device_register(&s3c64xx_dev); } @@ -404,6 +412,10 @@ static int __init s3c64xx_init_irq_eint(void) { int irq; + /* On DT-enabled systems EINTs are handled by pinctrl-s3c64xx driver. */ + if (of_have_populated_dt()) + return -ENODEV; + for (irq = IRQ_EINT(0); irq <= IRQ_EINT(27); irq++) { irq_set_chip_and_handler(irq, &s3c_irq_eint, handle_level_irq); irq_set_chip_data(irq, (void *)eint_irq_to_bit(irq)); diff --git a/arch/arm/mach-s3c64xx/dma.c b/arch/arm/mach-s3c64xx/dma.c index c511dfa..7e22c21 100644 --- a/arch/arm/mach-s3c64xx/dma.c +++ b/arch/arm/mach-s3c64xx/dma.c @@ -12,6 +12,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/module.h> #include <linux/interrupt.h> @@ -24,6 +28,7 @@ #include <linux/err.h> #include <linux/io.h> #include <linux/amba/pl080.h> +#include <linux/of.h> #include <mach/dma.h> #include <mach/map.h> @@ -726,6 +731,10 @@ static int __init s3c64xx_dma_init(void) { int ret; + /* This driver is not supported when booting with device tree. */ + if (of_have_populated_dt()) + return -ENODEV; + printk(KERN_INFO "%s: Registering DMA channels\n", __func__); dma_pool = dma_pool_create("DMA-LLI", NULL, sizeof(struct pl080s_lli), 16, 0); diff --git a/arch/arm/mach-s3c64xx/irq-pm.c b/arch/arm/mach-s3c64xx/irq-pm.c index c3da1b6..1649c0d 100644 --- a/arch/arm/mach-s3c64xx/irq-pm.c +++ b/arch/arm/mach-s3c64xx/irq-pm.c @@ -12,12 +12,17 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/syscore_ops.h> #include <linux/interrupt.h> #include <linux/serial_core.h> #include <linux/irq.h> #include <linux/io.h> +#include <linux/of.h> #include <mach/map.h> @@ -101,6 +106,10 @@ static struct syscore_ops s3c64xx_irq_syscore_ops = { static __init int s3c64xx_syscore_init(void) { + /* Appropriate drivers (pinctrl, uart) handle this when using DT. */ + if (of_have_populated_dt()) + return 0; + register_syscore_ops(&s3c64xx_irq_syscore_ops); return 0; diff --git a/arch/arm/mach-s3c64xx/s3c6400.c b/arch/arm/mach-s3c64xx/s3c6400.c index 331fe8e..3db0c98 100644 --- a/arch/arm/mach-s3c64xx/s3c6400.c +++ b/arch/arm/mach-s3c64xx/s3c6400.c @@ -9,6 +9,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/types.h> #include <linux/interrupt.h> @@ -20,6 +24,7 @@ #include <linux/device.h> #include <linux/serial_core.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <asm/mach/arch.h> #include <asm/mach/map.h> @@ -76,6 +81,10 @@ static struct device s3c6400_dev = { static int __init s3c6400_core_init(void) { + /* Not applicable when using DT. */ + if (of_have_populated_dt()) + return 0; + return subsys_system_register(&s3c6400_subsys, NULL); } diff --git a/arch/arm/mach-s3c64xx/s3c6410.c b/arch/arm/mach-s3c64xx/s3c6410.c index 7e6fa12..72b2278 100644 --- a/arch/arm/mach-s3c64xx/s3c6410.c +++ b/arch/arm/mach-s3c64xx/s3c6410.c @@ -10,6 +10,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/types.h> #include <linux/interrupt.h> @@ -21,6 +25,7 @@ #include <linux/device.h> #include <linux/serial_core.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <asm/mach/arch.h> #include <asm/mach/map.h> @@ -79,6 +84,10 @@ static struct device s3c6410_dev = { static int __init s3c6410_core_init(void) { + /* Not applicable when using DT. */ + if (of_have_populated_dt()) + return 0; + return subsys_system_register(&s3c6410_subsys, NULL); } diff --git a/arch/arm/plat-samsung/init.c b/arch/arm/plat-samsung/init.c index 50a3ea0..aa9511b 100644 --- a/arch/arm/plat-samsung/init.c +++ b/arch/arm/plat-samsung/init.c @@ -11,12 +11,18 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used on S3C64xx when booting with + * Device Tree support. + */ + #include <linux/init.h> #include <linux/module.h> #include <linux/interrupt.h> #include <linux/ioport.h> #include <linux/serial_core.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <mach/hardware.h> @@ -148,8 +154,12 @@ static int __init s3c_arch_init(void) // do the correct init for cpu - if (cpu == NULL) + if (cpu == NULL) { + /* Not needed when booting with device tree. */ + if (of_have_populated_dt()) + return 0; panic("s3c_arch_init: NULL cpu\n"); + } ret = (cpu->init)(); if (ret != 0) -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 2/7] ARM: s3c64xx: Bypass legacy initialization when booting with DT @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This patch allows bypassing most of legacy initialization when booting an S3C64xx-based board using device tree, by adding conditional checks for DT presence to initcalls which are no longer necessary when booting with DT.. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/mach-s3c64xx/common.c | 12 ++++++++++++ arch/arm/mach-s3c64xx/dma.c | 9 +++++++++ arch/arm/mach-s3c64xx/irq-pm.c | 9 +++++++++ arch/arm/mach-s3c64xx/s3c6400.c | 9 +++++++++ arch/arm/mach-s3c64xx/s3c6410.c | 9 +++++++++ arch/arm/plat-samsung/init.c | 12 +++++++++++- 6 files changed, 59 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-s3c64xx/common.c b/arch/arm/mach-s3c64xx/common.c index 7d3cb58..7a3ce4c 100644 --- a/arch/arm/mach-s3c64xx/common.c +++ b/arch/arm/mach-s3c64xx/common.c @@ -14,6 +14,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/init.h> #include <linux/module.h> @@ -203,6 +207,10 @@ void __init s3c64xx_init_io(struct map_desc *mach_desc, int size) static __init int s3c64xx_dev_init(void) { + /* Not applicable when using DT. */ + if (of_have_populated_dt()) + return 0; + subsys_system_register(&s3c64xx_subsys, NULL); return device_register(&s3c64xx_dev); } @@ -404,6 +412,10 @@ static int __init s3c64xx_init_irq_eint(void) { int irq; + /* On DT-enabled systems EINTs are handled by pinctrl-s3c64xx driver. */ + if (of_have_populated_dt()) + return -ENODEV; + for (irq = IRQ_EINT(0); irq <= IRQ_EINT(27); irq++) { irq_set_chip_and_handler(irq, &s3c_irq_eint, handle_level_irq); irq_set_chip_data(irq, (void *)eint_irq_to_bit(irq)); diff --git a/arch/arm/mach-s3c64xx/dma.c b/arch/arm/mach-s3c64xx/dma.c index c511dfa..7e22c21 100644 --- a/arch/arm/mach-s3c64xx/dma.c +++ b/arch/arm/mach-s3c64xx/dma.c @@ -12,6 +12,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/module.h> #include <linux/interrupt.h> @@ -24,6 +28,7 @@ #include <linux/err.h> #include <linux/io.h> #include <linux/amba/pl080.h> +#include <linux/of.h> #include <mach/dma.h> #include <mach/map.h> @@ -726,6 +731,10 @@ static int __init s3c64xx_dma_init(void) { int ret; + /* This driver is not supported when booting with device tree. */ + if (of_have_populated_dt()) + return -ENODEV; + printk(KERN_INFO "%s: Registering DMA channels\n", __func__); dma_pool = dma_pool_create("DMA-LLI", NULL, sizeof(struct pl080s_lli), 16, 0); diff --git a/arch/arm/mach-s3c64xx/irq-pm.c b/arch/arm/mach-s3c64xx/irq-pm.c index c3da1b6..1649c0d 100644 --- a/arch/arm/mach-s3c64xx/irq-pm.c +++ b/arch/arm/mach-s3c64xx/irq-pm.c @@ -12,12 +12,17 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/syscore_ops.h> #include <linux/interrupt.h> #include <linux/serial_core.h> #include <linux/irq.h> #include <linux/io.h> +#include <linux/of.h> #include <mach/map.h> @@ -101,6 +106,10 @@ static struct syscore_ops s3c64xx_irq_syscore_ops = { static __init int s3c64xx_syscore_init(void) { + /* Appropriate drivers (pinctrl, uart) handle this when using DT. */ + if (of_have_populated_dt()) + return 0; + register_syscore_ops(&s3c64xx_irq_syscore_ops); return 0; diff --git a/arch/arm/mach-s3c64xx/s3c6400.c b/arch/arm/mach-s3c64xx/s3c6400.c index 331fe8e..3db0c98 100644 --- a/arch/arm/mach-s3c64xx/s3c6400.c +++ b/arch/arm/mach-s3c64xx/s3c6400.c @@ -9,6 +9,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/types.h> #include <linux/interrupt.h> @@ -20,6 +24,7 @@ #include <linux/device.h> #include <linux/serial_core.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <asm/mach/arch.h> #include <asm/mach/map.h> @@ -76,6 +81,10 @@ static struct device s3c6400_dev = { static int __init s3c6400_core_init(void) { + /* Not applicable when using DT. */ + if (of_have_populated_dt()) + return 0; + return subsys_system_register(&s3c6400_subsys, NULL); } diff --git a/arch/arm/mach-s3c64xx/s3c6410.c b/arch/arm/mach-s3c64xx/s3c6410.c index 7e6fa12..72b2278 100644 --- a/arch/arm/mach-s3c64xx/s3c6410.c +++ b/arch/arm/mach-s3c64xx/s3c6410.c @@ -10,6 +10,10 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used when booting with Device Tree support. + */ + #include <linux/kernel.h> #include <linux/types.h> #include <linux/interrupt.h> @@ -21,6 +25,7 @@ #include <linux/device.h> #include <linux/serial_core.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <asm/mach/arch.h> #include <asm/mach/map.h> @@ -79,6 +84,10 @@ static struct device s3c6410_dev = { static int __init s3c6410_core_init(void) { + /* Not applicable when using DT. */ + if (of_have_populated_dt()) + return 0; + return subsys_system_register(&s3c6410_subsys, NULL); } diff --git a/arch/arm/plat-samsung/init.c b/arch/arm/plat-samsung/init.c index 50a3ea0..aa9511b 100644 --- a/arch/arm/plat-samsung/init.c +++ b/arch/arm/plat-samsung/init.c @@ -11,12 +11,18 @@ * published by the Free Software Foundation. */ +/* + * NOTE: Code in this file is not used on S3C64xx when booting with + * Device Tree support. + */ + #include <linux/init.h> #include <linux/module.h> #include <linux/interrupt.h> #include <linux/ioport.h> #include <linux/serial_core.h> #include <linux/platform_device.h> +#include <linux/of.h> #include <mach/hardware.h> @@ -148,8 +154,12 @@ static int __init s3c_arch_init(void) // do the correct init for cpu - if (cpu == NULL) + if (cpu == NULL) { + /* Not needed when booting with device tree. */ + if (of_have_populated_dt()) + return 0; panic("s3c_arch_init: NULL cpu\n"); + } ret = (cpu->init)(); if (ret != 0) -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa Since this driver does not handle GPIO on device tree enabled platforms any more, it should be bypassed whenever device tree is available, to not conflict with the new pinctrl-samsung driver. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- drivers/gpio/gpio-samsung.c | 34 +++++++--------------------------- 1 file changed, 7 insertions(+), 27 deletions(-) diff --git a/drivers/gpio/gpio-samsung.c b/drivers/gpio/gpio-samsung.c index a1392f4..cc93b1b 100644 --- a/drivers/gpio/gpio-samsung.c +++ b/drivers/gpio/gpio-samsung.c @@ -2949,34 +2949,14 @@ static __init int samsung_gpiolib_init(void) int i, nr_chips; int group = 0; -#if defined(CONFIG_PINCTRL_EXYNOS) || defined(CONFIG_PINCTRL_EXYNOS5440) /* - * This gpio driver includes support for device tree support and there - * are platforms using it. In order to maintain compatibility with those - * platforms, and to allow non-dt Exynos4210 platforms to use this - * gpiolib support, a check is added to find out if there is a active - * pin-controller driver support available. If it is available, this - * gpiolib support is ignored and the gpiolib support available in - * pin-controller driver is used. This is a temporary check and will go - * away when all of the Exynos4210 platforms have switched to using - * device tree and the pin-ctrl driver. - */ - struct device_node *pctrl_np; - static const struct of_device_id exynos_pinctrl_ids[] = { - { .compatible = "samsung,s3c2412-pinctrl", }, - { .compatible = "samsung,s3c2416-pinctrl", }, - { .compatible = "samsung,s3c2440-pinctrl", }, - { .compatible = "samsung,s3c2450-pinctrl", }, - { .compatible = "samsung,exynos4210-pinctrl", }, - { .compatible = "samsung,exynos4x12-pinctrl", }, - { .compatible = "samsung,exynos5250-pinctrl", }, - { .compatible = "samsung,exynos5440-pinctrl", }, - { } - }; - for_each_matching_node(pctrl_np, exynos_pinctrl_ids) - if (pctrl_np && of_device_is_available(pctrl_np)) - return -ENODEV; -#endif + * Currently there are two drivers that can provide GPIO support for + * Samsung SoCs. For device tree enabled platforms, the new + * pinctrl-samsung driver is used, providing both GPIO and pin control + * interfaces. For legacy (non-DT) platforms this driver is used. + */ + if (of_have_populated_dt()) + return -ENODEV; samsung_gpiolib_set_cfg(samsung_gpio_cfgs, ARRAY_SIZE(samsung_gpio_cfgs)); -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel Since this driver does not handle GPIO on device tree enabled platforms any more, it should be bypassed whenever device tree is available, to not conflict with the new pinctrl-samsung driver. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- drivers/gpio/gpio-samsung.c | 34 +++++++--------------------------- 1 file changed, 7 insertions(+), 27 deletions(-) diff --git a/drivers/gpio/gpio-samsung.c b/drivers/gpio/gpio-samsung.c index a1392f4..cc93b1b 100644 --- a/drivers/gpio/gpio-samsung.c +++ b/drivers/gpio/gpio-samsung.c @@ -2949,34 +2949,14 @@ static __init int samsung_gpiolib_init(void) int i, nr_chips; int group = 0; -#if defined(CONFIG_PINCTRL_EXYNOS) || defined(CONFIG_PINCTRL_EXYNOS5440) /* - * This gpio driver includes support for device tree support and there - * are platforms using it. In order to maintain compatibility with those - * platforms, and to allow non-dt Exynos4210 platforms to use this - * gpiolib support, a check is added to find out if there is a active - * pin-controller driver support available. If it is available, this - * gpiolib support is ignored and the gpiolib support available in - * pin-controller driver is used. This is a temporary check and will go - * away when all of the Exynos4210 platforms have switched to using - * device tree and the pin-ctrl driver. - */ - struct device_node *pctrl_np; - static const struct of_device_id exynos_pinctrl_ids[] = { - { .compatible = "samsung,s3c2412-pinctrl", }, - { .compatible = "samsung,s3c2416-pinctrl", }, - { .compatible = "samsung,s3c2440-pinctrl", }, - { .compatible = "samsung,s3c2450-pinctrl", }, - { .compatible = "samsung,exynos4210-pinctrl", }, - { .compatible = "samsung,exynos4x12-pinctrl", }, - { .compatible = "samsung,exynos5250-pinctrl", }, - { .compatible = "samsung,exynos5440-pinctrl", }, - { } - }; - for_each_matching_node(pctrl_np, exynos_pinctrl_ids) - if (pctrl_np && of_device_is_available(pctrl_np)) - return -ENODEV; -#endif + * Currently there are two drivers that can provide GPIO support for + * Samsung SoCs. For device tree enabled platforms, the new + * pinctrl-samsung driver is used, providing both GPIO and pin control + * interfaces. For legacy (non-DT) platforms this driver is used. + */ + if (of_have_populated_dt()) + return -ENODEV; samsung_gpiolib_set_cfg(samsung_gpio_cfgs, ARRAY_SIZE(samsung_gpio_cfgs)); -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* Re: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 23:21 ` Linus Walleij -1 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-21 23:21 UTC (permalink / raw) To: Tomasz Figa Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > Since this driver does not handle GPIO on device tree enabled platforms > any more, it should be bypassed whenever device tree is available, to > not conflict with the new pinctrl-samsung driver. > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> This seems like something I should apply to the GPIO tree right now, shall I? Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-21 23:21 ` Linus Walleij 0 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-21 23:21 UTC (permalink / raw) To: linux-arm-kernel On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > Since this driver does not handle GPIO on device tree enabled platforms > any more, it should be bypassed whenever device tree is available, to > not conflict with the new pinctrl-samsung driver. > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> This seems like something I should apply to the GPIO tree right now, shall I? Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-21 23:21 ` Linus Walleij @ 2013-08-22 8:06 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 8:06 UTC (permalink / raw) To: Linus Walleij Cc: linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > > Since this driver does not handle GPIO on device tree enabled > > platforms > > any more, it should be bypassed whenever device tree is available, to > > not conflict with the new pinctrl-samsung driver. > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > This seems like something I should apply to the GPIO tree > right now, shall I? Would be nice, but since this patch is a dependency for rest of this series and there are no other dependencies on GPIO tree, it might be easier to just let Kukjin take all the patches with required Acks. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-22 8:06 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 8:06 UTC (permalink / raw) To: linux-arm-kernel On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> wrote: > > Since this driver does not handle GPIO on device tree enabled > > platforms > > any more, it should be bypassed whenever device tree is available, to > > not conflict with the new pinctrl-samsung driver. > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > This seems like something I should apply to the GPIO tree > right now, shall I? Would be nice, but since this patch is a dependency for rest of this series and there are no other dependencies on GPIO tree, it might be easier to just let Kukjin take all the patches with required Acks. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-22 8:06 ` Tomasz Figa @ 2013-08-22 9:48 ` Mark Brown -1 siblings, 0 replies; 64+ messages in thread From: Mark Brown @ 2013-08-22 9:48 UTC (permalink / raw) To: Tomasz Figa Cc: Linus Walleij, linux-samsung-soc, linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier [-- Attachment #1: Type: text/plain, Size: 582 bytes --] On Thu, Aug 22, 2013 at 10:06:46AM +0200, Tomasz Figa wrote: > On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > > This seems like something I should apply to the GPIO tree > > right now, shall I? > Would be nice, but since this patch is a dependency for rest of this > series and there are no other dependencies on GPIO tree, it might be > easier to just let Kukjin take all the patches with required Acks. Though if the rest of the series might miss v3.12 (seems likely given the arm-soc deadlines have passed) then Linus could apply this for v3.12? [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 836 bytes --] ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-22 9:48 ` Mark Brown 0 siblings, 0 replies; 64+ messages in thread From: Mark Brown @ 2013-08-22 9:48 UTC (permalink / raw) To: linux-arm-kernel On Thu, Aug 22, 2013 at 10:06:46AM +0200, Tomasz Figa wrote: > On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > > This seems like something I should apply to the GPIO tree > > right now, shall I? > Would be nice, but since this patch is a dependency for rest of this > series and there are no other dependencies on GPIO tree, it might be > easier to just let Kukjin take all the patches with required Acks. Though if the rest of the series might miss v3.12 (seems likely given the arm-soc deadlines have passed) then Linus could apply this for v3.12? -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130822/03637f11/attachment-0001.sig> ^ permalink raw reply [flat|nested] 64+ messages in thread
* RE: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-22 8:06 ` Tomasz Figa @ 2013-08-22 9:59 ` Kukjin Kim -1 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-22 9:59 UTC (permalink / raw) To: 'Tomasz Figa', 'Linus Walleij' Cc: 'linux-samsung-soc', linux-arm-kernel, devicetree, linux-gpio, 'Ian Campbell', 'Mark Rutland', 'Pawel Moll', 'Rob Herring', 'Russell King', 'Stephen Warren', 'Thomas Gleixner', 'Olof Johansson', 'Arnd Bergmann', 'Marc Zyngier', 'Mark Brown' Tomasz Figa wrote: > > On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> > wrote: > > > Since this driver does not handle GPIO on device tree enabled > > > platforms > > > any more, it should be bypassed whenever device tree is available, to > > > not conflict with the new pinctrl-samsung driver. > > > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > > > This seems like something I should apply to the GPIO tree > > right now, shall I? > > Would be nice, but since this patch is a dependency for rest of this > series and there are no other dependencies on GPIO tree, it might be > easier to just let Kukjin take all the patches with required Acks. > Oh, I didn't see any dependencies...but if so, Linus do you agree with Tomasz' opinion? Please let me know so that I could take this with others into the samsung tree. And please kindly ignore my previous reply on this ;-) Thanks, Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-22 9:59 ` Kukjin Kim 0 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-22 9:59 UTC (permalink / raw) To: linux-arm-kernel Tomasz Figa wrote: > > On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> > wrote: > > > Since this driver does not handle GPIO on device tree enabled > > > platforms > > > any more, it should be bypassed whenever device tree is available, to > > > not conflict with the new pinctrl-samsung driver. > > > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > > > This seems like something I should apply to the GPIO tree > > right now, shall I? > > Would be nice, but since this patch is a dependency for rest of this > series and there are no other dependencies on GPIO tree, it might be > easier to just let Kukjin take all the patches with required Acks. > Oh, I didn't see any dependencies...but if so, Linus do you agree with Tomasz' opinion? Please let me know so that I could take this with others into the samsung tree. And please kindly ignore my previous reply on this ;-) Thanks, Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-22 9:59 ` Kukjin Kim @ 2013-08-22 23:19 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 23:19 UTC (permalink / raw) To: linux-arm-kernel Cc: Kukjin Kim, 'Linus Walleij', 'Mark Rutland', devicetree, 'linux-samsung-soc', 'Russell King', 'Ian Campbell', 'Pawel Moll', 'Stephen Warren', 'Marc Zyngier', 'Rob Herring', linux-gpio, 'Mark Brown', 'Arnd Bergmann', 'Olof Johansson', 'Thomas Gleixner' On Thursday 22 of August 2013 18:59:23 Kukjin Kim wrote: > Tomasz Figa wrote: > > On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > > > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa > > > <tomasz.figa@gmail.com> > > > > wrote: > > > > Since this driver does not handle GPIO on device tree enabled > > > > platforms > > > > any more, it should be bypassed whenever device tree is available, > > > > to > > > > not conflict with the new pinctrl-samsung driver. > > > > > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > > > > > This seems like something I should apply to the GPIO tree > > > right now, shall I? > > > > Would be nice, but since this patch is a dependency for rest of this > > series and there are no other dependencies on GPIO tree, it might be > > easier to just let Kukjin take all the patches with required Acks. > > Oh, I didn't see any dependencies...but if so, Linus do you agree with > Tomasz' opinion? Without this patch DT-based bootup would fail, because the legacy GPIO driver would kick in and register GPIO chips before the pinctrl driver. Things would compile fine, though. So this is a run time dependency, not compile time. > Please let me know so that I could take this with others into the > samsung tree. And please kindly ignore my previous reply on this ;-) I would be really happy if we could finally merge this for this release. This series is not really invasive in any way, so it is unlikely to introduce any regressions and it has waited so many releases, without any significant changes, due to a lot of other dependencies. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-22 23:19 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 23:19 UTC (permalink / raw) To: linux-arm-kernel On Thursday 22 of August 2013 18:59:23 Kukjin Kim wrote: > Tomasz Figa wrote: > > On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: > > > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa > > > <tomasz.figa@gmail.com> > > > > wrote: > > > > Since this driver does not handle GPIO on device tree enabled > > > > platforms > > > > any more, it should be bypassed whenever device tree is available, > > > > to > > > > not conflict with the new pinctrl-samsung driver. > > > > > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > > > > > This seems like something I should apply to the GPIO tree > > > right now, shall I? > > > > Would be nice, but since this patch is a dependency for rest of this > > series and there are no other dependencies on GPIO tree, it might be > > easier to just let Kukjin take all the patches with required Acks. > > Oh, I didn't see any dependencies...but if so, Linus do you agree with > Tomasz' opinion? Without this patch DT-based bootup would fail, because the legacy GPIO driver would kick in and register GPIO chips before the pinctrl driver. Things would compile fine, though. So this is a run time dependency, not compile time. > Please let me know so that I could take this with others into the > samsung tree. And please kindly ignore my previous reply on this ;-) I would be really happy if we could finally merge this for this release. This series is not really invasive in any way, so it is unlikely to introduce any regressions and it has waited so many releases, without any significant changes, due to a lot of other dependencies. Best regards, Tomasz ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-22 9:59 ` Kukjin Kim @ 2013-08-23 18:11 ` Linus Walleij -1 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-23 18:11 UTC (permalink / raw) To: Kukjin Kim Cc: Tomasz Figa, linux-samsung-soc, linux-arm-kernel, devicetree, linux-gpio, Ian Campbell, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown On Thu, Aug 22, 2013 at 11:59 AM, Kukjin Kim <kgene@kernel.org> wrote: > Tomasz Figa wrote: >> On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: >> > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> >> wrote: >> > > Since this driver does not handle GPIO on device tree enabled >> > > platforms >> > > any more, it should be bypassed whenever device tree is available, to >> > > not conflict with the new pinctrl-samsung driver. >> > > >> > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> >> > >> > This seems like something I should apply to the GPIO tree >> > right now, shall I? >> >> Would be nice, but since this patch is a dependency for rest of this >> series and there are no other dependencies on GPIO tree, it might be >> easier to just let Kukjin take all the patches with required Acks. >> > Oh, I didn't see any dependencies...but if so, Linus do you agree with > Tomasz' opinion? Yes please merge it through the Samsung tree. Acked-by: Linus Walleij <linus.walleij@linaro.org> Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-23 18:11 ` Linus Walleij 0 siblings, 0 replies; 64+ messages in thread From: Linus Walleij @ 2013-08-23 18:11 UTC (permalink / raw) To: linux-arm-kernel On Thu, Aug 22, 2013 at 11:59 AM, Kukjin Kim <kgene@kernel.org> wrote: > Tomasz Figa wrote: >> On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: >> > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> >> wrote: >> > > Since this driver does not handle GPIO on device tree enabled >> > > platforms >> > > any more, it should be bypassed whenever device tree is available, to >> > > not conflict with the new pinctrl-samsung driver. >> > > >> > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> >> > >> > This seems like something I should apply to the GPIO tree >> > right now, shall I? >> >> Would be nice, but since this patch is a dependency for rest of this >> series and there are no other dependencies on GPIO tree, it might be >> easier to just let Kukjin take all the patches with required Acks. >> > Oh, I didn't see any dependencies...but if so, Linus do you agree with > Tomasz' opinion? Yes please merge it through the Samsung tree. Acked-by: Linus Walleij <linus.walleij@linaro.org> Yours, Linus Walleij ^ permalink raw reply [flat|nested] 64+ messages in thread
* Re: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-23 18:11 ` Linus Walleij @ 2013-08-25 17:21 ` Kukjin Kim -1 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-25 17:21 UTC (permalink / raw) To: Linus Walleij Cc: Kukjin Kim, Mark Rutland, devicetree, linux-samsung-soc, Russell King, Ian Campbell, Pawel Moll, Stephen Warren, Marc Zyngier, Tomasz Figa, Rob Herring, linux-gpio, Mark Brown, Arnd Bergmann, Olof Johansson, Thomas Gleixner, linux-arm-kernel On 08/24/13 03:11, Linus Walleij wrote: > On Thu, Aug 22, 2013 at 11:59 AM, Kukjin Kim<kgene@kernel.org> wrote: >> Tomasz Figa wrote: >>> On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: >>>> On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa<tomasz.figa@gmail.com> >>> wrote: >>>>> Since this driver does not handle GPIO on device tree enabled >>>>> platforms >>>>> any more, it should be bypassed whenever device tree is available, to >>>>> not conflict with the new pinctrl-samsung driver. >>>>> >>>>> Signed-off-by: Tomasz Figa<tomasz.figa@gmail.com> >>>> >>>> This seems like something I should apply to the GPIO tree >>>> right now, shall I? >>> >>> Would be nice, but since this patch is a dependency for rest of this >>> series and there are no other dependencies on GPIO tree, it might be >>> easier to just let Kukjin take all the patches with required Acks. >>> >> Oh, I didn't see any dependencies...but if so, Linus do you agree with >> Tomasz' opinion? > > Yes please merge it through the Samsung tree. > Acked-by: Linus Walleij<linus.walleij@linaro.org> > Applied, thanks. - Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-25 17:21 ` Kukjin Kim 0 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-25 17:21 UTC (permalink / raw) To: linux-arm-kernel On 08/24/13 03:11, Linus Walleij wrote: > On Thu, Aug 22, 2013 at 11:59 AM, Kukjin Kim<kgene@kernel.org> wrote: >> Tomasz Figa wrote: >>> On Thursday 22 of August 2013 01:21:25 Linus Walleij wrote: >>>> On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa<tomasz.figa@gmail.com> >>> wrote: >>>>> Since this driver does not handle GPIO on device tree enabled >>>>> platforms >>>>> any more, it should be bypassed whenever device tree is available, to >>>>> not conflict with the new pinctrl-samsung driver. >>>>> >>>>> Signed-off-by: Tomasz Figa<tomasz.figa@gmail.com> >>>> >>>> This seems like something I should apply to the GPIO tree >>>> right now, shall I? >>> >>> Would be nice, but since this patch is a dependency for rest of this >>> series and there are no other dependencies on GPIO tree, it might be >>> easier to just let Kukjin take all the patches with required Acks. >>> >> Oh, I didn't see any dependencies...but if so, Linus do you agree with >> Tomasz' opinion? > > Yes please merge it through the Samsung tree. > Acked-by: Linus Walleij<linus.walleij@linaro.org> > Applied, thanks. - Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* RE: [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present 2013-08-21 23:21 ` Linus Walleij @ 2013-08-22 9:45 ` Kukjin Kim -1 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-22 9:45 UTC (permalink / raw) To: 'Linus Walleij', 'Tomasz Figa' Cc: 'linux-samsung-soc', linux-arm-kernel, devicetree, linux-gpio, 'Ian Campbell', 'Mark Rutland', 'Pawel Moll', 'Rob Herring', 'Russell King', 'Stephen Warren', 'Thomas Gleixner', 'Olof Johansson', 'Arnd Bergmann', 'Marc Zyngier', 'Mark Brown' Linus Walleij wrote: > > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> > wrote: > > > Since this driver does not handle GPIO on device tree enabled platforms > > any more, it should be bypassed whenever device tree is available, to > > not conflict with the new pinctrl-samsung driver. > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > This seems like something I should apply to the GPIO tree > right now, shall I? > I think so. Feel free to add my ack on this. Acked-by: Kukjin Kim <kgene.kim@samsung.com> Thanks, Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present @ 2013-08-22 9:45 ` Kukjin Kim 0 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-22 9:45 UTC (permalink / raw) To: linux-arm-kernel Linus Walleij wrote: > > On Wed, Aug 21, 2013 at 11:21 PM, Tomasz Figa <tomasz.figa@gmail.com> > wrote: > > > Since this driver does not handle GPIO on device tree enabled platforms > > any more, it should be bypassed whenever device tree is available, to > > not conflict with the new pinctrl-samsung driver. > > > > Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> > > This seems like something I should apply to the GPIO tree > right now, shall I? > I think so. Feel free to add my ack on this. Acked-by: Kukjin Kim <kgene.kim@samsung.com> Thanks, Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 4/7] ARM: s3c64xx: Add board file for boot using Device Tree 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This patch adds board file that will be used to boot S3C64xx-based boards using Device Tree. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/mach-s3c64xx/Kconfig | 16 +++++++ arch/arm/mach-s3c64xx/Makefile | 1 + arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 85 +++++++++++++++++++++++++++++++++ 3 files changed, 102 insertions(+) create mode 100644 arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c diff --git a/arch/arm/mach-s3c64xx/Kconfig b/arch/arm/mach-s3c64xx/Kconfig index 041da51..bd14e3a 100644 --- a/arch/arm/mach-s3c64xx/Kconfig +++ b/arch/arm/mach-s3c64xx/Kconfig @@ -306,3 +306,19 @@ config MACH_WLF_CRAGG_6410 select SAMSUNG_GPIO_EXTRA128 help Machine support for the Wolfson Cragganmore S3C6410 variant. + +config MACH_S3C64XX_DT + bool "Samsung S3C6400/S3C6410 machine using Device Tree" + select CLKSRC_OF + select CPU_S3C6400 + select CPU_S3C6410 + select PINCTRL + select PINCTRL_S3C64XX + select USE_OF + help + Machine support for Samsung S3C6400/S3C6410 machines with Device Tree + enabled. + Select this if a fdt blob is available for your S3C64XX SoC based + board. + Note: This is under development and not all peripherals can be + supported with this machine file. diff --git a/arch/arm/mach-s3c64xx/Makefile b/arch/arm/mach-s3c64xx/Makefile index 645a8fe..6faedcf 100644 --- a/arch/arm/mach-s3c64xx/Makefile +++ b/arch/arm/mach-s3c64xx/Makefile @@ -57,3 +57,4 @@ obj-$(CONFIG_MACH_SMARTQ7) += mach-smartq7.o obj-$(CONFIG_MACH_SMDK6400) += mach-smdk6400.o obj-$(CONFIG_MACH_SMDK6410) += mach-smdk6410.o obj-$(CONFIG_MACH_WLF_CRAGG_6410) += mach-crag6410.o mach-crag6410-module.o +obj-$(CONFIG_MACH_S3C64XX_DT) += mach-s3c64xx-dt.o diff --git a/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c b/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c new file mode 100644 index 0000000..7eb9a10 --- /dev/null +++ b/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c @@ -0,0 +1,85 @@ +/* + * Samsung's S3C64XX flattened device tree enabled machine + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include <linux/clk-provider.h> +#include <linux/irqchip.h> +#include <linux/of_platform.h> + +#include <asm/mach/arch.h> +#include <asm/mach/map.h> +#include <asm/system_misc.h> + +#include <plat/cpu.h> +#include <plat/watchdog-reset.h> + +#include <mach/map.h> + +#include "common.h" + +/* + * IO mapping for shared system controller IP. + * + * FIXME: Make remaining drivers use dynamic mapping. + */ +static struct map_desc s3c64xx_dt_iodesc[] __initdata = { + { + .virtual = (unsigned long)S3C_VA_SYS, + .pfn = __phys_to_pfn(S3C64XX_PA_SYSCON), + .length = SZ_4K, + .type = MT_DEVICE, + }, +}; + +static void __init s3c64xx_dt_map_io(void) +{ + debug_ll_io_init(); + iotable_init(s3c64xx_dt_iodesc, ARRAY_SIZE(s3c64xx_dt_iodesc)); + + s3c64xx_init_cpu(); + + if (!soc_is_s3c64xx()) + panic("SoC is not S3C64xx!"); +} + +static void __init s3c64xx_dt_init_irq(void) +{ + of_clk_init(NULL); + samsung_wdt_reset_of_init(); + irqchip_init(); +}; + +static void __init s3c64xx_dt_init_machine(void) +{ + of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); +} + +static void s3c64xx_dt_restart(enum reboot_mode mode, const char *cmd) +{ + if (mode != REBOOT_SOFT) + samsung_wdt_reset(); + + /* if all else fails, or mode was for soft, jump to 0 */ + soft_restart(0); +} + +static char const *s3c64xx_dt_compat[] __initdata = { + "samsung,s3c6400", + "samsung,s3c6410", + NULL +}; + +DT_MACHINE_START(S3C6400_DT, "Samsung S3C64xx (Flattened Device Tree)") + /* Maintainer: Tomasz Figa <tomasz.figa@gmail.com> */ + .dt_compat = s3c64xx_dt_compat, + .map_io = s3c64xx_dt_map_io, + .init_irq = s3c64xx_dt_init_irq, + .init_machine = s3c64xx_dt_init_machine, + .restart = s3c64xx_dt_restart, +MACHINE_END -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 4/7] ARM: s3c64xx: Add board file for boot using Device Tree @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This patch adds board file that will be used to boot S3C64xx-based boards using Device Tree. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/mach-s3c64xx/Kconfig | 16 +++++++ arch/arm/mach-s3c64xx/Makefile | 1 + arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 85 +++++++++++++++++++++++++++++++++ 3 files changed, 102 insertions(+) create mode 100644 arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c diff --git a/arch/arm/mach-s3c64xx/Kconfig b/arch/arm/mach-s3c64xx/Kconfig index 041da51..bd14e3a 100644 --- a/arch/arm/mach-s3c64xx/Kconfig +++ b/arch/arm/mach-s3c64xx/Kconfig @@ -306,3 +306,19 @@ config MACH_WLF_CRAGG_6410 select SAMSUNG_GPIO_EXTRA128 help Machine support for the Wolfson Cragganmore S3C6410 variant. + +config MACH_S3C64XX_DT + bool "Samsung S3C6400/S3C6410 machine using Device Tree" + select CLKSRC_OF + select CPU_S3C6400 + select CPU_S3C6410 + select PINCTRL + select PINCTRL_S3C64XX + select USE_OF + help + Machine support for Samsung S3C6400/S3C6410 machines with Device Tree + enabled. + Select this if a fdt blob is available for your S3C64XX SoC based + board. + Note: This is under development and not all peripherals can be + supported with this machine file. diff --git a/arch/arm/mach-s3c64xx/Makefile b/arch/arm/mach-s3c64xx/Makefile index 645a8fe..6faedcf 100644 --- a/arch/arm/mach-s3c64xx/Makefile +++ b/arch/arm/mach-s3c64xx/Makefile @@ -57,3 +57,4 @@ obj-$(CONFIG_MACH_SMARTQ7) += mach-smartq7.o obj-$(CONFIG_MACH_SMDK6400) += mach-smdk6400.o obj-$(CONFIG_MACH_SMDK6410) += mach-smdk6410.o obj-$(CONFIG_MACH_WLF_CRAGG_6410) += mach-crag6410.o mach-crag6410-module.o +obj-$(CONFIG_MACH_S3C64XX_DT) += mach-s3c64xx-dt.o diff --git a/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c b/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c new file mode 100644 index 0000000..7eb9a10 --- /dev/null +++ b/arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c @@ -0,0 +1,85 @@ +/* + * Samsung's S3C64XX flattened device tree enabled machine + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include <linux/clk-provider.h> +#include <linux/irqchip.h> +#include <linux/of_platform.h> + +#include <asm/mach/arch.h> +#include <asm/mach/map.h> +#include <asm/system_misc.h> + +#include <plat/cpu.h> +#include <plat/watchdog-reset.h> + +#include <mach/map.h> + +#include "common.h" + +/* + * IO mapping for shared system controller IP. + * + * FIXME: Make remaining drivers use dynamic mapping. + */ +static struct map_desc s3c64xx_dt_iodesc[] __initdata = { + { + .virtual = (unsigned long)S3C_VA_SYS, + .pfn = __phys_to_pfn(S3C64XX_PA_SYSCON), + .length = SZ_4K, + .type = MT_DEVICE, + }, +}; + +static void __init s3c64xx_dt_map_io(void) +{ + debug_ll_io_init(); + iotable_init(s3c64xx_dt_iodesc, ARRAY_SIZE(s3c64xx_dt_iodesc)); + + s3c64xx_init_cpu(); + + if (!soc_is_s3c64xx()) + panic("SoC is not S3C64xx!"); +} + +static void __init s3c64xx_dt_init_irq(void) +{ + of_clk_init(NULL); + samsung_wdt_reset_of_init(); + irqchip_init(); +}; + +static void __init s3c64xx_dt_init_machine(void) +{ + of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); +} + +static void s3c64xx_dt_restart(enum reboot_mode mode, const char *cmd) +{ + if (mode != REBOOT_SOFT) + samsung_wdt_reset(); + + /* if all else fails, or mode was for soft, jump to 0 */ + soft_restart(0); +} + +static char const *s3c64xx_dt_compat[] __initdata = { + "samsung,s3c6400", + "samsung,s3c6410", + NULL +}; + +DT_MACHINE_START(S3C6400_DT, "Samsung S3C64xx (Flattened Device Tree)") + /* Maintainer: Tomasz Figa <tomasz.figa@gmail.com> */ + .dt_compat = s3c64xx_dt_compat, + .map_io = s3c64xx_dt_map_io, + .init_irq = s3c64xx_dt_init_irq, + .init_machine = s3c64xx_dt_init_machine, + .restart = s3c64xx_dt_restart, +MACHINE_END -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This patch adds basic device tree definitions for Samsung S3C64xx SoCs. Since all the SoCs in the series are very similar, the files are created hierarchically - one file for the whole series and then separate files for particular SoCs including the common one. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++++ 4 files changed, 984 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi diff --git a/arch/arm/boot/dts/s3c6400.dtsi b/arch/arm/boot/dts/s3c6400.dtsi new file mode 100644 index 0000000..692f827 --- /dev/null +++ b/arch/arm/boot/dts/s3c6400.dtsi @@ -0,0 +1,41 @@ +/* + * Samsung's S3C6400 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6400 SoC device nodes are listed in this file. S3C6400 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6400 SoC. As device tree coverage for S3C6400 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6400"; +}; + +&vic0 { + interrupt-mask = <0xfffffe1f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + interrupt-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller@7e00f000 { + compatible = "samsung,s3c6400-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; +}; diff --git a/arch/arm/boot/dts/s3c6410.dtsi b/arch/arm/boot/dts/s3c6410.dtsi new file mode 100644 index 0000000..79c7083 --- /dev/null +++ b/arch/arm/boot/dts/s3c6410.dtsi @@ -0,0 +1,57 @@ +/* + * Samsung's S3C6410 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6410 SoC device nodes are listed in this file. S3C6410 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6410 SoC. As device tree coverage for S3C6410 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6410"; + + aliases { + i2c1 = &i2c1; + }; +}; + +&vic0 { + interrupt-mask = <0xffffff7f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + interrupt-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller@7e00f000 { + compatible = "samsung,s3c6410-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; + + i2c1: i2c@7f00f000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f00f000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <5>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC1>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi new file mode 100644 index 0000000..b1197d8 --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi @@ -0,0 +1,687 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * - pin control-related definitions + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoCs pin banks, pin-mux and pin-config options are + * listed as device tree nodes in this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#define PIN_PULL_NONE 0 +#define PIN_PULL_DOWN 1 +#define PIN_PULL_UP 2 + +&pinctrl0 { + /* + * Pin banks + */ + + gpa: gpa { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpb: gpb { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpc: gpc { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpd: gpd { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpe: gpe { + gpio-controller; + #gpio-cells = <2>; + }; + + gpf: gpf { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpg: gpg { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gph: gph { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpi: gpi { + gpio-controller; + #gpio-cells = <2>; + }; + + gpj: gpj { + gpio-controller; + #gpio-cells = <2>; + }; + + gpk: gpk { + gpio-controller; + #gpio-cells = <2>; + }; + + gpl: gpl { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpm: gpm { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpn: gpn { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpo: gpo { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpp: gpp { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpq: gpq { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + /* + * Pin groups + */ + + uart0_data: uart0-data { + samsung,pins = "gpa-0", "gpa-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart0_fctl: uart0-fctl { + samsung,pins = "gpa-2", "gpa-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_data: uart1-data { + samsung,pins = "gpa-4", "gpa-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_fctl: uart1-fctl { + samsung,pins = "gpa-6", "gpa-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart2_data: uart2-data { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart3_data: uart3-data { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_0: ext-dma-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_1: ext-dma-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_0: irda-data-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_1: irda-data-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_sdbw: irda-sdbw { + samsung,pins = "gpb-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2c0_bus: i2c0-bus { + samsung,pins = "gpb-5", "gpb-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + i2c1_bus: i2c1-bus { + /* S3C6410-only */ + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <6>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_bus: spi0-bus { + samsung,pins = "gpc-0", "gpc-1", "gpc-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_cs: spi0-cs { + samsung,pins = "gpc-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + spi1_bus: spi1-bus { + samsung,pins = "gpc-4", "gpc-5", "gpc-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi1_cs: spi1-cs { + samsung,pins = "gpc-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cmd: sd0-cmd { + samsung,pins = "gpg-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_clk: sd0-clk { + samsung,pins = "gpg-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus1: sd0-bus1 { + samsung,pins = "gpg-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus4: sd0-bus4 { + samsung,pins = "gpg-2", "gpg-3", "gpg-4", "gpg-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cd: sd0-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd1_cmd: sd1-cmd { + samsung,pins = "gph-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_clk: sd1-clk { + samsung,pins = "gph-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus1: sd1-bus1 { + samsung,pins = "gph-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus4: sd1-bus4 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus8: sd1-bus8 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5", + "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_cd: sd1-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd2_cmd: sd2-cmd { + samsung,pins = "gpc-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_clk: sd2-clk { + samsung,pins = "gpc-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus1: sd2-bus1 { + samsung,pins = "gph-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus4: sd2-bus4 { + samsung,pins = "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_bus: i2s0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_cdclk: i2s0-cdclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_bus: i2s1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_cdclk: i2s1-cdclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_bus: i2s2-bus { + /* S3C6410-only */ + samsung,pins = "gpc-4", "gpc-5", "gpc-6", "gph-6", + "gph-8", "gph-9"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_cdclk: i2s2-cdclk { + /* S3C6410-only */ + samsung,pins = "gph-7"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_bus: pcm0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_extclk: pcm0-extclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_bus: pcm1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_extclk: pcm1-extclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_0: ac97-bus-0 { + samsung,pins = "gpd-0", "gpd-1", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_1: ac97-bus-1 { + samsung,pins = "gpe-0", "gpe-1", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_port: cam-port { + samsung,pins = "gpf-0", "gpf-1", "gpf-2", "gpf-4", + "gpf-5", "gpf-6", "gpf-7", "gpf-8", + "gpf-9", "gpf-10", "gpf-11", "gpf-12"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_rst: cam-rst { + samsung,pins = "gpf-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_field: cam-field { + /* S3C6410-only */ + samsung,pins = "gpb-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm_extclk: pwm-extclk { + samsung,pins = "gpf-13"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm0_out: pwm0-out { + samsung,pins = "gpf-14"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm1_out: pwm1-out { + samsung,pins = "gpf-15"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + clkout0: clkout-0 { + samsung,pins = "gpf-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_0: keypad-col0-0 { + samsung,pins = "gph-0"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_0: keypad-col1-0 { + samsung,pins = "gph-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_0: keypad-col2-0 { + samsung,pins = "gph-2"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_0: keypad-col3-0 { + samsung,pins = "gph-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_0: keypad-col4-0 { + samsung,pins = "gph-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_0: keypad-col5-0 { + samsung,pins = "gph-5"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_0: keypad-col6-0 { + samsung,pins = "gph-6"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_0: keypad-col7-0 { + samsung,pins = "gph-7"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_1: keypad-col0-1 { + samsung,pins = "gpl-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_1: keypad-col1-1 { + samsung,pins = "gpl-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_1: keypad-col2-1 { + samsung,pins = "gpl-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_1: keypad-col3-1 { + samsung,pins = "gpl-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_1: keypad-col4-1 { + samsung,pins = "gpl-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_1: keypad-col5-1 { + samsung,pins = "gpl-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_1: keypad-col6-1 { + samsung,pins = "gpl-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_1: keypad-col7-1 { + samsung,pins = "gpl-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_0: keypad-row0-0 { + samsung,pins = "gpk-8"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_0: keypad-row1-0 { + samsung,pins = "gpk-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_0: keypad-row2-0 { + samsung,pins = "gpk-10"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_0: keypad-row3-0 { + samsung,pins = "gpk-11"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_0: keypad-row4-0 { + samsung,pins = "gpk-12"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_0: keypad-row5-0 { + samsung,pins = "gpk-13"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_0: keypad-row6-0 { + samsung,pins = "gpk-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_0: keypad-row7-0 { + samsung,pins = "gpk-15"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_1: keypad-row0-1 { + samsung,pins = "gpn-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_1: keypad-row1-1 { + samsung,pins = "gpn-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_1: keypad-row2-1 { + samsung,pins = "gpn-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_1: keypad-row3-1 { + samsung,pins = "gpn-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_1: keypad-row4-1 { + samsung,pins = "gpn-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_1: keypad-row5-1 { + samsung,pins = "gpn-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_1: keypad-row6-1 { + samsung,pins = "gpn-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_1: keypad-row7-1 { + samsung,pins = "gpn-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_ctrl: lcd-ctrl { + samsung,pins = "gpj-8", "gpj-9", "gpj-10", "gpj-11"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data16: lcd-data-width16 { + samsung,pins = "gpi-3", "gpi-4", "gpi-5", "gpi-6", + "gpi-7", "gpi-10", "gpi-11", "gpi-12", + "gpi-13", "gpi-14", "gpi-15", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data18: lcd-data-width18 { + samsung,pins = "gpi-2", "gpi-3", "gpi-4", "gpi-5", + "gpi-6", "gpi-7", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-2", "gpj-3", "gpj-4", "gpj-5", + "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data24: lcd-data-width24 { + samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3", + "gpi-4", "gpi-5", "gpi-6", "gpi-7", + "gpi-8", "gpi-9", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-0", "gpj-1", "gpj-2", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + hsi_bus: hsi-bus { + samsung,pins = "gpk-0", "gpk-1", "gpk-2", "gpk-3", + "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx.dtsi b/arch/arm/boot/dts/s3c64xx.dtsi new file mode 100644 index 0000000..4e3be4d --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx.dtsi @@ -0,0 +1,199 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoC series device nodes are listed in this file. + * Particular SoCs from S3C64xx series can include this file and provide + * values for SoCs specfic bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C64xx SoCs. As device tree coverage for S3C64xx increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include "skeleton.dtsi" +#include <dt-bindings/clock/samsung,s3c64xx-clock.h> + +/ { + aliases { + i2c0 = &i2c0; + pinctrl0 = &pinctrl0; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu@0 { + device_type = "cpu"; + compatible = "arm,arm1176jzf-s", "arm,arm1176"; + reg = <0x0>; + }; + }; + + soc: soc { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + vic0: interrupt-controller@71200000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71200000 0x1000>; + #interrupt-cells = <1>; + }; + + vic1: interrupt-controller@71300000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71300000 0x1000>; + #interrupt-cells = <1>; + }; + + sdhci0: sdhci@7c200000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c200000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <24>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC0>, <&clocks HCLK_HSMMC0>, + <&clocks SCLK_MMC0>; + status = "disabled"; + }; + + sdhci1: sdhci@7c300000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c300000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <25>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC1>, <&clocks HCLK_HSMMC1>, + <&clocks SCLK_MMC1>; + status = "disabled"; + }; + + sdhci2: sdhci@7c400000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c400000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <17>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC2>, <&clocks HCLK_HSMMC2>, + <&clocks SCLK_MMC2>; + status = "disabled"; + }; + + watchdog: watchdog@7e004000 { + compatible = "samsung,s3c2410-wdt"; + reg = <0x7e004000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <26>; + clock-names = "watchdog"; + clocks = <&clocks PCLK_WDT>; + status = "disabled"; + }; + + i2c0: i2c@7f004000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f004000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <18>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC0>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; + + uart0: serial@7f005000 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <5>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART0>, <&clocks PCLK_UART0>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart1: serial@7f005400 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005400 0x100>; + interrupt-parent = <&vic1>; + interrupts = <6>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART1>, <&clocks PCLK_UART1>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart2: serial@7f005800 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005800 0x100>; + interrupt-parent = <&vic1>; + interrupts = <7>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART2>, <&clocks PCLK_UART2>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart3: serial@7f005c00 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005c00 0x100>; + interrupt-parent = <&vic1>; + interrupts = <8>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART3>, <&clocks PCLK_UART3>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + pwm: pwm@7f006000 { + compatible = "samsung,s3c6400-pwm"; + reg = <0x7f006000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <23>, <24>, <25>, <27>, <28>; + clock-names = "timers"; + clocks = <&clocks PCLK_PWM>; + samsung,pwm-outputs = <0>, <1>; + #pwm-cells = <3>; + status = "disabled"; + }; + + pinctrl0: pinctrl@7f008000 { + compatible = "samsung,s3c64xx-pinctrl"; + reg = <0x7f008000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <21>; + + pctrl_int_map: pinctrl-interrupt-map { + interrupt-map = <0 &vic0 0>, + <1 &vic0 1>, + <2 &vic1 0>, + <3 &vic1 1>; + #address-cells = <0>; + #size-cells = <0>; + #interrupt-cells = <1>; + }; + + wakeup-interrupt-controller { + compatible = "samsung,s3c64xx-wakeup-eint"; + interrupts = <0>, <1>, <2>, <3>; + interrupt-parent = <&pctrl_int_map>; + }; + }; + }; +}; + +#include "s3c64xx-pinctrl.dtsi" -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This patch adds basic device tree definitions for Samsung S3C64xx SoCs. Since all the SoCs in the series are very similar, the files are created hierarchically - one file for the whole series and then separate files for particular SoCs including the common one. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++++ 4 files changed, 984 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi diff --git a/arch/arm/boot/dts/s3c6400.dtsi b/arch/arm/boot/dts/s3c6400.dtsi new file mode 100644 index 0000000..692f827 --- /dev/null +++ b/arch/arm/boot/dts/s3c6400.dtsi @@ -0,0 +1,41 @@ +/* + * Samsung's S3C6400 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6400 SoC device nodes are listed in this file. S3C6400 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6400 SoC. As device tree coverage for S3C6400 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6400"; +}; + +&vic0 { + interrupt-mask = <0xfffffe1f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + interrupt-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller at 7e00f000 { + compatible = "samsung,s3c6400-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; +}; diff --git a/arch/arm/boot/dts/s3c6410.dtsi b/arch/arm/boot/dts/s3c6410.dtsi new file mode 100644 index 0000000..79c7083 --- /dev/null +++ b/arch/arm/boot/dts/s3c6410.dtsi @@ -0,0 +1,57 @@ +/* + * Samsung's S3C6410 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6410 SoC device nodes are listed in this file. S3C6410 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6410 SoC. As device tree coverage for S3C6410 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6410"; + + aliases { + i2c1 = &i2c1; + }; +}; + +&vic0 { + interrupt-mask = <0xffffff7f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + interrupt-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller at 7e00f000 { + compatible = "samsung,s3c6410-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; + + i2c1: i2c at 7f00f000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f00f000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <5>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC1>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi new file mode 100644 index 0000000..b1197d8 --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi @@ -0,0 +1,687 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * - pin control-related definitions + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoCs pin banks, pin-mux and pin-config options are + * listed as device tree nodes in this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#define PIN_PULL_NONE 0 +#define PIN_PULL_DOWN 1 +#define PIN_PULL_UP 2 + +&pinctrl0 { + /* + * Pin banks + */ + + gpa: gpa { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpb: gpb { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpc: gpc { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpd: gpd { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpe: gpe { + gpio-controller; + #gpio-cells = <2>; + }; + + gpf: gpf { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpg: gpg { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gph: gph { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpi: gpi { + gpio-controller; + #gpio-cells = <2>; + }; + + gpj: gpj { + gpio-controller; + #gpio-cells = <2>; + }; + + gpk: gpk { + gpio-controller; + #gpio-cells = <2>; + }; + + gpl: gpl { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpm: gpm { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpn: gpn { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpo: gpo { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpp: gpp { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpq: gpq { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + /* + * Pin groups + */ + + uart0_data: uart0-data { + samsung,pins = "gpa-0", "gpa-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart0_fctl: uart0-fctl { + samsung,pins = "gpa-2", "gpa-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_data: uart1-data { + samsung,pins = "gpa-4", "gpa-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_fctl: uart1-fctl { + samsung,pins = "gpa-6", "gpa-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart2_data: uart2-data { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart3_data: uart3-data { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_0: ext-dma-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_1: ext-dma-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_0: irda-data-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_1: irda-data-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_sdbw: irda-sdbw { + samsung,pins = "gpb-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2c0_bus: i2c0-bus { + samsung,pins = "gpb-5", "gpb-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + i2c1_bus: i2c1-bus { + /* S3C6410-only */ + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <6>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_bus: spi0-bus { + samsung,pins = "gpc-0", "gpc-1", "gpc-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_cs: spi0-cs { + samsung,pins = "gpc-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + spi1_bus: spi1-bus { + samsung,pins = "gpc-4", "gpc-5", "gpc-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi1_cs: spi1-cs { + samsung,pins = "gpc-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cmd: sd0-cmd { + samsung,pins = "gpg-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_clk: sd0-clk { + samsung,pins = "gpg-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus1: sd0-bus1 { + samsung,pins = "gpg-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus4: sd0-bus4 { + samsung,pins = "gpg-2", "gpg-3", "gpg-4", "gpg-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cd: sd0-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd1_cmd: sd1-cmd { + samsung,pins = "gph-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_clk: sd1-clk { + samsung,pins = "gph-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus1: sd1-bus1 { + samsung,pins = "gph-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus4: sd1-bus4 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus8: sd1-bus8 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5", + "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_cd: sd1-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd2_cmd: sd2-cmd { + samsung,pins = "gpc-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_clk: sd2-clk { + samsung,pins = "gpc-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus1: sd2-bus1 { + samsung,pins = "gph-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus4: sd2-bus4 { + samsung,pins = "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_bus: i2s0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_cdclk: i2s0-cdclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_bus: i2s1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_cdclk: i2s1-cdclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_bus: i2s2-bus { + /* S3C6410-only */ + samsung,pins = "gpc-4", "gpc-5", "gpc-6", "gph-6", + "gph-8", "gph-9"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_cdclk: i2s2-cdclk { + /* S3C6410-only */ + samsung,pins = "gph-7"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_bus: pcm0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_extclk: pcm0-extclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_bus: pcm1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_extclk: pcm1-extclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_0: ac97-bus-0 { + samsung,pins = "gpd-0", "gpd-1", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_1: ac97-bus-1 { + samsung,pins = "gpe-0", "gpe-1", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_port: cam-port { + samsung,pins = "gpf-0", "gpf-1", "gpf-2", "gpf-4", + "gpf-5", "gpf-6", "gpf-7", "gpf-8", + "gpf-9", "gpf-10", "gpf-11", "gpf-12"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_rst: cam-rst { + samsung,pins = "gpf-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_field: cam-field { + /* S3C6410-only */ + samsung,pins = "gpb-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm_extclk: pwm-extclk { + samsung,pins = "gpf-13"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm0_out: pwm0-out { + samsung,pins = "gpf-14"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm1_out: pwm1-out { + samsung,pins = "gpf-15"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + clkout0: clkout-0 { + samsung,pins = "gpf-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_0: keypad-col0-0 { + samsung,pins = "gph-0"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_0: keypad-col1-0 { + samsung,pins = "gph-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_0: keypad-col2-0 { + samsung,pins = "gph-2"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_0: keypad-col3-0 { + samsung,pins = "gph-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_0: keypad-col4-0 { + samsung,pins = "gph-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_0: keypad-col5-0 { + samsung,pins = "gph-5"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_0: keypad-col6-0 { + samsung,pins = "gph-6"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_0: keypad-col7-0 { + samsung,pins = "gph-7"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_1: keypad-col0-1 { + samsung,pins = "gpl-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_1: keypad-col1-1 { + samsung,pins = "gpl-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_1: keypad-col2-1 { + samsung,pins = "gpl-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_1: keypad-col3-1 { + samsung,pins = "gpl-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_1: keypad-col4-1 { + samsung,pins = "gpl-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_1: keypad-col5-1 { + samsung,pins = "gpl-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_1: keypad-col6-1 { + samsung,pins = "gpl-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_1: keypad-col7-1 { + samsung,pins = "gpl-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_0: keypad-row0-0 { + samsung,pins = "gpk-8"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_0: keypad-row1-0 { + samsung,pins = "gpk-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_0: keypad-row2-0 { + samsung,pins = "gpk-10"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_0: keypad-row3-0 { + samsung,pins = "gpk-11"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_0: keypad-row4-0 { + samsung,pins = "gpk-12"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_0: keypad-row5-0 { + samsung,pins = "gpk-13"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_0: keypad-row6-0 { + samsung,pins = "gpk-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_0: keypad-row7-0 { + samsung,pins = "gpk-15"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_1: keypad-row0-1 { + samsung,pins = "gpn-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_1: keypad-row1-1 { + samsung,pins = "gpn-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_1: keypad-row2-1 { + samsung,pins = "gpn-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_1: keypad-row3-1 { + samsung,pins = "gpn-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_1: keypad-row4-1 { + samsung,pins = "gpn-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_1: keypad-row5-1 { + samsung,pins = "gpn-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_1: keypad-row6-1 { + samsung,pins = "gpn-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_1: keypad-row7-1 { + samsung,pins = "gpn-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_ctrl: lcd-ctrl { + samsung,pins = "gpj-8", "gpj-9", "gpj-10", "gpj-11"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data16: lcd-data-width16 { + samsung,pins = "gpi-3", "gpi-4", "gpi-5", "gpi-6", + "gpi-7", "gpi-10", "gpi-11", "gpi-12", + "gpi-13", "gpi-14", "gpi-15", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data18: lcd-data-width18 { + samsung,pins = "gpi-2", "gpi-3", "gpi-4", "gpi-5", + "gpi-6", "gpi-7", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-2", "gpj-3", "gpj-4", "gpj-5", + "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data24: lcd-data-width24 { + samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3", + "gpi-4", "gpi-5", "gpi-6", "gpi-7", + "gpi-8", "gpi-9", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-0", "gpj-1", "gpj-2", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + hsi_bus: hsi-bus { + samsung,pins = "gpk-0", "gpk-1", "gpk-2", "gpk-3", + "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx.dtsi b/arch/arm/boot/dts/s3c64xx.dtsi new file mode 100644 index 0000000..4e3be4d --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx.dtsi @@ -0,0 +1,199 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoC series device nodes are listed in this file. + * Particular SoCs from S3C64xx series can include this file and provide + * values for SoCs specfic bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C64xx SoCs. As device tree coverage for S3C64xx increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include "skeleton.dtsi" +#include <dt-bindings/clock/samsung,s3c64xx-clock.h> + +/ { + aliases { + i2c0 = &i2c0; + pinctrl0 = &pinctrl0; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu at 0 { + device_type = "cpu"; + compatible = "arm,arm1176jzf-s", "arm,arm1176"; + reg = <0x0>; + }; + }; + + soc: soc { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + vic0: interrupt-controller at 71200000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71200000 0x1000>; + #interrupt-cells = <1>; + }; + + vic1: interrupt-controller at 71300000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71300000 0x1000>; + #interrupt-cells = <1>; + }; + + sdhci0: sdhci at 7c200000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c200000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <24>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC0>, <&clocks HCLK_HSMMC0>, + <&clocks SCLK_MMC0>; + status = "disabled"; + }; + + sdhci1: sdhci at 7c300000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c300000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <25>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC1>, <&clocks HCLK_HSMMC1>, + <&clocks SCLK_MMC1>; + status = "disabled"; + }; + + sdhci2: sdhci at 7c400000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c400000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <17>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC2>, <&clocks HCLK_HSMMC2>, + <&clocks SCLK_MMC2>; + status = "disabled"; + }; + + watchdog: watchdog at 7e004000 { + compatible = "samsung,s3c2410-wdt"; + reg = <0x7e004000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <26>; + clock-names = "watchdog"; + clocks = <&clocks PCLK_WDT>; + status = "disabled"; + }; + + i2c0: i2c at 7f004000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f004000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <18>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC0>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; + + uart0: serial at 7f005000 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <5>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART0>, <&clocks PCLK_UART0>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart1: serial at 7f005400 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005400 0x100>; + interrupt-parent = <&vic1>; + interrupts = <6>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART1>, <&clocks PCLK_UART1>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart2: serial at 7f005800 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005800 0x100>; + interrupt-parent = <&vic1>; + interrupts = <7>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART2>, <&clocks PCLK_UART2>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart3: serial at 7f005c00 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005c00 0x100>; + interrupt-parent = <&vic1>; + interrupts = <8>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART3>, <&clocks PCLK_UART3>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + pwm: pwm at 7f006000 { + compatible = "samsung,s3c6400-pwm"; + reg = <0x7f006000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <23>, <24>, <25>, <27>, <28>; + clock-names = "timers"; + clocks = <&clocks PCLK_PWM>; + samsung,pwm-outputs = <0>, <1>; + #pwm-cells = <3>; + status = "disabled"; + }; + + pinctrl0: pinctrl at 7f008000 { + compatible = "samsung,s3c64xx-pinctrl"; + reg = <0x7f008000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <21>; + + pctrl_int_map: pinctrl-interrupt-map { + interrupt-map = <0 &vic0 0>, + <1 &vic0 1>, + <2 &vic1 0>, + <3 &vic1 1>; + #address-cells = <0>; + #size-cells = <0>; + #interrupt-cells = <1>; + }; + + wakeup-interrupt-controller { + compatible = "samsung,s3c64xx-wakeup-eint"; + interrupts = <0>, <1>, <2>, <3>; + interrupt-parent = <&pctrl_int_map>; + }; + }; + }; +}; + +#include "s3c64xx-pinctrl.dtsi" -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v8 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-22 23:24 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 23:24 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown This patch adds basic device tree definitions for Samsung S3C64xx SoCs. Since all the SoCs in the series are very similar, the files are created hierarchically - one file for the whole series and then separate files for particular SoCs including the common one. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++++ 4 files changed, 984 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi Changes since v7: - Updated VIC nodes to reflect changes done to patch 1/7 (renamed interrupt-mask property to valid-mask). diff --git a/arch/arm/boot/dts/s3c6400.dtsi b/arch/arm/boot/dts/s3c6400.dtsi new file mode 100644 index 0000000..9fec67e --- /dev/null +++ b/arch/arm/boot/dts/s3c6400.dtsi @@ -0,0 +1,41 @@ +/* + * Samsung's S3C6400 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6400 SoC device nodes are listed in this file. S3C6400 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6400 SoC. As device tree coverage for S3C6400 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6400"; +}; + +&vic0 { + valid-mask = <0xfffffe1f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller@7e00f000 { + compatible = "samsung,s3c6400-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; +}; diff --git a/arch/arm/boot/dts/s3c6410.dtsi b/arch/arm/boot/dts/s3c6410.dtsi new file mode 100644 index 0000000..94276bd --- /dev/null +++ b/arch/arm/boot/dts/s3c6410.dtsi @@ -0,0 +1,57 @@ +/* + * Samsung's S3C6410 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6410 SoC device nodes are listed in this file. S3C6410 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6410 SoC. As device tree coverage for S3C6410 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6410"; + + aliases { + i2c1 = &i2c1; + }; +}; + +&vic0 { + valid-mask = <0xffffff7f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller@7e00f000 { + compatible = "samsung,s3c6410-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; + + i2c1: i2c@7f00f000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f00f000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <5>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC1>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi new file mode 100644 index 0000000..b1197d8 --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi @@ -0,0 +1,687 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * - pin control-related definitions + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoCs pin banks, pin-mux and pin-config options are + * listed as device tree nodes in this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#define PIN_PULL_NONE 0 +#define PIN_PULL_DOWN 1 +#define PIN_PULL_UP 2 + +&pinctrl0 { + /* + * Pin banks + */ + + gpa: gpa { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpb: gpb { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpc: gpc { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpd: gpd { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpe: gpe { + gpio-controller; + #gpio-cells = <2>; + }; + + gpf: gpf { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpg: gpg { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gph: gph { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpi: gpi { + gpio-controller; + #gpio-cells = <2>; + }; + + gpj: gpj { + gpio-controller; + #gpio-cells = <2>; + }; + + gpk: gpk { + gpio-controller; + #gpio-cells = <2>; + }; + + gpl: gpl { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpm: gpm { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpn: gpn { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpo: gpo { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpp: gpp { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpq: gpq { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + /* + * Pin groups + */ + + uart0_data: uart0-data { + samsung,pins = "gpa-0", "gpa-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart0_fctl: uart0-fctl { + samsung,pins = "gpa-2", "gpa-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_data: uart1-data { + samsung,pins = "gpa-4", "gpa-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_fctl: uart1-fctl { + samsung,pins = "gpa-6", "gpa-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart2_data: uart2-data { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart3_data: uart3-data { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_0: ext-dma-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_1: ext-dma-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_0: irda-data-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_1: irda-data-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_sdbw: irda-sdbw { + samsung,pins = "gpb-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2c0_bus: i2c0-bus { + samsung,pins = "gpb-5", "gpb-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + i2c1_bus: i2c1-bus { + /* S3C6410-only */ + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <6>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_bus: spi0-bus { + samsung,pins = "gpc-0", "gpc-1", "gpc-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_cs: spi0-cs { + samsung,pins = "gpc-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + spi1_bus: spi1-bus { + samsung,pins = "gpc-4", "gpc-5", "gpc-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi1_cs: spi1-cs { + samsung,pins = "gpc-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cmd: sd0-cmd { + samsung,pins = "gpg-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_clk: sd0-clk { + samsung,pins = "gpg-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus1: sd0-bus1 { + samsung,pins = "gpg-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus4: sd0-bus4 { + samsung,pins = "gpg-2", "gpg-3", "gpg-4", "gpg-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cd: sd0-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd1_cmd: sd1-cmd { + samsung,pins = "gph-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_clk: sd1-clk { + samsung,pins = "gph-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus1: sd1-bus1 { + samsung,pins = "gph-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus4: sd1-bus4 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus8: sd1-bus8 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5", + "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_cd: sd1-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd2_cmd: sd2-cmd { + samsung,pins = "gpc-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_clk: sd2-clk { + samsung,pins = "gpc-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus1: sd2-bus1 { + samsung,pins = "gph-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus4: sd2-bus4 { + samsung,pins = "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_bus: i2s0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_cdclk: i2s0-cdclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_bus: i2s1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_cdclk: i2s1-cdclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_bus: i2s2-bus { + /* S3C6410-only */ + samsung,pins = "gpc-4", "gpc-5", "gpc-6", "gph-6", + "gph-8", "gph-9"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_cdclk: i2s2-cdclk { + /* S3C6410-only */ + samsung,pins = "gph-7"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_bus: pcm0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_extclk: pcm0-extclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_bus: pcm1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_extclk: pcm1-extclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_0: ac97-bus-0 { + samsung,pins = "gpd-0", "gpd-1", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_1: ac97-bus-1 { + samsung,pins = "gpe-0", "gpe-1", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_port: cam-port { + samsung,pins = "gpf-0", "gpf-1", "gpf-2", "gpf-4", + "gpf-5", "gpf-6", "gpf-7", "gpf-8", + "gpf-9", "gpf-10", "gpf-11", "gpf-12"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_rst: cam-rst { + samsung,pins = "gpf-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_field: cam-field { + /* S3C6410-only */ + samsung,pins = "gpb-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm_extclk: pwm-extclk { + samsung,pins = "gpf-13"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm0_out: pwm0-out { + samsung,pins = "gpf-14"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm1_out: pwm1-out { + samsung,pins = "gpf-15"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + clkout0: clkout-0 { + samsung,pins = "gpf-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_0: keypad-col0-0 { + samsung,pins = "gph-0"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_0: keypad-col1-0 { + samsung,pins = "gph-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_0: keypad-col2-0 { + samsung,pins = "gph-2"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_0: keypad-col3-0 { + samsung,pins = "gph-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_0: keypad-col4-0 { + samsung,pins = "gph-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_0: keypad-col5-0 { + samsung,pins = "gph-5"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_0: keypad-col6-0 { + samsung,pins = "gph-6"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_0: keypad-col7-0 { + samsung,pins = "gph-7"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_1: keypad-col0-1 { + samsung,pins = "gpl-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_1: keypad-col1-1 { + samsung,pins = "gpl-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_1: keypad-col2-1 { + samsung,pins = "gpl-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_1: keypad-col3-1 { + samsung,pins = "gpl-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_1: keypad-col4-1 { + samsung,pins = "gpl-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_1: keypad-col5-1 { + samsung,pins = "gpl-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_1: keypad-col6-1 { + samsung,pins = "gpl-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_1: keypad-col7-1 { + samsung,pins = "gpl-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_0: keypad-row0-0 { + samsung,pins = "gpk-8"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_0: keypad-row1-0 { + samsung,pins = "gpk-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_0: keypad-row2-0 { + samsung,pins = "gpk-10"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_0: keypad-row3-0 { + samsung,pins = "gpk-11"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_0: keypad-row4-0 { + samsung,pins = "gpk-12"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_0: keypad-row5-0 { + samsung,pins = "gpk-13"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_0: keypad-row6-0 { + samsung,pins = "gpk-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_0: keypad-row7-0 { + samsung,pins = "gpk-15"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_1: keypad-row0-1 { + samsung,pins = "gpn-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_1: keypad-row1-1 { + samsung,pins = "gpn-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_1: keypad-row2-1 { + samsung,pins = "gpn-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_1: keypad-row3-1 { + samsung,pins = "gpn-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_1: keypad-row4-1 { + samsung,pins = "gpn-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_1: keypad-row5-1 { + samsung,pins = "gpn-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_1: keypad-row6-1 { + samsung,pins = "gpn-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_1: keypad-row7-1 { + samsung,pins = "gpn-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_ctrl: lcd-ctrl { + samsung,pins = "gpj-8", "gpj-9", "gpj-10", "gpj-11"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data16: lcd-data-width16 { + samsung,pins = "gpi-3", "gpi-4", "gpi-5", "gpi-6", + "gpi-7", "gpi-10", "gpi-11", "gpi-12", + "gpi-13", "gpi-14", "gpi-15", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data18: lcd-data-width18 { + samsung,pins = "gpi-2", "gpi-3", "gpi-4", "gpi-5", + "gpi-6", "gpi-7", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-2", "gpj-3", "gpj-4", "gpj-5", + "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data24: lcd-data-width24 { + samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3", + "gpi-4", "gpi-5", "gpi-6", "gpi-7", + "gpi-8", "gpi-9", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-0", "gpj-1", "gpj-2", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + hsi_bus: hsi-bus { + samsung,pins = "gpk-0", "gpk-1", "gpk-2", "gpk-3", + "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx.dtsi b/arch/arm/boot/dts/s3c64xx.dtsi new file mode 100644 index 0000000..4e3be4d --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx.dtsi @@ -0,0 +1,199 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoC series device nodes are listed in this file. + * Particular SoCs from S3C64xx series can include this file and provide + * values for SoCs specfic bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C64xx SoCs. As device tree coverage for S3C64xx increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include "skeleton.dtsi" +#include <dt-bindings/clock/samsung,s3c64xx-clock.h> + +/ { + aliases { + i2c0 = &i2c0; + pinctrl0 = &pinctrl0; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu@0 { + device_type = "cpu"; + compatible = "arm,arm1176jzf-s", "arm,arm1176"; + reg = <0x0>; + }; + }; + + soc: soc { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + vic0: interrupt-controller@71200000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71200000 0x1000>; + #interrupt-cells = <1>; + }; + + vic1: interrupt-controller@71300000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71300000 0x1000>; + #interrupt-cells = <1>; + }; + + sdhci0: sdhci@7c200000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c200000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <24>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC0>, <&clocks HCLK_HSMMC0>, + <&clocks SCLK_MMC0>; + status = "disabled"; + }; + + sdhci1: sdhci@7c300000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c300000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <25>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC1>, <&clocks HCLK_HSMMC1>, + <&clocks SCLK_MMC1>; + status = "disabled"; + }; + + sdhci2: sdhci@7c400000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c400000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <17>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC2>, <&clocks HCLK_HSMMC2>, + <&clocks SCLK_MMC2>; + status = "disabled"; + }; + + watchdog: watchdog@7e004000 { + compatible = "samsung,s3c2410-wdt"; + reg = <0x7e004000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <26>; + clock-names = "watchdog"; + clocks = <&clocks PCLK_WDT>; + status = "disabled"; + }; + + i2c0: i2c@7f004000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f004000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <18>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC0>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; + + uart0: serial@7f005000 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <5>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART0>, <&clocks PCLK_UART0>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart1: serial@7f005400 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005400 0x100>; + interrupt-parent = <&vic1>; + interrupts = <6>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART1>, <&clocks PCLK_UART1>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart2: serial@7f005800 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005800 0x100>; + interrupt-parent = <&vic1>; + interrupts = <7>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART2>, <&clocks PCLK_UART2>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart3: serial@7f005c00 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005c00 0x100>; + interrupt-parent = <&vic1>; + interrupts = <8>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART3>, <&clocks PCLK_UART3>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + pwm: pwm@7f006000 { + compatible = "samsung,s3c6400-pwm"; + reg = <0x7f006000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <23>, <24>, <25>, <27>, <28>; + clock-names = "timers"; + clocks = <&clocks PCLK_PWM>; + samsung,pwm-outputs = <0>, <1>; + #pwm-cells = <3>; + status = "disabled"; + }; + + pinctrl0: pinctrl@7f008000 { + compatible = "samsung,s3c64xx-pinctrl"; + reg = <0x7f008000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <21>; + + pctrl_int_map: pinctrl-interrupt-map { + interrupt-map = <0 &vic0 0>, + <1 &vic0 1>, + <2 &vic1 0>, + <3 &vic1 1>; + #address-cells = <0>; + #size-cells = <0>; + #interrupt-cells = <1>; + }; + + wakeup-interrupt-controller { + compatible = "samsung,s3c64xx-wakeup-eint"; + interrupts = <0>, <1>, <2>, <3>; + interrupt-parent = <&pctrl_int_map>; + }; + }; + }; +}; + +#include "s3c64xx-pinctrl.dtsi" -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v8 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs @ 2013-08-22 23:24 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-22 23:24 UTC (permalink / raw) To: linux-arm-kernel This patch adds basic device tree definitions for Samsung S3C64xx SoCs. Since all the SoCs in the series are very similar, the files are created hierarchically - one file for the whole series and then separate files for particular SoCs including the common one. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++++ 4 files changed, 984 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi Changes since v7: - Updated VIC nodes to reflect changes done to patch 1/7 (renamed interrupt-mask property to valid-mask). diff --git a/arch/arm/boot/dts/s3c6400.dtsi b/arch/arm/boot/dts/s3c6400.dtsi new file mode 100644 index 0000000..9fec67e --- /dev/null +++ b/arch/arm/boot/dts/s3c6400.dtsi @@ -0,0 +1,41 @@ +/* + * Samsung's S3C6400 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6400 SoC device nodes are listed in this file. S3C6400 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6400 SoC. As device tree coverage for S3C6400 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6400"; +}; + +&vic0 { + valid-mask = <0xfffffe1f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller at 7e00f000 { + compatible = "samsung,s3c6400-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; +}; diff --git a/arch/arm/boot/dts/s3c6410.dtsi b/arch/arm/boot/dts/s3c6410.dtsi new file mode 100644 index 0000000..94276bd --- /dev/null +++ b/arch/arm/boot/dts/s3c6410.dtsi @@ -0,0 +1,57 @@ +/* + * Samsung's S3C6410 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6410 SoC device nodes are listed in this file. S3C6410 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6410 SoC. As device tree coverage for S3C6410 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6410"; + + aliases { + i2c1 = &i2c1; + }; +}; + +&vic0 { + valid-mask = <0xffffff7f>; + wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller at 7e00f000 { + compatible = "samsung,s3c6410-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; + + i2c1: i2c at 7f00f000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f00f000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <5>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC1>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi new file mode 100644 index 0000000..b1197d8 --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi @@ -0,0 +1,687 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * - pin control-related definitions + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoCs pin banks, pin-mux and pin-config options are + * listed as device tree nodes in this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#define PIN_PULL_NONE 0 +#define PIN_PULL_DOWN 1 +#define PIN_PULL_UP 2 + +&pinctrl0 { + /* + * Pin banks + */ + + gpa: gpa { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpb: gpb { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpc: gpc { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpd: gpd { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpe: gpe { + gpio-controller; + #gpio-cells = <2>; + }; + + gpf: gpf { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpg: gpg { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gph: gph { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpi: gpi { + gpio-controller; + #gpio-cells = <2>; + }; + + gpj: gpj { + gpio-controller; + #gpio-cells = <2>; + }; + + gpk: gpk { + gpio-controller; + #gpio-cells = <2>; + }; + + gpl: gpl { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpm: gpm { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpn: gpn { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpo: gpo { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpp: gpp { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpq: gpq { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + /* + * Pin groups + */ + + uart0_data: uart0-data { + samsung,pins = "gpa-0", "gpa-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart0_fctl: uart0-fctl { + samsung,pins = "gpa-2", "gpa-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_data: uart1-data { + samsung,pins = "gpa-4", "gpa-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_fctl: uart1-fctl { + samsung,pins = "gpa-6", "gpa-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart2_data: uart2-data { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart3_data: uart3-data { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_0: ext-dma-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_1: ext-dma-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_0: irda-data-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_1: irda-data-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_sdbw: irda-sdbw { + samsung,pins = "gpb-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2c0_bus: i2c0-bus { + samsung,pins = "gpb-5", "gpb-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + i2c1_bus: i2c1-bus { + /* S3C6410-only */ + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <6>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_bus: spi0-bus { + samsung,pins = "gpc-0", "gpc-1", "gpc-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_cs: spi0-cs { + samsung,pins = "gpc-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + spi1_bus: spi1-bus { + samsung,pins = "gpc-4", "gpc-5", "gpc-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi1_cs: spi1-cs { + samsung,pins = "gpc-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cmd: sd0-cmd { + samsung,pins = "gpg-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_clk: sd0-clk { + samsung,pins = "gpg-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus1: sd0-bus1 { + samsung,pins = "gpg-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus4: sd0-bus4 { + samsung,pins = "gpg-2", "gpg-3", "gpg-4", "gpg-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cd: sd0-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd1_cmd: sd1-cmd { + samsung,pins = "gph-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_clk: sd1-clk { + samsung,pins = "gph-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus1: sd1-bus1 { + samsung,pins = "gph-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus4: sd1-bus4 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus8: sd1-bus8 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5", + "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_cd: sd1-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd2_cmd: sd2-cmd { + samsung,pins = "gpc-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_clk: sd2-clk { + samsung,pins = "gpc-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus1: sd2-bus1 { + samsung,pins = "gph-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus4: sd2-bus4 { + samsung,pins = "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_bus: i2s0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_cdclk: i2s0-cdclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_bus: i2s1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_cdclk: i2s1-cdclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_bus: i2s2-bus { + /* S3C6410-only */ + samsung,pins = "gpc-4", "gpc-5", "gpc-6", "gph-6", + "gph-8", "gph-9"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_cdclk: i2s2-cdclk { + /* S3C6410-only */ + samsung,pins = "gph-7"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_bus: pcm0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_extclk: pcm0-extclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_bus: pcm1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_extclk: pcm1-extclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_0: ac97-bus-0 { + samsung,pins = "gpd-0", "gpd-1", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_1: ac97-bus-1 { + samsung,pins = "gpe-0", "gpe-1", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_port: cam-port { + samsung,pins = "gpf-0", "gpf-1", "gpf-2", "gpf-4", + "gpf-5", "gpf-6", "gpf-7", "gpf-8", + "gpf-9", "gpf-10", "gpf-11", "gpf-12"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_rst: cam-rst { + samsung,pins = "gpf-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_field: cam-field { + /* S3C6410-only */ + samsung,pins = "gpb-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm_extclk: pwm-extclk { + samsung,pins = "gpf-13"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm0_out: pwm0-out { + samsung,pins = "gpf-14"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm1_out: pwm1-out { + samsung,pins = "gpf-15"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + clkout0: clkout-0 { + samsung,pins = "gpf-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_0: keypad-col0-0 { + samsung,pins = "gph-0"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_0: keypad-col1-0 { + samsung,pins = "gph-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_0: keypad-col2-0 { + samsung,pins = "gph-2"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_0: keypad-col3-0 { + samsung,pins = "gph-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_0: keypad-col4-0 { + samsung,pins = "gph-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_0: keypad-col5-0 { + samsung,pins = "gph-5"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_0: keypad-col6-0 { + samsung,pins = "gph-6"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_0: keypad-col7-0 { + samsung,pins = "gph-7"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_1: keypad-col0-1 { + samsung,pins = "gpl-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_1: keypad-col1-1 { + samsung,pins = "gpl-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_1: keypad-col2-1 { + samsung,pins = "gpl-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_1: keypad-col3-1 { + samsung,pins = "gpl-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_1: keypad-col4-1 { + samsung,pins = "gpl-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_1: keypad-col5-1 { + samsung,pins = "gpl-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_1: keypad-col6-1 { + samsung,pins = "gpl-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_1: keypad-col7-1 { + samsung,pins = "gpl-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_0: keypad-row0-0 { + samsung,pins = "gpk-8"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_0: keypad-row1-0 { + samsung,pins = "gpk-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_0: keypad-row2-0 { + samsung,pins = "gpk-10"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_0: keypad-row3-0 { + samsung,pins = "gpk-11"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_0: keypad-row4-0 { + samsung,pins = "gpk-12"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_0: keypad-row5-0 { + samsung,pins = "gpk-13"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_0: keypad-row6-0 { + samsung,pins = "gpk-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_0: keypad-row7-0 { + samsung,pins = "gpk-15"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_1: keypad-row0-1 { + samsung,pins = "gpn-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_1: keypad-row1-1 { + samsung,pins = "gpn-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_1: keypad-row2-1 { + samsung,pins = "gpn-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_1: keypad-row3-1 { + samsung,pins = "gpn-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_1: keypad-row4-1 { + samsung,pins = "gpn-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_1: keypad-row5-1 { + samsung,pins = "gpn-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_1: keypad-row6-1 { + samsung,pins = "gpn-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_1: keypad-row7-1 { + samsung,pins = "gpn-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_ctrl: lcd-ctrl { + samsung,pins = "gpj-8", "gpj-9", "gpj-10", "gpj-11"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data16: lcd-data-width16 { + samsung,pins = "gpi-3", "gpi-4", "gpi-5", "gpi-6", + "gpi-7", "gpi-10", "gpi-11", "gpi-12", + "gpi-13", "gpi-14", "gpi-15", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data18: lcd-data-width18 { + samsung,pins = "gpi-2", "gpi-3", "gpi-4", "gpi-5", + "gpi-6", "gpi-7", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-2", "gpj-3", "gpj-4", "gpj-5", + "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data24: lcd-data-width24 { + samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3", + "gpi-4", "gpi-5", "gpi-6", "gpi-7", + "gpi-8", "gpi-9", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-0", "gpj-1", "gpj-2", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + hsi_bus: hsi-bus { + samsung,pins = "gpk-0", "gpk-1", "gpk-2", "gpk-3", + "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx.dtsi b/arch/arm/boot/dts/s3c64xx.dtsi new file mode 100644 index 0000000..4e3be4d --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx.dtsi @@ -0,0 +1,199 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoC series device nodes are listed in this file. + * Particular SoCs from S3C64xx series can include this file and provide + * values for SoCs specfic bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C64xx SoCs. As device tree coverage for S3C64xx increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include "skeleton.dtsi" +#include <dt-bindings/clock/samsung,s3c64xx-clock.h> + +/ { + aliases { + i2c0 = &i2c0; + pinctrl0 = &pinctrl0; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu at 0 { + device_type = "cpu"; + compatible = "arm,arm1176jzf-s", "arm,arm1176"; + reg = <0x0>; + }; + }; + + soc: soc { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + vic0: interrupt-controller at 71200000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71200000 0x1000>; + #interrupt-cells = <1>; + }; + + vic1: interrupt-controller at 71300000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71300000 0x1000>; + #interrupt-cells = <1>; + }; + + sdhci0: sdhci at 7c200000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c200000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <24>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC0>, <&clocks HCLK_HSMMC0>, + <&clocks SCLK_MMC0>; + status = "disabled"; + }; + + sdhci1: sdhci at 7c300000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c300000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <25>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC1>, <&clocks HCLK_HSMMC1>, + <&clocks SCLK_MMC1>; + status = "disabled"; + }; + + sdhci2: sdhci at 7c400000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c400000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <17>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC2>, <&clocks HCLK_HSMMC2>, + <&clocks SCLK_MMC2>; + status = "disabled"; + }; + + watchdog: watchdog at 7e004000 { + compatible = "samsung,s3c2410-wdt"; + reg = <0x7e004000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <26>; + clock-names = "watchdog"; + clocks = <&clocks PCLK_WDT>; + status = "disabled"; + }; + + i2c0: i2c at 7f004000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f004000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <18>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC0>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; + + uart0: serial at 7f005000 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <5>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART0>, <&clocks PCLK_UART0>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart1: serial at 7f005400 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005400 0x100>; + interrupt-parent = <&vic1>; + interrupts = <6>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART1>, <&clocks PCLK_UART1>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart2: serial at 7f005800 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005800 0x100>; + interrupt-parent = <&vic1>; + interrupts = <7>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART2>, <&clocks PCLK_UART2>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart3: serial at 7f005c00 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005c00 0x100>; + interrupt-parent = <&vic1>; + interrupts = <8>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART3>, <&clocks PCLK_UART3>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + pwm: pwm at 7f006000 { + compatible = "samsung,s3c6400-pwm"; + reg = <0x7f006000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <23>, <24>, <25>, <27>, <28>; + clock-names = "timers"; + clocks = <&clocks PCLK_PWM>; + samsung,pwm-outputs = <0>, <1>; + #pwm-cells = <3>; + status = "disabled"; + }; + + pinctrl0: pinctrl at 7f008000 { + compatible = "samsung,s3c64xx-pinctrl"; + reg = <0x7f008000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <21>; + + pctrl_int_map: pinctrl-interrupt-map { + interrupt-map = <0 &vic0 0>, + <1 &vic0 1>, + <2 &vic1 0>, + <3 &vic1 1>; + #address-cells = <0>; + #size-cells = <0>; + #interrupt-cells = <1>; + }; + + wakeup-interrupt-controller { + compatible = "samsung,s3c64xx-wakeup-eint"; + interrupts = <0>, <1>, <2>, <3>; + interrupt-parent = <&pctrl_int_map>; + }; + }; + }; +}; + +#include "s3c64xx-pinctrl.dtsi" -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v9 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs 2013-08-22 23:24 ` Tomasz Figa @ 2013-08-23 23:56 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:56 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown This patch adds basic device tree definitions for Samsung S3C64xx SoCs. Since all the SoCs in the series are very similar, the files are created hierarchically - one file for the whole series and then separate files for particular SoCs including the common one. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++++ 4 files changed, 984 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi Changes since v8: - Updated VIC nodes to reflect changes done to patch 1/7 (renamed wakeuo-mask property to valid-wakeup-mask). diff --git a/arch/arm/boot/dts/s3c6400.dtsi b/arch/arm/boot/dts/s3c6400.dtsi new file mode 100644 index 0000000..a7d1c8e --- /dev/null +++ b/arch/arm/boot/dts/s3c6400.dtsi @@ -0,0 +1,41 @@ +/* + * Samsung's S3C6400 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6400 SoC device nodes are listed in this file. S3C6400 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6400 SoC. As device tree coverage for S3C6400 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6400"; +}; + +&vic0 { + valid-mask = <0xfffffe1f>; + valid-wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + valid-wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller@7e00f000 { + compatible = "samsung,s3c6400-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; +}; diff --git a/arch/arm/boot/dts/s3c6410.dtsi b/arch/arm/boot/dts/s3c6410.dtsi new file mode 100644 index 0000000..eb4226b --- /dev/null +++ b/arch/arm/boot/dts/s3c6410.dtsi @@ -0,0 +1,57 @@ +/* + * Samsung's S3C6410 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6410 SoC device nodes are listed in this file. S3C6410 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6410 SoC. As device tree coverage for S3C6410 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6410"; + + aliases { + i2c1 = &i2c1; + }; +}; + +&vic0 { + valid-mask = <0xffffff7f>; + valid-wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + valid-wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller@7e00f000 { + compatible = "samsung,s3c6410-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; + + i2c1: i2c@7f00f000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f00f000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <5>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC1>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi new file mode 100644 index 0000000..b1197d8 --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi @@ -0,0 +1,687 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * - pin control-related definitions + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoCs pin banks, pin-mux and pin-config options are + * listed as device tree nodes in this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#define PIN_PULL_NONE 0 +#define PIN_PULL_DOWN 1 +#define PIN_PULL_UP 2 + +&pinctrl0 { + /* + * Pin banks + */ + + gpa: gpa { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpb: gpb { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpc: gpc { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpd: gpd { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpe: gpe { + gpio-controller; + #gpio-cells = <2>; + }; + + gpf: gpf { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpg: gpg { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gph: gph { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpi: gpi { + gpio-controller; + #gpio-cells = <2>; + }; + + gpj: gpj { + gpio-controller; + #gpio-cells = <2>; + }; + + gpk: gpk { + gpio-controller; + #gpio-cells = <2>; + }; + + gpl: gpl { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpm: gpm { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpn: gpn { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpo: gpo { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpp: gpp { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpq: gpq { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + /* + * Pin groups + */ + + uart0_data: uart0-data { + samsung,pins = "gpa-0", "gpa-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart0_fctl: uart0-fctl { + samsung,pins = "gpa-2", "gpa-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_data: uart1-data { + samsung,pins = "gpa-4", "gpa-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_fctl: uart1-fctl { + samsung,pins = "gpa-6", "gpa-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart2_data: uart2-data { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart3_data: uart3-data { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_0: ext-dma-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_1: ext-dma-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_0: irda-data-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_1: irda-data-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_sdbw: irda-sdbw { + samsung,pins = "gpb-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2c0_bus: i2c0-bus { + samsung,pins = "gpb-5", "gpb-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + i2c1_bus: i2c1-bus { + /* S3C6410-only */ + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <6>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_bus: spi0-bus { + samsung,pins = "gpc-0", "gpc-1", "gpc-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_cs: spi0-cs { + samsung,pins = "gpc-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + spi1_bus: spi1-bus { + samsung,pins = "gpc-4", "gpc-5", "gpc-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi1_cs: spi1-cs { + samsung,pins = "gpc-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cmd: sd0-cmd { + samsung,pins = "gpg-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_clk: sd0-clk { + samsung,pins = "gpg-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus1: sd0-bus1 { + samsung,pins = "gpg-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus4: sd0-bus4 { + samsung,pins = "gpg-2", "gpg-3", "gpg-4", "gpg-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cd: sd0-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd1_cmd: sd1-cmd { + samsung,pins = "gph-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_clk: sd1-clk { + samsung,pins = "gph-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus1: sd1-bus1 { + samsung,pins = "gph-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus4: sd1-bus4 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus8: sd1-bus8 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5", + "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_cd: sd1-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd2_cmd: sd2-cmd { + samsung,pins = "gpc-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_clk: sd2-clk { + samsung,pins = "gpc-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus1: sd2-bus1 { + samsung,pins = "gph-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus4: sd2-bus4 { + samsung,pins = "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_bus: i2s0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_cdclk: i2s0-cdclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_bus: i2s1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_cdclk: i2s1-cdclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_bus: i2s2-bus { + /* S3C6410-only */ + samsung,pins = "gpc-4", "gpc-5", "gpc-6", "gph-6", + "gph-8", "gph-9"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_cdclk: i2s2-cdclk { + /* S3C6410-only */ + samsung,pins = "gph-7"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_bus: pcm0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_extclk: pcm0-extclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_bus: pcm1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_extclk: pcm1-extclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_0: ac97-bus-0 { + samsung,pins = "gpd-0", "gpd-1", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_1: ac97-bus-1 { + samsung,pins = "gpe-0", "gpe-1", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_port: cam-port { + samsung,pins = "gpf-0", "gpf-1", "gpf-2", "gpf-4", + "gpf-5", "gpf-6", "gpf-7", "gpf-8", + "gpf-9", "gpf-10", "gpf-11", "gpf-12"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_rst: cam-rst { + samsung,pins = "gpf-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_field: cam-field { + /* S3C6410-only */ + samsung,pins = "gpb-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm_extclk: pwm-extclk { + samsung,pins = "gpf-13"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm0_out: pwm0-out { + samsung,pins = "gpf-14"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm1_out: pwm1-out { + samsung,pins = "gpf-15"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + clkout0: clkout-0 { + samsung,pins = "gpf-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_0: keypad-col0-0 { + samsung,pins = "gph-0"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_0: keypad-col1-0 { + samsung,pins = "gph-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_0: keypad-col2-0 { + samsung,pins = "gph-2"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_0: keypad-col3-0 { + samsung,pins = "gph-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_0: keypad-col4-0 { + samsung,pins = "gph-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_0: keypad-col5-0 { + samsung,pins = "gph-5"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_0: keypad-col6-0 { + samsung,pins = "gph-6"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_0: keypad-col7-0 { + samsung,pins = "gph-7"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_1: keypad-col0-1 { + samsung,pins = "gpl-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_1: keypad-col1-1 { + samsung,pins = "gpl-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_1: keypad-col2-1 { + samsung,pins = "gpl-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_1: keypad-col3-1 { + samsung,pins = "gpl-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_1: keypad-col4-1 { + samsung,pins = "gpl-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_1: keypad-col5-1 { + samsung,pins = "gpl-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_1: keypad-col6-1 { + samsung,pins = "gpl-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_1: keypad-col7-1 { + samsung,pins = "gpl-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_0: keypad-row0-0 { + samsung,pins = "gpk-8"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_0: keypad-row1-0 { + samsung,pins = "gpk-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_0: keypad-row2-0 { + samsung,pins = "gpk-10"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_0: keypad-row3-0 { + samsung,pins = "gpk-11"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_0: keypad-row4-0 { + samsung,pins = "gpk-12"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_0: keypad-row5-0 { + samsung,pins = "gpk-13"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_0: keypad-row6-0 { + samsung,pins = "gpk-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_0: keypad-row7-0 { + samsung,pins = "gpk-15"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_1: keypad-row0-1 { + samsung,pins = "gpn-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_1: keypad-row1-1 { + samsung,pins = "gpn-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_1: keypad-row2-1 { + samsung,pins = "gpn-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_1: keypad-row3-1 { + samsung,pins = "gpn-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_1: keypad-row4-1 { + samsung,pins = "gpn-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_1: keypad-row5-1 { + samsung,pins = "gpn-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_1: keypad-row6-1 { + samsung,pins = "gpn-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_1: keypad-row7-1 { + samsung,pins = "gpn-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_ctrl: lcd-ctrl { + samsung,pins = "gpj-8", "gpj-9", "gpj-10", "gpj-11"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data16: lcd-data-width16 { + samsung,pins = "gpi-3", "gpi-4", "gpi-5", "gpi-6", + "gpi-7", "gpi-10", "gpi-11", "gpi-12", + "gpi-13", "gpi-14", "gpi-15", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data18: lcd-data-width18 { + samsung,pins = "gpi-2", "gpi-3", "gpi-4", "gpi-5", + "gpi-6", "gpi-7", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-2", "gpj-3", "gpj-4", "gpj-5", + "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data24: lcd-data-width24 { + samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3", + "gpi-4", "gpi-5", "gpi-6", "gpi-7", + "gpi-8", "gpi-9", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-0", "gpj-1", "gpj-2", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + hsi_bus: hsi-bus { + samsung,pins = "gpk-0", "gpk-1", "gpk-2", "gpk-3", + "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx.dtsi b/arch/arm/boot/dts/s3c64xx.dtsi new file mode 100644 index 0000000..4e3be4d --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx.dtsi @@ -0,0 +1,199 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoC series device nodes are listed in this file. + * Particular SoCs from S3C64xx series can include this file and provide + * values for SoCs specfic bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C64xx SoCs. As device tree coverage for S3C64xx increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include "skeleton.dtsi" +#include <dt-bindings/clock/samsung,s3c64xx-clock.h> + +/ { + aliases { + i2c0 = &i2c0; + pinctrl0 = &pinctrl0; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu@0 { + device_type = "cpu"; + compatible = "arm,arm1176jzf-s", "arm,arm1176"; + reg = <0x0>; + }; + }; + + soc: soc { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + vic0: interrupt-controller@71200000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71200000 0x1000>; + #interrupt-cells = <1>; + }; + + vic1: interrupt-controller@71300000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71300000 0x1000>; + #interrupt-cells = <1>; + }; + + sdhci0: sdhci@7c200000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c200000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <24>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC0>, <&clocks HCLK_HSMMC0>, + <&clocks SCLK_MMC0>; + status = "disabled"; + }; + + sdhci1: sdhci@7c300000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c300000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <25>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC1>, <&clocks HCLK_HSMMC1>, + <&clocks SCLK_MMC1>; + status = "disabled"; + }; + + sdhci2: sdhci@7c400000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c400000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <17>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC2>, <&clocks HCLK_HSMMC2>, + <&clocks SCLK_MMC2>; + status = "disabled"; + }; + + watchdog: watchdog@7e004000 { + compatible = "samsung,s3c2410-wdt"; + reg = <0x7e004000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <26>; + clock-names = "watchdog"; + clocks = <&clocks PCLK_WDT>; + status = "disabled"; + }; + + i2c0: i2c@7f004000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f004000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <18>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC0>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; + + uart0: serial@7f005000 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <5>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART0>, <&clocks PCLK_UART0>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart1: serial@7f005400 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005400 0x100>; + interrupt-parent = <&vic1>; + interrupts = <6>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART1>, <&clocks PCLK_UART1>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart2: serial@7f005800 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005800 0x100>; + interrupt-parent = <&vic1>; + interrupts = <7>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART2>, <&clocks PCLK_UART2>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart3: serial@7f005c00 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005c00 0x100>; + interrupt-parent = <&vic1>; + interrupts = <8>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART3>, <&clocks PCLK_UART3>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + pwm: pwm@7f006000 { + compatible = "samsung,s3c6400-pwm"; + reg = <0x7f006000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <23>, <24>, <25>, <27>, <28>; + clock-names = "timers"; + clocks = <&clocks PCLK_PWM>; + samsung,pwm-outputs = <0>, <1>; + #pwm-cells = <3>; + status = "disabled"; + }; + + pinctrl0: pinctrl@7f008000 { + compatible = "samsung,s3c64xx-pinctrl"; + reg = <0x7f008000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <21>; + + pctrl_int_map: pinctrl-interrupt-map { + interrupt-map = <0 &vic0 0>, + <1 &vic0 1>, + <2 &vic1 0>, + <3 &vic1 1>; + #address-cells = <0>; + #size-cells = <0>; + #interrupt-cells = <1>; + }; + + wakeup-interrupt-controller { + compatible = "samsung,s3c64xx-wakeup-eint"; + interrupts = <0>, <1>, <2>, <3>; + interrupt-parent = <&pctrl_int_map>; + }; + }; + }; +}; + +#include "s3c64xx-pinctrl.dtsi" -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v9 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs @ 2013-08-23 23:56 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-23 23:56 UTC (permalink / raw) To: linux-arm-kernel This patch adds basic device tree definitions for Samsung S3C64xx SoCs. Since all the SoCs in the series are very similar, the files are created hierarchically - one file for the whole series and then separate files for particular SoCs including the common one. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/s3c6400.dtsi | 41 ++ arch/arm/boot/dts/s3c6410.dtsi | 57 +++ arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 +++++++++++++++++++++++++++++++++ arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++++ 4 files changed, 984 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6400.dtsi create mode 100644 arch/arm/boot/dts/s3c6410.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi Changes since v8: - Updated VIC nodes to reflect changes done to patch 1/7 (renamed wakeuo-mask property to valid-wakeup-mask). diff --git a/arch/arm/boot/dts/s3c6400.dtsi b/arch/arm/boot/dts/s3c6400.dtsi new file mode 100644 index 0000000..a7d1c8e --- /dev/null +++ b/arch/arm/boot/dts/s3c6400.dtsi @@ -0,0 +1,41 @@ +/* + * Samsung's S3C6400 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6400 SoC device nodes are listed in this file. S3C6400 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6400 SoC. As device tree coverage for S3C6400 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6400"; +}; + +&vic0 { + valid-mask = <0xfffffe1f>; + valid-wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + valid-wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller at 7e00f000 { + compatible = "samsung,s3c6400-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; +}; diff --git a/arch/arm/boot/dts/s3c6410.dtsi b/arch/arm/boot/dts/s3c6410.dtsi new file mode 100644 index 0000000..eb4226b --- /dev/null +++ b/arch/arm/boot/dts/s3c6410.dtsi @@ -0,0 +1,57 @@ +/* + * Samsung's S3C6410 SoC device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C6410 SoC device nodes are listed in this file. S3C6410 + * based board files can include this file and provide values for board specfic + * bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C6410 SoC. As device tree coverage for S3C6410 increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +#include "s3c64xx.dtsi" + +/ { + compatible = "samsung,s3c6410"; + + aliases { + i2c1 = &i2c1; + }; +}; + +&vic0 { + valid-mask = <0xffffff7f>; + valid-wakeup-mask = <0x00200004>; +}; + +&vic1 { + valid-mask = <0xffffffff>; + valid-wakeup-mask = <0x53020000>; +}; + +&soc { + clocks: clock-controller at 7e00f000 { + compatible = "samsung,s3c6410-clock"; + reg = <0x7e00f000 0x1000>; + #clock-cells = <1>; + }; + + i2c1: i2c at 7f00f000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f00f000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <5>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC1>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi new file mode 100644 index 0000000..b1197d8 --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx-pinctrl.dtsi @@ -0,0 +1,687 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * - pin control-related definitions + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoCs pin banks, pin-mux and pin-config options are + * listed as device tree nodes in this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#define PIN_PULL_NONE 0 +#define PIN_PULL_DOWN 1 +#define PIN_PULL_UP 2 + +&pinctrl0 { + /* + * Pin banks + */ + + gpa: gpa { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpb: gpb { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpc: gpc { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpd: gpd { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpe: gpe { + gpio-controller; + #gpio-cells = <2>; + }; + + gpf: gpf { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpg: gpg { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gph: gph { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpi: gpi { + gpio-controller; + #gpio-cells = <2>; + }; + + gpj: gpj { + gpio-controller; + #gpio-cells = <2>; + }; + + gpk: gpk { + gpio-controller; + #gpio-cells = <2>; + }; + + gpl: gpl { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpm: gpm { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpn: gpn { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpo: gpo { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpp: gpp { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + gpq: gpq { + gpio-controller; + #gpio-cells = <2>; + interrupt-controller; + #interrupt-cells = <2>; + }; + + /* + * Pin groups + */ + + uart0_data: uart0-data { + samsung,pins = "gpa-0", "gpa-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart0_fctl: uart0-fctl { + samsung,pins = "gpa-2", "gpa-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_data: uart1-data { + samsung,pins = "gpa-4", "gpa-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart1_fctl: uart1-fctl { + samsung,pins = "gpa-6", "gpa-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart2_data: uart2-data { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + uart3_data: uart3-data { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_0: ext-dma-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ext_dma_1: ext-dma-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_0: irda-data-0 { + samsung,pins = "gpb-0", "gpb-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_data_1: irda-data-1 { + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + irda_sdbw: irda-sdbw { + samsung,pins = "gpb-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2c0_bus: i2c0-bus { + samsung,pins = "gpb-5", "gpb-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + i2c1_bus: i2c1-bus { + /* S3C6410-only */ + samsung,pins = "gpb-2", "gpb-3"; + samsung,pin-function = <6>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_bus: spi0-bus { + samsung,pins = "gpc-0", "gpc-1", "gpc-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi0_cs: spi0-cs { + samsung,pins = "gpc-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + spi1_bus: spi1-bus { + samsung,pins = "gpc-4", "gpc-5", "gpc-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + spi1_cs: spi1-cs { + samsung,pins = "gpc-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cmd: sd0-cmd { + samsung,pins = "gpg-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_clk: sd0-clk { + samsung,pins = "gpg-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus1: sd0-bus1 { + samsung,pins = "gpg-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_bus4: sd0-bus4 { + samsung,pins = "gpg-2", "gpg-3", "gpg-4", "gpg-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd0_cd: sd0-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd1_cmd: sd1-cmd { + samsung,pins = "gph-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_clk: sd1-clk { + samsung,pins = "gph-0"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus1: sd1-bus1 { + samsung,pins = "gph-2"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus4: sd1-bus4 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_bus8: sd1-bus8 { + samsung,pins = "gph-2", "gph-3", "gph-4", "gph-5", + "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd1_cd: sd1-cd { + samsung,pins = "gpg-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_UP>; + }; + + sd2_cmd: sd2-cmd { + samsung,pins = "gpc-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_clk: sd2-clk { + samsung,pins = "gpc-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus1: sd2-bus1 { + samsung,pins = "gph-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + sd2_bus4: sd2-bus4 { + samsung,pins = "gph-6", "gph-7", "gph-8", "gph-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_bus: i2s0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s0_cdclk: i2s0-cdclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_bus: i2s1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s1_cdclk: i2s1-cdclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_bus: i2s2-bus { + /* S3C6410-only */ + samsung,pins = "gpc-4", "gpc-5", "gpc-6", "gph-6", + "gph-8", "gph-9"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + i2s2_cdclk: i2s2-cdclk { + /* S3C6410-only */ + samsung,pins = "gph-7"; + samsung,pin-function = <5>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_bus: pcm0-bus { + samsung,pins = "gpd-0", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm0_extclk: pcm0-extclk { + samsung,pins = "gpd-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_bus: pcm1-bus { + samsung,pins = "gpe-0", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pcm1_extclk: pcm1-extclk { + samsung,pins = "gpe-1"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_0: ac97-bus-0 { + samsung,pins = "gpd-0", "gpd-1", "gpd-2", "gpd-3", "gpd-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + ac97_bus_1: ac97-bus-1 { + samsung,pins = "gpe-0", "gpe-1", "gpe-2", "gpe-3", "gpe-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_port: cam-port { + samsung,pins = "gpf-0", "gpf-1", "gpf-2", "gpf-4", + "gpf-5", "gpf-6", "gpf-7", "gpf-8", + "gpf-9", "gpf-10", "gpf-11", "gpf-12"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_rst: cam-rst { + samsung,pins = "gpf-3"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + cam_field: cam-field { + /* S3C6410-only */ + samsung,pins = "gpb-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm_extclk: pwm-extclk { + samsung,pins = "gpf-13"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm0_out: pwm0-out { + samsung,pins = "gpf-14"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + pwm1_out: pwm1-out { + samsung,pins = "gpf-15"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + clkout0: clkout-0 { + samsung,pins = "gpf-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_0: keypad-col0-0 { + samsung,pins = "gph-0"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_0: keypad-col1-0 { + samsung,pins = "gph-1"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_0: keypad-col2-0 { + samsung,pins = "gph-2"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_0: keypad-col3-0 { + samsung,pins = "gph-3"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_0: keypad-col4-0 { + samsung,pins = "gph-4"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_0: keypad-col5-0 { + samsung,pins = "gph-5"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_0: keypad-col6-0 { + samsung,pins = "gph-6"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_0: keypad-col7-0 { + samsung,pins = "gph-7"; + samsung,pin-function = <4>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col0_1: keypad-col0-1 { + samsung,pins = "gpl-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col1_1: keypad-col1-1 { + samsung,pins = "gpl-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col2_1: keypad-col2-1 { + samsung,pins = "gpl-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col3_1: keypad-col3-1 { + samsung,pins = "gpl-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col4_1: keypad-col4-1 { + samsung,pins = "gpl-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col5_1: keypad-col5-1 { + samsung,pins = "gpl-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col6_1: keypad-col6-1 { + samsung,pins = "gpl-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_col7_1: keypad-col7-1 { + samsung,pins = "gpl-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_0: keypad-row0-0 { + samsung,pins = "gpk-8"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_0: keypad-row1-0 { + samsung,pins = "gpk-9"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_0: keypad-row2-0 { + samsung,pins = "gpk-10"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_0: keypad-row3-0 { + samsung,pins = "gpk-11"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_0: keypad-row4-0 { + samsung,pins = "gpk-12"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_0: keypad-row5-0 { + samsung,pins = "gpk-13"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_0: keypad-row6-0 { + samsung,pins = "gpk-14"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_0: keypad-row7-0 { + samsung,pins = "gpk-15"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row0_1: keypad-row0-1 { + samsung,pins = "gpn-0"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row1_1: keypad-row1-1 { + samsung,pins = "gpn-1"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row2_1: keypad-row2-1 { + samsung,pins = "gpn-2"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row3_1: keypad-row3-1 { + samsung,pins = "gpn-3"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row4_1: keypad-row4-1 { + samsung,pins = "gpn-4"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row5_1: keypad-row5-1 { + samsung,pins = "gpn-5"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row6_1: keypad-row6-1 { + samsung,pins = "gpn-6"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + keypad_row7_1: keypad-row7-1 { + samsung,pins = "gpn-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_ctrl: lcd-ctrl { + samsung,pins = "gpj-8", "gpj-9", "gpj-10", "gpj-11"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data16: lcd-data-width16 { + samsung,pins = "gpi-3", "gpi-4", "gpi-5", "gpi-6", + "gpi-7", "gpi-10", "gpi-11", "gpi-12", + "gpi-13", "gpi-14", "gpi-15", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data18: lcd-data-width18 { + samsung,pins = "gpi-2", "gpi-3", "gpi-4", "gpi-5", + "gpi-6", "gpi-7", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-2", "gpj-3", "gpj-4", "gpj-5", + "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + lcd_data24: lcd-data-width24 { + samsung,pins = "gpi-0", "gpi-1", "gpi-2", "gpi-3", + "gpi-4", "gpi-5", "gpi-6", "gpi-7", + "gpi-8", "gpi-9", "gpi-10", "gpi-11", + "gpi-12", "gpi-13", "gpi-14", "gpi-15", + "gpj-0", "gpj-1", "gpj-2", "gpj-3", + "gpj-4", "gpj-5", "gpj-6", "gpj-7"; + samsung,pin-function = <2>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + hsi_bus: hsi-bus { + samsung,pins = "gpk-0", "gpk-1", "gpk-2", "gpk-3", + "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-function = <3>; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; diff --git a/arch/arm/boot/dts/s3c64xx.dtsi b/arch/arm/boot/dts/s3c64xx.dtsi new file mode 100644 index 0000000..4e3be4d --- /dev/null +++ b/arch/arm/boot/dts/s3c64xx.dtsi @@ -0,0 +1,199 @@ +/* + * Samsung's S3C64xx SoC series common device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Samsung's S3C64xx SoC series device nodes are listed in this file. + * Particular SoCs from S3C64xx series can include this file and provide + * values for SoCs specfic bindings. + * + * Note: This file does not include device nodes for all the controllers in + * S3C64xx SoCs. As device tree coverage for S3C64xx increases, additional + * nodes can be added to this file. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#include "skeleton.dtsi" +#include <dt-bindings/clock/samsung,s3c64xx-clock.h> + +/ { + aliases { + i2c0 = &i2c0; + pinctrl0 = &pinctrl0; + }; + + cpus { + #address-cells = <1>; + #size-cells = <0>; + + cpu at 0 { + device_type = "cpu"; + compatible = "arm,arm1176jzf-s", "arm,arm1176"; + reg = <0x0>; + }; + }; + + soc: soc { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + vic0: interrupt-controller at 71200000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71200000 0x1000>; + #interrupt-cells = <1>; + }; + + vic1: interrupt-controller at 71300000 { + compatible = "arm,pl192-vic"; + interrupt-controller; + reg = <0x71300000 0x1000>; + #interrupt-cells = <1>; + }; + + sdhci0: sdhci at 7c200000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c200000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <24>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC0>, <&clocks HCLK_HSMMC0>, + <&clocks SCLK_MMC0>; + status = "disabled"; + }; + + sdhci1: sdhci at 7c300000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c300000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <25>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC1>, <&clocks HCLK_HSMMC1>, + <&clocks SCLK_MMC1>; + status = "disabled"; + }; + + sdhci2: sdhci at 7c400000 { + compatible = "samsung,s3c6410-sdhci"; + reg = <0x7c400000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <17>; + clock-names = "hsmmc", "mmc_busclk.0", "mmc_busclk.2"; + clocks = <&clocks HCLK_HSMMC2>, <&clocks HCLK_HSMMC2>, + <&clocks SCLK_MMC2>; + status = "disabled"; + }; + + watchdog: watchdog at 7e004000 { + compatible = "samsung,s3c2410-wdt"; + reg = <0x7e004000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <26>; + clock-names = "watchdog"; + clocks = <&clocks PCLK_WDT>; + status = "disabled"; + }; + + i2c0: i2c at 7f004000 { + compatible = "samsung,s3c2440-i2c"; + reg = <0x7f004000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <18>; + clock-names = "i2c"; + clocks = <&clocks PCLK_IIC0>; + status = "disabled"; + #address-cells = <1>; + #size-cells = <0>; + }; + + uart0: serial at 7f005000 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005000 0x100>; + interrupt-parent = <&vic1>; + interrupts = <5>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART0>, <&clocks PCLK_UART0>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart1: serial at 7f005400 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005400 0x100>; + interrupt-parent = <&vic1>; + interrupts = <6>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART1>, <&clocks PCLK_UART1>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart2: serial at 7f005800 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005800 0x100>; + interrupt-parent = <&vic1>; + interrupts = <7>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART2>, <&clocks PCLK_UART2>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + uart3: serial at 7f005c00 { + compatible = "samsung,s3c6400-uart"; + reg = <0x7f005c00 0x100>; + interrupt-parent = <&vic1>; + interrupts = <8>; + clock-names = "uart", "clk_uart_baud2", + "clk_uart_baud3"; + clocks = <&clocks PCLK_UART3>, <&clocks PCLK_UART3>, + <&clocks SCLK_UART>; + status = "disabled"; + }; + + pwm: pwm at 7f006000 { + compatible = "samsung,s3c6400-pwm"; + reg = <0x7f006000 0x1000>; + interrupt-parent = <&vic0>; + interrupts = <23>, <24>, <25>, <27>, <28>; + clock-names = "timers"; + clocks = <&clocks PCLK_PWM>; + samsung,pwm-outputs = <0>, <1>; + #pwm-cells = <3>; + status = "disabled"; + }; + + pinctrl0: pinctrl at 7f008000 { + compatible = "samsung,s3c64xx-pinctrl"; + reg = <0x7f008000 0x1000>; + interrupt-parent = <&vic1>; + interrupts = <21>; + + pctrl_int_map: pinctrl-interrupt-map { + interrupt-map = <0 &vic0 0>, + <1 &vic0 1>, + <2 &vic1 0>, + <3 &vic1 1>; + #address-cells = <0>; + #size-cells = <0>; + #interrupt-cells = <1>; + }; + + wakeup-interrupt-controller { + compatible = "samsung,s3c64xx-wakeup-eint"; + interrupts = <0>, <1>, <2>, <3>; + interrupt-parent = <&pctrl_int_map>; + }; + }; + }; +}; + +#include "s3c64xx-pinctrl.dtsi" -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 6/7] ARM: dts: Add dts file for S3C6410-based Mini6410 board 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This patch adds basic device tree sources for FriendlyARM Mini6410 board based on Samsung S3C6410 SoC. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/s3c6410-mini6410.dts | 228 +++++++++++++++++++++++++++++++++ 2 files changed, 229 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6410-mini6410.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index ada589c..72f8af3 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -194,6 +194,7 @@ dtb-$(CONFIG_ARCH_U8500) += snowball.dtb \ ccu8540.dtb \ ccu9540.dtb dtb-$(CONFIG_ARCH_S3C24XX) += s3c2416-smdk2416.dtb +dtb-$(CONFIG_ARCH_S3C64XX) += s3c6410-mini6410.dtb dtb-$(CONFIG_ARCH_SHMOBILE) += emev2-kzm9d.dtb \ emev2-kzm9d-reference.dtb \ r8a7740-armadillo800eva.dtb \ diff --git a/arch/arm/boot/dts/s3c6410-mini6410.dts b/arch/arm/boot/dts/s3c6410-mini6410.dts new file mode 100644 index 0000000..57e00f9 --- /dev/null +++ b/arch/arm/boot/dts/s3c6410-mini6410.dts @@ -0,0 +1,228 @@ +/* + * Samsung's S3C6410 based Mini6410 board device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Device tree source file for FriendlyARM Mini6410 board which is based on + * Samsung's S3C6410 SoC. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +/dts-v1/; + +#include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/interrupt-controller/irq.h> + +#include "s3c6410.dtsi" + +/ { + model = "FriendlyARM Mini6410 board based on S3C6410"; + compatible = "friendlyarm,mini6410", "samsung,s3c6410"; + + memory { + reg = <0x50000000 0x10000000>; + }; + + chosen { + bootargs = "console=ttySAC0,115200n8 earlyprintk rootwait root=/dev/mmcblk0p1"; + }; + + clocks { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <0>; + + fin_pll: oscillator@0 { + compatible = "fixed-clock"; + reg = <0>; + clock-frequency = <12000000>; + clock-output-names = "fin_pll"; + #clock-cells = <0>; + }; + + xusbxti: oscillator@1 { + compatible = "fixed-clock"; + reg = <1>; + clock-output-names = "xusbxti"; + clock-frequency = <48000000>; + #clock-cells = <0>; + }; + }; + + srom-cs1@18000000 { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + reg = <0x18000000 0x8000000>; + ranges; + + ethernet@18000000 { + compatible = "davicom,dm9000"; + reg = <0x18000000 0x2 0x18000004 0x2>; + interrupt-parent = <&gpn>; + interrupts = <7 IRQ_TYPE_LEVEL_HIGH>; + davicom,no-eeprom; + }; + }; + + gpio-keys { + compatible = "gpio-keys"; + pinctrl-names = "default"; + pinctrl-0 = <&gpio_keys>; + autorepeat; + + button-k1 { + label = "K1"; + gpios = <&gpn 0 GPIO_ACTIVE_LOW>; + linux,code = <2>; + debounce-interval = <20>; + }; + + button-k2 { + label = "K2"; + gpios = <&gpn 1 GPIO_ACTIVE_LOW>; + linux,code = <3>; + debounce-interval = <20>; + }; + + button-k3 { + label = "K3"; + gpios = <&gpn 2 GPIO_ACTIVE_LOW>; + linux,code = <4>; + debounce-interval = <20>; + }; + + button-k4 { + label = "K4"; + gpios = <&gpn 3 GPIO_ACTIVE_LOW>; + linux,code = <5>; + debounce-interval = <20>; + }; + + button-k5 { + label = "K5"; + gpios = <&gpn 4 GPIO_ACTIVE_LOW>; + linux,code = <6>; + debounce-interval = <20>; + }; + + button-k6 { + label = "K6"; + gpios = <&gpn 5 GPIO_ACTIVE_LOW>; + linux,code = <7>; + debounce-interval = <20>; + }; + + button-k7 { + label = "K7"; + gpios = <&gpl 11 GPIO_ACTIVE_LOW>; + linux,code = <8>; + debounce-interval = <20>; + }; + + button-k8 { + label = "K8"; + gpios = <&gpl 12 GPIO_ACTIVE_LOW>; + linux,code = <9>; + debounce-interval = <20>; + }; + }; + + leds { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&gpio_leds>; + + led-1 { + label = "LED1"; + gpios = <&gpk 4 GPIO_ACTIVE_LOW>; + linux,default-trigger = "heartbeat"; + }; + + led-2 { + label = "LED2"; + gpios = <&gpk 5 GPIO_ACTIVE_LOW>; + linux,default-trigger = "mmc0"; + }; + + led-3 { + label = "LED3"; + gpios = <&gpk 6 GPIO_ACTIVE_LOW>; + }; + + led-4 { + label = "LED4"; + gpios = <&gpk 7 GPIO_ACTIVE_LOW>; + }; + }; + + buzzer { + compatible = "pwm-beeper"; + pwms = <&pwm 0 1000000 0>; + pinctrl-names = "default"; + pinctrl-0 = <&pwm0_out>; + }; +}; + +&sdhci0 { + pinctrl-names = "default"; + pinctrl-0 = <&sd0_clk>, <&sd0_cmd>, <&sd0_cd>, <&sd0_bus4>; + bus-width = <4>; + status = "okay"; +}; + +&uart0 { + pinctrl-names = "default"; + pinctrl-0 = <&uart0_data>; + status = "okay"; +}; + +&uart1 { + pinctrl-names = "default"; + pinctrl-0 = <&uart1_data>, <&uart1_fctl>; + status = "okay"; +}; + +&uart2 { + pinctrl-names = "default"; + pinctrl-0 = <&uart2_data>; + status = "okay"; +}; + +&uart3 { + pinctrl-names = "default"; + pinctrl-0 = <&uart3_data>; + status = "okay"; +}; + +&pwm { + status = "okay"; +}; + +&pinctrl0 { + gpio_leds: gpio-leds { + samsung,pins = "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + gpio_keys: gpio-keys { + samsung,pins = "gpn-0", "gpn-1", "gpn-2", "gpn-3", + "gpn-4", "gpn-5", "gpl-11", "gpl-12"; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; + +&i2c0 { + pinctrl-names = "default"; + pinctrl-0 = <&i2c0_bus>; + status = "okay"; + + eeprom@50 { + compatible = "atmel,24c08"; + reg = <0x50>; + pagesize = <16>; + }; +}; -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 6/7] ARM: dts: Add dts file for S3C6410-based Mini6410 board @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This patch adds basic device tree sources for FriendlyARM Mini6410 board based on Samsung S3C6410 SoC. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/Makefile | 1 + arch/arm/boot/dts/s3c6410-mini6410.dts | 228 +++++++++++++++++++++++++++++++++ 2 files changed, 229 insertions(+) create mode 100644 arch/arm/boot/dts/s3c6410-mini6410.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index ada589c..72f8af3 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -194,6 +194,7 @@ dtb-$(CONFIG_ARCH_U8500) += snowball.dtb \ ccu8540.dtb \ ccu9540.dtb dtb-$(CONFIG_ARCH_S3C24XX) += s3c2416-smdk2416.dtb +dtb-$(CONFIG_ARCH_S3C64XX) += s3c6410-mini6410.dtb dtb-$(CONFIG_ARCH_SHMOBILE) += emev2-kzm9d.dtb \ emev2-kzm9d-reference.dtb \ r8a7740-armadillo800eva.dtb \ diff --git a/arch/arm/boot/dts/s3c6410-mini6410.dts b/arch/arm/boot/dts/s3c6410-mini6410.dts new file mode 100644 index 0000000..57e00f9 --- /dev/null +++ b/arch/arm/boot/dts/s3c6410-mini6410.dts @@ -0,0 +1,228 @@ +/* + * Samsung's S3C6410 based Mini6410 board device tree source + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Device tree source file for FriendlyARM Mini6410 board which is based on + * Samsung's S3C6410 SoC. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +/dts-v1/; + +#include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/interrupt-controller/irq.h> + +#include "s3c6410.dtsi" + +/ { + model = "FriendlyARM Mini6410 board based on S3C6410"; + compatible = "friendlyarm,mini6410", "samsung,s3c6410"; + + memory { + reg = <0x50000000 0x10000000>; + }; + + chosen { + bootargs = "console=ttySAC0,115200n8 earlyprintk rootwait root=/dev/mmcblk0p1"; + }; + + clocks { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <0>; + + fin_pll: oscillator at 0 { + compatible = "fixed-clock"; + reg = <0>; + clock-frequency = <12000000>; + clock-output-names = "fin_pll"; + #clock-cells = <0>; + }; + + xusbxti: oscillator at 1 { + compatible = "fixed-clock"; + reg = <1>; + clock-output-names = "xusbxti"; + clock-frequency = <48000000>; + #clock-cells = <0>; + }; + }; + + srom-cs1 at 18000000 { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + reg = <0x18000000 0x8000000>; + ranges; + + ethernet at 18000000 { + compatible = "davicom,dm9000"; + reg = <0x18000000 0x2 0x18000004 0x2>; + interrupt-parent = <&gpn>; + interrupts = <7 IRQ_TYPE_LEVEL_HIGH>; + davicom,no-eeprom; + }; + }; + + gpio-keys { + compatible = "gpio-keys"; + pinctrl-names = "default"; + pinctrl-0 = <&gpio_keys>; + autorepeat; + + button-k1 { + label = "K1"; + gpios = <&gpn 0 GPIO_ACTIVE_LOW>; + linux,code = <2>; + debounce-interval = <20>; + }; + + button-k2 { + label = "K2"; + gpios = <&gpn 1 GPIO_ACTIVE_LOW>; + linux,code = <3>; + debounce-interval = <20>; + }; + + button-k3 { + label = "K3"; + gpios = <&gpn 2 GPIO_ACTIVE_LOW>; + linux,code = <4>; + debounce-interval = <20>; + }; + + button-k4 { + label = "K4"; + gpios = <&gpn 3 GPIO_ACTIVE_LOW>; + linux,code = <5>; + debounce-interval = <20>; + }; + + button-k5 { + label = "K5"; + gpios = <&gpn 4 GPIO_ACTIVE_LOW>; + linux,code = <6>; + debounce-interval = <20>; + }; + + button-k6 { + label = "K6"; + gpios = <&gpn 5 GPIO_ACTIVE_LOW>; + linux,code = <7>; + debounce-interval = <20>; + }; + + button-k7 { + label = "K7"; + gpios = <&gpl 11 GPIO_ACTIVE_LOW>; + linux,code = <8>; + debounce-interval = <20>; + }; + + button-k8 { + label = "K8"; + gpios = <&gpl 12 GPIO_ACTIVE_LOW>; + linux,code = <9>; + debounce-interval = <20>; + }; + }; + + leds { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&gpio_leds>; + + led-1 { + label = "LED1"; + gpios = <&gpk 4 GPIO_ACTIVE_LOW>; + linux,default-trigger = "heartbeat"; + }; + + led-2 { + label = "LED2"; + gpios = <&gpk 5 GPIO_ACTIVE_LOW>; + linux,default-trigger = "mmc0"; + }; + + led-3 { + label = "LED3"; + gpios = <&gpk 6 GPIO_ACTIVE_LOW>; + }; + + led-4 { + label = "LED4"; + gpios = <&gpk 7 GPIO_ACTIVE_LOW>; + }; + }; + + buzzer { + compatible = "pwm-beeper"; + pwms = <&pwm 0 1000000 0>; + pinctrl-names = "default"; + pinctrl-0 = <&pwm0_out>; + }; +}; + +&sdhci0 { + pinctrl-names = "default"; + pinctrl-0 = <&sd0_clk>, <&sd0_cmd>, <&sd0_cd>, <&sd0_bus4>; + bus-width = <4>; + status = "okay"; +}; + +&uart0 { + pinctrl-names = "default"; + pinctrl-0 = <&uart0_data>; + status = "okay"; +}; + +&uart1 { + pinctrl-names = "default"; + pinctrl-0 = <&uart1_data>, <&uart1_fctl>; + status = "okay"; +}; + +&uart2 { + pinctrl-names = "default"; + pinctrl-0 = <&uart2_data>; + status = "okay"; +}; + +&uart3 { + pinctrl-names = "default"; + pinctrl-0 = <&uart3_data>; + status = "okay"; +}; + +&pwm { + status = "okay"; +}; + +&pinctrl0 { + gpio_leds: gpio-leds { + samsung,pins = "gpk-4", "gpk-5", "gpk-6", "gpk-7"; + samsung,pin-pud = <PIN_PULL_NONE>; + }; + + gpio_keys: gpio-keys { + samsung,pins = "gpn-0", "gpn-1", "gpn-2", "gpn-3", + "gpn-4", "gpn-5", "gpl-11", "gpl-12"; + samsung,pin-pud = <PIN_PULL_NONE>; + }; +}; + +&i2c0 { + pinctrl-names = "default"; + pinctrl-0 = <&i2c0_bus>; + status = "okay"; + + eeprom at 50 { + compatible = "atmel,24c08"; + reg = <0x50>; + pagesize = <16>; + }; +}; -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 7/7] ARM: dts: Add dts file for S3C6410-based SMDK6410 board 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-21 21:21 ` Tomasz Figa -1 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-samsung-soc Cc: linux-arm-kernel, devicetree, Kukjin Kim, linux-gpio, Ian Campbell, Linus Walleij, Mark Rutland, Pawel Moll, Rob Herring, Russell King, Stephen Warren, Thomas Gleixner, Olof Johansson, Arnd Bergmann, Marc Zyngier, Mark Brown, Tomasz Figa This patch adds basic device tree sources for SAMSUNG SMDK6410 board based on SAMSUNG S3C6410 SoC. Currently only UARTs, SD channel 0 and 100Mbps ethernet (SMSC911x) are supported. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/s3c6410-smdk6410.dts | 103 +++++++++++++++++++++++++++++++++ 2 files changed, 105 insertions(+), 1 deletion(-) create mode 100644 arch/arm/boot/dts/s3c6410-smdk6410.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index 72f8af3..e55c644 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -194,7 +194,8 @@ dtb-$(CONFIG_ARCH_U8500) += snowball.dtb \ ccu8540.dtb \ ccu9540.dtb dtb-$(CONFIG_ARCH_S3C24XX) += s3c2416-smdk2416.dtb -dtb-$(CONFIG_ARCH_S3C64XX) += s3c6410-mini6410.dtb +dtb-$(CONFIG_ARCH_S3C64XX) += s3c6410-mini6410.dtb \ + s3c6410-smdk6410.dtb dtb-$(CONFIG_ARCH_SHMOBILE) += emev2-kzm9d.dtb \ emev2-kzm9d-reference.dtb \ r8a7740-armadillo800eva.dtb \ diff --git a/arch/arm/boot/dts/s3c6410-smdk6410.dts b/arch/arm/boot/dts/s3c6410-smdk6410.dts new file mode 100644 index 0000000..ecf35ec --- /dev/null +++ b/arch/arm/boot/dts/s3c6410-smdk6410.dts @@ -0,0 +1,103 @@ +/* + * Samsung S3C6410 based SMDK6410 board device tree source. + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Device tree source file for SAMSUNG SMDK6410 board which is based on + * Samsung's S3C6410 SoC. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +/dts-v1/; + +#include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/interrupt-controller/irq.h> + +#include "s3c6410.dtsi" + +/ { + model = "SAMSUNG SMDK6410 board based on S3C6410"; + compatible = "samsung,mini6410", "samsung,s3c6410"; + + memory { + reg = <0x50000000 0x8000000>; + }; + + chosen { + bootargs = "console=ttySAC0,115200n8 earlyprintk rootwait root=/dev/mmcblk0p1"; + }; + + clocks { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <0>; + + fin_pll: oscillator@0 { + compatible = "fixed-clock"; + reg = <0>; + clock-frequency = <12000000>; + clock-output-names = "fin_pll"; + #clock-cells = <0>; + }; + + xusbxti: oscillator@1 { + compatible = "fixed-clock"; + reg = <1>; + clock-output-names = "xusbxti"; + clock-frequency = <48000000>; + #clock-cells = <0>; + }; + }; + + srom-cs1@18000000 { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + reg = <0x18000000 0x8000000>; + ranges; + + ethernet@18000000 { + compatible = "smsc,lan9115"; + reg = <0x18000000 0x10000>; + interrupt-parent = <&gpn>; + interrupts = <10 IRQ_TYPE_LEVEL_LOW>; + phy-mode = "mii"; + reg-io-width = <4>; + smsc,force-internal-phy; + }; + }; +}; + +&sdhci0 { + pinctrl-names = "default"; + pinctrl-0 = <&sd0_clk>, <&sd0_cmd>, <&sd0_cd>, <&sd0_bus4>; + bus-width = <4>; + status = "okay"; +}; + +&uart0 { + pinctrl-names = "default"; + pinctrl-0 = <&uart0_data>, <&uart0_fctl>; + status = "okay"; +}; + +&uart1 { + pinctrl-names = "default"; + pinctrl-0 = <&uart1_data>; + status = "okay"; +}; + +&uart2 { + pinctrl-names = "default"; + pinctrl-0 = <&uart2_data>; + status = "okay"; +}; + +&uart3 { + pinctrl-names = "default"; + pinctrl-0 = <&uart3_data>; + status = "okay"; +}; -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* [PATCH v7 7/7] ARM: dts: Add dts file for S3C6410-based SMDK6410 board @ 2013-08-21 21:21 ` Tomasz Figa 0 siblings, 0 replies; 64+ messages in thread From: Tomasz Figa @ 2013-08-21 21:21 UTC (permalink / raw) To: linux-arm-kernel This patch adds basic device tree sources for SAMSUNG SMDK6410 board based on SAMSUNG S3C6410 SoC. Currently only UARTs, SD channel 0 and 100Mbps ethernet (SMSC911x) are supported. Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com> --- arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/s3c6410-smdk6410.dts | 103 +++++++++++++++++++++++++++++++++ 2 files changed, 105 insertions(+), 1 deletion(-) create mode 100644 arch/arm/boot/dts/s3c6410-smdk6410.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index 72f8af3..e55c644 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -194,7 +194,8 @@ dtb-$(CONFIG_ARCH_U8500) += snowball.dtb \ ccu8540.dtb \ ccu9540.dtb dtb-$(CONFIG_ARCH_S3C24XX) += s3c2416-smdk2416.dtb -dtb-$(CONFIG_ARCH_S3C64XX) += s3c6410-mini6410.dtb +dtb-$(CONFIG_ARCH_S3C64XX) += s3c6410-mini6410.dtb \ + s3c6410-smdk6410.dtb dtb-$(CONFIG_ARCH_SHMOBILE) += emev2-kzm9d.dtb \ emev2-kzm9d-reference.dtb \ r8a7740-armadillo800eva.dtb \ diff --git a/arch/arm/boot/dts/s3c6410-smdk6410.dts b/arch/arm/boot/dts/s3c6410-smdk6410.dts new file mode 100644 index 0000000..ecf35ec --- /dev/null +++ b/arch/arm/boot/dts/s3c6410-smdk6410.dts @@ -0,0 +1,103 @@ +/* + * Samsung S3C6410 based SMDK6410 board device tree source. + * + * Copyright (c) 2013 Tomasz Figa <tomasz.figa@gmail.com> + * + * Device tree source file for SAMSUNG SMDK6410 board which is based on + * Samsung's S3C6410 SoC. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. +*/ + +/dts-v1/; + +#include <dt-bindings/gpio/gpio.h> +#include <dt-bindings/interrupt-controller/irq.h> + +#include "s3c6410.dtsi" + +/ { + model = "SAMSUNG SMDK6410 board based on S3C6410"; + compatible = "samsung,mini6410", "samsung,s3c6410"; + + memory { + reg = <0x50000000 0x8000000>; + }; + + chosen { + bootargs = "console=ttySAC0,115200n8 earlyprintk rootwait root=/dev/mmcblk0p1"; + }; + + clocks { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <0>; + + fin_pll: oscillator at 0 { + compatible = "fixed-clock"; + reg = <0>; + clock-frequency = <12000000>; + clock-output-names = "fin_pll"; + #clock-cells = <0>; + }; + + xusbxti: oscillator at 1 { + compatible = "fixed-clock"; + reg = <1>; + clock-output-names = "xusbxti"; + clock-frequency = <48000000>; + #clock-cells = <0>; + }; + }; + + srom-cs1 at 18000000 { + compatible = "simple-bus"; + #address-cells = <1>; + #size-cells = <1>; + reg = <0x18000000 0x8000000>; + ranges; + + ethernet at 18000000 { + compatible = "smsc,lan9115"; + reg = <0x18000000 0x10000>; + interrupt-parent = <&gpn>; + interrupts = <10 IRQ_TYPE_LEVEL_LOW>; + phy-mode = "mii"; + reg-io-width = <4>; + smsc,force-internal-phy; + }; + }; +}; + +&sdhci0 { + pinctrl-names = "default"; + pinctrl-0 = <&sd0_clk>, <&sd0_cmd>, <&sd0_cd>, <&sd0_bus4>; + bus-width = <4>; + status = "okay"; +}; + +&uart0 { + pinctrl-names = "default"; + pinctrl-0 = <&uart0_data>, <&uart0_fctl>; + status = "okay"; +}; + +&uart1 { + pinctrl-names = "default"; + pinctrl-0 = <&uart1_data>; + status = "okay"; +}; + +&uart2 { + pinctrl-names = "default"; + pinctrl-0 = <&uart2_data>; + status = "okay"; +}; + +&uart3 { + pinctrl-names = "default"; + pinctrl-0 = <&uart3_data>; + status = "okay"; +}; -- 1.8.3.2 ^ permalink raw reply related [flat|nested] 64+ messages in thread
* Re: [PATCH v7 0/7] Initial Device Tree support for S3C64xx 2013-08-21 21:21 ` Tomasz Figa @ 2013-08-25 17:31 ` Kukjin Kim -1 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-25 17:31 UTC (permalink / raw) To: Tomasz Figa Cc: linux-samsung-soc, Mark Rutland, devicetree, Kukjin Kim, Russell King, Ian Campbell, Pawel Moll, Stephen Warren, Marc Zyngier, Linus Walleij, Rob Herring, linux-gpio, Mark Brown, Arnd Bergmann, Olof Johansson, Thomas Gleixner, linux-arm-kernel On 08/22/13 06:21, Tomasz Figa wrote: > This series adds Device Tree support for Samsung S3C64xx SoC series. > > It fixes several problems preventing from booting an S3C64xx-based system > using Device Tree, adds all the infrastructure for Device Tree-based board > support, including mach-s3c64xx-dt and dts include files for S3C64xx SoCs, > and basic device tree source for FriendlyARM Mini6410 and SAMSUNG SMDK6410 > boards. > > Current support is somewhat limite, but should be fine as a start and > will be extended in future, hopefully with help of S3C64xx board > maintainers. > > Depends on: > - [PATCH v2 0/8] Common Clock Framework support for Samsung S3C64xx > http://thread.gmane.org/gmane.linux.usb.general/90493 > > On Samsung S3C6410-based Mini6410 and SMDK6410 boards: > > Tested-by: Tomasz Figa<tomasz.figa@gmail.com> > > Changes since v6: > - Rebased onto current for-next branch of Kgene's tree, > - Dropped the idea of .init_platform() machine callback, > - Added support for i2c controllers, > - Replaced separate apb and ahb nodes with a single common soc node, > - Updated cpus node according to CPU bindings, > - Updated fixed rate clock nodes to use generic bindings, > - Added support for PWM buzzer and I2C EEPROM on Mini6410 board, > - Simplified the condition of skipping legacy GPIO initialization. > > Changes since v5: > - Rebased onto current for-next branch of Kgene's tree, > - Added support for new Common Clock Framework based clock driver, > - Introduced hierarchical structure of device nodes (representing > physical AHB and APB buses), > - Bypassed most of legacy initialization when booting with DT, > - Used preprocessor macros in dts files to improve readabilty, > - Added support for SMDK6410 board. > > Changes since v4: > - Rebased onto current for-next branch of Kgene's tree > - Added support for pinctrl (driver merged through pinctrl tree) > - Added labels to all nodes that can be overridden from board dts > - Modified board dts to use the&label syntax to reference device nodes > > Changes since v3: > - Rebased onto current for-next branch of Kgene's tree > - Updated timer node for next version of samsung-time patches > - Replaced local s3c64xx_dt_init_irq with irqchip_init > > Changes since v2: > - Updated timer node for next version of samsung-time patches > > Changes since v1: > - Dropped two VIC-related patches that are no longer necessary > - Added Device Tree-based instantation of system timers > - Corrected VIC interrupt specifiers > - Adjusted CPU compatible values and dropped @id > > Tomasz Figa (7): > ARM: common: vic: Parse interrupt and resume masks from device tree > ARM: s3c64xx: Bypass legacy initialization when booting with DT > gpio: samsung: Skip initialization if device tree is present > ARM: s3c64xx: Add board file for boot using Device Tree > ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs > ARM: dts: Add dts file for S3C6410-based Mini6410 board > ARM: dts: Add dts file for S3C6410-based SMDK6410 board > > Documentation/devicetree/bindings/arm/vic.txt | 6 + > arch/arm/boot/dts/Makefile | 2 + > arch/arm/boot/dts/s3c6400.dtsi | 41 ++ > arch/arm/boot/dts/s3c6410-mini6410.dts | 228 +++++++++ > arch/arm/boot/dts/s3c6410-smdk6410.dts | 103 ++++ > arch/arm/boot/dts/s3c6410.dtsi | 57 +++ > arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 ++++++++++++++++++++++++++ > arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++ > arch/arm/mach-s3c64xx/Kconfig | 16 + > arch/arm/mach-s3c64xx/Makefile | 1 + > arch/arm/mach-s3c64xx/common.c | 12 + > arch/arm/mach-s3c64xx/dma.c | 9 + > arch/arm/mach-s3c64xx/irq-pm.c | 9 + > arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 85 ++++ > arch/arm/mach-s3c64xx/s3c6400.c | 9 + > arch/arm/mach-s3c64xx/s3c6410.c | 9 + > arch/arm/plat-samsung/init.c | 12 +- > drivers/gpio/gpio-samsung.c | 34 +- > drivers/irqchip/irq-vic.c | 7 +- > 19 files changed, 1497 insertions(+), 29 deletions(-) > create mode 100644 arch/arm/boot/dts/s3c6400.dtsi > create mode 100644 arch/arm/boot/dts/s3c6410-mini6410.dts > create mode 100644 arch/arm/boot/dts/s3c6410-smdk6410.dts > create mode 100644 arch/arm/boot/dts/s3c6410.dtsi > create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi > create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi > create mode 100644 arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c > Nice, applied this whole series. Thanks, Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
* [PATCH v7 0/7] Initial Device Tree support for S3C64xx @ 2013-08-25 17:31 ` Kukjin Kim 0 siblings, 0 replies; 64+ messages in thread From: Kukjin Kim @ 2013-08-25 17:31 UTC (permalink / raw) To: linux-arm-kernel On 08/22/13 06:21, Tomasz Figa wrote: > This series adds Device Tree support for Samsung S3C64xx SoC series. > > It fixes several problems preventing from booting an S3C64xx-based system > using Device Tree, adds all the infrastructure for Device Tree-based board > support, including mach-s3c64xx-dt and dts include files for S3C64xx SoCs, > and basic device tree source for FriendlyARM Mini6410 and SAMSUNG SMDK6410 > boards. > > Current support is somewhat limite, but should be fine as a start and > will be extended in future, hopefully with help of S3C64xx board > maintainers. > > Depends on: > - [PATCH v2 0/8] Common Clock Framework support for Samsung S3C64xx > http://thread.gmane.org/gmane.linux.usb.general/90493 > > On Samsung S3C6410-based Mini6410 and SMDK6410 boards: > > Tested-by: Tomasz Figa<tomasz.figa@gmail.com> > > Changes since v6: > - Rebased onto current for-next branch of Kgene's tree, > - Dropped the idea of .init_platform() machine callback, > - Added support for i2c controllers, > - Replaced separate apb and ahb nodes with a single common soc node, > - Updated cpus node according to CPU bindings, > - Updated fixed rate clock nodes to use generic bindings, > - Added support for PWM buzzer and I2C EEPROM on Mini6410 board, > - Simplified the condition of skipping legacy GPIO initialization. > > Changes since v5: > - Rebased onto current for-next branch of Kgene's tree, > - Added support for new Common Clock Framework based clock driver, > - Introduced hierarchical structure of device nodes (representing > physical AHB and APB buses), > - Bypassed most of legacy initialization when booting with DT, > - Used preprocessor macros in dts files to improve readabilty, > - Added support for SMDK6410 board. > > Changes since v4: > - Rebased onto current for-next branch of Kgene's tree > - Added support for pinctrl (driver merged through pinctrl tree) > - Added labels to all nodes that can be overridden from board dts > - Modified board dts to use the&label syntax to reference device nodes > > Changes since v3: > - Rebased onto current for-next branch of Kgene's tree > - Updated timer node for next version of samsung-time patches > - Replaced local s3c64xx_dt_init_irq with irqchip_init > > Changes since v2: > - Updated timer node for next version of samsung-time patches > > Changes since v1: > - Dropped two VIC-related patches that are no longer necessary > - Added Device Tree-based instantation of system timers > - Corrected VIC interrupt specifiers > - Adjusted CPU compatible values and dropped @id > > Tomasz Figa (7): > ARM: common: vic: Parse interrupt and resume masks from device tree > ARM: s3c64xx: Bypass legacy initialization when booting with DT > gpio: samsung: Skip initialization if device tree is present > ARM: s3c64xx: Add board file for boot using Device Tree > ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs > ARM: dts: Add dts file for S3C6410-based Mini6410 board > ARM: dts: Add dts file for S3C6410-based SMDK6410 board > > Documentation/devicetree/bindings/arm/vic.txt | 6 + > arch/arm/boot/dts/Makefile | 2 + > arch/arm/boot/dts/s3c6400.dtsi | 41 ++ > arch/arm/boot/dts/s3c6410-mini6410.dts | 228 +++++++++ > arch/arm/boot/dts/s3c6410-smdk6410.dts | 103 ++++ > arch/arm/boot/dts/s3c6410.dtsi | 57 +++ > arch/arm/boot/dts/s3c64xx-pinctrl.dtsi | 687 ++++++++++++++++++++++++++ > arch/arm/boot/dts/s3c64xx.dtsi | 199 ++++++++ > arch/arm/mach-s3c64xx/Kconfig | 16 + > arch/arm/mach-s3c64xx/Makefile | 1 + > arch/arm/mach-s3c64xx/common.c | 12 + > arch/arm/mach-s3c64xx/dma.c | 9 + > arch/arm/mach-s3c64xx/irq-pm.c | 9 + > arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c | 85 ++++ > arch/arm/mach-s3c64xx/s3c6400.c | 9 + > arch/arm/mach-s3c64xx/s3c6410.c | 9 + > arch/arm/plat-samsung/init.c | 12 +- > drivers/gpio/gpio-samsung.c | 34 +- > drivers/irqchip/irq-vic.c | 7 +- > 19 files changed, 1497 insertions(+), 29 deletions(-) > create mode 100644 arch/arm/boot/dts/s3c6400.dtsi > create mode 100644 arch/arm/boot/dts/s3c6410-mini6410.dts > create mode 100644 arch/arm/boot/dts/s3c6410-smdk6410.dts > create mode 100644 arch/arm/boot/dts/s3c6410.dtsi > create mode 100644 arch/arm/boot/dts/s3c64xx-pinctrl.dtsi > create mode 100644 arch/arm/boot/dts/s3c64xx.dtsi > create mode 100644 arch/arm/mach-s3c64xx/mach-s3c64xx-dt.c > Nice, applied this whole series. Thanks, Kukjin ^ permalink raw reply [flat|nested] 64+ messages in thread
end of thread, other threads:[~2013-08-25 17:31 UTC | newest] Thread overview: 64+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2013-08-21 21:21 [PATCH v7 0/7] Initial Device Tree support for S3C64xx Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-21 21:21 ` [PATCH v7 1/7] ARM: common: vic: Parse interrupt and resume masks from device tree Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-21 23:19 ` Linus Walleij 2013-08-21 23:19 ` Linus Walleij 2013-08-22 7:57 ` Tomasz Figa 2013-08-22 7:57 ` Tomasz Figa 2013-08-22 23:22 ` [PATCH v8 1/7] irqchip: " Tomasz Figa 2013-08-22 23:22 ` Tomasz Figa 2013-08-23 18:12 ` Linus Walleij 2013-08-23 18:12 ` Linus Walleij 2013-08-23 22:11 ` Stephen Warren 2013-08-23 22:11 ` Stephen Warren 2013-08-23 23:04 ` Tomasz Figa 2013-08-23 23:04 ` Tomasz Figa 2013-08-23 23:19 ` Stephen Warren 2013-08-23 23:19 ` Stephen Warren 2013-08-23 23:33 ` Tomasz Figa 2013-08-23 23:33 ` Tomasz Figa 2013-08-24 15:25 ` Rob Herring 2013-08-24 15:25 ` Rob Herring 2013-08-24 15:31 ` Tomasz Figa 2013-08-24 15:31 ` Tomasz Figa 2013-08-24 16:35 ` Rob Herring 2013-08-24 16:35 ` Rob Herring 2013-08-24 16:57 ` Tomasz Figa 2013-08-24 16:57 ` Tomasz Figa 2013-08-23 23:54 ` [PATCH v9 " Tomasz Figa 2013-08-23 23:54 ` Tomasz Figa 2013-08-21 21:21 ` [PATCH v7 2/7] ARM: s3c64xx: Bypass legacy initialization when booting with DT Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-21 21:21 ` [PATCH v7 3/7] gpio: samsung: Skip initialization if device tree is present Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-21 23:21 ` Linus Walleij 2013-08-21 23:21 ` Linus Walleij 2013-08-22 8:06 ` Tomasz Figa 2013-08-22 8:06 ` Tomasz Figa 2013-08-22 9:48 ` Mark Brown 2013-08-22 9:48 ` Mark Brown 2013-08-22 9:59 ` Kukjin Kim 2013-08-22 9:59 ` Kukjin Kim 2013-08-22 23:19 ` Tomasz Figa 2013-08-22 23:19 ` Tomasz Figa 2013-08-23 18:11 ` Linus Walleij 2013-08-23 18:11 ` Linus Walleij 2013-08-25 17:21 ` Kukjin Kim 2013-08-25 17:21 ` Kukjin Kim 2013-08-22 9:45 ` Kukjin Kim 2013-08-22 9:45 ` Kukjin Kim 2013-08-21 21:21 ` [PATCH v7 4/7] ARM: s3c64xx: Add board file for boot using Device Tree Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-21 21:21 ` [PATCH v7 5/7] ARM: dts: Add basic dts include files for Samsung S3C64xx SoCs Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-22 23:24 ` [PATCH v8 " Tomasz Figa 2013-08-22 23:24 ` Tomasz Figa 2013-08-23 23:56 ` [PATCH v9 " Tomasz Figa 2013-08-23 23:56 ` Tomasz Figa 2013-08-21 21:21 ` [PATCH v7 6/7] ARM: dts: Add dts file for S3C6410-based Mini6410 board Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-21 21:21 ` [PATCH v7 7/7] ARM: dts: Add dts file for S3C6410-based SMDK6410 board Tomasz Figa 2013-08-21 21:21 ` Tomasz Figa 2013-08-25 17:31 ` [PATCH v7 0/7] Initial Device Tree support for S3C64xx Kukjin Kim 2013-08-25 17:31 ` Kukjin Kim
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.