Re: [PATCH 4/4] staging: dwc2: load parameters from the devicetree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Thu, Apr 11, 2013 at 06:43:49PM +0200, Matthijs Kooijman wrote:
> diff --git a/Documentation/devicetree/bindings/staging/dwc2.txt b/Documentation/devicetree/bindings/staging/dwc2.txt
> index 3649c88..05d9c08 100644
> --- a/Documentation/devicetree/bindings/staging/dwc2.txt
> +++ b/Documentation/devicetree/bindings/staging/dwc2.txt
> @@ -5,6 +5,39 @@ Required properties:
>  - compatible : "snps,dwc2"
>  - reg : Should contain 1 register range (address and length)
>  - interrupts : Should contain 1 interrupt
> +Optional properties:
> + - dma-enable
> + - otg-cap
> + - otg-ver
> + - dma-enable
> + - dma-desc-enable
> + - speed
> + - enable-dynamic-fifo
> + - en-multiple-tx-fifo
> + - host-rx-fifo-size
> + - host-nperio-tx-fifo-size
> + - host-perio-tx-fifo-size
> + - max-transfer-size
> + - max-packet-count
> + - host-channels
> + - phy-type
> + - phy-utmi-width
> + - phy-ulpi-ddr
> + - phy-ulpi-ext-vbus
> + - i2c-enable
> + - ulpi-fs-ls
> + - host-support-fs-ls-low-power
> + - host-ls-low-power-phy-clk
> + - ts-dline
> + - reload-ctl
> + - ahb-single

are you 110% sure you want all of these parameters ? You will have to
support them forever once it gets accepted in mainline kernel. After DT
is accepted, it's really, really hard to change.

> @@ -12,4 +45,7 @@ Example:
>                  compatible = "ralink,rt3050-otg, snps,dwc2";
>                  reg = <0x101c0000 40000>;
>                  interrupts = <18>;
> +
> +		# Force slave mode, even when dma is advertised to work
> +		dma-enable = <0>;

looks like a test feature.

> diff --git a/drivers/staging/dwc2/platform.c b/drivers/staging/dwc2/platform.c
> index e65fa0d..9e05865 100644
> --- a/drivers/staging/dwc2/platform.c
> +++ b/drivers/staging/dwc2/platform.c
> @@ -40,6 +40,8 @@
>  #include <linux/device.h>
>  #include <linux/dma-mapping.h>
>  #include <linux/platform_device.h>
> +#include <linux/of.h>
> +#include <asm/byteorder.h>

can you use the generic header instead ?

-- 
balbi

Attachment: signature.asc
Description: Digital signature


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux