All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof
@ 2015-03-05  1:52 Axel Lin
  2015-03-05  1:57 ` [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h Axel Lin
  2015-03-05  7:53 ` [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof Lee Jones
  0 siblings, 2 replies; 12+ messages in thread
From: Axel Lin @ 2015-03-05  1:52 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring

Prefer devm_kcalloc over devm_kzalloc with multiply.
In additional, use sizeof(phy) is incorrect, fix it.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
---
 drivers/phy/phy-miphy365x.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/phy/phy-miphy365x.c b/drivers/phy/phy-miphy365x.c
index 61177a6..51b459d 100644
--- a/drivers/phy/phy-miphy365x.c
+++ b/drivers/phy/phy-miphy365x.c
@@ -549,9 +549,8 @@ static int miphy365x_probe(struct platform_device *pdev)
 		return -ENOMEM;
 
 	miphy_dev->nphys = of_get_child_count(np);
-	miphy_dev->phys = devm_kzalloc(&pdev->dev,
-				       sizeof(phy) * miphy_dev->nphys,
-				       GFP_KERNEL);
+	miphy_dev->phys = devm_kcalloc(&pdev->dev, miphy_dev->nphys,
+				       sizeof(*miphy_dev->phys), GFP_KERNEL);
 	if (!miphy_dev->phys)
 		return -ENOMEM;
 
-- 
1.9.1




^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
  2015-03-05  1:52 [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof Axel Lin
@ 2015-03-05  1:57 ` Axel Lin
  2015-03-05  7:54   ` Lee Jones
  2015-03-09 11:44     ` Kishon Vijay Abraham I
  2015-03-05  7:53 ` [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof Lee Jones
  1 sibling, 2 replies; 12+ messages in thread
From: Axel Lin @ 2015-03-05  1:57 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring

The defines in phy-miphy365x.h are all covered in phy.h:

MIPHY_TYPE_SATA == PHY_TYPE_STA
MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
MIPPHY_TYPE_USB == PHY_TYPE_USB2

So covert to use phy.h and then delete phy-miphy365x.h.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
---
 Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
 Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
 arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
 drivers/phy/phy-miphy365x.c                             | 14 +++++++-------
 include/dt-bindings/phy/phy-miphy365x.h                 | 14 --------------
 5 files changed, 14 insertions(+), 28 deletions(-)
 delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h

diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt b/Documentation/devicetree/bindings/ata/ahci-st.txt
index 0574a77..070748b 100644
--- a/Documentation/devicetree/bindings/ata/ahci-st.txt
+++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
@@ -21,7 +21,7 @@ Example:
 		reg             = <0xfe380000 0x1000>;
 		interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
 		interrupt-names = "hostc";
-		phys	        = <&miphy365x_phy MIPHY_PORT_0 MIPHY_TYPE_SATA>;
+		phys	        = <&miphy365x_phy MIPHY_PORT_0 PHY_TYPE_SATA>;
 		phy-names       = "ahci_phy";
 		resets	        = <&powerdown STIH416_SATA0_POWERDOWN>,
 				  <&softreset STIH416_SATA0_SOFTRESET>;
diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
index 9802d5d..087294d 100644
--- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
+++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
@@ -20,8 +20,8 @@ Required nodes	:  A sub-node is required for each channel the controller
 Required properties (port (child) node):
 - #phy-cells 	: Should be 1 (See second example)
 		  Cell after port phandle is device type from:
-			- MIPHY_TYPE_SATA
-			- MIPHY_TYPE_PCI
+			- PHY_TYPE_SATA
+			- PHY_TYPE_PCIE
 - reg        	: Address and length of register sets for each device in
 		  "reg-names"
 - reg-names     : The names of the register addresses corresponding to the
@@ -68,10 +68,10 @@ property, containing a phandle to the phy port node and a device type.
 
 Example:
 
-#include <dt-bindings/phy/phy-miphy365x.h>
+#include <dt-bindings/phy/phy.h>
 
 	sata0: sata@fe380000 {
 		...
-		phys	  = <&phy_port0 MIPHY_TYPE_SATA>;
+		phys	  = <&phy_port0 PHY_TYPE_SATA>;
 		...
 	};
diff --git a/arch/arm/boot/dts/stih416.dtsi b/arch/arm/boot/dts/stih416.dtsi
index ea28eba..eeb7afe 100644
--- a/arch/arm/boot/dts/stih416.dtsi
+++ b/arch/arm/boot/dts/stih416.dtsi
@@ -10,7 +10,7 @@
 #include "stih416-clock.dtsi"
 #include "stih416-pinctrl.dtsi"
 
-#include <dt-bindings/phy/phy-miphy365x.h>
+#include <dt-bindings/phy/phy.h>
 #include <dt-bindings/interrupt-controller/arm-gic.h>
 #include <dt-bindings/reset-controller/stih416-resets.h>
 / {
@@ -306,7 +306,7 @@
 			reg             = <0xfe380000 0x1000>;
 			interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
 			interrupt-names = "hostc";
-			phys	        = <&phy_port0 MIPHY_TYPE_SATA>;
+			phys	        = <&phy_port0 PHY_TYPE_SATA>;
 			phy-names       = "sata-phy";
 			resets	        = <&powerdown STIH416_SATA0_POWERDOWN>,
 					  <&softreset STIH416_SATA0_SOFTRESET>;
diff --git a/drivers/phy/phy-miphy365x.c b/drivers/phy/phy-miphy365x.c
index 51b459d..019c2d7 100644
--- a/drivers/phy/phy-miphy365x.c
+++ b/drivers/phy/phy-miphy365x.c
@@ -25,7 +25,7 @@
 #include <linux/mfd/syscon.h>
 #include <linux/regmap.h>
 
-#include <dt-bindings/phy/phy-miphy365x.h>
+#include <dt-bindings/phy/phy.h>
 
 #define HFC_TIMEOUT		100
 
@@ -177,7 +177,7 @@ static u8 rx_tx_spd[] = {
 static int miphy365x_set_path(struct miphy365x_phy *miphy_phy,
 			      struct miphy365x_dev *miphy_dev)
 {
-	bool sata = (miphy_phy->type == MIPHY_TYPE_SATA);
+	bool sata = (miphy_phy->type == PHY_TYPE_SATA);
 
 	return regmap_update_bits(miphy_dev->regmap,
 				  miphy_phy->ctrlreg,
@@ -431,7 +431,7 @@ static int miphy365x_init(struct phy *phy)
 	}
 
 	/* Initialise Miphy for PCIe or SATA */
-	if (miphy_phy->type == MIPHY_TYPE_PCIE)
+	if (miphy_phy->type == PHY_TYPE_PCIE)
 		ret = miphy365x_init_pcie_port(miphy_phy, miphy_dev);
 	else
 		ret = miphy365x_init_sata_port(miphy_phy, miphy_dev);
@@ -455,8 +455,8 @@ int miphy365x_get_addr(struct device *dev, struct miphy365x_phy *miphy_phy,
 		return ret;
 	}
 
-	if (!((!strncmp(name, "sata", 4) && type == MIPHY_TYPE_SATA) ||
-	      (!strncmp(name, "pcie", 4) && type == MIPHY_TYPE_PCIE)))
+	if (!((!strncmp(name, "sata", 4) && type == PHY_TYPE_SATA) ||
+	      (!strncmp(name, "pcie", 4) && type == PHY_TYPE_PCIE)))
 		return 0;
 
 	miphy_phy->base = of_iomap(phynode, index);
@@ -499,8 +499,8 @@ static struct phy *miphy365x_xlate(struct device *dev,
 
 	miphy_phy->type = args->args[0];
 
-	if (!(miphy_phy->type == MIPHY_TYPE_SATA ||
-	      miphy_phy->type == MIPHY_TYPE_PCIE)) {
+	if (!(miphy_phy->type == PHY_TYPE_SATA ||
+	      miphy_phy->type == PHY_TYPE_PCIE)) {
 		dev_err(dev, "Unsupported device type: %d\n", miphy_phy->type);
 		return ERR_PTR(-EINVAL);
 	}
diff --git a/include/dt-bindings/phy/phy-miphy365x.h b/include/dt-bindings/phy/phy-miphy365x.h
deleted file mode 100644
index 8ef8aba..0000000
--- a/include/dt-bindings/phy/phy-miphy365x.h
+++ /dev/null
@@ -1,14 +0,0 @@
-/*
- * This header provides constants for the phy framework
- * based on the STMicroelectronics MiPHY365x.
- *
- * Author: Lee Jones <lee.jones@linaro.org>
- */
-#ifndef _DT_BINDINGS_PHY_MIPHY
-#define _DT_BINDINGS_PHY_MIPHY
-
-#define MIPHY_TYPE_SATA		1
-#define MIPHY_TYPE_PCIE		2
-#define MIPPHY_TYPE_USB		3
-
-#endif /* _DT_BINDINGS_PHY_MIPHY */
-- 
1.9.1




^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof
  2015-03-05  1:52 [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof Axel Lin
  2015-03-05  1:57 ` [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h Axel Lin
@ 2015-03-05  7:53 ` Lee Jones
  1 sibling, 0 replies; 12+ messages in thread
From: Lee Jones @ 2015-03-05  7:53 UTC (permalink / raw)
  To: Axel Lin
  Cc: Kishon Vijay Abraham I, Gabriel FERNANDEZ, Alexandre Torgue,
	linux-kernel, devicetree, Rob Herring

On Thu, 05 Mar 2015, Axel Lin wrote:

> Prefer devm_kcalloc over devm_kzalloc with multiply.
> In additional, use sizeof(phy) is incorrect, fix it.
> 
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---
>  drivers/phy/phy-miphy365x.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)

Acked-by: Lee Jones <lee.jones@linaro.org>

> diff --git a/drivers/phy/phy-miphy365x.c b/drivers/phy/phy-miphy365x.c
> index 61177a6..51b459d 100644
> --- a/drivers/phy/phy-miphy365x.c
> +++ b/drivers/phy/phy-miphy365x.c
> @@ -549,9 +549,8 @@ static int miphy365x_probe(struct platform_device *pdev)
>  		return -ENOMEM;
>  
>  	miphy_dev->nphys = of_get_child_count(np);
> -	miphy_dev->phys = devm_kzalloc(&pdev->dev,
> -				       sizeof(phy) * miphy_dev->nphys,
> -				       GFP_KERNEL);
> +	miphy_dev->phys = devm_kcalloc(&pdev->dev, miphy_dev->nphys,
> +				       sizeof(*miphy_dev->phys), GFP_KERNEL);
>  	if (!miphy_dev->phys)
>  		return -ENOMEM;
>  

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
  2015-03-05  1:57 ` [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h Axel Lin
@ 2015-03-05  7:54   ` Lee Jones
  2015-03-09 11:44     ` Kishon Vijay Abraham I
  1 sibling, 0 replies; 12+ messages in thread
From: Lee Jones @ 2015-03-05  7:54 UTC (permalink / raw)
  To: Axel Lin
  Cc: Kishon Vijay Abraham I, Gabriel FERNANDEZ, Alexandre Torgue,
	linux-kernel, devicetree, Rob Herring

On Thu, 05 Mar 2015, Axel Lin wrote:

> The defines in phy-miphy365x.h are all covered in phy.h:
> 
> MIPHY_TYPE_SATA == PHY_TYPE_STA
> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
> MIPPHY_TYPE_USB == PHY_TYPE_USB2
> 
> So covert to use phy.h and then delete phy-miphy365x.h.
> 
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---
>  Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>  Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>  arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>  drivers/phy/phy-miphy365x.c                             | 14 +++++++-------
>  include/dt-bindings/phy/phy-miphy365x.h                 | 14 --------------
>  5 files changed, 14 insertions(+), 28 deletions(-)
>  delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h

Acked-by: Lee Jones <lee.jones@linaro.org>

> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt b/Documentation/devicetree/bindings/ata/ahci-st.txt
> index 0574a77..070748b 100644
> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
> @@ -21,7 +21,7 @@ Example:
>  		reg             = <0xfe380000 0x1000>;
>  		interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>  		interrupt-names = "hostc";
> -		phys	        = <&miphy365x_phy MIPHY_PORT_0 MIPHY_TYPE_SATA>;
> +		phys	        = <&miphy365x_phy MIPHY_PORT_0 PHY_TYPE_SATA>;
>  		phy-names       = "ahci_phy";
>  		resets	        = <&powerdown STIH416_SATA0_POWERDOWN>,
>  				  <&softreset STIH416_SATA0_SOFTRESET>;
> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> index 9802d5d..087294d 100644
> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> @@ -20,8 +20,8 @@ Required nodes	:  A sub-node is required for each channel the controller
>  Required properties (port (child) node):
>  - #phy-cells 	: Should be 1 (See second example)
>  		  Cell after port phandle is device type from:
> -			- MIPHY_TYPE_SATA
> -			- MIPHY_TYPE_PCI
> +			- PHY_TYPE_SATA
> +			- PHY_TYPE_PCIE
>  - reg        	: Address and length of register sets for each device in
>  		  "reg-names"
>  - reg-names     : The names of the register addresses corresponding to the
> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node and a device type.
>  
>  Example:
>  
> -#include <dt-bindings/phy/phy-miphy365x.h>
> +#include <dt-bindings/phy/phy.h>
>  
>  	sata0: sata@fe380000 {
>  		...
> -		phys	  = <&phy_port0 MIPHY_TYPE_SATA>;
> +		phys	  = <&phy_port0 PHY_TYPE_SATA>;
>  		...
>  	};
> diff --git a/arch/arm/boot/dts/stih416.dtsi b/arch/arm/boot/dts/stih416.dtsi
> index ea28eba..eeb7afe 100644
> --- a/arch/arm/boot/dts/stih416.dtsi
> +++ b/arch/arm/boot/dts/stih416.dtsi
> @@ -10,7 +10,7 @@
>  #include "stih416-clock.dtsi"
>  #include "stih416-pinctrl.dtsi"
>  
> -#include <dt-bindings/phy/phy-miphy365x.h>
> +#include <dt-bindings/phy/phy.h>
>  #include <dt-bindings/interrupt-controller/arm-gic.h>
>  #include <dt-bindings/reset-controller/stih416-resets.h>
>  / {
> @@ -306,7 +306,7 @@
>  			reg             = <0xfe380000 0x1000>;
>  			interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>  			interrupt-names = "hostc";
> -			phys	        = <&phy_port0 MIPHY_TYPE_SATA>;
> +			phys	        = <&phy_port0 PHY_TYPE_SATA>;
>  			phy-names       = "sata-phy";
>  			resets	        = <&powerdown STIH416_SATA0_POWERDOWN>,
>  					  <&softreset STIH416_SATA0_SOFTRESET>;
> diff --git a/drivers/phy/phy-miphy365x.c b/drivers/phy/phy-miphy365x.c
> index 51b459d..019c2d7 100644
> --- a/drivers/phy/phy-miphy365x.c
> +++ b/drivers/phy/phy-miphy365x.c
> @@ -25,7 +25,7 @@
>  #include <linux/mfd/syscon.h>
>  #include <linux/regmap.h>
>  
> -#include <dt-bindings/phy/phy-miphy365x.h>
> +#include <dt-bindings/phy/phy.h>
>  
>  #define HFC_TIMEOUT		100
>  
> @@ -177,7 +177,7 @@ static u8 rx_tx_spd[] = {
>  static int miphy365x_set_path(struct miphy365x_phy *miphy_phy,
>  			      struct miphy365x_dev *miphy_dev)
>  {
> -	bool sata = (miphy_phy->type == MIPHY_TYPE_SATA);
> +	bool sata = (miphy_phy->type == PHY_TYPE_SATA);
>  
>  	return regmap_update_bits(miphy_dev->regmap,
>  				  miphy_phy->ctrlreg,
> @@ -431,7 +431,7 @@ static int miphy365x_init(struct phy *phy)
>  	}
>  
>  	/* Initialise Miphy for PCIe or SATA */
> -	if (miphy_phy->type == MIPHY_TYPE_PCIE)
> +	if (miphy_phy->type == PHY_TYPE_PCIE)
>  		ret = miphy365x_init_pcie_port(miphy_phy, miphy_dev);
>  	else
>  		ret = miphy365x_init_sata_port(miphy_phy, miphy_dev);
> @@ -455,8 +455,8 @@ int miphy365x_get_addr(struct device *dev, struct miphy365x_phy *miphy_phy,
>  		return ret;
>  	}
>  
> -	if (!((!strncmp(name, "sata", 4) && type == MIPHY_TYPE_SATA) ||
> -	      (!strncmp(name, "pcie", 4) && type == MIPHY_TYPE_PCIE)))
> +	if (!((!strncmp(name, "sata", 4) && type == PHY_TYPE_SATA) ||
> +	      (!strncmp(name, "pcie", 4) && type == PHY_TYPE_PCIE)))
>  		return 0;
>  
>  	miphy_phy->base = of_iomap(phynode, index);
> @@ -499,8 +499,8 @@ static struct phy *miphy365x_xlate(struct device *dev,
>  
>  	miphy_phy->type = args->args[0];
>  
> -	if (!(miphy_phy->type == MIPHY_TYPE_SATA ||
> -	      miphy_phy->type == MIPHY_TYPE_PCIE)) {
> +	if (!(miphy_phy->type == PHY_TYPE_SATA ||
> +	      miphy_phy->type == PHY_TYPE_PCIE)) {
>  		dev_err(dev, "Unsupported device type: %d\n", miphy_phy->type);
>  		return ERR_PTR(-EINVAL);
>  	}
> diff --git a/include/dt-bindings/phy/phy-miphy365x.h b/include/dt-bindings/phy/phy-miphy365x.h
> deleted file mode 100644
> index 8ef8aba..0000000
> --- a/include/dt-bindings/phy/phy-miphy365x.h
> +++ /dev/null
> @@ -1,14 +0,0 @@
> -/*
> - * This header provides constants for the phy framework
> - * based on the STMicroelectronics MiPHY365x.
> - *
> - * Author: Lee Jones <lee.jones@linaro.org>
> - */
> -#ifndef _DT_BINDINGS_PHY_MIPHY
> -#define _DT_BINDINGS_PHY_MIPHY
> -
> -#define MIPHY_TYPE_SATA		1
> -#define MIPHY_TYPE_PCIE		2
> -#define MIPPHY_TYPE_USB		3
> -
> -#endif /* _DT_BINDINGS_PHY_MIPHY */

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
  2015-03-05  1:57 ` [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h Axel Lin
@ 2015-03-09 11:44     ` Kishon Vijay Abraham I
  2015-03-09 11:44     ` Kishon Vijay Abraham I
  1 sibling, 0 replies; 12+ messages in thread
From: Kishon Vijay Abraham I @ 2015-03-09 11:44 UTC (permalink / raw)
  To: Axel Lin
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring

Hi,

On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
> The defines in phy-miphy365x.h are all covered in phy.h:
>
> MIPHY_TYPE_SATA == PHY_TYPE_STA
> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>
> So covert to use phy.h and then delete phy-miphy365x.h.
>
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---
>   Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>   Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>   arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>   drivers/phy/phy-miphy365x.c                             | 14 +++++++-------
>   include/dt-bindings/phy/phy-miphy365x.h                 | 14 --------------
>   5 files changed, 14 insertions(+), 28 deletions(-)
>   delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>
> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt b/Documentation/devicetree/bindings/ata/ahci-st.txt
> index 0574a77..070748b 100644
> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
> @@ -21,7 +21,7 @@ Example:
>   		reg             = <0xfe380000 0x1000>;
>   		interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>   		interrupt-names = "hostc";
> -		phys	        = <&miphy365x_phy MIPHY_PORT_0 MIPHY_TYPE_SATA>;
> +		phys	        = <&miphy365x_phy MIPHY_PORT_0 PHY_TYPE_SATA>;
>   		phy-names       = "ahci_phy";
>   		resets	        = <&powerdown STIH416_SATA0_POWERDOWN>,
>   				  <&softreset STIH416_SATA0_SOFTRESET>;
> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> index 9802d5d..087294d 100644
> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> @@ -20,8 +20,8 @@ Required nodes	:  A sub-node is required for each channel the controller
>   Required properties (port (child) node):
>   - #phy-cells 	: Should be 1 (See second example)
>   		  Cell after port phandle is device type from:
> -			- MIPHY_TYPE_SATA
> -			- MIPHY_TYPE_PCI
> +			- PHY_TYPE_SATA
> +			- PHY_TYPE_PCIE
>   - reg        	: Address and length of register sets for each device in
>   		  "reg-names"
>   - reg-names     : The names of the register addresses corresponding to the
> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node and a device type.
>
>   Example:
>
> -#include <dt-bindings/phy/phy-miphy365x.h>
> +#include <dt-bindings/phy/phy.h>
>
>   	sata0: sata@fe380000 {
>   		...
> -		phys	  = <&phy_port0 MIPHY_TYPE_SATA>;
> +		phys	  = <&phy_port0 PHY_TYPE_SATA>;
>   		...
>   	};
> diff --git a/arch/arm/boot/dts/stih416.dtsi b/arch/arm/boot/dts/stih416.dtsi
> index ea28eba..eeb7afe 100644
> --- a/arch/arm/boot/dts/stih416.dtsi
> +++ b/arch/arm/boot/dts/stih416.dtsi

Can you split the patch so that I can queue the PHY part?

Cheers
Kishon

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-09 11:44     ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 12+ messages in thread
From: Kishon Vijay Abraham I @ 2015-03-09 11:44 UTC (permalink / raw)
  To: Axel Lin
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring

Hi,

On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
> The defines in phy-miphy365x.h are all covered in phy.h:
>
> MIPHY_TYPE_SATA == PHY_TYPE_STA
> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>
> So covert to use phy.h and then delete phy-miphy365x.h.
>
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---
>   Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>   Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>   arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>   drivers/phy/phy-miphy365x.c                             | 14 +++++++-------
>   include/dt-bindings/phy/phy-miphy365x.h                 | 14 --------------
>   5 files changed, 14 insertions(+), 28 deletions(-)
>   delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>
> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt b/Documentation/devicetree/bindings/ata/ahci-st.txt
> index 0574a77..070748b 100644
> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
> @@ -21,7 +21,7 @@ Example:
>   		reg             = <0xfe380000 0x1000>;
>   		interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>   		interrupt-names = "hostc";
> -		phys	        = <&miphy365x_phy MIPHY_PORT_0 MIPHY_TYPE_SATA>;
> +		phys	        = <&miphy365x_phy MIPHY_PORT_0 PHY_TYPE_SATA>;
>   		phy-names       = "ahci_phy";
>   		resets	        = <&powerdown STIH416_SATA0_POWERDOWN>,
>   				  <&softreset STIH416_SATA0_SOFTRESET>;
> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> index 9802d5d..087294d 100644
> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
> @@ -20,8 +20,8 @@ Required nodes	:  A sub-node is required for each channel the controller
>   Required properties (port (child) node):
>   - #phy-cells 	: Should be 1 (See second example)
>   		  Cell after port phandle is device type from:
> -			- MIPHY_TYPE_SATA
> -			- MIPHY_TYPE_PCI
> +			- PHY_TYPE_SATA
> +			- PHY_TYPE_PCIE
>   - reg        	: Address and length of register sets for each device in
>   		  "reg-names"
>   - reg-names     : The names of the register addresses corresponding to the
> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node and a device type.
>
>   Example:
>
> -#include <dt-bindings/phy/phy-miphy365x.h>
> +#include <dt-bindings/phy/phy.h>
>
>   	sata0: sata@fe380000 {
>   		...
> -		phys	  = <&phy_port0 MIPHY_TYPE_SATA>;
> +		phys	  = <&phy_port0 PHY_TYPE_SATA>;
>   		...
>   	};
> diff --git a/arch/arm/boot/dts/stih416.dtsi b/arch/arm/boot/dts/stih416.dtsi
> index ea28eba..eeb7afe 100644
> --- a/arch/arm/boot/dts/stih416.dtsi
> +++ b/arch/arm/boot/dts/stih416.dtsi

Can you split the patch so that I can queue the PHY part?

Cheers
Kishon

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-09 13:25       ` Axel Lin
  0 siblings, 0 replies; 12+ messages in thread
From: Axel Lin @ 2015-03-09 13:25 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring

2015-03-09 19:44 GMT+08:00 Kishon Vijay Abraham I <kishon@ti.com>:
> Hi,
>
>
> On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
>>
>> The defines in phy-miphy365x.h are all covered in phy.h:
>>
>> MIPHY_TYPE_SATA == PHY_TYPE_STA
>> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
>> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>>
>> So covert to use phy.h and then delete phy-miphy365x.h.
>>
>> Signed-off-by: Axel Lin <axel.lin@ingics.com>
>> ---
>>   Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>>   Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>>   arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>>   drivers/phy/phy-miphy365x.c                             | 14
>> +++++++-------
>>   include/dt-bindings/phy/phy-miphy365x.h                 | 14
>> --------------
>>   5 files changed, 14 insertions(+), 28 deletions(-)
>>   delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>>
>> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt
>> b/Documentation/devicetree/bindings/ata/ahci-st.txt
>> index 0574a77..070748b 100644
>> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
>> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
>> @@ -21,7 +21,7 @@ Example:
>>                 reg             = <0xfe380000 0x1000>;
>>                 interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>>                 interrupt-names = "hostc";
>> -               phys            = <&miphy365x_phy MIPHY_PORT_0
>> MIPHY_TYPE_SATA>;
>> +               phys            = <&miphy365x_phy MIPHY_PORT_0
>> PHY_TYPE_SATA>;
>>                 phy-names       = "ahci_phy";
>>                 resets          = <&powerdown STIH416_SATA0_POWERDOWN>,
>>                                   <&softreset STIH416_SATA0_SOFTRESET>;
>> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> index 9802d5d..087294d 100644
>> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> @@ -20,8 +20,8 @@ Required nodes        :  A sub-node is required for each
>> channel the controller
>>   Required properties (port (child) node):
>>   - #phy-cells  : Should be 1 (See second example)
>>                   Cell after port phandle is device type from:
>> -                       - MIPHY_TYPE_SATA
>> -                       - MIPHY_TYPE_PCI
>> +                       - PHY_TYPE_SATA
>> +                       - PHY_TYPE_PCIE
>>   - reg         : Address and length of register sets for each device in
>>                   "reg-names"
>>   - reg-names     : The names of the register addresses corresponding to
>> the
>> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node
>> and a device type.
>>
>>   Example:
>>
>> -#include <dt-bindings/phy/phy-miphy365x.h>
>> +#include <dt-bindings/phy/phy.h>
>>
>>         sata0: sata@fe380000 {
>>                 ...
>> -               phys      = <&phy_port0 MIPHY_TYPE_SATA>;
>> +               phys      = <&phy_port0 PHY_TYPE_SATA>;
>>                 ...
>>         };
>> diff --git a/arch/arm/boot/dts/stih416.dtsi
>> b/arch/arm/boot/dts/stih416.dtsi
>> index ea28eba..eeb7afe 100644
>> --- a/arch/arm/boot/dts/stih416.dtsi
>> +++ b/arch/arm/boot/dts/stih416.dtsi
>
>
> Can you split the patch so that I can queue the PHY part?

In my opinion, apply the patch as is should be fine and we don't have any
build breakage. I think the change in each file is pretty trivial and won't
cause problem. otherwise, I will have to send patches for the conversion
in each file and then wait until all patches are merged. Then send another
patch to delete include/dt-bindings/phy/phy-miphy365x.h.

Regards,
Axel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-09 13:25       ` Axel Lin
  0 siblings, 0 replies; 12+ messages in thread
From: Axel Lin @ 2015-03-09 13:25 UTC (permalink / raw)
  To: Kishon Vijay Abraham I
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring

2015-03-09 19:44 GMT+08:00 Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>:
> Hi,
>
>
> On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
>>
>> The defines in phy-miphy365x.h are all covered in phy.h:
>>
>> MIPHY_TYPE_SATA == PHY_TYPE_STA
>> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
>> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>>
>> So covert to use phy.h and then delete phy-miphy365x.h.
>>
>> Signed-off-by: Axel Lin <axel.lin-8E1dMatC8ynQT0dZR+AlfA@public.gmane.org>
>> ---
>>   Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>>   Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>>   arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>>   drivers/phy/phy-miphy365x.c                             | 14
>> +++++++-------
>>   include/dt-bindings/phy/phy-miphy365x.h                 | 14
>> --------------
>>   5 files changed, 14 insertions(+), 28 deletions(-)
>>   delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>>
>> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt
>> b/Documentation/devicetree/bindings/ata/ahci-st.txt
>> index 0574a77..070748b 100644
>> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
>> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
>> @@ -21,7 +21,7 @@ Example:
>>                 reg             = <0xfe380000 0x1000>;
>>                 interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>>                 interrupt-names = "hostc";
>> -               phys            = <&miphy365x_phy MIPHY_PORT_0
>> MIPHY_TYPE_SATA>;
>> +               phys            = <&miphy365x_phy MIPHY_PORT_0
>> PHY_TYPE_SATA>;
>>                 phy-names       = "ahci_phy";
>>                 resets          = <&powerdown STIH416_SATA0_POWERDOWN>,
>>                                   <&softreset STIH416_SATA0_SOFTRESET>;
>> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> index 9802d5d..087294d 100644
>> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>> @@ -20,8 +20,8 @@ Required nodes        :  A sub-node is required for each
>> channel the controller
>>   Required properties (port (child) node):
>>   - #phy-cells  : Should be 1 (See second example)
>>                   Cell after port phandle is device type from:
>> -                       - MIPHY_TYPE_SATA
>> -                       - MIPHY_TYPE_PCI
>> +                       - PHY_TYPE_SATA
>> +                       - PHY_TYPE_PCIE
>>   - reg         : Address and length of register sets for each device in
>>                   "reg-names"
>>   - reg-names     : The names of the register addresses corresponding to
>> the
>> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node
>> and a device type.
>>
>>   Example:
>>
>> -#include <dt-bindings/phy/phy-miphy365x.h>
>> +#include <dt-bindings/phy/phy.h>
>>
>>         sata0: sata@fe380000 {
>>                 ...
>> -               phys      = <&phy_port0 MIPHY_TYPE_SATA>;
>> +               phys      = <&phy_port0 PHY_TYPE_SATA>;
>>                 ...
>>         };
>> diff --git a/arch/arm/boot/dts/stih416.dtsi
>> b/arch/arm/boot/dts/stih416.dtsi
>> index ea28eba..eeb7afe 100644
>> --- a/arch/arm/boot/dts/stih416.dtsi
>> +++ b/arch/arm/boot/dts/stih416.dtsi
>
>
> Can you split the patch so that I can queue the PHY part?

In my opinion, apply the patch as is should be fine and we don't have any
build breakage. I think the change in each file is pretty trivial and won't
cause problem. otherwise, I will have to send patches for the conversion
in each file and then wait until all patches are merged. Then send another
patch to delete include/dt-bindings/phy/phy-miphy365x.h.

Regards,
Axel
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-25 23:11         ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 12+ messages in thread
From: Kishon Vijay Abraham I @ 2015-03-25 23:11 UTC (permalink / raw)
  To: Axel Lin
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring, Maxime Coquelin, Srinivas Kandagatla,
	patrice CHOTARD

+Maxime, Srinivas, patrice

On Monday 09 March 2015 06:55 PM, Axel Lin wrote:
> 2015-03-09 19:44 GMT+08:00 Kishon Vijay Abraham I <kishon@ti.com>:
>> Hi,
>>
>>
>> On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
>>>
>>> The defines in phy-miphy365x.h are all covered in phy.h:
>>>
>>> MIPHY_TYPE_SATA == PHY_TYPE_STA
>>> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
>>> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>>>
>>> So covert to use phy.h and then delete phy-miphy365x.h.
>>>
>>> Signed-off-by: Axel Lin <axel.lin@ingics.com>
>>> ---
>>>   Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>>>   Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>>>   arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>>>   drivers/phy/phy-miphy365x.c                             | 14
>>> +++++++-------
>>>   include/dt-bindings/phy/phy-miphy365x.h                 | 14
>>> --------------
>>>   5 files changed, 14 insertions(+), 28 deletions(-)
>>>   delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>>>
>>> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> index 0574a77..070748b 100644
>>> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> @@ -21,7 +21,7 @@ Example:
>>>                 reg             = <0xfe380000 0x1000>;
>>>                 interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>>>                 interrupt-names = "hostc";
>>> -               phys            = <&miphy365x_phy MIPHY_PORT_0
>>> MIPHY_TYPE_SATA>;
>>> +               phys            = <&miphy365x_phy MIPHY_PORT_0
>>> PHY_TYPE_SATA>;
>>>                 phy-names       = "ahci_phy";
>>>                 resets          = <&powerdown STIH416_SATA0_POWERDOWN>,
>>>                                   <&softreset STIH416_SATA0_SOFTRESET>;
>>> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> index 9802d5d..087294d 100644
>>> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> @@ -20,8 +20,8 @@ Required nodes        :  A sub-node is required for each
>>> channel the controller
>>>   Required properties (port (child) node):
>>>   - #phy-cells  : Should be 1 (See second example)
>>>                   Cell after port phandle is device type from:
>>> -                       - MIPHY_TYPE_SATA
>>> -                       - MIPHY_TYPE_PCI
>>> +                       - PHY_TYPE_SATA
>>> +                       - PHY_TYPE_PCIE
>>>   - reg         : Address and length of register sets for each device in
>>>                   "reg-names"
>>>   - reg-names     : The names of the register addresses corresponding to
>>> the
>>> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node
>>> and a device type.
>>>
>>>   Example:
>>>
>>> -#include <dt-bindings/phy/phy-miphy365x.h>
>>> +#include <dt-bindings/phy/phy.h>
>>>
>>>         sata0: sata@fe380000 {
>>>                 ...
>>> -               phys      = <&phy_port0 MIPHY_TYPE_SATA>;
>>> +               phys      = <&phy_port0 PHY_TYPE_SATA>;
>>>                 ...
>>>         };
>>> diff --git a/arch/arm/boot/dts/stih416.dtsi
>>> b/arch/arm/boot/dts/stih416.dtsi
>>> index ea28eba..eeb7afe 100644
>>> --- a/arch/arm/boot/dts/stih416.dtsi
>>> +++ b/arch/arm/boot/dts/stih416.dtsi
>>
>>
>> Can you split the patch so that I can queue the PHY part?
> 
> In my opinion, apply the patch as is should be fine and we don't have any
> build breakage. I think the change in each file is pretty trivial and won't
> cause problem. otherwise, I will have to send patches for the conversion
> in each file and then wait until all patches are merged. Then send another
> patch to delete include/dt-bindings/phy/phy-miphy365x.h.

Okay. I can queue after getting Ack from arch/arm/boot/dts/sti* maintainers.

Cheers
Kishon

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-25 23:11         ` Kishon Vijay Abraham I
  0 siblings, 0 replies; 12+ messages in thread
From: Kishon Vijay Abraham I @ 2015-03-25 23:11 UTC (permalink / raw)
  To: Axel Lin
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Maxime Coquelin,
	Srinivas Kandagatla, patrice CHOTARD

+Maxime, Srinivas, patrice

On Monday 09 March 2015 06:55 PM, Axel Lin wrote:
> 2015-03-09 19:44 GMT+08:00 Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>:
>> Hi,
>>
>>
>> On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
>>>
>>> The defines in phy-miphy365x.h are all covered in phy.h:
>>>
>>> MIPHY_TYPE_SATA == PHY_TYPE_STA
>>> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
>>> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>>>
>>> So covert to use phy.h and then delete phy-miphy365x.h.
>>>
>>> Signed-off-by: Axel Lin <axel.lin-8E1dMatC8ynQT0dZR+AlfA@public.gmane.org>
>>> ---
>>>   Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>>>   Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>>>   arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>>>   drivers/phy/phy-miphy365x.c                             | 14
>>> +++++++-------
>>>   include/dt-bindings/phy/phy-miphy365x.h                 | 14
>>> --------------
>>>   5 files changed, 14 insertions(+), 28 deletions(-)
>>>   delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>>>
>>> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> index 0574a77..070748b 100644
>>> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>> @@ -21,7 +21,7 @@ Example:
>>>                 reg             = <0xfe380000 0x1000>;
>>>                 interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>>>                 interrupt-names = "hostc";
>>> -               phys            = <&miphy365x_phy MIPHY_PORT_0
>>> MIPHY_TYPE_SATA>;
>>> +               phys            = <&miphy365x_phy MIPHY_PORT_0
>>> PHY_TYPE_SATA>;
>>>                 phy-names       = "ahci_phy";
>>>                 resets          = <&powerdown STIH416_SATA0_POWERDOWN>,
>>>                                   <&softreset STIH416_SATA0_SOFTRESET>;
>>> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> index 9802d5d..087294d 100644
>>> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>> @@ -20,8 +20,8 @@ Required nodes        :  A sub-node is required for each
>>> channel the controller
>>>   Required properties (port (child) node):
>>>   - #phy-cells  : Should be 1 (See second example)
>>>                   Cell after port phandle is device type from:
>>> -                       - MIPHY_TYPE_SATA
>>> -                       - MIPHY_TYPE_PCI
>>> +                       - PHY_TYPE_SATA
>>> +                       - PHY_TYPE_PCIE
>>>   - reg         : Address and length of register sets for each device in
>>>                   "reg-names"
>>>   - reg-names     : The names of the register addresses corresponding to
>>> the
>>> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node
>>> and a device type.
>>>
>>>   Example:
>>>
>>> -#include <dt-bindings/phy/phy-miphy365x.h>
>>> +#include <dt-bindings/phy/phy.h>
>>>
>>>         sata0: sata@fe380000 {
>>>                 ...
>>> -               phys      = <&phy_port0 MIPHY_TYPE_SATA>;
>>> +               phys      = <&phy_port0 PHY_TYPE_SATA>;
>>>                 ...
>>>         };
>>> diff --git a/arch/arm/boot/dts/stih416.dtsi
>>> b/arch/arm/boot/dts/stih416.dtsi
>>> index ea28eba..eeb7afe 100644
>>> --- a/arch/arm/boot/dts/stih416.dtsi
>>> +++ b/arch/arm/boot/dts/stih416.dtsi
>>
>>
>> Can you split the patch so that I can queue the PHY part?
> 
> In my opinion, apply the patch as is should be fine and we don't have any
> build breakage. I think the change in each file is pretty trivial and won't
> cause problem. otherwise, I will have to send patches for the conversion
> in each file and then wait until all patches are merged. Then send another
> patch to delete include/dt-bindings/phy/phy-miphy365x.h.

Okay. I can queue after getting Ack from arch/arm/boot/dts/sti* maintainers.

Cheers
Kishon
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-26  8:48           ` Patrice Chotard
  0 siblings, 0 replies; 12+ messages in thread
From: Patrice Chotard @ 2015-03-26  8:48 UTC (permalink / raw)
  To: Kishon Vijay Abraham I, Axel Lin
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue, linux-kernel,
	devicetree, Rob Herring, Maxime Coquelin, Srinivas Kandagatla

Hi Kishon

On 03/26/2015 12:11 AM, Kishon Vijay Abraham I wrote:
> +Maxime, Srinivas, patrice
>
> On Monday 09 March 2015 06:55 PM, Axel Lin wrote:
>> 2015-03-09 19:44 GMT+08:00 Kishon Vijay Abraham I <kishon@ti.com>:
>>> Hi,
>>>
>>>
>>> On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
>>>> The defines in phy-miphy365x.h are all covered in phy.h:
>>>>
>>>> MIPHY_TYPE_SATA == PHY_TYPE_STA
>>>> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
>>>> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>>>>
>>>> So covert to use phy.h and then delete phy-miphy365x.h.
>>>>
>>>> Signed-off-by: Axel Lin <axel.lin@ingics.com>
>>>> ---
>>>>    Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>>>>    Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>>>>    arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>>>>    drivers/phy/phy-miphy365x.c                             | 14
>>>> +++++++-------
>>>>    include/dt-bindings/phy/phy-miphy365x.h                 | 14
>>>> --------------
>>>>    5 files changed, 14 insertions(+), 28 deletions(-)
>>>>    delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>>>>
>>>> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> index 0574a77..070748b 100644
>>>> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> @@ -21,7 +21,7 @@ Example:
>>>>                  reg             = <0xfe380000 0x1000>;
>>>>                  interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>>>>                  interrupt-names = "hostc";
>>>> -               phys            = <&miphy365x_phy MIPHY_PORT_0
>>>> MIPHY_TYPE_SATA>;
>>>> +               phys            = <&miphy365x_phy MIPHY_PORT_0
>>>> PHY_TYPE_SATA>;
>>>>                  phy-names       = "ahci_phy";
>>>>                  resets          = <&powerdown STIH416_SATA0_POWERDOWN>,
>>>>                                    <&softreset STIH416_SATA0_SOFTRESET>;
>>>> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> index 9802d5d..087294d 100644
>>>> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> @@ -20,8 +20,8 @@ Required nodes        :  A sub-node is required for each
>>>> channel the controller
>>>>    Required properties (port (child) node):
>>>>    - #phy-cells  : Should be 1 (See second example)
>>>>                    Cell after port phandle is device type from:
>>>> -                       - MIPHY_TYPE_SATA
>>>> -                       - MIPHY_TYPE_PCI
>>>> +                       - PHY_TYPE_SATA
>>>> +                       - PHY_TYPE_PCIE
>>>>    - reg         : Address and length of register sets for each device in
>>>>                    "reg-names"
>>>>    - reg-names     : The names of the register addresses corresponding to
>>>> the
>>>> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node
>>>> and a device type.
>>>>
>>>>    Example:
>>>>
>>>> -#include <dt-bindings/phy/phy-miphy365x.h>
>>>> +#include <dt-bindings/phy/phy.h>
>>>>
>>>>          sata0: sata@fe380000 {
>>>>                  ...
>>>> -               phys      = <&phy_port0 MIPHY_TYPE_SATA>;
>>>> +               phys      = <&phy_port0 PHY_TYPE_SATA>;
>>>>                  ...
>>>>          };
>>>> diff --git a/arch/arm/boot/dts/stih416.dtsi
>>>> b/arch/arm/boot/dts/stih416.dtsi
>>>> index ea28eba..eeb7afe 100644
>>>> --- a/arch/arm/boot/dts/stih416.dtsi
>>>> +++ b/arch/arm/boot/dts/stih416.dtsi
>>>
>>> Can you split the patch so that I can queue the PHY part?
>> In my opinion, apply the patch as is should be fine and we don't have any
>> build breakage. I think the change in each file is pretty trivial and won't
>> cause problem. otherwise, I will have to send patches for the conversion
>> in each file and then wait until all patches are merged. Then send another
>> patch to delete include/dt-bindings/phy/phy-miphy365x.h.
> Okay. I can queue after getting Ack from arch/arm/boot/dts/sti* maintainers.


Acked-by: Patrice Chotard <patrice.chotard@st.com>


Thanks

Patrice

>
> Cheers
> Kishon


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h
@ 2015-03-26  8:48           ` Patrice Chotard
  0 siblings, 0 replies; 12+ messages in thread
From: Patrice Chotard @ 2015-03-26  8:48 UTC (permalink / raw)
  To: Kishon Vijay Abraham I, Axel Lin
  Cc: Gabriel FERNANDEZ, Lee Jones, Alexandre Torgue,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA, Rob Herring, Maxime Coquelin,
	Srinivas Kandagatla

Hi Kishon

On 03/26/2015 12:11 AM, Kishon Vijay Abraham I wrote:
> +Maxime, Srinivas, patrice
>
> On Monday 09 March 2015 06:55 PM, Axel Lin wrote:
>> 2015-03-09 19:44 GMT+08:00 Kishon Vijay Abraham I <kishon-l0cyMroinI0@public.gmane.org>:
>>> Hi,
>>>
>>>
>>> On Thursday 05 March 2015 07:27 AM, Axel Lin wrote:
>>>> The defines in phy-miphy365x.h are all covered in phy.h:
>>>>
>>>> MIPHY_TYPE_SATA == PHY_TYPE_STA
>>>> MIPHY_TYPE_PCIE == PHY_TYPE_PCIE
>>>> MIPPHY_TYPE_USB == PHY_TYPE_USB2
>>>>
>>>> So covert to use phy.h and then delete phy-miphy365x.h.
>>>>
>>>> Signed-off-by: Axel Lin <axel.lin-8E1dMatC8ynQT0dZR+AlfA@public.gmane.org>
>>>> ---
>>>>    Documentation/devicetree/bindings/ata/ahci-st.txt       |  2 +-
>>>>    Documentation/devicetree/bindings/phy/phy-miphy365x.txt |  8 ++++----
>>>>    arch/arm/boot/dts/stih416.dtsi                          |  4 ++--
>>>>    drivers/phy/phy-miphy365x.c                             | 14
>>>> +++++++-------
>>>>    include/dt-bindings/phy/phy-miphy365x.h                 | 14
>>>> --------------
>>>>    5 files changed, 14 insertions(+), 28 deletions(-)
>>>>    delete mode 100644 include/dt-bindings/phy/phy-miphy365x.h
>>>>
>>>> diff --git a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> index 0574a77..070748b 100644
>>>> --- a/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> +++ b/Documentation/devicetree/bindings/ata/ahci-st.txt
>>>> @@ -21,7 +21,7 @@ Example:
>>>>                  reg             = <0xfe380000 0x1000>;
>>>>                  interrupts      = <GIC_SPI 157 IRQ_TYPE_NONE>;
>>>>                  interrupt-names = "hostc";
>>>> -               phys            = <&miphy365x_phy MIPHY_PORT_0
>>>> MIPHY_TYPE_SATA>;
>>>> +               phys            = <&miphy365x_phy MIPHY_PORT_0
>>>> PHY_TYPE_SATA>;
>>>>                  phy-names       = "ahci_phy";
>>>>                  resets          = <&powerdown STIH416_SATA0_POWERDOWN>,
>>>>                                    <&softreset STIH416_SATA0_SOFTRESET>;
>>>> diff --git a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> index 9802d5d..087294d 100644
>>>> --- a/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> +++ b/Documentation/devicetree/bindings/phy/phy-miphy365x.txt
>>>> @@ -20,8 +20,8 @@ Required nodes        :  A sub-node is required for each
>>>> channel the controller
>>>>    Required properties (port (child) node):
>>>>    - #phy-cells  : Should be 1 (See second example)
>>>>                    Cell after port phandle is device type from:
>>>> -                       - MIPHY_TYPE_SATA
>>>> -                       - MIPHY_TYPE_PCI
>>>> +                       - PHY_TYPE_SATA
>>>> +                       - PHY_TYPE_PCIE
>>>>    - reg         : Address and length of register sets for each device in
>>>>                    "reg-names"
>>>>    - reg-names     : The names of the register addresses corresponding to
>>>> the
>>>> @@ -68,10 +68,10 @@ property, containing a phandle to the phy port node
>>>> and a device type.
>>>>
>>>>    Example:
>>>>
>>>> -#include <dt-bindings/phy/phy-miphy365x.h>
>>>> +#include <dt-bindings/phy/phy.h>
>>>>
>>>>          sata0: sata@fe380000 {
>>>>                  ...
>>>> -               phys      = <&phy_port0 MIPHY_TYPE_SATA>;
>>>> +               phys      = <&phy_port0 PHY_TYPE_SATA>;
>>>>                  ...
>>>>          };
>>>> diff --git a/arch/arm/boot/dts/stih416.dtsi
>>>> b/arch/arm/boot/dts/stih416.dtsi
>>>> index ea28eba..eeb7afe 100644
>>>> --- a/arch/arm/boot/dts/stih416.dtsi
>>>> +++ b/arch/arm/boot/dts/stih416.dtsi
>>>
>>> Can you split the patch so that I can queue the PHY part?
>> In my opinion, apply the patch as is should be fine and we don't have any
>> build breakage. I think the change in each file is pretty trivial and won't
>> cause problem. otherwise, I will have to send patches for the conversion
>> in each file and then wait until all patches are merged. Then send another
>> patch to delete include/dt-bindings/phy/phy-miphy365x.h.
> Okay. I can queue after getting Ack from arch/arm/boot/dts/sti* maintainers.


Acked-by: Patrice Chotard <patrice.chotard-qxv4g6HH51o@public.gmane.org>


Thanks

Patrice

>
> Cheers
> Kishon

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2015-03-26  8:48 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-05  1:52 [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof Axel Lin
2015-03-05  1:57 ` [RFC][PATCH 2/2] phy: miphy365x: Convert to use phy.h instead of phy-miphy365x.h Axel Lin
2015-03-05  7:54   ` Lee Jones
2015-03-09 11:44   ` Kishon Vijay Abraham I
2015-03-09 11:44     ` Kishon Vijay Abraham I
2015-03-09 13:25     ` Axel Lin
2015-03-09 13:25       ` Axel Lin
2015-03-25 23:11       ` Kishon Vijay Abraham I
2015-03-25 23:11         ` Kishon Vijay Abraham I
2015-03-26  8:48         ` Patrice Chotard
2015-03-26  8:48           ` Patrice Chotard
2015-03-05  7:53 ` [PATCH 1/2] phy: miphy365x: Convert to devm_kcalloc and fix wrong sizof Lee Jones

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.