Re: [PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Sylwester Nawrocki
On 07/29/2013 11:12 PM, Julius Werner wrote: - if (sphy->phy_type == USB_PHY_TYPE_DEVICE) { - reg = sphy->pmuregs + sphy->drv_data->devphy_reg_offset; - en_mask = sphy->drv_data->devphy_en_mask; - } else if (sphy->phy_type == USB_PHY_TYPE_HOST) { -

Re: [PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Julius Werner
>> - if (sphy->phy_type == USB_PHY_TYPE_DEVICE) { >> - reg = sphy->pmuregs + sphy->drv_data->devphy_reg_offset; >> - en_mask = sphy->drv_data->devphy_en_mask; >> - } else if (sphy->phy_type == USB_PHY_TYPE_HOST) { >> - reg = sphy->pmuregs +

Re: [PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Sylwester Nawrocki
Hi, On 07/29/2013 10:47 PM, Julius Werner wrote: This patch simplifies the way the phy-samsung-usb code finds the correct power management register to enable PHY clock gating. Previously, the code would calculate the register address from a device tree supplied base address and add an offset

[PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Julius Werner
This patch simplifies the way the phy-samsung-usb code finds the correct power management register to enable PHY clock gating. Previously, the code would calculate the register address from a device tree supplied base address and add an offset based on the PHY type. Since every PHY has its own

[PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Julius Werner
This patch simplifies the way the phy-samsung-usb code finds the correct power management register to enable PHY clock gating. Previously, the code would calculate the register address from a device tree supplied base address and add an offset based on the PHY type. Since every PHY has its own

Re: [PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Sylwester Nawrocki
Hi, On 07/29/2013 10:47 PM, Julius Werner wrote: This patch simplifies the way the phy-samsung-usb code finds the correct power management register to enable PHY clock gating. Previously, the code would calculate the register address from a device tree supplied base address and add an offset

Re: [PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Julius Werner
- if (sphy-phy_type == USB_PHY_TYPE_DEVICE) { - reg = sphy-pmuregs + sphy-drv_data-devphy_reg_offset; - en_mask = sphy-drv_data-devphy_en_mask; - } else if (sphy-phy_type == USB_PHY_TYPE_HOST) { - reg = sphy-pmuregs +

Re: [PATCH] usb: phy-samsung-usb: Simplify PMU register handling

2013-07-29 Thread Sylwester Nawrocki
On 07/29/2013 11:12 PM, Julius Werner wrote: - if (sphy-phy_type == USB_PHY_TYPE_DEVICE) { - reg = sphy-pmuregs + sphy-drv_data-devphy_reg_offset; - en_mask = sphy-drv_data-devphy_en_mask; - } else if (sphy-phy_type == USB_PHY_TYPE_HOST) { -