Re: OMAP display kconfig options changing

2015-12-29 Thread Javier Martinez Canillas
Hello Tomi,

On Tue, Dec 29, 2015 at 7:23 AM, Tomi Valkeinen <tomi.valkei...@ti.com> wrote:
> Hi Javier, Tony,
>
> On 22/12/15 23:18, Javier Martinez Canillas wrote:
>
>>> But if the userspace is using any omapfb specific apps, then yes, update
>>> is necessary.
>>>
>>
>> Yes but these people should have a migration plan anyways since omapfb
>> (and fbdev in general) is going away right?
>
> Well, I would guess most people don't know/care about that.
>

Fair enough.

>>> Ok. I think it's then best that I just update the defconfig to enable
>>> omapfb as modules, as it is currently.
>>>
>>
>> In that case I think you should squash the defconfig changes with
>> commit ("70ba4e05531f omapfb/displays: change CONFIG_DISPLAY_* to
>> CONFIG_FB_OMAP2_*") to maintain bisectability.
>
> Here's the diff to change the defconfig to enable the same items as before:
>
> diff --git a/arch/arm/configs/omap2plus_defconfig
> b/arch/arm/configs/omap2plus_defconfig
> index c5e1943e5427..b9581f1f0536 100644
> --- a/arch/arm/configs/omap2plus_defconfig
> +++ b/arch/arm/configs/omap2plus_defconfig
> @@ -290,24 +290,23 @@ CONFIG_FB=y
>  CONFIG_FIRMWARE_EDID=y
>  CONFIG_FB_MODE_HELPERS=y
>  CONFIG_FB_TILEBLITTING=y
> -CONFIG_OMAP2_DSS=m
> -CONFIG_OMAP5_DSS_HDMI=y
> -CONFIG_OMAP2_DSS_SDI=y
> -CONFIG_OMAP2_DSS_DSI=y
> +CONFIG_FB_OMAP5_DSS_HDMI=y
> +CONFIG_FB_OMAP2_DSS_SDI=y
> +CONFIG_FB_OMAP2_DSS_DSI=y
>  CONFIG_FB_OMAP2=m
> -CONFIG_DISPLAY_ENCODER_TFP410=m
> -CONFIG_DISPLAY_ENCODER_TPD12S015=m
> -CONFIG_DISPLAY_CONNECTOR_DVI=m
> -CONFIG_DISPLAY_CONNECTOR_HDMI=m
> -CONFIG_DISPLAY_CONNECTOR_ANALOG_TV=m
> -CONFIG_DISPLAY_PANEL_DPI=m
> -CONFIG_DISPLAY_PANEL_DSI_CM=m
> -CONFIG_DISPLAY_PANEL_SONY_ACX565AKM=m
> -CONFIG_DISPLAY_PANEL_LGPHILIPS_LB035Q02=m
> -CONFIG_DISPLAY_PANEL_SHARP_LS037V7DW01=m
> -CONFIG_DISPLAY_PANEL_TPO_TD028TTEC1=m
> -CONFIG_DISPLAY_PANEL_TPO_TD043MTEA1=m
> -CONFIG_DISPLAY_PANEL_NEC_NL8048HL11=m
> +CONFIG_FB_OMAP2_ENCODER_TFP410=m
> +CONFIG_FB_OMAP2_ENCODER_TPD12S015=m
> +CONFIG_FB_OMAP2_CONNECTOR_DVI=m
> +CONFIG_FB_OMAP2_CONNECTOR_HDMI=m
> +CONFIG_FB_OMAP2_CONNECTOR_ANALOG_TV=m
> +CONFIG_FB_OMAP2_PANEL_DPI=m
> +CONFIG_FB_OMAP2_PANEL_DSI_CM=m
> +CONFIG_FB_OMAP2_PANEL_SONY_ACX565AKM=m
> +CONFIG_FB_OMAP2_PANEL_LGPHILIPS_LB035Q02=m
> +CONFIG_FB_OMAP2_PANEL_SHARP_LS037V7DW01=m
> +CONFIG_FB_OMAP2_PANEL_TPO_TD028TTEC1=m
> +CONFIG_FB_OMAP2_PANEL_TPO_TD043MTEA1=m
> +CONFIG_FB_OMAP2_PANEL_NEC_NL8048HL11=m
>  CONFIG_BACKLIGHT_LCD_SUPPORT=y
>  CONFIG_LCD_CLASS_DEVICE=y
>  CONFIG_LCD_PLATFORM=y
>

Cool, that's what I changed to test omapfb as well. I can't test your
diff right now but looks correct to me.

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v3 00/23] Unrestricted media entity ID range support

2015-12-27 Thread Javier Martinez Canillas
52002000 + 0x200,
>> +.name = "bte",
>> +.flags = IORESOURCE_MEM,
>> +}, {
>> +.start = 0x5201,
>> +.end = 0x5201 + 0x0a0,
>> +.name = "isp_sys1",
>> +.flags = IORESOURCE_MEM,
>> +}, {
>> +.start = 0x52010400,
>> +.end = 0x52010400 + 0x400,
>> +.name = "isp_resizer",
>> +.flags = IORESOURCE_MEM,
>> +}, {
>> +.start = 0x52010800,
>> +.end = 0x52010800 + 0x800,
>> +.name = "isp_ipipe",
>> +.flags = IORESOURCE_MEM,
>> +}, {
>> +.start = 0x52011000,
>> +.end = 0x52011000 + 0x200,
>> +.name = "isp_isif",
>> +.flags = IORESOURCE_MEM,
>> +}, {
>> +.start = 0x52011200,
>> +.end = 0x52011200 + 0x080,
>> +.name = "isp_ipipeif",
>> +.flags = IORESOURCE_MEM,
>> +}
>> +};
>> +
>> +static struct i2c_board_info panda_camera_i2c_device = {
>> +I2C_BOARD_INFO("smia", 0x10),
>> +};
>> +
>> +static struct iss_subdev_i2c_board_info panda_camera_subdevs[] = {
>> +{
>> +.board_info = _camera_i2c_device,
>> +.i2c_adapter_id = 3,
>> +},
>> +};
>> +
>> +static struct iss_v4l2_subdevs_group iss_subdevs[] = {
>> +{
>> +.subdevs = panda_camera_subdevs,
>> +.interface = ISS_INTERFACE_CSI2A_PHY1,
>> +.bus = {
>> +.csi2 = {
>> +.lanecfg = {
>> +.clk = {
>> +.pol = 0,
>> +.pos = 2,
>> +},
>> +.data[0] = {
>> +.pol = 0,
>> +.pos = 1,
>> +},
>> +.data[1] = {
>> +.pol = 0,
>> +.pos = 3,
>> +},
>> +},
>> +} },
>> +},
>> +{ /* sentinel */ },
>> +};
>> +
>> +static struct iss_platform_data iss_pdata = {
>> +.subdevs = iss_subdevs,
>> +};
>> +
>> +static struct platform_device omap4iss_device = {
>> +.name   = "omap4iss",
>> +.id = -1,
>> +.dev = {
>> +.platform_data = _pdata,
>> +},
>> +.num_resources  = ARRAY_SIZE(panda_iss_resource),
>> +.resource   = panda_iss_resource,
>> +};
>> +
>> +static void __init omap4_panda_legacy_init(void)
>> +{
>> +platform_device_register(_device);
>> +}
>> +
>> +#endif /* CONFIG_ARCH_OMAP4 */
>> +
>>  #if defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5)
>>  static struct iommu_platform_data omap4_iommu_pdata = {
>>  .reset_name = "mmu_cache",
>> @@ -539,6 +659,9 @@ static struct pdata_init pdata_quirks[] __initdata = {
>>  #ifdef CONFIG_SOC_TI81XX
>>  { "hp,t410", t410_abort_init, },
>>  #endif
>> +#ifdef CONFIG_ARCH_OMAP4
>> +{ "ti,omap4-panda", omap4_panda_legacy_init, },
>> +#endif
>>  #ifdef CONFIG_SOC_OMAP5
>>  { "ti,omap5-uevm", omap5_uevm_legacy_init, },
>>  #endif
>>
>> diff --git a/drivers/staging/media/omap4iss/iss.c
>> b/drivers/staging/media/omap4iss/iss.c index 30b473cfb020..b528cacda17b
>> 100644
>> --- a/drivers/staging/media/omap4iss/iss.c
>> +++ b/drivers/staging/media/omap4iss/iss.c
>> @@ -1412,6 +1412,9 @@ static int iss_probe(struct platform_device *pdev)
>>  unsigned int i;
>>  int ret;
>>
>> +
>> +printk("%s: pdata=%p\n", __func__, pdata);
>> +
>>  if (!pdata)
>>  return -EINVAL;
>>
>> @@ -1437,24 +1440,33 @@ static int iss_probe(struct platform_device *pdev)
>>  iss->syscon = syscon_regmap_lookup_by_compatible("syscon");
>>  if (IS_ERR(iss->syscon)) {
>>  ret = PTR_ERR(iss->syscon);
>> +dev_err(iss->dev, "Unable to find syscon");
>>  goto error;
>>  }
>>
>>  /* Clocks */
>>  ret = iss_map_mem_resource(pdev, iss, OMAP4_ISS_MEM_TOP);
>> -if (ret < 0)
>> +if (ret < 0) {
>> +dev_err(iss->dev, "Unable to map memory resource\n");
>>  goto error;
>> +}
>>
>>  ret = iss_get_clocks(iss);
>> -if (ret < 0)
>> +if (ret < 0) {
>> +dev_err(iss->dev, "Unable to get clocks\n");
>>  goto error;
>> +}
>>
>> -if (!omap4iss_get(iss))
>> +if (!omap4iss_get(iss)) {
>> +dev_err(iss->dev, "Failed to acquire ISS resource\n");
>>  goto error;
>> +}
>>
>>  ret = iss_reset(iss);
>> -if (ret < 0)
>> +if (ret < 0) {
>> +dev_err(iss->dev, "Unable to reset ISS\n");
>>  goto error_iss;
>> +}
>>
>>  iss->revision = iss_reg_read(iss, OMAP4_ISS_MEM_TOP, ISS_HL_REVISION);
>>  dev_info(iss->dev, "Revision %08x found\n", iss->revision);
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 2/3] wlcore/wl12xx: spi: add device tree support

2015-12-24 Thread Javier Martinez Canillas
Hello Uri,

On Thu, Dec 24, 2015 at 12:35 PM, Uri Mashiach
 wrote:
> Add DT support for the wl1271 SPI WiFi.
>
> Add documentation file for the wl1271 SPI WiFi.
>
> Signed-off-by: Uri Mashiach 
> Acked-by: Igor Grinberg 
> ---
> v1 -> v2: update interrupt documentation.
>   replace interrupts and interrupt-parent with interrupts-extended.
>   IRQ parameters retrieved from spi_device instead of DT.
>   remove redundant #ifdef CONFIG_OF
>
>  .../bindings/net/wireless/ti,wlcore,spi.txt| 34 +
>  drivers/net/wireless/ti/wlcore/spi.c   | 55 
> --
>  2 files changed, 85 insertions(+), 4 deletions(-)
>  create mode 100644 
> Documentation/devicetree/bindings/net/wireless/ti,wlcore,spi.txt
>
> diff --git a/Documentation/devicetree/bindings/net/wireless/ti,wlcore,spi.txt 
> b/Documentation/devicetree/bindings/net/wireless/ti,wlcore,spi.txt
> new file mode 100644
> index 000..502c27e
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/net/wireless/ti,wlcore,spi.txt
> @@ -0,0 +1,34 @@
> +* Texas Instruments wl1271 wireless lan controller
> +
> +The wl1271 chip can be connected via SPI or via SDIO. This
> +document describes the binding for the SPI connected chip.
> +
> +Required properties:
> +- compatible :  Should be "ti,wl1271"
> +- reg : Chip select address of device
> +- spi-max-frequency :   Maximum SPI clocking speed of device in Hz
> +- ref-clock-frequency : Reference clock frequency
> +- interrupts-extended : Should contain parameters for 1 interrupt line.
> +Interrupt parameters: parent, line number, type.
> +- vwlan-supply :Point the node of the regulator that powers/enable 
> the wl1271 chip
> +
> +Optional properties:
> +- clock-xtal :  boolean, clock is generated from XTAL
> +
> +- Please consult Documentation/devicetree/bindings/spi/spi-bus.txt
> +  for optional SPI connection related properties,
> +
> +Examples:
> +
> + {
> +   wl1271@1 {
> +   compatible = "ti,wl1271";
> +
> +   reg = <1>;
> +   spi-max-frequency = <4800>;
> +   clock-xtal;
> +   ref-clock-frequency = <3840>;
> +   interrupts-extended = < 8 IRQ_TYPE_LEVEL_HIGH>;
> +   vwlan-supply = <_fixed>;
> +   };
> +};
> diff --git a/drivers/net/wireless/ti/wlcore/spi.c 
> b/drivers/net/wireless/ti/wlcore/spi.c
> index d3a4bcb..e9e8d54 100644
> --- a/drivers/net/wireless/ti/wlcore/spi.c
> +++ b/drivers/net/wireless/ti/wlcore/spi.c
> @@ -30,6 +30,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  #include 
>
>  #include "wlcore.h"
> @@ -357,6 +358,46 @@ static struct wl1271_if_operations spi_ops = {
> .set_block_size = NULL,
>  };
>
> +#ifdef CONFIG_OF
> +static const struct of_device_id wlcore_spi_of_match_table[] = {
> +   { .compatible = "ti,wl1271" },
> +   { }
> +};

Could you please add a MODULE_DEVICE_TABLE(of, wlcore_spi_of_match_table) here?

> +
> +/**
> + * wlcore_probe_of - DT node parsing.
> + * @spi: SPI slave device parameters.
> + * @res: resource parameters.
> + * @glue: wl12xx SPI bus to slave device glue parameters.
> + * @pdev_data: wlcore device parameters
> + */
> +static int wlcore_probe_of(struct spi_device *spi, struct wl12xx_spi_glue 
> *glue,
> +  struct wlcore_platdev_data *pdev_data)
> +{
> +   struct device_node *dt_node = spi->dev.of_node;
> +   int ret;
> +
> +   if (of_find_property(dt_node, "clock-xtal", NULL))
> +   pdev_data->ref_clock_xtal = true;
> +
> +   ret = of_property_read_u32(dt_node, "ref-clock-frequency",
> +  _data->ref_clock_freq);
> +   if (IS_ERR_VALUE(ret)) {
> +   dev_err(glue->dev,
> +   "can't get reference clock frequency (%d)\n", ret);
> +   return ret;
> +   }
> +
> +   return 0;
> +}
> +#else /* CONFIG_OF */
> +static int wlcore_probe_of(struct spi_device *spi, struct wl12xx_spi_glue 
> *glue,
> +  struct wlcore_platdev_data *pdev_data)
> +{
> +   return -ENODATA;
> +}
> +#endif /* CONFIG_OF */
> +

I don't understand what's the point of making the driver to be built
with !CONFIG_OF if the probe function is going to fail anyways. If
this driver really need then is better to remove the ifdefery and make
the Kconfig symbol to depend on OF.

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 3/3] wlcore/wl12xx: spi: add wifi support to cm-t335

2015-12-24 Thread Javier Martinez Canillas
Hello Uri,

On Thu, Dec 24, 2015 at 12:35 PM, Uri Mashiach
 wrote:
> Device tree modifications:
> - Pinmux for SPI0 and WiFi GPIOs.
> - SPI0 node with wlcore as a child node.
>
> Cc: Tony Lindgren 
> Signed-off-by: Uri Mashiach 
> Acked-by: Igor Grinberg 
> ---
> v1 -> v2: replace interrupts and interrupt-parent with interrupts-extended.
>
>  arch/arm/boot/dts/am335x-cm-t335.dts | 57 
> +++-
>  1 file changed, 56 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/boot/dts/am335x-cm-t335.dts 
> b/arch/arm/boot/dts/am335x-cm-t335.dts
> index 42e9b66..31f8371 100644
> --- a/arch/arm/boot/dts/am335x-cm-t335.dts
> +++ b/arch/arm/boot/dts/am335x-cm-t335.dts
> @@ -11,6 +11,7 @@
>  /dts-v1/;
>
>  #include "am33xx.dtsi"
> +#include 
>
>  / {
> model = "CompuLab CM-T335";
> @@ -40,6 +41,15 @@
> regulator-max-microvolt = <330>;
> };
>
> +   /* Regulator for WiFi */
> +   vwlan_fixed: fixedregulator@2 {
> +   compatible = "regulator-fixed";
> +   regulator-name = "vwlan_fixed";
> +   gpio = < 20 GPIO_ACTIVE_HIGH>; /* gpio0_20 */
> +   enable-active-high;
> +   regulator-boot-off;
> +   };
> +
> backlight {
> compatible = "pwm-backlight";
> pwms = < 0 5 0>;
> @@ -50,7 +60,10 @@
>
>  _pinmux {
> pinctrl-names = "default";
> -   pinctrl-0 = <_pins>;
> +   pinctrl-0 = <
> + _pins
> + _pins
> +   >;

The pinctrl lines should be in the device node that needs the pin
muxing (unless there isn't a device node) so I think is better if you
mofe the pinctrl-0 = <_pins> to the wlcore dev node.

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 5/6] ARM: LG Optimus Black (P970) codename sniper support, with basic features

2015-12-23 Thread Javier Martinez Canillas
Hello Paul,

[snip]

> +
> +_pmx_core {
> +   pinctrl-names = "default";
> +
> +   uart3_pins: pinmux_uart3_pins {
> +   pinctrl-single,pins = <
> +   0x16e (PIN_INPUT | MUX_MODE0)   /* 
> uart3_rx_irrx */
> +   0x170 (PIN_OUTPUT | MUX_MODE0)  /* 
> uart3_tx_irtx */
> +   >;

Could you please use the IOPAD mux macros from
include/dt-bindings/pinctrl/omap.h instead?

We just did a massive cleanup on the OMAP DTS to use them instead of
an offset from the padconf registers.

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: OMAP display kconfig options changing

2015-12-22 Thread Javier Martinez Canillas
Hello Tomi,

On Fri, Dec 18, 2015 at 1:14 PM, Tomi Valkeinen  wrote:
> On 18/12/15 18:05, Tony Lindgren wrote:
>
>>> Are you referring to Kconfig options? Or userspace?
>>
>> Well sounds like both need updating :)
>
> Depends... For simple fb apps, omapdrm works fine, and X with the
> standard fbdev driver should work with omapdrm too.
>

It does, I just tested omapdrm + X with the fbdev DDX and I was able
to start X and the xfce4 wm.

I just needed to enable DRM_FBDEV_EMULATION in omap2plus_defconfig to
have fbdev emulation over DRM.

> But if the userspace is using any omapfb specific apps, then yes, update
> is necessary.
>

Yes but these people should have a migration plan anyways since omapfb
(and fbdev in general) is going away right?

>>> But no, I don't have links to either.
>>
>> So change the Kconfig options and then deal with the flood
>> of angry emails? :) I think we need instructions..
>
> Ok. I think it's then best that I just update the defconfig to enable
> omapfb as modules, as it is currently.
>

In that case I think you should squash the defconfig changes with
commit ("70ba4e05531f omapfb/displays: change CONFIG_DISPLAY_* to
CONFIG_FB_OMAP2_*") to maintain bisectability.

Alternatively, the current panel and encoders Kconfig symbols could
remain for omapfb since that's the current ones used in
omap2plus_defconfig where omapfb is the default and have new Kconfig
symbols for omapdrm (i.e: CONFIG_DRM_OMAP_ENCODER_TFP410).

> We can look again at changing the default to omapdrm after we've tested
> it on OMAP2 too, and we have a better idea what the user needs to take
> care of.
>
>  Tomi
>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] OMAPDSS: fix omapfb build error due missing feat functions declaration

2015-12-22 Thread Javier Martinez Canillas
Hello Tomi,

On 12/22/2015 04:50 AM, Tomi Valkeinen wrote:
> Hi Javier,
> 
> On 21/12/15 20:26, Javier Martinez Canillas wrote:
>> The omapfb is failing to build in -next due missing declarations for
>> dss_feat_get_supported_displays() and dss_feat_get_supported_outputs():
>>
>>  CC [M]  drivers/video/fbdev/omap2//omapfb/dss/dss.o
>> drivers/video/fbdev/omap2//omapfb/dss/dss.c: In function 'dss_save_context':
>> drivers/video/fbdev/omap2//omapfb/dss/dss.c:144:2: error: implicit 
>> declaration of function 'dss_feat_get_supported_displays' 
>> [-Werror=implicit-function-declaration]
>>
>> Add the declaration for these functions in the dss_features.h header
>> file to fix this compile error.
>>
>> Also, remove the functions export since are not used outside the driver.
> 
> Thanks!
>

You are welcome.
 
> Yep, I messed that up. I thought I had tested it, but apparently I only
> tested the final for-next only for omapdrm, which does compile and work.
>

Yes, that's what I thought.
 
> omapdss.h is the the only file still shared between omapdrm and omapfb
> after the copy-omapdss-series (I'll work on omapdss.h later), and of
> course there was a change to omapdss.h which broke the build.
> 
> So I rebased the copy-omapdss-series on top of the rest of the omapdss
> patches, and updated the "omapfb: copy omapdss & displays for omapfb" to
> make a fresh copy of omapdss for omapfb. I think it's better to update
> the series, rather than applying fixes for already confusing series.
>

I completely agree, maintaining bisectability is important. As I mentioned
in my last email, I just posted in case you couldn't rework your branches
for whatever reason.
 
> I've pushed new version to my for-next branch.
>

Great, thanks!

>  Tomi
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] OMAPDSS: fix omapfb build error due missing feat functions declaration

2015-12-21 Thread Javier Martinez Canillas
The omapfb is failing to build in -next due missing declarations for
dss_feat_get_supported_displays() and dss_feat_get_supported_outputs():

 CC [M]  drivers/video/fbdev/omap2//omapfb/dss/dss.o
drivers/video/fbdev/omap2//omapfb/dss/dss.c: In function 'dss_save_context':
drivers/video/fbdev/omap2//omapfb/dss/dss.c:144:2: error: implicit declaration 
of function 'dss_feat_get_supported_displays' 
[-Werror=implicit-function-declaration]

Add the declaration for these functions in the dss_features.h header
file to fix this compile error.

Also, remove the functions export since are not used outside the driver.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

Hello Tomi,

This seems to be caused by a wrong order in which some commits from
the omapdss tree [0] were merged, or rather a wrong base used for
the dss-drm-merge (4.4.0-rc4) and the for-next (4.4.0-rc5) branches.

The problem is that commit 2ea164a9af9c ("drm/omap: move omapdss &
displays under omapdrm") moves the dss_features.h header from the
drivers/video/fbdev/omap2/dss/ dir to drivers/gpu/drm/omapdrm}/dss.

And then commit 8b987a111b1a ("omapfb: copy omapdss & displays for
omapfb" copies the hader from the omapdrm dir to the omapfb one.

Now, since commit 66c78ddd7a2e ("OMAPDSS: make a two dss feat funcs
internal to omapdss") is the one that moves the function declaration
from the public include/video/omapdss.h header to the internal one,
this means that git will be smart enough to identify that the header
that was drivers/video/fbdev/omap2/dss/dss_features.h now is the one
in the omapdrm directory but that means that the omapfb files won't
get the changes since the move & copy happened before.

This happens AFAIU because dss-drm-merge having an older base so the
patches in for-next are rebased on top of dss-drm-merge when merging.

The issue can easily be avoided by first merging the patch that does
the feat funcs declaration move and then merging the ones that do the
per driver omapdss refactoring.

But I'm posting this patch anyways in case you can't redo your branches
and need a fix to apply on top of your current for-next.

[0]: git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux.git

Best regards,
Javier

 drivers/video/fbdev/omap2/omapfb/dss/dss_features.c | 2 --
 drivers/video/fbdev/omap2/omapfb/dss/dss_features.h | 3 +++
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/video/fbdev/omap2/omapfb/dss/dss_features.c 
b/drivers/video/fbdev/omap2/omapfb/dss/dss_features.c
index b0b6dfd657bf..a2e26b8d6ded 100644
--- a/drivers/video/fbdev/omap2/omapfb/dss/dss_features.c
+++ b/drivers/video/fbdev/omap2/omapfb/dss/dss_features.c
@@ -844,13 +844,11 @@ enum omap_display_type 
dss_feat_get_supported_displays(enum omap_channel channel
 {
return omap_current_dss_features->supported_displays[channel];
 }
-EXPORT_SYMBOL(dss_feat_get_supported_displays);
 
 enum omap_dss_output_id dss_feat_get_supported_outputs(enum omap_channel 
channel)
 {
return omap_current_dss_features->supported_outputs[channel];
 }
-EXPORT_SYMBOL(dss_feat_get_supported_outputs);
 
 enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane plane)
 {
diff --git a/drivers/video/fbdev/omap2/omapfb/dss/dss_features.h 
b/drivers/video/fbdev/omap2/omapfb/dss/dss_features.h
index 100f7a2d0638..4474ebff8607 100644
--- a/drivers/video/fbdev/omap2/omapfb/dss/dss_features.h
+++ b/drivers/video/fbdev/omap2/omapfb/dss/dss_features.h
@@ -102,4 +102,7 @@ bool dss_feat_rotation_type_supported(enum 
omap_dss_rotation_type rot_type);
 bool dss_has_feature(enum dss_feat_id id);
 void dss_feat_get_reg_field(enum dss_feat_reg_field id, u8 *start, u8 *end);
 void dss_features_init(enum omapdss_version version);
+
+enum omap_display_type dss_feat_get_supported_displays(enum omap_channel 
channel);
+enum omap_dss_output_id dss_feat_get_supported_outputs(enum omap_channel 
channel);
 #endif
-- 
2.4.3

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


Re: [PATCH] mmc: pwrseq_simple: Fix regression with optional GPIOs

2015-12-07 Thread Javier Martinez Canillas
Hello Tony,

On 12/07/2015 09:32 PM, Tony Lindgren wrote:
> * Ulf Hansson <ulf.hans...@linaro.org> [151207 16:20]:
>> +Linus
>>
>> On 7 December 2015 at 23:54, Tony Lindgren <t...@atomide.com> wrote:
>>> Commit ce037275861e ("mmc: pwrseq_simple: use GPIO descriptors array API")
>>> changed the handling MMC power sequence so GPIOs no longer are optional.
>>>
>>> This broke SDIO WLAN at least for omap5 that can't yet use the reset GPIOs
>>> with pwrseq_simple as a wait is needed after enabling the SDIO device.
>>
>> Can you elaborate on this. Did it break omap5 or not? :-)
> 
> Yes it broke WLAN for omap5 that I just got fixed.. It only uses the clocks
> art of the pwrseq currently because of the delay needed.
> 
>> Also, I am interested to know more about the waiting period you need.
>> I assume that's because of the HW's characteristic?
> 
> At least TI wl12xx and Marvell 8787 need a delay after enabling the the WLAN.
> 
>> Why can't we have that being described in DT and then make
>> pwrseq_simple *wait* if needed?
> 
> We can, but I'm thinking that we might be better off adding support for
> regulators to pwrseq. Both TI wl12xx and Marvell 8787 get power from the
> battery, and probably have an integrated regulator.
> 
> Also, the delay and the power up sequencey can be more complicated than what
> we currently support. In the 8787 case, pdn pin needs to be asserted for 300ms
> after power pins are stable and while reset is held high.
> 
>>> Let's fix the problem by allocating the GPIO values array during init
>>> depending on the optional GPIOs found.
>>
>> Certainly it shall be optional! I wonder how I could let that patch
>> slip through, my bad!
>

I also wonder how I missed that in my patch, sorry for the mess :(
 
> OK good to hear :)
> 
>> Thanks for fixing this!
>

+1

> No problem, thanks,
> 
> Tony
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/2] ARM: dts: Use MMC pwrseq instead regulators for IGEP WiFi init

2015-12-03 Thread Javier Martinez Canillas
Hello Tony,

On 12/03/2015 03:16 PM, Tony Lindgren wrote:
> * Javier Martinez Canillas <jav...@osg.samsung.com> [151203 10:03]:
>> Hello,
>>
>> This series converts the IGEPv2 (IGEP0020) and IGEP COM Module (IGEP0030)
>> Device Tree to use the MMC power sequence provider to initialize the SDIO
>> WiFi chip instead of using fake fixed regulators to just toggle the Reset
>> and Power pins in the chip.
>>
>> The patches were tested on an DM3730 IGEPv2 board but the IGEP COM Module
>> is the same with regard to the SDIO WiFi so it should be safe to land too.
>>
>> The IGEPv2 Rev.F and the IGEP COM Module Rev.G DTS were not converted due
>> using a different WiFi chip (wlcore instead of libertas) than the one in
>> the board I've access to test so I preferred to leave those untouched.
> 
> Do you have some solution for the start-up latency issue?
>

No, I don't and that's one of the reasons why I didn't want to touch the
DTS that have the wlcore chip.

The omap3-igep0020-rev-f.dts and omap3-igep0030-rev-g.dts don't have a
startup-delay-us property in the regulator for the WLAN_EN pin as is
the case for the IGEPv5 DTS but I don't know if those DTS are just wrong.

The DTS for the igep0020 and igep0030 that have the libertas chip,
did have a startup-delay-us for the WIFI_PDN but using the GPIOs
for RESET_N_W and WIFI_PDN in the mmc-pwrseq-simple reset-gpios is
enough to make the SDIO chip reset, be enumerated and WiFi to work
correctly so I don't know if that is really needed or is just a bad
description in the DTS.

Since is working for the boards with the libertas chip, I preferred
to remove the DTS hack but left the boards with wlcore chip since
you said the startup-delay-us is needed there (but probably we should
add to the regulators in the boards that don't have it then).

> Regards,
> 
> Tony
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 2/2] ARM: dts: omap3-igep0030: Use MMC pwrseq to init SDIO WiFi

2015-12-03 Thread Javier Martinez Canillas
When the WiFi support was added to the IGEP0030 board, the MMC subsystem
did not provide a mechanism to define power sequence providers. So a DT
hack was used to toggle the WiFi chip reset and power down pins by using
fake fixed regulators whose enable GPIO was the GPIOs connected to these
pins.

But now the simple MMC power sequence provider can be used for this and
the workaround removed.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/omap3-igep0030.dts | 24 
 1 file changed, 8 insertions(+), 16 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-igep0030.dts 
b/arch/arm/boot/dts/omap3-igep0030.dts
index 468608dab30a..55b0cc4f5ee5 100644
--- a/arch/arm/boot/dts/omap3-igep0030.dts
+++ b/arch/arm/boot/dts/omap3-igep0030.dts
@@ -15,25 +15,17 @@
model = "IGEP COM MODULE Rev. E (TI OMAP AM/DM37x)";
compatible = "isee,omap3-igep0030", "ti,omap36xx", "ti,omap3";
 
-   /* Regulator to trigger the WIFI_PDN signal of the Wifi module */
-   lbee1usjyc_pdn: lbee1usjyc_pdn {
+   vmmcsdio_fixed: fixedregulator-mmcsdio {
compatible = "regulator-fixed";
-   regulator-name = "regulator-lbee1usjyc-pdn";
+   regulator-name = "vmmcsdio_fixed";
regulator-min-microvolt = <330>;
regulator-max-microvolt = <330>;
-   gpio = < 10 GPIO_ACTIVE_HIGH>;/* gpio_138 - WIFI_PDN 
*/
-   startup-delay-us = <1>;
-   enable-active-high;
};
 
-   /* Regulator to trigger the RESET_N_W signal of the Wifi module */
-   lbee1usjyc_reset_n_w: lbee1usjyc_reset_n_w {
-   compatible = "regulator-fixed";
-   regulator-name = "regulator-lbee1usjyc-reset-n-w";
-   regulator-min-microvolt = <330>;
-   regulator-max-microvolt = <330>;
-   gpio = < 11 GPIO_ACTIVE_HIGH>;/* gpio_139 - RESET_N_W 
*/
-   enable-active-high;
+   mmc2_pwrseq: mmc2_pwrseq {
+   compatible = "mmc-pwrseq-simple";
+   reset-gpios = < 11 GPIO_ACTIVE_LOW>,  /* gpio_139 - 
RESET_N_W */
+ < 10 GPIO_ACTIVE_LOW>;  /* gpio_138 - 
WIFI_PDN */
};
 };
 
@@ -62,8 +54,8 @@
  {
pinctrl-names = "default";
pinctrl-0 = <_pins _pins>;
-   vmmc-supply = <_pdn>;
-   vmmc_aux-supply = <_reset_n_w>;
+   vmmc-supply = <_fixed>;
+   mmc-pwrseq = <_pwrseq>;
bus-width = <4>;
non-removable;
 };
-- 
2.4.3

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


[PATCH 0/2] ARM: dts: Use MMC pwrseq instead regulators for IGEP WiFi init

2015-12-03 Thread Javier Martinez Canillas
Hello,

This series converts the IGEPv2 (IGEP0020) and IGEP COM Module (IGEP0030)
Device Tree to use the MMC power sequence provider to initialize the SDIO
WiFi chip instead of using fake fixed regulators to just toggle the Reset
and Power pins in the chip.

The patches were tested on an DM3730 IGEPv2 board but the IGEP COM Module
is the same with regard to the SDIO WiFi so it should be safe to land too.

The IGEPv2 Rev.F and the IGEP COM Module Rev.G DTS were not converted due
using a different WiFi chip (wlcore instead of libertas) than the one in
the board I've access to test so I preferred to leave those untouched.

Best regards,
Javier


Javier Martinez Canillas (2):
  ARM: dts: omap3-igep0020: Use MMC pwrseq to init SDIO WiFi
  ARM: dts: omap3-igep0030: Use MMC pwrseq to init SDIO WiFi

 arch/arm/boot/dts/omap3-igep0020.dts | 24 
 arch/arm/boot/dts/omap3-igep0030.dts | 24 
 2 files changed, 16 insertions(+), 32 deletions(-)

-- 
2.4.3

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


[PATCH 1/2] ARM: dts: omap3-igep0020: Use MMC pwrseq to init SDIO WiFi

2015-12-03 Thread Javier Martinez Canillas
When the WiFi support was added to the IGEP0020 board, the MMC subsystem
did not provide a mechanism to define power sequence providers. So a DT
hack was used to toggle the WiFi chip reset and power down pins by using
fake fixed regulators whose enable GPIO was the GPIOs connected to these
pins.

But now the simple MMC power sequence provider can be used for this and
the workaround removed.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-igep0020.dts | 24 
 1 file changed, 8 insertions(+), 16 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-igep0020.dts 
b/arch/arm/boot/dts/omap3-igep0020.dts
index 3835e1569c29..33d6b4ead092 100644
--- a/arch/arm/boot/dts/omap3-igep0020.dts
+++ b/arch/arm/boot/dts/omap3-igep0020.dts
@@ -15,25 +15,17 @@
model = "IGEPv2 Rev. C (TI OMAP AM/DM37x)";
compatible = "isee,omap3-igep0020", "ti,omap36xx", "ti,omap3";
 
-   /* Regulator to trigger the WIFI_PDN signal of the Wifi module */
-   lbee1usjyc_pdn: lbee1usjyc_pdn {
+   vmmcsdio_fixed: fixedregulator-mmcsdio {
compatible = "regulator-fixed";
-   regulator-name = "regulator-lbee1usjyc-pdn";
+   regulator-name = "vmmcsdio_fixed";
regulator-min-microvolt = <330>;
regulator-max-microvolt = <330>;
-   gpio = < 10 GPIO_ACTIVE_HIGH>;/* gpio_138 - WIFI_PDN 
*/
-   startup-delay-us = <1>;
-   enable-active-high;
};
 
-   /* Regulator to trigger the RESET_N_W signal of the Wifi module */
-   lbee1usjyc_reset_n_w: lbee1usjyc_reset_n_w {
-   compatible = "regulator-fixed";
-   regulator-name = "regulator-lbee1usjyc-reset-n-w";
-   regulator-min-microvolt = <330>;
-   regulator-max-microvolt = <330>;
-   gpio = < 11 GPIO_ACTIVE_HIGH>;/* gpio_139 - RESET_N_W 
*/
-   enable-active-high;
+   mmc2_pwrseq: mmc2_pwrseq {
+   compatible = "mmc-pwrseq-simple";
+   reset-gpios = < 11 GPIO_ACTIVE_LOW>,  /* gpio_139 - 
RESET_N_W */
+ < 10 GPIO_ACTIVE_LOW>;  /* gpio_138 - 
WIFI_PDN */
};
 };
 
@@ -51,8 +43,8 @@
  {
pinctrl-names = "default";
pinctrl-0 = <_pins _pins>;
-   vmmc-supply = <_pdn>;
-   vmmc_aux-supply = <_reset_n_w>;
+   vmmc-supply = <_fixed>;
+   mmc-pwrseq = <_pwrseq>;
bus-width = <4>;
non-removable;
 };
-- 
2.4.3

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


Re: [PATCH 01/39] pinctrl: Move am4372 and dra7 macros to the the SoC header files

2015-11-17 Thread Javier Martinez Canillas
Hello Linus,

On 11/17/2015 10:47 AM, Linus Walleij wrote:
> On Fri, Nov 13, 2015 at 5:53 AM, Javier Martinez Canillas
> <jav...@osg.samsung.com> wrote:
> 
>> The  header file defines a set of macros
>> for different SoCs families that falls under the OMAP sub-arch, that
>> allow to define the padconf register physical address instead of the
>> register offset from the padconf base.
>>
>> But the am43xx and dra7xx SoCs families have their own pinctrl header
>> file so the DTS using these SoCs aren't able to use the AM4372_IOPAD()
>> and DRA7XX_CORE_IOPAD() macros since  is
>> not included.
>>
>> Move the macros to the correct header files so can be used by the DTS.
>>
>> Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
> 
> I need Tony's ACK on this.
>

OK, I believe he was waiting for yours to pick the series though ;)
 
> Yours,
> Linus Walleij
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 38/39] ARM: dts: omap5-cm-t54: Use OMAP5_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap5-cm-t54.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap5-cm-t54.dts 
b/arch/arm/boot/dts/omap5-cm-t54.dts
index 3774b37be6c8..0c03dca9ea04 100644
--- a/arch/arm/boot/dts/omap5-cm-t54.dts
+++ b/arch/arm/boot/dts/omap5-cm-t54.dts
@@ -175,7 +175,7 @@
 
ads7846_pins: pinmux_ads7846_pins {
pinctrl-single,pins = <
-   0x02 (PIN_INPUT_PULLDOWN | MUX_MODE6)  /* 
llib_wakereqin.gpio1_wk15 */
+   OMAP5_IOPAD(0x0042, PIN_INPUT_PULLDOWN | MUX_MODE6)  /* 
llib_wakereqin.gpio1_wk15 */
>;
};
 };
-- 
2.4.3

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


[PATCH 37/39] ARM: dts: omap5-board-common: Use OMAP5_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap5-board-common.dtsi | 94 +++
 1 file changed, 47 insertions(+), 47 deletions(-)

diff --git a/arch/arm/boot/dts/omap5-board-common.dtsi 
b/arch/arm/boot/dts/omap5-board-common.dtsi
index 5cf76a1c5c75..888412c63f97 100644
--- a/arch/arm/boot/dts/omap5-board-common.dtsi
+++ b/arch/arm/boot/dts/omap5-board-common.dtsi
@@ -139,60 +139,60 @@
 
twl6040_pins: pinmux_twl6040_pins {
pinctrl-single,pins = <
-   0x17e (PIN_OUTPUT | MUX_MODE6)  /* 
mcspi1_somi.gpio5_141 */
+   OMAP5_IOPAD(0x1be, PIN_OUTPUT | MUX_MODE6)  /* 
mcspi1_somi.gpio5_141 */
>;
};
 
mcpdm_pins: pinmux_mcpdm_pins {
pinctrl-single,pins = <
-   0x142 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
abe_clks.abe_clks */
-   0x15c (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
abemcpdm_ul_data.abemcpdm_ul_data */
-   0x15e (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
abemcpdm_dl_data.abemcpdm_dl_data */
-   0x160 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
abemcpdm_frame.abemcpdm_frame */
-   0x162 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
abemcpdm_lb_clk.abemcpdm_lb_clk */
+   OMAP5_IOPAD(0x182, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_clks.abe_clks */
+   OMAP5_IOPAD(0x19c, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abemcpdm_ul_data.abemcpdm_ul_data */
+   OMAP5_IOPAD(0x19e, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abemcpdm_dl_data.abemcpdm_dl_data */
+   OMAP5_IOPAD(0x1a0, PIN_INPUT_PULLUP | MUX_MODE0)
/* abemcpdm_frame.abemcpdm_frame */
+   OMAP5_IOPAD(0x1a2, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abemcpdm_lb_clk.abemcpdm_lb_clk */
>;
};
 
mcbsp1_pins: pinmux_mcbsp1_pins {
pinctrl-single,pins = <
-   0x14c (PIN_INPUT | MUX_MODE1)   /* 
abedmic_clk2.abemcbsp1_fsx */
-   0x14e (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
abedmic_clk3.abemcbsp1_dx */
-   0x150 (PIN_INPUT | MUX_MODE1)   /* 
abeslimbus1_clock.abemcbsp1_clkx */
-   0x152 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
abeslimbus1_data.abemcbsp1_dr */
+   OMAP5_IOPAD(0x18c, PIN_INPUT | MUX_MODE1)   
/* abedmic_clk2.abemcbsp1_fsx */
+   OMAP5_IOPAD(0x18e, PIN_OUTPUT_PULLDOWN | MUX_MODE1) 
/* abedmic_clk3.abemcbsp1_dx */
+   OMAP5_IOPAD(0x190, PIN_INPUT | MUX_MODE1)   
/* abeslimbus1_clock.abemcbsp1_clkx */
+   OMAP5_IOPAD(0x192, PIN_INPUT_PULLDOWN | MUX_MODE1)  
/* abeslimbus1_data.abemcbsp1_dr */
>;
};
 
mcbsp2_pins: pinmux_mcbsp2_pins {
pinctrl-single,pins = <
-   0x154 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
abemcbsp2_dr.abemcbsp2_dr */
-   0x156 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
abemcbsp2_dx.abemcbsp2_dx */
-   0x158 (PIN_INPUT | MUX_MODE0)   /* 
abemcbsp2_fsx.abemcbsp2_fsx */
-   0x15a (PIN_INPUT | MUX_MODE0)   /* 
abemcbsp2_clkx.abemcbsp2_clkx */
+   OMAP5_IOPAD(0x194, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abemcbsp2_dr.abemcbsp2_dr */
+   OMAP5_IOPAD(0x196, PIN_OUTPUT_PULLDOWN | MUX_MODE0) 
/* abemcbsp2_dx.abemcbsp2_dx */
+   OMAP5_IOPAD(0x198, PIN_INPUT | MUX_MODE0)   
/* abemcbsp2_fsx.abemcbsp2_fsx */
+   OMAP5_IOPAD(0x19a, PIN_INPUT | MUX_MODE0)   
/* abemcbsp2_clkx.abemcbsp2_clkx */
>;
};
 
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
-   0x1b2 (PIN_INPUT_PULLUP | MUX_MODE0)/* i2c1_scl */
-   0x1b4 (PIN_INPUT_PULLUP | MUX_MODE0)/* i2c1_sda */
+   OMAP5_IOPAD(0x1f2, PIN_INPUT_PULLUP | MUX_MODE0)
/* i2c1_scl */
+   OMAP5_IOPAD(0x1f4, PIN_INPUT_PULLUP | MUX_MODE0)
/* i2c1_sda */
>;
};
 
mcspi2_pins: pinmux_mcspi2_pins {
pinctrl-single,pins = <
-   0xbc (PIN_INPUT | MUX_MODE0)/*  mcspi2_clk 
*/
-   0xbe (PIN_INPUT | MUX_MODE0)/*  mcspi2_simo 
*/
-   0xc0 (PIN_INPUT_PULLUP | MUX_MODE0) /*  mcspi2_somi 
*/
-

[PATCH 39/39] ARM: dts: omap5-uevm.dts: Use OMAP5_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/omap5-uevm.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/omap5-uevm.dts b/arch/arm/boot/dts/omap5-uevm.dts
index 05b1c1ebded8..60b3fbb3bf07 100644
--- a/arch/arm/boot/dts/omap5-uevm.dts
+++ b/arch/arm/boot/dts/omap5-uevm.dts
@@ -40,8 +40,8 @@
 _pmx_core {
i2c5_pins: pinmux_i2c5_pins {
pinctrl-single,pins = <
-   0x186 (PIN_INPUT | MUX_MODE0)   /* i2c5_scl */
-   0x188 (PIN_INPUT | MUX_MODE0)   /* i2c5_sda */
+   OMAP5_IOPAD(0x1c6, PIN_INPUT | MUX_MODE0)   
/* i2c5_scl */
+   OMAP5_IOPAD(0x1c8, PIN_INPUT | MUX_MODE0)   
/* i2c5_sda */
>;
};
 };
-- 
2.4.3

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


[PATCH 35/39] ARM: dts: omap4-sdp-es23plus: Use OMAP4_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap4-sdp-es23plus.dts | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-sdp-es23plus.dts 
b/arch/arm/boot/dts/omap4-sdp-es23plus.dts
index aad5dda0f469..b4d19a7ae393 100644
--- a/arch/arm/boot/dts/omap4-sdp-es23plus.dts
+++ b/arch/arm/boot/dts/omap4-sdp-es23plus.dts
@@ -10,8 +10,8 @@
 /* SDP boards with 4430 ES2.3+ or 4460 have external pullups on SCL & SDA */
 _hdmi_pins {
pinctrl-single,pins = <
-   0x5a (PIN_INPUT_PULLUP | MUX_MODE0) /* hdmi_cec.hdmi_cec */
-   0x5c (PIN_INPUT | MUX_MODE0)/* hdmi_scl.hdmi_scl */
-   0x5e (PIN_INPUT | MUX_MODE0)/* hdmi_sda.hdmi_sda */
+   OMAP4_IOPAD(0x09a, PIN_INPUT_PULLUP | MUX_MODE0)/* 
hdmi_cec.hdmi_cec */
+   OMAP4_IOPAD(0x09c, PIN_INPUT | MUX_MODE0)   /* 
hdmi_scl.hdmi_scl */
+   OMAP4_IOPAD(0x09e, PIN_INPUT | MUX_MODE0)   /* 
hdmi_sda.hdmi_sda */
>;
 };
-- 
2.4.3

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


[PATCH 19/39] ARM: dts: am43x-epos-evm: Use AM4372_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am43x-epos-evm.dts | 246 +--
 1 file changed, 123 insertions(+), 123 deletions(-)

diff --git a/arch/arm/boot/dts/am43x-epos-evm.dts 
b/arch/arm/boot/dts/am43x-epos-evm.dts
index 47954ed990f8..746fd2b17958 100644
--- a/arch/arm/boot/dts/am43x-epos-evm.dts
+++ b/arch/arm/boot/dts/am43x-epos-evm.dts
@@ -144,228 +144,228 @@
cpsw_default: cpsw_default {
pinctrl-single,pins = <
/* Slave 1 */
-   0x10c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_crs.rmii1_crs */
-   0x110 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxerr.rmii1_rxerr */
-   0x114 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
mii1_txen.rmii1_txen */
-   0x118 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxdv.rmii1_rxdv */
-   0x124 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
mii1_txd1.rmii1_txd1 */
-   0x128 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
mii1_txd0.rmii1_txd0 */
-   0x13c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxd1.rmii1_rxd1 */
-   0x140 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxd0.rmii1_rxd0 */
-   0x144 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
rmii1_refclk.rmii1_refclk */
+   AM4372_IOPAD(0x90c, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mii1_crs.rmii1_crs */
+   AM4372_IOPAD(0x910, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mii1_rxerr.rmii1_rxerr */
+   AM4372_IOPAD(0x914, PIN_OUTPUT_PULLDOWN | 
MUX_MODE1)/* mii1_txen.rmii1_txen */
+   AM4372_IOPAD(0x918, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mii1_rxdv.rmii1_rxdv */
+   AM4372_IOPAD(0x924, PIN_OUTPUT_PULLDOWN | 
MUX_MODE1)/* mii1_txd1.rmii1_txd1 */
+   AM4372_IOPAD(0x928, PIN_OUTPUT_PULLDOWN | 
MUX_MODE1)/* mii1_txd0.rmii1_txd0 */
+   AM4372_IOPAD(0x93c, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mii1_rxd1.rmii1_rxd1 */
+   AM4372_IOPAD(0x940, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mii1_rxd0.rmii1_rxd0 */
+   AM4372_IOPAD(0x944, PIN_INPUT_PULLDOWN | 
MUX_MODE0) /* rmii1_refclk.rmii1_refclk */
>;
};
 
cpsw_sleep: cpsw_sleep {
pinctrl-single,pins = <
/* Slave 1 reset value */
-   0x10c (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x110 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x114 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x118 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x124 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x128 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x13c (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x140 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x144 (PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x90c, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x910, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x914, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x918, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x924, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x928, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x93c, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x940, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
+   AM4372_IOPAD(0x944, PIN_INPUT_PULLDOWN | 
MUX_MODE7)
>;
};
 
davinci_mdio_default: davinci_mdio_default {
pinctrl-single,pins = <
/* MDIO */
-   0x148 (PIN_INPUT_PULLUP | SLEWCTRL_FAST | 
MUX_MODE0)/* mdio_data.mdio_data */
-   0x14c (PIN_OUTPUT_PULLUP | MUX_MODE0)   
/* mdio_clk.mdio_clk */
+   AM4372_IOPAD(0x948, PIN_INPUT_PULLUP | 
SLEWCTRL_FAST | MUX_MODE0)   /* mdio_data.mdio_data */
+   AM4372_IOPAD(0x9

[PATCH 16/39] ARM: dts: am437x-gp-evm: Use AM4372_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am437x-gp-evm.dts | 380 ++--
 1 file changed, 190 insertions(+), 190 deletions(-)

diff --git a/arch/arm/boot/dts/am437x-gp-evm.dts 
b/arch/arm/boot/dts/am437x-gp-evm.dts
index d2450ab0a380..7f00e85eebed 100644
--- a/arch/arm/boot/dts/am437x-gp-evm.dts
+++ b/arch/arm/boot/dts/am437x-gp-evm.dts
@@ -154,138 +154,138 @@
 
i2c0_pins: i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE0)  
/* i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE0)  
/* i2c0_scl.i2c0_scl */
+   AM4372_IOPAD(0x988, PIN_INPUT_PULLUP | SLEWCTRL_FAST | 
MUX_MODE0)  /* i2c0_sda.i2c0_sda */
+   AM4372_IOPAD(0x98c, PIN_INPUT_PULLUP | SLEWCTRL_FAST | 
MUX_MODE0)  /* i2c0_scl.i2c0_scl */
>;
};
 
i2c1_pins: i2c1_pins {
pinctrl-single,pins = <
-   0x15c (PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE2)  
/* spi0_cs0.i2c1_scl */
-   0x158 (PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE2)  
/* spi0_d1.i2c1_sda  */
+   AM4372_IOPAD(0x95c, PIN_INPUT_PULLUP | SLEWCTRL_FAST | 
MUX_MODE2)  /* spi0_cs0.i2c1_scl */
+   AM4372_IOPAD(0x958, PIN_INPUT_PULLUP | SLEWCTRL_FAST | 
MUX_MODE2)  /* spi0_d1.i2c1_sda  */
>;
};
 
mmc1_pins: pinmux_mmc1_pins {
pinctrl-single,pins = <
-   0x160 (PIN_INPUT | MUX_MODE7) /* spi0_cs1.gpio0_6 */
+   AM4372_IOPAD(0x960, PIN_INPUT | MUX_MODE7) /* 
spi0_cs1.gpio0_6 */
>;
};
 
ecap0_pins: backlight_pins {
pinctrl-single,pins = <
-   0x164 MUX_MODE0   /* 
eCAP0_in_PWM0_out.eCAP0_in_PWM0_out MODE0 */
+   AM4372_IOPAD(0x964, MUX_MODE0)   /* 
eCAP0_in_PWM0_out.eCAP0_in_PWM0_out MODE0 */
>;
};
 
pixcir_ts_pins: pixcir_ts_pins {
pinctrl-single,pins = <
-   0x264 (PIN_INPUT_PULLUP | MUX_MODE7)  /* 
spi2_d0.gpio3_22 */
+   AM4372_IOPAD(0xa64, PIN_INPUT_PULLUP | MUX_MODE7)  /* 
spi2_d0.gpio3_22 */
>;
};
 
cpsw_default: cpsw_default {
pinctrl-single,pins = <
/* Slave 1 */
-   0x114 (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mii1_txen.rgmii1_txen */
-   0x118 (PIN_INPUT_PULLDOWN | MUX_MODE2)  /* 
mii1_rxdv.rgmii1_rxctl */
-   0x11c (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mii1_txd1.rgmii1_txd3 */
-   0x120 (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mii1_txd0.rgmii1_txd2 */
-   0x124 (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mii1_txd1.rgmii1_txd1 */
-   0x128 (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mii1_txd0.rgmii1_txd0 */
-   0x12c (PIN_OUTPUT_PULLDOWN | MUX_MODE2) /* 
mii1_txclk.rmii1_tclk */
-   0x130 (PIN_INPUT_PULLDOWN | MUX_MODE2)  /* 
mii1_rxclk.rmii1_rclk */
-   0x134 (PIN_INPUT_PULLDOWN | MUX_MODE2)  /* 
mii1_rxd1.rgmii1_rxd3 */
-   0x138 (PIN_INPUT_PULLDOWN | MUX_MODE2)  /* 
mii1_rxd0.rgmii1_rxd2 */
-   0x13c (PIN_INPUT_PULLDOWN | MUX_MODE2)  /* 
mii1_rxd1.rgmii1_rxd1 */
-   0x140 (PIN_INPUT_PULLDOWN | MUX_MODE2)  /* 
mii1_rxd0.rgmii1_rxd0 */
+   AM4372_IOPAD(0x914, PIN_OUTPUT_PULLDOWN | MUX_MODE2)
/* mii1_txen.rgmii1_txen */
+   AM4372_IOPAD(0x918, PIN_INPUT_PULLDOWN | MUX_MODE2) 
/* mii1_rxdv.rgmii1_rxctl */
+   AM4372_IOPAD(0x91c, PIN_OUTPUT_PULLDOWN | MUX_MODE2)
/* mii1_txd1.rgmii1_txd3 */
+   AM4372_IOPAD(0x920, PIN_OUTPUT_PULLDOWN | MUX_MODE2)
/* mii1_txd0.rgmii1_txd2 */
+   AM4372_IOPAD(0x924, PIN_OUTPUT_PULLDOWN | MUX_MODE2)
/* mii1_txd1.rgmii1_txd1 */
+   AM4372_IOPAD(0x928, PIN_OUTPUT_PULLDOWN | MUX_MODE2)
/* mii1_txd0.rgmii1_txd0 */
+   AM4372_IOPAD(0x92c, PIN_OUTPUT_PULLDOWN | MUX_MODE2)
/* mii1_txclk.rmii1_tclk */
+   AM4372_IOPAD(0x930, PIN_INPUT_PULLDOWN | MUX_MODE2) 
/* mii1_rxclk.rmii1_rclk */
+   AM4372_IOPAD(0x934, PIN_INPUT_PULLDOWN | MUX_MODE2) 
/* mii1_rxd1.rgmii1_rxd3 */
+   AM4372_IOPAD(0x938, PIN_INPUT_PULLDOWN | M

[PATCH 17/39] ARM: dts: am437x-idk-evm: Use AM4372_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am437x-idk-evm.dts | 128 +--
 1 file changed, 64 insertions(+), 64 deletions(-)

diff --git a/arch/arm/boot/dts/am437x-idk-evm.dts 
b/arch/arm/boot/dts/am437x-idk-evm.dts
index 337fb91ee74c..76dcfc6d5f0d 100644
--- a/arch/arm/boot/dts/am437x-idk-evm.dts
+++ b/arch/arm/boot/dts/am437x-idk-evm.dts
@@ -122,137 +122,137 @@
 _pinmux {
gpio_keys_pins_default: gpio_keys_pins_default {
pinctrl-single,pins = <
-   0x1b8 (PIN_INPUT | MUX_MODE7)   /* cam0_field.gpio4_2 */
+   AM4372_IOPAD(0x9b8, PIN_INPUT | MUX_MODE7)  /* 
cam0_field.gpio4_2 */
>;
};
 
i2c0_pins_default: i2c0_pins_default {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE0) /* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE0) /* 
i2c0_scl.i2c0_scl */
+   AM4372_IOPAD(0x988, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE0) /* i2c0_sda.i2c0_sda */
+   AM4372_IOPAD(0x98c, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE0) /* i2c0_scl.i2c0_scl */
>;
};
 
i2c0_pins_sleep: i2c0_pins_sleep {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x18c (PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x988, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x98c, PIN_INPUT_PULLDOWN | MUX_MODE7)
>;
};
 
i2c2_pins_default: i2c2_pins_default {
pinctrl-single,pins = <
-   0x1e8 (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE3) /* 
cam1_data1.i2c2_scl */
-   0x1ec (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE3) /* 
cam1_data0.i2c2_sda */
+   AM4372_IOPAD(0x9e8, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE3) /* cam1_data1.i2c2_scl */
+   AM4372_IOPAD(0x9ec, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE3) /* cam1_data0.i2c2_sda */
>;
};
 
i2c2_pins_sleep: i2c2_pins_sleep {
pinctrl-single,pins = <
-   0x1e8 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x1ec (PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x9e8, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x9ec, PIN_INPUT_PULLDOWN | MUX_MODE7)
>;
};
 
mmc1_pins_default: pinmux_mmc1_pins_default {
pinctrl-single,pins = <
-   0x100 (PIN_INPUT | MUX_MODE0) /* mmc0_clk.mmc0_clk */
-   0x104 (PIN_INPUT | MUX_MODE0) /* mmc0_cmd.mmc0_cmd */
-   0x1f0 (PIN_INPUT | MUX_MODE0) /* mmc0_dat3.mmc0_dat3 */
-   0x1f4 (PIN_INPUT | MUX_MODE0) /* mmc0_dat2.mmc0_dat2 */
-   0x1f8 (PIN_INPUT | MUX_MODE0) /* mmc0_dat1.mmc0_dat1 */
-   0x1fc (PIN_INPUT | MUX_MODE0) /* mmc0_dat0.mmc0_dat0 */
-   0x160 (PIN_INPUT | MUX_MODE7) /* spi0_cs1.gpio0_6 */
+   AM4372_IOPAD(0x900, PIN_INPUT | MUX_MODE0) /* 
mmc0_clk.mmc0_clk */
+   AM4372_IOPAD(0x904, PIN_INPUT | MUX_MODE0) /* 
mmc0_cmd.mmc0_cmd */
+   AM4372_IOPAD(0x9f0, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat3.mmc0_dat3 */
+   AM4372_IOPAD(0x9f4, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat2.mmc0_dat2 */
+   AM4372_IOPAD(0x9f8, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat1.mmc0_dat1 */
+   AM4372_IOPAD(0x9fc, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat0.mmc0_dat0 */
+   AM4372_IOPAD(0x960, PIN_INPUT | MUX_MODE7) /* 
spi0_cs1.gpio0_6 */
>;
};
 
mmc1_pins_sleep: pinmux_mmc1_pins_sleep {
pinctrl-single,pins = <
-   0x100 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x104 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x1f0 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x1f4 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x1f8 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x1fc (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x160 (PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x900, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x904, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM4372_IOPAD(0x9f0, PIN_INPUT_PULLDOWN | MUX_MODE7)
+

[PATCH 15/39] ARM: dts: am3517-craneboard: Use OMAP3_CORE1_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am3517-craneboard.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/am3517-craneboard.dts 
b/arch/arm/boot/dts/am3517-craneboard.dts
index 2d40b3f241cd..cb7de1d4e05f 100644
--- a/arch/arm/boot/dts/am3517-craneboard.dts
+++ b/arch/arm/boot/dts/am3517-craneboard.dts
@@ -77,7 +77,7 @@
 _pmx_core {
tps_pins: pinmux_tps_pins {
pinctrl-single,pins = <
-   0x1b0 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
sys_nirq.sys_nirq */
+   OMAP3_CORE1_IOPAD(0x21e0, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sys_nirq.sys_nirq */
>;
};
 };
-- 
2.4.3

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


[PATCH 13/39] ARM: dts: am335x-phycore-som: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-phycore-som.dtsi | 60 +++
 1 file changed, 30 insertions(+), 30 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-phycore-som.dtsi 
b/arch/arm/boot/dts/am335x-phycore-som.dtsi
index 2f43e458ea4a..c20ae6c6f6c7 100644
--- a/arch/arm/boot/dts/am335x-phycore-som.dtsi
+++ b/arch/arm/boot/dts/am335x-phycore-som.dtsi
@@ -56,22 +56,22 @@
 _pinmux {
ethernet0_pins: pinmux_ethernet0 {
pinctrl-single,pins = <
-   0x10c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_crs.rmii1_crs_dv */
-   0x110 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxerr.rmii1_rxerr */
-   0x114 (PIN_OUTPUT | MUX_MODE1)  /* 
mii1_txen.rmii1_txen */
-   0x124 (PIN_OUTPUT | MUX_MODE1)  /* 
mii1_txd1.rmii1_txd1 */
-   0x128 (PIN_OUTPUT | MUX_MODE1)  /* 
mii1_txd0.rmii1_txd0 */
-   0x13c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxd1.rmii1_rxd1 */
-   0x140 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_rxd0.rmii1_rxd0 */
-   0x144 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
rmii1_refclk.rmii1_refclk */
+   AM33XX_IOPAD(0x90c, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* mii1_crs.rmii1_crs_dv */
+   AM33XX_IOPAD(0x910, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* mii1_rxerr.rmii1_rxerr */
+   AM33XX_IOPAD(0x914, PIN_OUTPUT | MUX_MODE1) 
/* mii1_txen.rmii1_txen */
+   AM33XX_IOPAD(0x924, PIN_OUTPUT | MUX_MODE1) 
/* mii1_txd1.rmii1_txd1 */
+   AM33XX_IOPAD(0x928, PIN_OUTPUT | MUX_MODE1) 
/* mii1_txd0.rmii1_txd0 */
+   AM33XX_IOPAD(0x93c, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* mii1_rxd1.rmii1_rxd1 */
+   AM33XX_IOPAD(0x940, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* mii1_rxd0.rmii1_rxd0 */
+   AM33XX_IOPAD(0x944, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* rmii1_refclk.rmii1_refclk */
>;
};
 
mdio_pins: pinmux_mdio {
pinctrl-single,pins = <
/* MDIO */
-   0x148 (PIN_INPUT_PULLUP | SLEWCTRL_FAST | MUX_MODE0)
/* mdio_data.mdio_data */
-   0x14c (PIN_OUTPUT_PULLUP | MUX_MODE0)   
/* mdio_clk.mdio_clk */
+   AM33XX_IOPAD(0x948, PIN_INPUT_PULLUP | SLEWCTRL_FAST | 
MUX_MODE0)   /* mdio_data.mdio_data */
+   AM33XX_IOPAD(0x94c, PIN_OUTPUT_PULLUP | MUX_MODE0)  
/* mdio_clk.mdio_clk */
>;
};
 };
@@ -103,8 +103,8 @@
 _pinmux {
i2c0_pins: pinmux_i2c0 {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT | MUX_MODE0)   /* i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT | MUX_MODE0)   /* i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT | MUX_MODE0)  /* 
i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT | MUX_MODE0)  /* 
i2c0_scl.i2c0_scl */
>;
};
 };
@@ -137,20 +137,20 @@
 _pinmux {
nandflash_pins: pinmux_nandflash {
pinctrl-single,pins = <
-   0x0 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad0.gpmc_ad0 */
-   0x4 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad1.gpmc_ad1 */
-   0x8 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad2.gpmc_ad2 */
-   0xc (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad3.gpmc_ad3 */
-   0x10 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad4.gpmc_ad4 */
-   0x14 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad5.gpmc_ad5 */
-   0x18 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad6.gpmc_ad6 */
-   0x1c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad7.gpmc_ad7 */
-   0x70 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_wait0.gpmc_wait0 */
-   0x7c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn0.gpmc_csn0 */
-   0x90 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_advn_ale.gpmc_advn_ale */
-   0x94 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_oen_ren.gpmc_oen_ren */
-   0x98 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_wen.gpmc_wen */
-   0x9c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_be0n_cle.gpmc_be0n_cle */
+   AM33XX_IO

[PATCH 14/39] ARM: dts: am335x-wega: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-wega.dtsi | 58 +++---
 1 file changed, 29 insertions(+), 29 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-wega.dtsi 
b/arch/arm/boot/dts/am335x-wega.dtsi
index 2cecb3951e1b..282f6d4b27bc 100644
--- a/arch/arm/boot/dts/am335x-wega.dtsi
+++ b/arch/arm/boot/dts/am335x-wega.dtsi
@@ -28,8 +28,8 @@
 _pinmux {
dcan1_pins: pinmux_dcan1 {
pinctrl-single,pins = <
-   0x168 (PIN_OUTPUT_PULLUP | MUX_MODE2) /* 
uart0_ctsn.d_can1_tx */
-   0x16c (PIN_INPUT_PULLUP | MUX_MODE2) /* 
uart0_rtsn.d_can1_rx */
+   AM33XX_IOPAD(0x968, PIN_OUTPUT_PULLUP | MUX_MODE2) /* 
uart0_ctsn.d_can1_tx */
+   AM33XX_IOPAD(0x96c, PIN_INPUT_PULLUP | MUX_MODE2) /* 
uart0_rtsn.d_can1_rx */
>;
};
 };
@@ -44,20 +44,20 @@
 _pinmux {
ethernet1_pins: pinmux_ethernet1 {
pinctrl-single,pins = <
-   0x40 (PIN_OUTPUT | MUX_MODE1)   /* 
gpmc_a0.mii2_txen */
-   0x44 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a1.mii2_rxdv */
-   0x48 (PIN_OUTPUT | MUX_MODE1)   /* 
gpmc_a2.mii2_txd3 */
-   0x4c (PIN_OUTPUT | MUX_MODE1)   /* 
gpmc_a3.mii2_txd2 */
-   0x50 (PIN_OUTPUT | MUX_MODE1)   /* 
gpmc_a4.mii2_txd1 */
-   0x54 (PIN_OUTPUT | MUX_MODE1)   /* 
gpmc_a5.mii2_txd0 */
-   0x58 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a6.mii2_txclk */
-   0x5c (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a7.mii2_rxclk */
-   0x60 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a8.mii2_rxd3 */
-   0x64 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a9.mii2_rxd2 */
-   0x68 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a10.mii2_rxd1 */
-   0x6c (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_a11.mii2_rxd0 */
-   0x74 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_wpn.mii2_rxerr */
-   0x78 (PIN_INPUT_PULLDOWN | MUX_MODE1)   /* 
gpmc_ben1.mii2_col */
+   AM33XX_IOPAD(0x840, PIN_OUTPUT | MUX_MODE1) 
/* gpmc_a0.mii2_txen */
+   AM33XX_IOPAD(0x844, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a1.mii2_rxdv */
+   AM33XX_IOPAD(0x848, PIN_OUTPUT | MUX_MODE1) 
/* gpmc_a2.mii2_txd3 */
+   AM33XX_IOPAD(0x84c, PIN_OUTPUT | MUX_MODE1) 
/* gpmc_a3.mii2_txd2 */
+   AM33XX_IOPAD(0x850, PIN_OUTPUT | MUX_MODE1) 
/* gpmc_a4.mii2_txd1 */
+   AM33XX_IOPAD(0x854, PIN_OUTPUT | MUX_MODE1) 
/* gpmc_a5.mii2_txd0 */
+   AM33XX_IOPAD(0x858, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a6.mii2_txclk */
+   AM33XX_IOPAD(0x85c, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a7.mii2_rxclk */
+   AM33XX_IOPAD(0x860, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a8.mii2_rxd3 */
+   AM33XX_IOPAD(0x864, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a9.mii2_rxd2 */
+   AM33XX_IOPAD(0x868, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a10.mii2_rxd1 */
+   AM33XX_IOPAD(0x86c, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_a11.mii2_rxd0 */
+   AM33XX_IOPAD(0x874, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_wpn.mii2_rxerr */
+   AM33XX_IOPAD(0x878, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* gpmc_ben1.mii2_col */
>;
};
 };
@@ -79,13 +79,13 @@
 _pinmux {
mmc1_pins: pinmux_mmc1 {
pinctrl-single,pins = <
-   0x0F0 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mmc0_dat3.mmc0_dat3 */
-   0x0F4 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mmc0_dat2.mmc0_dat2 */
-   0x0F8 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mmc0_dat1.mmc0_dat1 */
-   0x0FC (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mmc0_dat0.mmc0_dat0 */
-   0x100 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mmc0_clk.mmc0_clk */
-   0x104 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mmc0_cmd.mmc0_cmd */
-   0x160 (PIN_INPUT_PULLUP | MUX_MODE7)/* 
spi0_cs1.mmc0_sdcd */
+   AM33XX_IOPAD(0x8f0, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_dat3.mmc0_dat3 */
+   AM33XX_IOPAD(0x8f4, PIN_INPUT_PULLUP | MUX_MODE0)   
/

[PATCH 31/39] ARM: dts: omap4-panda-a4: Use OMAP4_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap4-panda-a4.dts | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-panda-a4.dts 
b/arch/arm/boot/dts/omap4-panda-a4.dts
index 133f1b74e8ae..78d363177762 100644
--- a/arch/arm/boot/dts/omap4-panda-a4.dts
+++ b/arch/arm/boot/dts/omap4-panda-a4.dts
@@ -13,8 +13,8 @@
 /* Pandaboard Rev A4+ have external pullups on SCL & SDA */
 _hdmi_pins {
pinctrl-single,pins = <
-   0x5a (PIN_INPUT_PULLUP | MUX_MODE0) /* hdmi_cec.hdmi_cec */
-   0x5c (PIN_INPUT | MUX_MODE0)/* hdmi_scl.hdmi_scl */
-   0x5e (PIN_INPUT | MUX_MODE0)/* hdmi_sda.hdmi_sda */
+   OMAP4_IOPAD(0x09a, PIN_INPUT_PULLUP | MUX_MODE0)/* 
hdmi_cec.hdmi_cec */
+   OMAP4_IOPAD(0x09c, PIN_INPUT | MUX_MODE0)   /* 
hdmi_scl.hdmi_scl */
+   OMAP4_IOPAD(0x09e, PIN_INPUT | MUX_MODE0)   /* 
hdmi_sda.hdmi_sda */
>;
 };
-- 
2.4.3

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


[PATCH 32/39] ARM: dts: omap4-panda-common: Use OMAP4_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap4-panda-common.dtsi | 164 +++---
 1 file changed, 82 insertions(+), 82 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-panda-common.dtsi 
b/arch/arm/boot/dts/omap4-panda-common.dtsi
index 18d096696fc0..df2e356ec089 100644
--- a/arch/arm/boot/dts/omap4-panda-common.dtsi
+++ b/arch/arm/boot/dts/omap4-panda-common.dtsi
@@ -199,129 +199,129 @@
 
twl6040_pins: pinmux_twl6040_pins {
pinctrl-single,pins = <
-   0xe0 (PIN_OUTPUT | MUX_MODE3)   /* hdq_sio.gpio_127 */
-   0x160 (PIN_INPUT | MUX_MODE0)   /* sys_nirq2.sys_nirq2 
*/
+   OMAP4_IOPAD(0x120, PIN_OUTPUT | MUX_MODE3)  /* 
hdq_sio.gpio_127 */
+   OMAP4_IOPAD(0x1a0, PIN_INPUT | MUX_MODE0)   /* 
sys_nirq2.sys_nirq2 */
>;
};
 
mcpdm_pins: pinmux_mcpdm_pins {
pinctrl-single,pins = <
-   0xc6 (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_pdm_ul_data.abe_pdm_ul_data */
-   0xc8 (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_pdm_dl_data.abe_pdm_dl_data */
-   0xca (PIN_INPUT_PULLUP   | MUX_MODE0)   /* 
abe_pdm_frame.abe_pdm_frame */
-   0xcc (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_pdm_lb_clk.abe_pdm_lb_clk */
-   0xce (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_clks.abe_clks */
+   OMAP4_IOPAD(0x106, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_pdm_ul_data.abe_pdm_ul_data */
+   OMAP4_IOPAD(0x108, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_pdm_dl_data.abe_pdm_dl_data */
+   OMAP4_IOPAD(0x10a, PIN_INPUT_PULLUP   | MUX_MODE0)  
/* abe_pdm_frame.abe_pdm_frame */
+   OMAP4_IOPAD(0x10c, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_pdm_lb_clk.abe_pdm_lb_clk */
+   OMAP4_IOPAD(0x10e, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_clks.abe_clks */
>;
};
 
mcbsp1_pins: pinmux_mcbsp1_pins {
pinctrl-single,pins = <
-   0xbe (PIN_INPUT | MUX_MODE0)/* 
abe_mcbsp1_clkx.abe_mcbsp1_clkx */
-   0xc0 (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_mcbsp1_dr.abe_mcbsp1_dr */
-   0xc2 (PIN_OUTPUT_PULLDOWN | MUX_MODE0)  /* 
abe_mcbsp1_dx.abe_mcbsp1_dx */
-   0xc4 (PIN_INPUT | MUX_MODE0)/* 
abe_mcbsp1_fsx.abe_mcbsp1_fsx */
+   OMAP4_IOPAD(0x0fe, PIN_INPUT | MUX_MODE0)   
/* abe_mcbsp1_clkx.abe_mcbsp1_clkx */
+   OMAP4_IOPAD(0x100, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_mcbsp1_dr.abe_mcbsp1_dr */
+   OMAP4_IOPAD(0x102, PIN_OUTPUT_PULLDOWN | MUX_MODE0) 
/* abe_mcbsp1_dx.abe_mcbsp1_dx */
+   OMAP4_IOPAD(0x104, PIN_INPUT | MUX_MODE0)   
/* abe_mcbsp1_fsx.abe_mcbsp1_fsx */
>;
};
 
dss_dpi_pins: pinmux_dss_dpi_pins {
pinctrl-single,pins = <
-   0x122 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data23 */
-   0x124 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data22 */
-   0x126 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data21 */
-   0x128 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data20 */
-   0x12a (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data19 */
-   0x12c (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data18 */
-   0x12e (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data15 */
-   0x130 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data14 */
-   0x132 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data13 */
-   0x134 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data12 */
-   0x136 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data11 */
-
-   0x174 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data10 */
-   0x176 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data9 */
-   0x178 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data16 */
-   0x17a (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data17 */
-   0x17c (PIN_OUTPUT | MUX_MODE5)  /* dispc2_hsync */
-   0x17e (PIN_OUTPUT | MUX_MODE5)  /* dispc2_pclk */
-   0x180 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_vsync */
-   0x182 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_de */
-   0x184 (PIN_OUTPUT | MUX_MODE5)  /* dispc2_data8 */
-   0x

[PATCH 33/39] ARM: dts: omap4-panda-es: Use OMAP4_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap4-panda-es.dts | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-panda-es.dts 
b/arch/arm/boot/dts/omap4-panda-es.dts
index 2f1dabcc6adf..119f8e657edc 100644
--- a/arch/arm/boot/dts/omap4-panda-es.dts
+++ b/arch/arm/boot/dts/omap4-panda-es.dts
@@ -34,23 +34,23 @@
 /* PandaboardES has external pullups on SCL & SDA */
 _hdmi_pins {
pinctrl-single,pins = <
-   0x5a (PIN_INPUT_PULLUP | MUX_MODE0) /* hdmi_cec.hdmi_cec */
-   0x5c (PIN_INPUT | MUX_MODE0)/* hdmi_scl.hdmi_scl */
-   0x5e (PIN_INPUT | MUX_MODE0)/* hdmi_sda.hdmi_sda */
+   OMAP4_IOPAD(0x09a, PIN_INPUT_PULLUP | MUX_MODE0)/* 
hdmi_cec.hdmi_cec */
+   OMAP4_IOPAD(0x09c, PIN_INPUT | MUX_MODE0)   /* 
hdmi_scl.hdmi_scl */
+   OMAP4_IOPAD(0x09e, PIN_INPUT | MUX_MODE0)   /* 
hdmi_sda.hdmi_sda */
>;
 };
 
 _pmx_core {
led_gpio_pins: gpio_led_pmx {
pinctrl-single,pins = <
-   0xb6 (PIN_OUTPUT | MUX_MODE3)   /* gpio_110 */
+   OMAP4_IOPAD(0x0f6, PIN_OUTPUT | MUX_MODE3)  /* 
gpio_110 */
>;
};
 };
 
 _wkgpio_pins {
pinctrl-single,pins = <
-   0x1c (PIN_OUTPUT | MUX_MODE3)   /* gpio_wk8 */
+   OMAP4_IOPAD(0x05c, PIN_OUTPUT | MUX_MODE3)  /* gpio_wk8 */
>;
 };
 
-- 
2.4.3

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


[PATCH 34/39] ARM: dts: omap4-sdp: Use OMAP4_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap4-sdp.dts | 110 
 1 file changed, 55 insertions(+), 55 deletions(-)

diff --git a/arch/arm/boot/dts/omap4-sdp.dts b/arch/arm/boot/dts/omap4-sdp.dts
index f0bdc41f8eff..aae513265dc2 100644
--- a/arch/arm/boot/dts/omap4-sdp.dts
+++ b/arch/arm/boot/dts/omap4-sdp.dts
@@ -212,143 +212,143 @@
 
uart2_pins: pinmux_uart2_pins {
pinctrl-single,pins = <
-   0xd8 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
uart2_cts.uart2_cts */
-   0xda (PIN_OUTPUT | MUX_MODE0)   /* 
uart2_rts.uart2_rts */
-   0xdc (PIN_INPUT_PULLUP | MUX_MODE0) /* 
uart2_rx.uart2_rx */
-   0xde (PIN_OUTPUT | MUX_MODE0)   /* 
uart2_tx.uart2_tx */
+   OMAP4_IOPAD(0x118, PIN_INPUT_PULLUP | MUX_MODE0)
/* uart2_cts.uart2_cts */
+   OMAP4_IOPAD(0x11a, PIN_OUTPUT | MUX_MODE0)  
/* uart2_rts.uart2_rts */
+   OMAP4_IOPAD(0x11c, PIN_INPUT_PULLUP | MUX_MODE0)
/* uart2_rx.uart2_rx */
+   OMAP4_IOPAD(0x11e, PIN_OUTPUT | MUX_MODE0)  
/* uart2_tx.uart2_tx */
>;
};
 
uart3_pins: pinmux_uart3_pins {
pinctrl-single,pins = <
-   0x100 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart3_cts_rctx.uart3_cts_rctx */
-   0x102 (PIN_OUTPUT | MUX_MODE0)  /* 
uart3_rts_sd.uart3_rts_sd */
-   0x104 (PIN_INPUT | MUX_MODE0)   /* 
uart3_rx_irrx.uart3_rx_irrx */
-   0x106 (PIN_OUTPUT | MUX_MODE0)  /* 
uart3_tx_irtx.uart3_tx_irtx */
+   OMAP4_IOPAD(0x140, PIN_INPUT_PULLUP | MUX_MODE0)
/* uart3_cts_rctx.uart3_cts_rctx */
+   OMAP4_IOPAD(0x142, PIN_OUTPUT | MUX_MODE0)  
/* uart3_rts_sd.uart3_rts_sd */
+   OMAP4_IOPAD(0x144, PIN_INPUT | MUX_MODE0)   
/* uart3_rx_irrx.uart3_rx_irrx */
+   OMAP4_IOPAD(0x146, PIN_OUTPUT | MUX_MODE0)  
/* uart3_tx_irtx.uart3_tx_irtx */
>;
};
 
uart4_pins: pinmux_uart4_pins {
pinctrl-single,pins = <
-   0x11c (PIN_INPUT | MUX_MODE0)   /* 
uart4_rx.uart4_rx */
-   0x11e (PIN_OUTPUT | MUX_MODE0)  /* 
uart4_tx.uart4_tx */
+   OMAP4_IOPAD(0x15c, PIN_INPUT | MUX_MODE0)   
/* uart4_rx.uart4_rx */
+   OMAP4_IOPAD(0x15e, PIN_OUTPUT | MUX_MODE0)  
/* uart4_tx.uart4_tx */
>;
};
 
twl6040_pins: pinmux_twl6040_pins {
pinctrl-single,pins = <
-   0xe0 (PIN_OUTPUT | MUX_MODE3)   /* 
hdq_sio.gpio_127 */
-   0x160 (PIN_INPUT | MUX_MODE0)   /* 
sys_nirq2.sys_nirq2 */
+   OMAP4_IOPAD(0x120, PIN_OUTPUT | MUX_MODE3)  
/* hdq_sio.gpio_127 */
+   OMAP4_IOPAD(0x1a0, PIN_INPUT | MUX_MODE0)   
/* sys_nirq2.sys_nirq2 */
>;
};
 
mcpdm_pins: pinmux_mcpdm_pins {
pinctrl-single,pins = <
-   0xc6 (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_pdm_ul_data.abe_pdm_ul_data */
-   0xc8 (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_pdm_dl_data.abe_pdm_dl_data */
-   0xca (PIN_INPUT_PULLUP | MUX_MODE0) /* 
abe_pdm_frame.abe_pdm_frame */
-   0xcc (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_pdm_lb_clk.abe_pdm_lb_clk */
-   0xce (PIN_INPUT_PULLDOWN | MUX_MODE0)   /* 
abe_clks.abe_clks */
+   OMAP4_IOPAD(0x106, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_pdm_ul_data.abe_pdm_ul_data */
+   OMAP4_IOPAD(0x108, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_pdm_dl_data.abe_pdm_dl_data */
+   OMAP4_IOPAD(0x10a, PIN_INPUT_PULLUP | MUX_MODE0)
/* abe_pdm_frame.abe_pdm_frame */
+   OMAP4_IOPAD(0x10c, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_pdm_lb_clk.abe_pdm_lb_clk */
+   OMAP4_IOPAD(0x10e, PIN_INPUT_PULLDOWN | MUX_MODE0)  
/* abe_clks.abe_clks */
>;
};
 
dmic_pins: pinmux_dmic_pins {
pinctrl-single,pins = <
-   0xd0 (PIN_OUTPUT | MUX_MODE0)   /* 
abe_dmic_clk1.abe_dmic_clk1 */
-   0xd2 (PIN_INPUT | MUX_MODE0)

[PATCH 36/39] ARM: dts: twl6030: Use OMAP4_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register as an offset from
the padconf physical address instead of the offset from padconf base.
This makes the DTS easier to read since matches the addresses listed
in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/twl6030_omap4.dtsi | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/twl6030_omap4.dtsi 
b/arch/arm/boot/dts/twl6030_omap4.dtsi
index a4fa5703c42b..e373f59cea9c 100644
--- a/arch/arm/boot/dts/twl6030_omap4.dtsi
+++ b/arch/arm/boot/dts/twl6030_omap4.dtsi
@@ -24,7 +24,7 @@
 _pmx_wkup {
twl6030_wkup_pins: pinmux_twl6030_wkup_pins {
pinctrl-single,pins = <
-   0x14 (PIN_OUTPUT | MUX_MODE2)   /* 
fref_clk0_out.sys_drm_msecure */
+   OMAP4_IOPAD(0x054, PIN_OUTPUT | MUX_MODE2)  
/* fref_clk0_out.sys_drm_msecure */
>;
};
 };
@@ -32,7 +32,7 @@
 _pmx_core {
twl6030_pins: pinmux_twl6030_pins {
pinctrl-single,pins = <
-   0x15e (WAKEUP_EN | PIN_INPUT_PULLUP | MUX_MODE0)
/* sys_nirq1.sys_nirq1 */
+   OMAP4_IOPAD(0x19e, WAKEUP_EN | PIN_INPUT_PULLUP | 
MUX_MODE0)/* sys_nirq1.sys_nirq1 */
>;
};
 };
-- 
2.4.3

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


[PATCH 30/39] ARM: dts: twl4030: Use OMAP3_CORE1_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/twl4030_omap3.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/twl4030_omap3.dtsi 
b/arch/arm/boot/dts/twl4030_omap3.dtsi
index 3537ae5b2146..5288e6dffef7 100644
--- a/arch/arm/boot/dts/twl4030_omap3.dtsi
+++ b/arch/arm/boot/dts/twl4030_omap3.dtsi
@@ -19,7 +19,7 @@
 */
twl4030_pins: pinmux_twl4030_pins {
pinctrl-single,pins = <
-   0x1b0 (PIN_INPUT_PULLUP | PIN_OFF_WAKEUPENABLE | 
MUX_MODE0) /* sys_nirq.sys_nirq */
+   OMAP3_CORE1_IOPAD(0x21e0, PIN_INPUT_PULLUP | 
PIN_OFF_WAKEUPENABLE | MUX_MODE0) /* sys_nirq.sys_nirq */
>;
};
 };
-- 
2.4.3

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


[PATCH 28/39] ARM: dts: omap3-n9: Use OMAP3_CORE1_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-n950-n9.dtsi | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-n950-n9.dtsi 
b/arch/arm/boot/dts/omap3-n950-n9.dtsi
index e9ee1df0e467..a2c2b8d8dd2c 100644
--- a/arch/arm/boot/dts/omap3-n950-n9.dtsi
+++ b/arch/arm/boot/dts/omap3-n950-n9.dtsi
@@ -36,12 +36,12 @@
 _pmx_core {
mmc2_pins: pinmux_mmc2_pins {
pinctrl-single,pins = <
-   0x128 (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_clk */
-   0x12a (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_cmd */
-   0x12c (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat0 */
-   0x12e (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat1 */
-   0x130 (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat2 */
-   0x132 (PIN_INPUT_PULLUP | MUX_MODE0) /* sdmmc2_dat3 */
+   OMAP3_CORE1_IOPAD(0x2158, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_clk */
+   OMAP3_CORE1_IOPAD(0x215a, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_cmd */
+   OMAP3_CORE1_IOPAD(0x215c, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat0 */
+   OMAP3_CORE1_IOPAD(0x215e, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat1 */
+   OMAP3_CORE1_IOPAD(0x2160, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat2 */
+   OMAP3_CORE1_IOPAD(0x2162, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat3 */
>;
};
 };
-- 
2.4.3

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


[PATCH 00/39] ARM: dts: Convert OMAP boards to use IOPAD pinmux macros

2015-11-12 Thread Javier Martinez Canillas
Hello Tony,

This series converts all the remaining OMAP boards that didn't use the
IOPAD macros to specify the padconf register addresses. The only board
that I left was arch/arm/boot/dts/am335x-boneblack.dts because Andrew
already posted a patch for that DTS [0].

I built tested all the DTBs that are build by omap2plus_defconfig and
the md5 checksum was the same before and after the patches so there's
no functional change and is only to make the DTS more readable.

Patch #1 should be acked by the pinctrl maintainer and picked through
the linux-omap tree to maintain bisectability.

[0]: https://lkml.org/lkml/2015/10/24/114

Best regards,
Javier


Javier Martinez Canillas (39):
  pinctrl: Move am4372 and dra7 macros to the the SoC header files
  ARM: dts: am335x-baltos-ir5221: Remove leftover pinctrl lines
  ARM: dts: am335x-baltos-ir5221: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-bone-common: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-bonegreen: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-chiliboard: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-chilisom: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-evm: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-evmsk: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-lxm: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-nano: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-pepper: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-phycore-som: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am335x-wega: Use AM33XX_IOPAD pinmux macro
  ARM: dts: am3517-craneboard: Use OMAP3_CORE1_IOPAD pinmux macro
  ARM: dts: am437x-gp-evm: Use AM4372_IOPAD pinmux macro
  ARM: dts: am437x-idk-evm: Use AM4372_IOPAD pinmux macro
  ARM: dts: am437x-sk-evm: Use AM4372_IOPAD pinmux macro
  ARM: dts: am43x-epos-evm: Use AM4372_IOPAD pinmux macro
  ARM: dts: am57xx-beagle-x15: Use DRA7XX_CORE_IOPAD pinmux macro
  ARM: dts: dra7-evm: Use DRA7XX_CORE_IOPAD pinmux macro
  ARM: dts: dra72-evm: Use DRA7XX_CORE_IOPAD pinmux macro
  ARM: dts: omap3-beagle: Use OMAP3_*_IOPAD pinmux macros
  ARM: dts: omap3-beagle-xm: Use OMAP3_*_IOPAD pinmux macros
  ARM: dts: omap3-evm-37xx: Use OMAP3_*_IOPAD pinmux macros
  ARM: dts: omap3-ldp: Use OMAP3_CORE1_IOPAD pinmux macro
  ARM: dts: omap3-n900: Use OMAP3_CORE1_IOPAD pinmux macro
  ARM: dts: omap3-n9: Use OMAP3_CORE1_IOPAD pinmux macro
  ARM: dts: omap3-zoom3: Use OMAP3_*_IOPAD pinmux macros
  ARM: dts: twl4030: Use OMAP3_CORE1_IOPAD pinmux macro
  ARM: dts: omap4-panda-a4: Use OMAP4_IOPAD pinmux macro
  ARM: dts: omap4-panda-common: Use OMAP4_IOPAD pinmux macro
  ARM: dts: omap4-panda-es: Use OMAP4_IOPAD pinmux macro
  ARM: dts: omap4-sdp: Use OMAP4_IOPAD pinmux macro
  ARM: dts: omap4-sdp-es23plus: Use OMAP4_IOPAD pinmux macro
  ARM: dts: twl6030: Use OMAP4_IOPAD pinmux macro
  ARM: dts: omap5-board-common: Use OMAP5_IOPAD pinmux macro
  ARM: dts: omap5-cm-t54: Use OMAP5_IOPAD pinmux macro
  ARM: dts: omap5-uevm.dts: Use OMAP5_IOPAD pinmux macro

 arch/arm/boot/dts/am335x-baltos-ir5221.dts | 186 +++---
 arch/arm/boot/dts/am335x-bone-common.dtsi  | 104 
 arch/arm/boot/dts/am335x-bonegreen.dts |   4 +-
 arch/arm/boot/dts/am335x-chiliboard.dts|  20 +-
 arch/arm/boot/dts/am335x-chilisom.dtsi |  80 +++---
 arch/arm/boot/dts/am335x-evm.dts   | 220 -
 arch/arm/boot/dts/am335x-evmsk.dts | 278 ++---
 arch/arm/boot/dts/am335x-lxm.dts   | 120 -
 arch/arm/boot/dts/am335x-nano.dts  | 140 +--
 arch/arm/boot/dts/am335x-pepper.dts| 200 +++
 arch/arm/boot/dts/am335x-phycore-som.dtsi  |  60 ++---
 arch/arm/boot/dts/am335x-wega.dtsi |  58 ++---
 arch/arm/boot/dts/am3517-craneboard.dts|   2 +-
 arch/arm/boot/dts/am437x-gp-evm.dts| 380 ++---
 arch/arm/boot/dts/am437x-idk-evm.dts   | 128 +-
 arch/arm/boot/dts/am437x-sk-evm.dts| 298 +++---
 arch/arm/boot/dts/am43x-epos-evm.dts   | 246 +--
 arch/arm/boot/dts/am57xx-beagle-x15.dts| 198 +++
 arch/arm/boot/dts/dra7-evm.dts | 254 +--
 arch/arm/boot/dts/dra72-evm.dts| 200 +++
 arch/arm/boot/dts/omap3-beagle-xm.dts  |  18 +-
 arch/arm/boot/dts/omap3-beagle.dts |  64 ++---
 arch/arm/boot/dts/omap3-evm-37xx.dts   |  54 ++--
 arch/arm/boot/dts/omap3-ldp.dts|  42 ++--
 arch/arm/boot/dts/omap3-n900.dts   | 106 
 arch/arm/boot/dts/omap3-n950-n9.dtsi   |  12 +-
 arch/arm/boot/dts/omap3-zoom3.dts  |  60 ++---
 arch/arm/boot/dts/omap4-panda-a4.dts   |   6 +-
 arch/arm/boot/dts/omap4-panda-common.dtsi  | 164 ++---
 arch/arm/boot/dts/omap4-panda-es.dts   |  10 +-
 arch/arm/boot/dts/omap4-sdp-es23plus.dts   |   6 +-
 arch/arm/boot/dts/omap4-sdp.dts| 110 -
 arch/arm/boot/dts/omap5-board-common.dtsi  |  94 +++
 arch/arm/boot/dts/omap5-cm-t54

[PATCH 03/39] ARM: dts: am335x-baltos-ir5221: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Also, use the mux defines instead of magic numbers for the padconf
values when defining the pinctrl lines to make it more readable.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-baltos-ir5221.dts | 182 ++---
 1 file changed, 91 insertions(+), 91 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-baltos-ir5221.dts 
b/arch/arm/boot/dts/am335x-baltos-ir5221.dts
index 3b42635bc995..ded1eb64ea52 100644
--- a/arch/arm/boot/dts/am335x-baltos-ir5221.dts
+++ b/arch/arm/boot/dts/am335x-baltos-ir5221.dts
@@ -56,171 +56,171 @@
 _pinmux {
mmc2_pins: pinmux_mmc2_pins {
pinctrl-single,pins = <
-   0x020 (PIN_INPUT_PULLUP | MUX_MODE2)  /* 
gpmc_ad8.mmc1_dat0_mux0 */
-   0x024 (PIN_INPUT_PULLUP | MUX_MODE2)  /* 
gpmc_ad9.mmc1_dat1_mux0 */
-   0x028 (PIN_INPUT_PULLUP | MUX_MODE2)  /* 
gpmc_ad10.mmc1_dat2_mux0 */
-   0x02c (PIN_INPUT_PULLUP | MUX_MODE2)  /* 
gpmc_ad11.mmc1_dat3_mux0 */
-   0x080 (PIN_INPUT_PULLUP | MUX_MODE2)  /* 
gpmc_csn1.mmc1_clk_mux0 */
-   0x084 (PIN_INPUT_PULLUP | MUX_MODE2)  /* 
gpmc_csn2.mmc1_cmd_mux0 */
-   0x1e4 (PIN_INPUT_PULLUP | MUX_MODE7)  /* 
emu0.gpio3[7] */
+   AM33XX_IOPAD(0x820, PIN_INPUT_PULLUP | MUX_MODE2)  
/* gpmc_ad8.mmc1_dat0_mux0 */
+   AM33XX_IOPAD(0x824, PIN_INPUT_PULLUP | MUX_MODE2)  
/* gpmc_ad9.mmc1_dat1_mux0 */
+   AM33XX_IOPAD(0x828, PIN_INPUT_PULLUP | MUX_MODE2)  
/* gpmc_ad10.mmc1_dat2_mux0 */
+   AM33XX_IOPAD(0x82c, PIN_INPUT_PULLUP | MUX_MODE2)  
/* gpmc_ad11.mmc1_dat3_mux0 */
+   AM33XX_IOPAD(0x880, PIN_INPUT_PULLUP | MUX_MODE2)  
/* gpmc_csn1.mmc1_clk_mux0 */
+   AM33XX_IOPAD(0x884, PIN_INPUT_PULLUP | MUX_MODE2)  
/* gpmc_csn2.mmc1_cmd_mux0 */
+   AM33XX_IOPAD(0x9e4, PIN_INPUT_PULLUP | MUX_MODE7)  
/* emu0.gpio3[7] */
>;
};
 
wl12xx_gpio: pinmux_wl12xx_gpio {
pinctrl-single,pins = <
-   0x1e8 (PIN_OUTPUT_PULLUP | MUX_MODE7)  /* 
emu1.gpio3[8] */
+   AM33XX_IOPAD(0x9e8, PIN_OUTPUT_PULLUP | MUX_MODE7)  
/* emu1.gpio3[8] */
>;
};
 
tps65910_pins: pinmux_tps65910_pins {
pinctrl-single,pins = <
-   0x078 (PIN_INPUT_PULLUP | MUX_MODE7)  /* 
gpmc_ben1.gpio1[28] */
+   AM33XX_IOPAD(0x878, PIN_INPUT_PULLUP | MUX_MODE7)  
/* gpmc_ben1.gpio1[28] */
>;
};
 
tca6416_pins: pinmux_tca6416_pins {
pinctrl-single,pins = <
-   0x1b4 (PIN_INPUT_PULLUP | MUX_MODE7)  /* 
xdma_event_intr1.gpio0[20] tca6416 stuff */
+   AM33XX_IOPAD(0x9b4, PIN_INPUT_PULLUP | MUX_MODE7)  
/* xdma_event_intr1.gpio0[20] tca6416 stuff */
>;
};
 
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
-   0x158 0x2a  /* spi0_d1.i2c1_sda_mux3, INPUT | MODE2 
*/
-   0x15c 0x2a  /* spi0_cs0.i2c1_scl_mux3, INPUT | 
MODE2 */
+   AM33XX_IOPAD(0x958, PIN_INPUT | MUX_MODE2)  /* 
spi0_d1.i2c1_sda_mux3 */
+   AM33XX_IOPAD(0x95c, PIN_INPUT | MUX_MODE2)  /* 
spi0_cs0.i2c1_scl_mux3 */
>;
};
 
dcan1_pins: pinmux_dcan1_pins {
pinctrl-single,pins = <
-   0x168 0x0a  /* uart0_ctsn.dcan1_tx_mux0, OUTPUT | 
MODE2 */
-   0x16c 0x2a  /* uart0_rtsn.dcan1_rx_mux0, INPUT | 
MODE2 */
+   AM33XX_IOPAD(0x968, PIN_OUTPUT | MUX_MODE2)  /* 
uart0_ctsn.dcan1_tx_mux0 */
+   AM33XX_IOPAD(0x96c, PIN_INPUT | MUX_MODE2)  /* 
uart0_rtsn.dcan1_rx_mux0 */
>;
};
 
uart0_pins: pinmux_uart0_pins {
pinctrl-single,pins = <
-   0x170 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart0_rxd.uart0_rxd */
-   0x174 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart0_txd.uart0_txd */
+   AM33XX_IOPAD(0x970, PIN_INPUT_PULLUP | MUX_MODE0)   
/* uart0_rxd.uart0_rxd */
+   AM33XX_IOPAD(0x974, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart0_txd.uart0_txd */
>;
};
 
uart1_pins: pinmux_uart1_pins {
pinctrl-single,pins = <
-

[PATCH 07/39] ARM: dts: am335x-chilisom: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-chilisom.dtsi | 80 +-
 1 file changed, 40 insertions(+), 40 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-chilisom.dtsi 
b/arch/arm/boot/dts/am335x-chilisom.dtsi
index 7e9a34dffe21..857d9894103a 100644
--- a/arch/arm/boot/dts/am335x-chilisom.dtsi
+++ b/arch/arm/boot/dts/am335x-chilisom.dtsi
@@ -29,81 +29,81 @@
 
i2c0_pins: pinmux_i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_scl.i2c0_scl */
>;
};
 
uart0_pins: pinmux_uart0_pins {
pinctrl-single,pins = <
-   0x170 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart0_rxd.uart0_rxd */
-   0x174 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart0_txd.uart0_txd */
+   AM33XX_IOPAD(0x970, PIN_INPUT_PULLUP | MUX_MODE0)   
/* uart0_rxd.uart0_rxd */
+   AM33XX_IOPAD(0x974, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart0_txd.uart0_txd */
>;
};
 
cpsw_default: cpsw_default {
pinctrl-single,pins = <
/* Slave 1 */
-   0x10c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_crs.rmii1_crs */
-   0x110 (PIN_INPUT_PULLUP | MUX_MODE1)/* 
mii1_rxerr.rmii1_rxerr */
-   0x114 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
mii1_txen.rmii1_txen */
-   0x124 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
mii1_txd1.rmii1_txd1 */
-   0x128 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* 
mii1_txd0.rmii1_txd0 */
-   0x13c (PIN_INPUT_PULLUP | MUX_MODE1)/* 
mii1_rxd1.rmii1_rxd1 */
-   0x140 (PIN_INPUT_PULLUP | MUX_MODE1)/* 
mii1_rxd0.rmii1_rxd0 */
-   0x144 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
rmii1_ref_clk.rmii_ref_clk */
+   AM33XX_IOPAD(0x90c, PIN_INPUT_PULLDOWN | MUX_MODE1)  /* 
mii1_crs.rmii1_crs */
+   AM33XX_IOPAD(0x910, PIN_INPUT_PULLUP | MUX_MODE1)   
/* mii1_rxerr.rmii1_rxerr */
+   AM33XX_IOPAD(0x914, PIN_OUTPUT_PULLDOWN | MUX_MODE1)
/* mii1_txen.rmii1_txen */
+   AM33XX_IOPAD(0x924, PIN_OUTPUT_PULLDOWN | MUX_MODE1)
/* mii1_txd1.rmii1_txd1 */
+   AM33XX_IOPAD(0x928, PIN_OUTPUT_PULLDOWN | MUX_MODE1)
/* mii1_txd0.rmii1_txd0 */
+   AM33XX_IOPAD(0x93c, PIN_INPUT_PULLUP | MUX_MODE1)   
/* mii1_rxd1.rmii1_rxd1 */
+   AM33XX_IOPAD(0x940, PIN_INPUT_PULLUP | MUX_MODE1)   
/* mii1_rxd0.rmii1_rxd0 */
+   AM33XX_IOPAD(0x944, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* rmii1_ref_clk.rmii_ref_clk */
>;
};
 
cpsw_sleep: cpsw_sleep {
pinctrl-single,pins = <
/* Slave 1 reset value */
-   0x10c (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x110 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x114 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x118 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x124 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x128 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x13c (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x140 (PIN_INPUT_PULLDOWN | MUX_MODE7)
-   0x144 (PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x90c, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x910, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x914, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x918, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x924, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x928, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x93c, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x940, PIN_INPUT_PULLDOWN | MUX_MODE7)
+   AM33XX_IOPAD(0x944, PIN_INPUT_PULLDOWN | MUX_MODE7)
>;
};
 
davinci_mdio_default: davinci_mdio_default {
pinctrl-single,pins = <
 

[PATCH 06/39] ARM: dts: am335x-chiliboard: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-chiliboard.dts | 20 ++--
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-chiliboard.dts 
b/arch/arm/boot/dts/am335x-chiliboard.dts
index 310da20a8aa7..15d47ab28865 100644
--- a/arch/arm/boot/dts/am335x-chiliboard.dts
+++ b/arch/arm/boot/dts/am335x-chiliboard.dts
@@ -37,26 +37,26 @@
 _pinmux {
usb1_drvvbus: usb1_drvvbus {
pinctrl-single,pins = <
-   0x234 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
usb1_drvvbus.usb1_drvvbus */
+   AM33XX_IOPAD(0xa34, PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
usb1_drvvbus.usb1_drvvbus */
>;
};
 
sd_pins: pinmux_sd_card {
pinctrl-single,pins = <
-   0xf0 (PIN_INPUT | MUX_MODE0) /* mmc0_dat0.mmc0_dat0 */
-   0xf4 (PIN_INPUT | MUX_MODE0) /* mmc0_dat1.mmc0_dat1 */
-   0xf8 (PIN_INPUT | MUX_MODE0) /* mmc0_dat2.mmc0_dat2 */
-   0xfc (PIN_INPUT | MUX_MODE0) /* mmc0_dat3.mmc0_dat3 */
-   0x100 (PIN_INPUT | MUX_MODE0) /* mmc0_clk.mmc0_clk */
-   0x104 (PIN_INPUT | MUX_MODE0) /* mmc0_cmd.mmc0_cmd */
-   0x160 (PIN_INPUT | MUX_MODE7) /* spi0_cs1.gpio0_6 */
+   AM33XX_IOPAD(0x8f0, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat0.mmc0_dat0 */
+   AM33XX_IOPAD(0x8f4, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat1.mmc0_dat1 */
+   AM33XX_IOPAD(0x8f8, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat2.mmc0_dat2 */
+   AM33XX_IOPAD(0x8fc, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat3.mmc0_dat3 */
+   AM33XX_IOPAD(0x900, PIN_INPUT | MUX_MODE0) /* 
mmc0_clk.mmc0_clk */
+   AM33XX_IOPAD(0x904, PIN_INPUT | MUX_MODE0) /* 
mmc0_cmd.mmc0_cmd */
+   AM33XX_IOPAD(0x960, PIN_INPUT | MUX_MODE7) /* 
spi0_cs1.gpio0_6 */
>;
};
 
led_gpio_pins: led_gpio_pins {
pinctrl-single,pins = <
-   0x1e4 (PIN_OUTPUT | MUX_MODE7) /* emu0.gpio3_7 */
-   0x1e8 (PIN_OUTPUT | MUX_MODE7) /* emu1.gpio3_8 */
+   AM33XX_IOPAD(0x9e4, PIN_OUTPUT | MUX_MODE7) /* 
emu0.gpio3_7 */
+   AM33XX_IOPAD(0x9e8, PIN_OUTPUT | MUX_MODE7) /* 
emu1.gpio3_8 */
>;
};
 };
-- 
2.4.3

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


[PATCH 02/39] ARM: dts: am335x-baltos-ir5221: Remove leftover pinctrl lines

2015-11-12 Thread Javier Martinez Canillas
When the Device Tree source file got merged, some commented pinctrl lines
were left in the file. These are already defined so seems to be a cleanup
that was missed. Delete the unneeded lines from the file.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-baltos-ir5221.dts | 4 
 1 file changed, 4 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-baltos-ir5221.dts 
b/arch/arm/boot/dts/am335x-baltos-ir5221.dts
index 7d36601697da..3b42635bc995 100644
--- a/arch/arm/boot/dts/am335x-baltos-ir5221.dts
+++ b/arch/arm/boot/dts/am335x-baltos-ir5221.dts
@@ -109,8 +109,6 @@
pinctrl-single,pins = <
0x180 0x28  /* uart1_rxd, INPUT | MODE0 */
0x184 0x28  /* uart1_txd, INPUT | MODE0 */
-   /*0x178 0x28*/  /* uart1_ctsn, INPUT | MODE0 */
-   /*0x17c 0x08*/  /* uart1_rtsn, OUTPUT | MODE0 */
0x178 (PIN_INPUT_PULLDOWN | MUX_MODE7)  /* 
uart1_ctsn, INPUT | MODE0 */
0x17c (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
uart1_rtsn, OUTPUT | MODE0 */
0x0e0 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
lcd_vsync.gpio2[22] DTR */
@@ -124,8 +122,6 @@
pinctrl-single,pins = <
0x150 0x29  /* spi0_sclk.uart2_rxd_mux3, INPUT | 
MODE1 */
0x154 0x09  /* spi0_d0.uart2_txd_mux3, OUTPUT | 
MODE1 */
-   /*0x188 0x2a*/  /* i2c0_sda.uart2_ctsn_mux0, INPUT 
| MODE2 */
-   /*0x18c 0x2a*/  /* i2c0_scl.uart2_rtsn_mux0, INPUT 
| MODE2 */
0x188 (PIN_INPUT_PULLDOWN | MUX_MODE7)  /* 
i2c0_sda.uart2_ctsn_mux0 */
0x18c (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
i2c0_scl.uart2_rtsn_mux0 */
0x030 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_ad12.gpio1[12] DTR */
-- 
2.4.3

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


[PATCH 01/39] pinctrl: Move am4372 and dra7 macros to the the SoC header files

2015-11-12 Thread Javier Martinez Canillas
The  header file defines a set of macros
for different SoCs families that falls under the OMAP sub-arch, that
allow to define the padconf register physical address instead of the
register offset from the padconf base.

But the am43xx and dra7xx SoCs families have their own pinctrl header
file so the DTS using these SoCs aren't able to use the AM4372_IOPAD()
and DRA7XX_CORE_IOPAD() macros since  is
not included.

Move the macros to the correct header files so can be used by the DTS.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 include/dt-bindings/pinctrl/am43xx.h | 6 ++
 include/dt-bindings/pinctrl/dra.h| 6 ++
 include/dt-bindings/pinctrl/omap.h   | 2 --
 3 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/include/dt-bindings/pinctrl/am43xx.h 
b/include/dt-bindings/pinctrl/am43xx.h
index 774dc1e843c5..344bd1eb3386 100644
--- a/include/dt-bindings/pinctrl/am43xx.h
+++ b/include/dt-bindings/pinctrl/am43xx.h
@@ -31,5 +31,11 @@
 #define PIN_INPUT_PULLUP   (INPUT_EN | PULL_UP)
 #define PIN_INPUT_PULLDOWN (INPUT_EN)
 
+/*
+ * Macro to allow using the absolute physical address instead of the
+ * padconf registers instead of the offset from padconf base.
+ */
+#define AM4372_IOPAD(pa, val)  (((pa) & 0x) - 0x0800) (val)
+
 #endif
 
diff --git a/include/dt-bindings/pinctrl/dra.h 
b/include/dt-bindings/pinctrl/dra.h
index 4379e29f0460..5c75e80915fc 100644
--- a/include/dt-bindings/pinctrl/dra.h
+++ b/include/dt-bindings/pinctrl/dra.h
@@ -67,5 +67,11 @@
 #define PIN_INPUT_PULLUP   (PULL_ENA | INPUT_EN | PULL_UP)
 #define PIN_INPUT_PULLDOWN (PULL_ENA | INPUT_EN)
 
+/*
+ * Macro to allow using the absolute physical address instead of the
+ * padconf registers instead of the offset from padconf base.
+ */
+#define DRA7XX_CORE_IOPAD(pa, val) (((pa) & 0x) - 0x3400) (val)
+
 #endif
 
diff --git a/include/dt-bindings/pinctrl/omap.h 
b/include/dt-bindings/pinctrl/omap.h
index 13949259705a..8100de13851c 100644
--- a/include/dt-bindings/pinctrl/omap.h
+++ b/include/dt-bindings/pinctrl/omap.h
@@ -63,8 +63,6 @@
 #define OMAP3_WKUP_IOPAD(pa, val)  OMAP_IOPAD_OFFSET((pa), 0x2a00) (val)
 #define DM816X_IOPAD(pa, val)  OMAP_IOPAD_OFFSET((pa), 0x0800) (val)
 #define AM33XX_IOPAD(pa, val)  OMAP_IOPAD_OFFSET((pa), 0x0800) (val)
-#define AM4372_IOPAD(pa, val)  OMAP_IOPAD_OFFSET((pa), 0x0800) (val)
-#define DRA7XX_CORE_IOPAD(pa, val) OMAP_IOPAD_OFFSET((pa), 0x3400) (val)
 
 /*
  * Macros to allow using the offset from the padconf physical address
-- 
2.4.3

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


[PATCH 04/39] ARM: dts: am335x-bone-common: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-bone-common.dtsi | 104 +++---
 1 file changed, 52 insertions(+), 52 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi 
b/arch/arm/boot/dts/am335x-bone-common.dtsi
index 5d370d54bd30..0cc150b87b86 100644
--- a/arch/arm/boot/dts/am335x-bone-common.dtsi
+++ b/arch/arm/boot/dts/am335x-bone-common.dtsi
@@ -67,112 +67,112 @@
 
user_leds_s0: user_leds_s0 {
pinctrl-single,pins = <
-   0x54 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_a5.gpio1_21 */
-   0x58 (PIN_OUTPUT_PULLUP | MUX_MODE7)/* 
gpmc_a6.gpio1_22 */
-   0x5c (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_a7.gpio1_23 */
-   0x60 (PIN_OUTPUT_PULLUP | MUX_MODE7)/* 
gpmc_a8.gpio1_24 */
+   AM33XX_IOPAD(0x854, PIN_OUTPUT_PULLDOWN | MUX_MODE7)
/* gpmc_a5.gpio1_21 */
+   AM33XX_IOPAD(0x858, PIN_OUTPUT_PULLUP | MUX_MODE7)  
/* gpmc_a6.gpio1_22 */
+   AM33XX_IOPAD(0x85c, PIN_OUTPUT_PULLDOWN | MUX_MODE7)
/* gpmc_a7.gpio1_23 */
+   AM33XX_IOPAD(0x860, PIN_OUTPUT_PULLUP | MUX_MODE7)  
/* gpmc_a8.gpio1_24 */
>;
};
 
i2c0_pins: pinmux_i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_scl.i2c0_scl */
>;
};
 
i2c2_pins: pinmux_i2c2_pins {
pinctrl-single,pins = <
-   0x178 (PIN_INPUT_PULLUP | MUX_MODE3)/* 
uart1_ctsn.i2c2_sda */
-   0x17c (PIN_INPUT_PULLUP | MUX_MODE3)/* 
uart1_rtsn.i2c2_scl */
+   AM33XX_IOPAD(0x978, PIN_INPUT_PULLUP | MUX_MODE3)   
/* uart1_ctsn.i2c2_sda */
+   AM33XX_IOPAD(0x97c, PIN_INPUT_PULLUP | MUX_MODE3)   
/* uart1_rtsn.i2c2_scl */
>;
};
 
uart0_pins: pinmux_uart0_pins {
pinctrl-single,pins = <
-   0x170 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart0_rxd.uart0_rxd */
-   0x174 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart0_txd.uart0_txd */
+   AM33XX_IOPAD(0x970, PIN_INPUT_PULLUP | MUX_MODE0)   
/* uart0_rxd.uart0_rxd */
+   AM33XX_IOPAD(0x974, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart0_txd.uart0_txd */
>;
};
 
clkout2_pin: pinmux_clkout2_pin {
pinctrl-single,pins = <
-   0x1b4 (PIN_OUTPUT_PULLDOWN | MUX_MODE3) /* 
xdma_event_intr1.clkout2 */
+   AM33XX_IOPAD(0x9b4, PIN_OUTPUT_PULLDOWN | MUX_MODE3)
/* xdma_event_intr1.clkout2 */
>;
};
 
cpsw_default: cpsw_default {
pinctrl-single,pins = <
/* Slave 1 */
-   0x110 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxerr.mii1_rxerr */
-   0x114 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
mii1_txen.mii1_txen */
-   0x118 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxdv.mii1_rxdv */
-   0x11c (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
mii1_txd3.mii1_txd3 */
-   0x120 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
mii1_txd2.mii1_txd2 */
-   0x124 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
mii1_txd1.mii1_txd1 */
-   0x128 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
mii1_txd0.mii1_txd0 */
-   0x12c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_txclk.mii1_txclk */
-   0x130 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxclk.mii1_rxclk */
-   0x134 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxd3.mii1_rxd3 */
-   0x138 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxd2.mii1_rxd2 */
-   0x13c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxd1.mii1_rxd1 */
-   0x140 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
mii1_rxd0.mii1_rxd0 */
+   AM33XX_IOPAD(0x910, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mii1_rxerr.mii1_rxerr */
+   AM33XX_IOPAD(0x914, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* mii1_txen.mii1_txen */
+

[PATCH 05/39] ARM: dts: am335x-bonegreen: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-bonegreen.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-bonegreen.dts 
b/arch/arm/boot/dts/am335x-bonegreen.dts
index 0f65bdaaa583..dce3c8657e04 100644
--- a/arch/arm/boot/dts/am335x-bonegreen.dts
+++ b/arch/arm/boot/dts/am335x-bonegreen.dts
@@ -36,8 +36,8 @@
 _pinmux {
uart2_pins: uart2_pins {
pinctrl-single,pins = <
-   0x150 (PIN_INPUT | MUX_MODE1)   /* spi0_sclk.uart2_rxd 
*/
-   0x154 (PIN_OUTPUT | MUX_MODE1)  /* spi0_d0.uart2_txd */
+   AM33XX_IOPAD(0x950, PIN_INPUT | MUX_MODE1)  /* 
spi0_sclk.uart2_rxd */
+   AM33XX_IOPAD(0x954, PIN_OUTPUT | MUX_MODE1) /* 
spi0_d0.uart2_txd */
>;
};
 };
-- 
2.4.3

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


[PATCH 22/39] ARM: dts: dra72-evm: Use DRA7XX_CORE_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/dra72-evm.dts | 200 
 1 file changed, 100 insertions(+), 100 deletions(-)

diff --git a/arch/arm/boot/dts/dra72-evm.dts b/arch/arm/boot/dts/dra72-evm.dts
index d6104d5f0c01..e5cc5d307f97 100644
--- a/arch/arm/boot/dts/dra72-evm.dts
+++ b/arch/arm/boot/dts/dra72-evm.dts
@@ -142,158 +142,158 @@
 _pmx_core {
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
-   0x400 (PIN_INPUT | MUX_MODE0) /* i2c1_sda.i2c1_sda */
-   0x404 (PIN_INPUT | MUX_MODE0) /* i2c1_scl.i2c1_scl */
+   DRA7XX_CORE_IOPAD(0x3800, PIN_INPUT | MUX_MODE0) /* 
i2c1_sda.i2c1_sda */
+   DRA7XX_CORE_IOPAD(0x3804, PIN_INPUT | MUX_MODE0) /* 
i2c1_scl.i2c1_scl */
>;
};
 
i2c5_pins: pinmux_i2c5_pins {
pinctrl-single,pins = <
-   0x2b4 (PIN_INPUT | MUX_MODE10) /* mcasp1_axr0.i2c5_sda 
*/
-   0x2b8 (PIN_INPUT | MUX_MODE10) /* mcasp1_axr1.i2c5_scl 
*/
+   DRA7XX_CORE_IOPAD(0x36b4, PIN_INPUT | MUX_MODE10) /* 
mcasp1_axr0.i2c5_sda */
+   DRA7XX_CORE_IOPAD(0x36b8, PIN_INPUT | MUX_MODE10) /* 
mcasp1_axr1.i2c5_scl */
>;
};
 
i2c5_pins: pinmux_i2c5_pins {
pinctrl-single,pins = <
-   0x2b4 (PIN_INPUT | MUX_MODE10) /* mcasp1_axr0.i2c5_sda 
*/
-   0x2b8 (PIN_INPUT | MUX_MODE10) /* mcasp1_axr1.i2c5_scl 
*/
+   DRA7XX_CORE_IOPAD(0x36b4, PIN_INPUT | MUX_MODE10) /* 
mcasp1_axr0.i2c5_sda */
+   DRA7XX_CORE_IOPAD(0x36b8, PIN_INPUT | MUX_MODE10) /* 
mcasp1_axr1.i2c5_scl */
>;
};
 
nand_default: nand_default {
pinctrl-single,pins = <
-   0x0 (PIN_INPUT  | MUX_MODE0) /* gpmc_ad0 */
-   0x4 (PIN_INPUT  | MUX_MODE0) /* gpmc_ad1 */
-   0x8 (PIN_INPUT  | MUX_MODE0) /* gpmc_ad2 */
-   0xc (PIN_INPUT  | MUX_MODE0) /* gpmc_ad3 */
-   0x10(PIN_INPUT  | MUX_MODE0) /* gpmc_ad4 */
-   0x14(PIN_INPUT  | MUX_MODE0) /* gpmc_ad5 */
-   0x18(PIN_INPUT  | MUX_MODE0) /* gpmc_ad6 */
-   0x1c(PIN_INPUT  | MUX_MODE0) /* gpmc_ad7 */
-   0x20(PIN_INPUT  | MUX_MODE0) /* gpmc_ad8 */
-   0x24(PIN_INPUT  | MUX_MODE0) /* gpmc_ad9 */
-   0x28(PIN_INPUT  | MUX_MODE0) /* gpmc_ad10 */
-   0x2c(PIN_INPUT  | MUX_MODE0) /* gpmc_ad11 */
-   0x30(PIN_INPUT  | MUX_MODE0) /* gpmc_ad12 */
-   0x34(PIN_INPUT  | MUX_MODE0) /* gpmc_ad13 */
-   0x38(PIN_INPUT  | MUX_MODE0) /* gpmc_ad14 */
-   0x3c(PIN_INPUT  | MUX_MODE0) /* gpmc_ad15 */
-   0xb4(PIN_OUTPUT | MUX_MODE0) /* gpmc_cs0 */
-   0xc4(PIN_OUTPUT | MUX_MODE0) /* gpmc_advn_ale */
-   0xcc(PIN_OUTPUT | MUX_MODE0) /* gpmc_wen */
-   0xc8(PIN_OUTPUT | MUX_MODE0) /* gpmc_oen_ren */
-   0xd0(PIN_OUTPUT | MUX_MODE0) /* gpmc_ben0 */
-   0xd8(PIN_INPUT  | MUX_MODE0) /* gpmc_wait0 */
+   DRA7XX_CORE_IOPAD(0x3400, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad0 */
+   DRA7XX_CORE_IOPAD(0x3404, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad1 */
+   DRA7XX_CORE_IOPAD(0x3408, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad2 */
+   DRA7XX_CORE_IOPAD(0x340c, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad3 */
+   DRA7XX_CORE_IOPAD(0x3410, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad4 */
+   DRA7XX_CORE_IOPAD(0x3414, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad5 */
+   DRA7XX_CORE_IOPAD(0x3418, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad6 */
+   DRA7XX_CORE_IOPAD(0x341c, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad7 */
+   DRA7XX_CORE_IOPAD(0x3420, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad8 */
+   DRA7XX_CORE_IOPAD(0x3424, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad9 */
+   DRA7XX_CORE_IOPAD(0x3428, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad10 */
+   DRA7XX_CORE_IOPAD(0x342c, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad11 */
+   DRA7XX_CORE_IOPAD(0x3430, PIN_INPUT  | MUX_MODE0) /* 
gpmc_ad12 */
+

[PATCH 20/39] ARM: dts: am57xx-beagle-x15: Use DRA7XX_CORE_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am57xx-beagle-x15.dts | 198 
 1 file changed, 99 insertions(+), 99 deletions(-)

diff --git a/arch/arm/boot/dts/am57xx-beagle-x15.dts 
b/arch/arm/boot/dts/am57xx-beagle-x15.dts
index d9ba6b879fc1..d3b2a92e3a3c 100644
--- a/arch/arm/boot/dts/am57xx-beagle-x15.dts
+++ b/arch/arm/boot/dts/am57xx-beagle-x15.dts
@@ -181,97 +181,97 @@
 _pmx_core {
leds_pins_default: leds_pins_default {
pinctrl-single,pins = <
-   0x3a8 (PIN_OUTPUT | MUX_MODE14) /* spi1_d1.gpio7_8 */
-   0x3ac (PIN_OUTPUT | MUX_MODE14) /* spi1_d0.gpio7_9 */
-   0x3c0 (PIN_OUTPUT | MUX_MODE14) /* spi2_sclk.gpio7_14 */
-   0x3c4 (PIN_OUTPUT | MUX_MODE14) /* spi2_d1.gpio7_15 */
+   DRA7XX_CORE_IOPAD(0x37a8, PIN_OUTPUT | MUX_MODE14)  
/* spi1_d1.gpio7_8 */
+   DRA7XX_CORE_IOPAD(0x37ac, PIN_OUTPUT | MUX_MODE14)  
/* spi1_d0.gpio7_9 */
+   DRA7XX_CORE_IOPAD(0x37c0, PIN_OUTPUT | MUX_MODE14)  
/* spi2_sclk.gpio7_14 */
+   DRA7XX_CORE_IOPAD(0x37c4, PIN_OUTPUT | MUX_MODE14)  
/* spi2_d1.gpio7_15 */
>;
};
 
i2c1_pins_default: i2c1_pins_default {
pinctrl-single,pins = <
-   0x400 (PIN_INPUT_PULLUP | MUX_MODE0)/* i2c1_sda.sda 
*/
-   0x404 (PIN_INPUT_PULLUP | MUX_MODE0)/* i2c1_scl.scl 
*/
+   DRA7XX_CORE_IOPAD(0x3800, PIN_INPUT_PULLUP | MUX_MODE0) 
/* i2c1_sda.sda */
+   DRA7XX_CORE_IOPAD(0x3804, PIN_INPUT_PULLUP | MUX_MODE0) 
/* i2c1_scl.scl */
>;
};
 
hdmi_pins: pinmux_hdmi_pins {
pinctrl-single,pins = <
-   0x408 (PIN_INPUT | MUX_MODE1)   /* 
i2c2_sda.hdmi1_ddc_scl */
-   0x40c (PIN_INPUT | MUX_MODE1)   /* 
i2c2_scl.hdmi1_ddc_sda */
+   DRA7XX_CORE_IOPAD(0x3808, PIN_INPUT | MUX_MODE1)
/* i2c2_sda.hdmi1_ddc_scl */
+   DRA7XX_CORE_IOPAD(0x380c, PIN_INPUT | MUX_MODE1)
/* i2c2_scl.hdmi1_ddc_sda */
>;
};
 
i2c3_pins_default: i2c3_pins_default {
pinctrl-single,pins = <
-   0x2a4 (PIN_INPUT| MUX_MODE10)   /* 
mcasp1_aclkx.i2c3_sda */
-   0x2a8 (PIN_INPUT| MUX_MODE10)   /* mcasp1_fsx.i2c3_scl 
*/
+   DRA7XX_CORE_IOPAD(0x36a4, PIN_INPUT| MUX_MODE10)
/* mcasp1_aclkx.i2c3_sda */
+   DRA7XX_CORE_IOPAD(0x36a8, PIN_INPUT| MUX_MODE10)
/* mcasp1_fsx.i2c3_scl */
>;
};
 
uart3_pins_default: uart3_pins_default {
pinctrl-single,pins = <
-   0x3f8 (PIN_INPUT_SLEW | MUX_MODE2) /* 
uart2_ctsn.uart3_rxd */
-   0x3fc (PIN_INPUT_SLEW | MUX_MODE1) /* 
uart2_rtsn.uart3_txd */
+   DRA7XX_CORE_IOPAD(0x37f8, PIN_INPUT_SLEW | MUX_MODE2) 
/* uart2_ctsn.uart3_rxd */
+   DRA7XX_CORE_IOPAD(0x37fc, PIN_INPUT_SLEW | MUX_MODE1) 
/* uart2_rtsn.uart3_txd */
>;
};
 
mmc1_pins_default: mmc1_pins_default {
pinctrl-single,pins = <
-   0x36c (PIN_INPUT | MUX_MODE14)  /* mmc1sdcd.gpio219 */
-   0x354 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc1_clk.clk */
-   0x358 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc1_cmd.cmd */
-   0x35c (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc1_dat0.dat0 
*/
-   0x360 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc1_dat1.dat1 
*/
-   0x364 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc1_dat2.dat2 
*/
-   0x368 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc1_dat3.dat3 
*/
+   DRA7XX_CORE_IOPAD(0x376c, PIN_INPUT | MUX_MODE14)   
/* mmc1sdcd.gpio219 */
+   DRA7XX_CORE_IOPAD(0x3754, PIN_INPUT_PULLUP | MUX_MODE0) 
/* mmc1_clk.clk */
+   DRA7XX_CORE_IOPAD(0x3758, PIN_INPUT_PULLUP | MUX_MODE0) 
/* mmc1_cmd.cmd */
+   DRA7XX_CORE_IOPAD(0x375c, PIN_INPUT_PULLUP | MUX_MODE0) 
/* mmc1_dat0.dat0 */
+   DRA7XX_CORE_IOPAD(0x3760, PIN_INPUT_PULLUP | MUX_MODE0) 
/* mmc1_dat1.dat1 */
+   DRA7XX_CORE_IOPAD(0x3764, PIN_INPUT_PULLUP | MUX_MODE0) 
/* mmc1_dat2.dat2 */
+   DRA7XX_CORE_IOPAD(0x3768, PIN_INPUT_PULLUP | MUX_MODE0) 
/* mmc1_dat3.dat3 */
>;
};
 
  

[PATCH 21/39] ARM: dts: dra7-evm: Use DRA7XX_CORE_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/dra7-evm.dts | 254 -
 1 file changed, 127 insertions(+), 127 deletions(-)

diff --git a/arch/arm/boot/dts/dra7-evm.dts b/arch/arm/boot/dts/dra7-evm.dts
index 864f60020124..53b3a4b97086 100644
--- a/arch/arm/boot/dts/dra7-evm.dts
+++ b/arch/arm/boot/dts/dra7-evm.dts
@@ -154,100 +154,100 @@
 
vtt_pin: pinmux_vtt_pin {
pinctrl-single,pins = <
-   0x3b4 (PIN_OUTPUT | MUX_MODE14) /* spi1_cs1.gpio7_11 */
+   DRA7XX_CORE_IOPAD(0x37b4, PIN_OUTPUT | MUX_MODE14) /* 
spi1_cs1.gpio7_11 */
>;
};
 
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
-   0x400 (PIN_INPUT | MUX_MODE0) /* i2c1_sda */
-   0x404 (PIN_INPUT | MUX_MODE0) /* i2c1_scl */
+   DRA7XX_CORE_IOPAD(0x3800, PIN_INPUT | MUX_MODE0) /* 
i2c1_sda */
+   DRA7XX_CORE_IOPAD(0x3804, PIN_INPUT | MUX_MODE0) /* 
i2c1_scl */
>;
};
 
i2c2_pins: pinmux_i2c2_pins {
pinctrl-single,pins = <
-   0x408 (PIN_INPUT | MUX_MODE0) /* i2c2_sda */
-   0x40c (PIN_INPUT | MUX_MODE0) /* i2c2_scl */
+   DRA7XX_CORE_IOPAD(0x3808, PIN_INPUT | MUX_MODE0) /* 
i2c2_sda */
+   DRA7XX_CORE_IOPAD(0x380c, PIN_INPUT | MUX_MODE0) /* 
i2c2_scl */
>;
};
 
i2c3_pins: pinmux_i2c3_pins {
pinctrl-single,pins = <
-   0x288 (PIN_INPUT | MUX_MODE9) /* gpio6_14.i2c3_sda */
-   0x28c (PIN_INPUT | MUX_MODE9) /* gpio6_15.i2c3_scl */
+   DRA7XX_CORE_IOPAD(0x3688, PIN_INPUT | MUX_MODE9) /* 
gpio6_14.i2c3_sda */
+   DRA7XX_CORE_IOPAD(0x368c, PIN_INPUT | MUX_MODE9) /* 
gpio6_15.i2c3_scl */
>;
};
 
mcspi1_pins: pinmux_mcspi1_pins {
pinctrl-single,pins = <
-   0x3a4 (PIN_INPUT | MUX_MODE0) /* spi1_sclk */
-   0x3a8 (PIN_INPUT | MUX_MODE0) /* spi1_d1 */
-   0x3ac (PIN_INPUT | MUX_MODE0) /* spi1_d0 */
-   0x3b0 (PIN_INPUT_SLEW | MUX_MODE0) /* spi1_cs0 */
-   0x3b8 (PIN_INPUT_SLEW | MUX_MODE6) /* 
spi1_cs2.hdmi1_hpd */
-   0x3bc (PIN_INPUT_SLEW | MUX_MODE6) /* 
spi1_cs3.hdmi1_cec */
+   DRA7XX_CORE_IOPAD(0x37a4, PIN_INPUT | MUX_MODE0) /* 
spi1_sclk */
+   DRA7XX_CORE_IOPAD(0x37a8, PIN_INPUT | MUX_MODE0) /* 
spi1_d1 */
+   DRA7XX_CORE_IOPAD(0x37ac, PIN_INPUT | MUX_MODE0) /* 
spi1_d0 */
+   DRA7XX_CORE_IOPAD(0x37b0, PIN_INPUT_SLEW | MUX_MODE0) 
/* spi1_cs0 */
+   DRA7XX_CORE_IOPAD(0x37b8, PIN_INPUT_SLEW | MUX_MODE6) 
/* spi1_cs2.hdmi1_hpd */
+   DRA7XX_CORE_IOPAD(0x37bc, PIN_INPUT_SLEW | MUX_MODE6) 
/* spi1_cs3.hdmi1_cec */
>;
};
 
mcspi2_pins: pinmux_mcspi2_pins {
pinctrl-single,pins = <
-   0x3c0 (PIN_INPUT | MUX_MODE0) /* spi2_sclk */
-   0x3c4 (PIN_INPUT_SLEW | MUX_MODE0) /* spi2_d1 */
-   0x3c8 (PIN_INPUT_SLEW | MUX_MODE0) /* spi2_d1 */
-   0x3cc (PIN_INPUT_SLEW | MUX_MODE0) /* spi2_cs0 */
+   DRA7XX_CORE_IOPAD(0x37c0, PIN_INPUT | MUX_MODE0) /* 
spi2_sclk */
+   DRA7XX_CORE_IOPAD(0x37c4, PIN_INPUT_SLEW | MUX_MODE0) 
/* spi2_d1 */
+   DRA7XX_CORE_IOPAD(0x37c8, PIN_INPUT_SLEW | MUX_MODE0) 
/* spi2_d1 */
+   DRA7XX_CORE_IOPAD(0x37cc, PIN_INPUT_SLEW | MUX_MODE0) 
/* spi2_cs0 */
>;
};
 
uart1_pins: pinmux_uart1_pins {
pinctrl-single,pins = <
-   0x3e0 (PIN_INPUT_SLEW | MUX_MODE0) /* uart1_rxd */
-   0x3e4 (PIN_INPUT_SLEW | MUX_MODE0) /* uart1_txd */
-   0x3e8 (PIN_INPUT | MUX_MODE3) /* uart1_ctsn */
-   0x3ec (PIN_INPUT | MUX_MODE3) /* uart1_rtsn */
+   DRA7XX_CORE_IOPAD(0x37e0, PIN_INPUT_SLEW | MUX_MODE0) 
/* uart1_rxd */
+   DRA7XX_CORE_IOPAD(0x37e4, PIN_INPUT_SLEW | MUX_MODE0) 
/* uart1_txd */
+   DRA7XX_CORE_IOPAD(0x37e8, PIN_INPUT | MUX_MODE3) /* 
uart1_ctsn */
+   DRA7XX_CORE_IOPAD(0x37ec, PIN_INPUT | MUX_MODE3) /* 
uart1_rtsn */
>;
  

[PATCH 18/39] ARM: dts: am437x-sk-evm: Use AM4372_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am437x-sk-evm.dts | 298 ++--
 1 file changed, 149 insertions(+), 149 deletions(-)

diff --git a/arch/arm/boot/dts/am437x-sk-evm.dts 
b/arch/arm/boot/dts/am437x-sk-evm.dts
index 63de2a1b4315..d82dd6e3f9b1 100644
--- a/arch/arm/boot/dts/am437x-sk-evm.dts
+++ b/arch/arm/boot/dts/am437x-sk-evm.dts
@@ -157,259 +157,259 @@
 _pinmux {
matrix_keypad_pins: matrix_keypad_pins {
pinctrl-single,pins = <
-   0x24c (PIN_OUTPUT | MUX_MODE7)  /* gpio5_13.gpio5_13 */
-   0x250 (PIN_OUTPUT | MUX_MODE7)  /* spi4_sclk.gpio5_4 */
-   0x254 (PIN_INPUT | MUX_MODE7)   /* spi4_d0.gpio5_5 */
-   0x258 (PIN_INPUT | MUX_MODE7)   /* spi4_d1.gpio5_5 */
+   AM4372_IOPAD(0xa4c, PIN_OUTPUT | MUX_MODE7) /* 
gpio5_13.gpio5_13 */
+   AM4372_IOPAD(0xa50, PIN_OUTPUT | MUX_MODE7) /* 
spi4_sclk.gpio5_4 */
+   AM4372_IOPAD(0xa54, PIN_INPUT | MUX_MODE7)  /* 
spi4_d0.gpio5_5 */
+   AM4372_IOPAD(0xa58, PIN_INPUT | MUX_MODE7)  /* 
spi4_d1.gpio5_5 */
>;
};
 
leds_pins: leds_pins {
pinctrl-single,pins = <
-   0x228 (PIN_OUTPUT | MUX_MODE7)  /* uart3_rxd.gpio5_2 */
-   0x22c (PIN_OUTPUT | MUX_MODE7)  /* uart3_txd.gpio5_3 */
-   0x230 (PIN_OUTPUT | MUX_MODE7)  /* uart3_ctsn.gpio5_0 */
-   0x234 (PIN_OUTPUT | MUX_MODE7)  /* uart3_rtsn.gpio5_1 */
+   AM4372_IOPAD(0xa28, PIN_OUTPUT | MUX_MODE7) /* 
uart3_rxd.gpio5_2 */
+   AM4372_IOPAD(0xa2c, PIN_OUTPUT | MUX_MODE7) /* 
uart3_txd.gpio5_3 */
+   AM4372_IOPAD(0xa30, PIN_OUTPUT | MUX_MODE7) /* 
uart3_ctsn.gpio5_0 */
+   AM4372_IOPAD(0xa34, PIN_OUTPUT | MUX_MODE7) /* 
uart3_rtsn.gpio5_1 */
>;
};
 
i2c0_pins: i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE0)  /* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE0)  /* 
i2c0_scl.i2c0_scl */
+   AM4372_IOPAD(0x988, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE0)  /* i2c0_sda.i2c0_sda */
+   AM4372_IOPAD(0x98c, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE0)  /* i2c0_scl.i2c0_scl */
>;
};
 
i2c1_pins: i2c1_pins {
pinctrl-single,pins = <
-   0x15c (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE2)  /* 
spi0_cs0.i2c1_scl */
-   0x158 (PIN_INPUT | SLEWCTRL_FAST | MUX_MODE2)  /* 
spi0_d1.i2c1_sda  */
+   AM4372_IOPAD(0x95c, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE2)  /* spi0_cs0.i2c1_scl */
+   AM4372_IOPAD(0x958, PIN_INPUT | SLEWCTRL_FAST | 
MUX_MODE2)  /* spi0_d1.i2c1_sda  */
>;
};
 
mmc1_pins: pinmux_mmc1_pins {
pinctrl-single,pins = <
-   0x0f0 (PIN_INPUT | MUX_MODE0) /* mmc0_dat3.mmc0_dat3 */
-   0x0f4 (PIN_INPUT | MUX_MODE0) /* mmc0_dat2.mmc0_dat2 */
-   0x0f8 (PIN_INPUT | MUX_MODE0) /* mmc0_dat1.mmc0_dat1 */
-   0x0fc (PIN_INPUT | MUX_MODE0) /* mmc0_dat0.mmc0_dat0 */
-   0x100 (PIN_INPUT | MUX_MODE0) /* mmc0_clk.mmc0_clk */
-   0x104 (PIN_INPUT | MUX_MODE0) /* mmc0_cmd.mmc0_cmd */
-   0x160 (PIN_INPUT | MUX_MODE7) /* spi0_cs1.gpio0_6 */
+   AM4372_IOPAD(0x8f0, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat3.mmc0_dat3 */
+   AM4372_IOPAD(0x8f4, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat2.mmc0_dat2 */
+   AM4372_IOPAD(0x8f8, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat1.mmc0_dat1 */
+   AM4372_IOPAD(0x8fc, PIN_INPUT | MUX_MODE0) /* 
mmc0_dat0.mmc0_dat0 */
+   AM4372_IOPAD(0x900, PIN_INPUT | MUX_MODE0) /* 
mmc0_clk.mmc0_clk */
+   AM4372_IOPAD(0x904, PIN_INPUT | MUX_MODE0) /* 
mmc0_cmd.mmc0_cmd */
+   AM4372_IOPAD(0x960, PIN_INPUT | MUX_MODE7) /* 
spi0_cs1.gpio0_6 */
>;
};
 
ecap0_pins: backlight_pins {
pinctrl-single,pins = <
-   0x164 (PIN_OUTPUT | MUX_MODE0) /* 
eCAP0_in_PWM0_out.eCAP0_in_PWM0_out */
+   AM4372_IOPAD(0x964, PIN_OUTPUT | MUX_MODE0) 

[PATCH 24/39] ARM: dts: omap3-beagle-xm: Use OMAP3_*_IOPAD pinmux macros

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-beagle-xm.dts | 18 +-
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle-xm.dts 
b/arch/arm/boot/dts/omap3-beagle-xm.dts
index 73f1e3a8f62c..5e0bf475051e 100644
--- a/arch/arm/boot/dts/omap3-beagle-xm.dts
+++ b/arch/arm/boot/dts/omap3-beagle-xm.dts
@@ -176,18 +176,18 @@
 _pmx_wkup {
gpio1_pins: pinmux_gpio1_pins {
pinctrl-single,pins = <
-   0x0e (PIN_INPUT | PIN_OFF_WAKEUPENABLE | MUX_MODE4) /* 
sys_boot2.gpio_4 */
+   OMAP3_WKUP_IOPAD(0x2a0e, PIN_INPUT | 
PIN_OFF_WAKEUPENABLE | MUX_MODE4) /* sys_boot2.gpio_4 */
>;
};
 
dss_dpi_pins2: pinmux_dss_dpi_pins1 {
pinctrl-single,pins = <
-   0x0a (PIN_OUTPUT | MUX_MODE3)   /* sys_boot0.dss_data18 
*/
-   0x0c (PIN_OUTPUT | MUX_MODE3)   /* sys_boot1.dss_data19 
*/
-   0x10 (PIN_OUTPUT | MUX_MODE3)   /* sys_boot3.dss_data20 
*/
-   0x12 (PIN_OUTPUT | MUX_MODE3)   /* sys_boot4.dss_data21 
*/
-   0x14 (PIN_OUTPUT | MUX_MODE3)   /* sys_boot5.dss_data22 
*/
-   0x16 (PIN_OUTPUT | MUX_MODE3)   /* sys_boot6.dss_data23 
*/
+   OMAP3_WKUP_IOPAD(0x2a0a, PIN_OUTPUT | MUX_MODE3)   /* 
sys_boot0.dss_data18 */
+   OMAP3_WKUP_IOPAD(0x2a0c, PIN_OUTPUT | MUX_MODE3)   /* 
sys_boot1.dss_data19 */
+   OMAP3_WKUP_IOPAD(0x2a10, PIN_OUTPUT | MUX_MODE3)   /* 
sys_boot3.dss_data20 */
+   OMAP3_WKUP_IOPAD(0x2a12, PIN_OUTPUT | MUX_MODE3)   /* 
sys_boot4.dss_data21 */
+   OMAP3_WKUP_IOPAD(0x2a14, PIN_OUTPUT | MUX_MODE3)   /* 
sys_boot5.dss_data22 */
+   OMAP3_WKUP_IOPAD(0x2a16, PIN_OUTPUT | MUX_MODE3)   /* 
sys_boot6.dss_data23 */
>;
};
 };
@@ -200,8 +200,8 @@
 
uart3_pins: pinmux_uart3_pins {
pinctrl-single,pins = <
-   0x16e (PIN_INPUT | MUX_MODE0)   /* 
uart3_rx_irrx.uart3_rx_irrx */
-   0x170 (PIN_OUTPUT | MUX_MODE0)  /* 
uart3_tx_irtx.uart3_tx_irtx OUTPUT | MODE0 */
+   OMAP3_CORE1_IOPAD(0x219e, PIN_INPUT | MUX_MODE0)
/* uart3_rx_irrx.uart3_rx_irrx */
+   OMAP3_CORE1_IOPAD(0x21a0, PIN_OUTPUT | MUX_MODE0)   
/* uart3_tx_irtx.uart3_tx_irtx OUTPUT | MODE0 */
>;
};
 
-- 
2.4.3

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


[PATCH 25/39] ARM: dts: omap3-evm-37xx: Use OMAP3_*_IOPAD pinmux macros

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-evm-37xx.dts | 54 ++--
 1 file changed, 27 insertions(+), 27 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-evm-37xx.dts 
b/arch/arm/boot/dts/omap3-evm-37xx.dts
index bb339d1648e0..ac188657a95d 100644
--- a/arch/arm/boot/dts/omap3-evm-37xx.dts
+++ b/arch/arm/boot/dts/omap3-evm-37xx.dts
@@ -66,48 +66,48 @@
 
mmc1_pins: pinmux_mmc1_pins {
pinctrl-single,pins = <
-   0x114 (PIN_OUTPUT_PULLUP | MUX_MODE0)   /* 
sdmmc1_clk.sdmmc1_clk */
-   0x116 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_cmd.sdmmc1_cmd */
-   0x118 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat0.sdmmc1_dat0 */
-   0x11a (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat1.sdmmc1_dat1 */
-   0x11c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat2.sdmmc1_dat2 */
-   0x11e (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat3.sdmmc1_dat3 */
-   0x120 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat4.sdmmc1_dat4 */
-   0x122 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat5.sdmmc1_dat5 */
-   0x124 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat6.sdmmc1_dat6 */
-   0x126 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat7.sdmmc1_dat7 */
+   OMAP3_CORE1_IOPAD(0x2144, PIN_OUTPUT_PULLUP | 
MUX_MODE0)/* sdmmc1_clk.sdmmc1_clk */
+   OMAP3_CORE1_IOPAD(0x2146, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_cmd.sdmmc1_cmd */
+   OMAP3_CORE1_IOPAD(0x2148, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat0.sdmmc1_dat0 */
+   OMAP3_CORE1_IOPAD(0x214a, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat1.sdmmc1_dat1 */
+   OMAP3_CORE1_IOPAD(0x214c, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat2.sdmmc1_dat2 */
+   OMAP3_CORE1_IOPAD(0x214e, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat3.sdmmc1_dat3 */
+   OMAP3_CORE1_IOPAD(0x2150, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat4.sdmmc1_dat4 */
+   OMAP3_CORE1_IOPAD(0x2152, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat5.sdmmc1_dat5 */
+   OMAP3_CORE1_IOPAD(0x2154, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat6.sdmmc1_dat6 */
+   OMAP3_CORE1_IOPAD(0x2156, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat7.sdmmc1_dat7 */
>;
};
 
/* NOTE: Clocked externally, needs INPUT also for sdmmc2_clk.sdmmc2_clk 
*/
mmc2_pins: pinmux_mmc2_pins {
pinctrl-single,pins = <
-   0x128 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_clk.sdmmc2_clk */
-   0x12a (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_cmd.sdmmc2_cmd */
-   0x12c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_dat0.sdmmc2_dat0 */
-   0x12e (WAKEUP_EN | PIN_INPUT_PULLUP | MUX_MODE0) /* 
sdmmc2_dat1.sdmmc2_dat1 */
-   0x130 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_dat2.sdmmc2_dat2 */
-   0x132 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_dat3.sdmmc2_dat3 */
+   OMAP3_CORE1_IOPAD(0x2158, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_clk.sdmmc2_clk */
+   OMAP3_CORE1_IOPAD(0x215a, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_cmd.sdmmc2_cmd */
+   OMAP3_CORE1_IOPAD(0x215c, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat0.sdmmc2_dat0 */
+   OMAP3_CORE1_IOPAD(0x215e, WAKEUP_EN | PIN_INPUT_PULLUP 
| MUX_MODE0) /* sdmmc2_dat1.sdmmc2_dat1 */
+   OMAP3_CORE1_IOPAD(0x2160, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat2.sdmmc2_dat2 */
+   OMAP3_CORE1_IOPAD(0x2162, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_dat3.sdmmc2_dat3 */
>;
};
 
uart3_pins: pinmux_uart3_pins {
pinctrl-single,pins = <
-   0x16e (WAKEUP_EN | PIN_INPUT | MUX_MODE0) /* 
uart3_rx_irrx.uart3_rx_irrx */
-   0x170 (PIN_OUTPUT | MUX_MODE0)  /* 
uart3_tx_irtx.uart3_tx_irtx */
+   OMAP3_CORE1_IOPAD(0x219e, WAKEUP_EN | PIN_INPUT | 
MUX_MODE0) /* uart3_rx_irrx.uart3_rx_irrx */
+   OMAP3_CORE1_IOPAD(0x21a0, PIN_OUTPUT | MUX_MODE0)   
/* uart3_tx_irtx.uart3_tx_irtx */
>;
};
 
wl12xx_gpio: pinmux_wl12xx_gpio {
   

[PATCH 23/39] ARM: dts: omap3-beagle: Use OMAP3_*_IOPAD pinmux macros

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-beagle.dts | 64 +++---
 1 file changed, 32 insertions(+), 32 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-beagle.dts 
b/arch/arm/boot/dts/omap3-beagle.dts
index 274c2c482aaa..8dcf84ac79bb 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -171,7 +171,7 @@
 _pmx_wkup {
gpio1_pins: pinmux_gpio1_pins {
pinctrl-single,pins = <
-   0x14 (PIN_INPUT | PIN_OFF_WAKEUPENABLE | MUX_MODE4) /* 
sys_boot5.gpio_7 */
+   OMAP3_WKUP_IOPAD(0x2a14, PIN_INPUT | 
PIN_OFF_WAKEUPENABLE | MUX_MODE4) /* sys_boot5.gpio_7 */
>;
};
 };
@@ -195,47 +195,47 @@
 
uart3_pins: pinmux_uart3_pins {
pinctrl-single,pins = <
-   0x16e (PIN_INPUT | PIN_OFF_WAKEUPENABLE | MUX_MODE0) /* 
uart3_rx_irrx.uart3_rx_irrx */
-   0x170 (PIN_OUTPUT | MUX_MODE0) /* 
uart3_tx_irtx.uart3_tx_irtx */
+   OMAP3_CORE1_IOPAD(0x219e, PIN_INPUT | 
PIN_OFF_WAKEUPENABLE | MUX_MODE0) /* uart3_rx_irrx.uart3_rx_irrx */
+   OMAP3_CORE1_IOPAD(0x21a0, PIN_OUTPUT | MUX_MODE0) /* 
uart3_tx_irtx.uart3_tx_irtx */
>;
};
 
tfp410_pins: pinmux_tfp410_pins {
pinctrl-single,pins = <
-   0x196 (PIN_OUTPUT | MUX_MODE4)  /* hdq_sio.gpio_170 */
+   OMAP3_CORE1_IOPAD(0x21c6, PIN_OUTPUT | MUX_MODE4)   
/* hdq_sio.gpio_170 */
>;
};
 
dss_dpi_pins: pinmux_dss_dpi_pins {
pinctrl-single,pins = <
-   0x0a4 (PIN_OUTPUT | MUX_MODE0)   /* dss_pclk.dss_pclk */
-   0x0a6 (PIN_OUTPUT | MUX_MODE0)   /* dss_hsync.dss_hsync 
*/
-   0x0a8 (PIN_OUTPUT | MUX_MODE0)   /* dss_vsync.dss_vsync 
*/
-   0x0aa (PIN_OUTPUT | MUX_MODE0)   /* 
dss_acbias.dss_acbias */
-   0x0ac (PIN_OUTPUT | MUX_MODE0)   /* dss_data0.dss_data0 
*/
-   0x0ae (PIN_OUTPUT | MUX_MODE0)   /* dss_data1.dss_data1 
*/
-   0x0b0 (PIN_OUTPUT | MUX_MODE0)   /* dss_data2.dss_data2 
*/
-   0x0b2 (PIN_OUTPUT | MUX_MODE0)   /* dss_data3.dss_data3 
*/
-   0x0b4 (PIN_OUTPUT | MUX_MODE0)   /* dss_data4.dss_data4 
*/
-   0x0b6 (PIN_OUTPUT | MUX_MODE0)   /* dss_data5.dss_data5 
*/
-   0x0b8 (PIN_OUTPUT | MUX_MODE0)   /* dss_data6.dss_data6 
*/
-   0x0ba (PIN_OUTPUT | MUX_MODE0)   /* dss_data7.dss_data7 
*/
-   0x0bc (PIN_OUTPUT | MUX_MODE0)   /* dss_data8.dss_data8 
*/
-   0x0be (PIN_OUTPUT | MUX_MODE0)   /* dss_data9.dss_data9 
*/
-   0x0c0 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data10.dss_data10 */
-   0x0c2 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data11.dss_data11 */
-   0x0c4 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data12.dss_data12 */
-   0x0c6 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data13.dss_data13 */
-   0x0c8 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data14.dss_data14 */
-   0x0ca (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data15.dss_data15 */
-   0x0cc (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data16.dss_data16 */
-   0x0ce (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data17.dss_data17 */
-   0x0d0 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data18.dss_data18 */
-   0x0d2 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data19.dss_data19 */
-   0x0d4 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data20.dss_data20 */
-   0x0d6 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data21.dss_data21 */
-   0x0d8 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data22.dss_data22 */
-   0x0da (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data23.dss_data23 */
+   OMAP3_CORE1_IOPAD(0x20d4, PIN_OUTPUT | MUX_MODE0)   /* 
dss_pclk.dss_pclk */
+   OMAP3_CORE1_IOPAD(0x20d6, PIN_OUTPUT | MUX_MODE0)   /* 
dss_hsync.dss_hsync */
+   OMAP3_CORE1_IOPAD(0x20d8, PIN_OUTPUT | MUX_MODE0)   /* 
dss_vsync.dss_vsync */
+   OMAP3_CORE1_IOPAD(0x20da, PIN_OUTPUT | MUX_MODE0)   /* 
dss_acbias.dss_acbias */
+   OMAP3_CORE1_IOPAD(0x20dc, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data0.dss_data0 */
+   OMAP3_CORE1_IOPAD(0x20de, PIN_OUTPUT | MUX_MODE0

[PATCH 26/39] ARM: dts: omap3-ldp: Use OMAP3_CORE1_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-ldp.dts | 42 -
 1 file changed, 21 insertions(+), 21 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-ldp.dts b/arch/arm/boot/dts/omap3-ldp.dts
index d2fab8c0d4f8..0d0f1a7444f7 100644
--- a/arch/arm/boot/dts/omap3-ldp.dts
+++ b/arch/arm/boot/dts/omap3-ldp.dts
@@ -224,32 +224,32 @@
 _pmx_core {
gpio_key_pins: pinmux_gpio_key_pins {
pinctrl-single,pins = <
-   0xea (PIN_INPUT | MUX_MODE4)/* cam_d2.gpio_101 */
-   0xec (PIN_INPUT | MUX_MODE4)/* cam_d3.gpio_102 */
-   0xee (PIN_INPUT | MUX_MODE4)/* cam_d4.gpio_103 */
-   0xf0 (PIN_INPUT | MUX_MODE4)/* cam_d5.gpio_104 */
-   0xf2 (PIN_INPUT | MUX_MODE4)/* cam_d6.gpio_105 */
-   0xf4 (PIN_INPUT | MUX_MODE4)/* cam_d7.gpio_106 */
-   0xf6 (PIN_INPUT | MUX_MODE4)/* cam_d8.gpio_107 */
-   0xf8 (PIN_INPUT | MUX_MODE4)/* cam_d9.gpio_108 */
-   0xfa (PIN_INPUT | MUX_MODE4)/* cam_d10.gpio_109 */
+   OMAP3_CORE1_IOPAD(0x211a, PIN_INPUT | MUX_MODE4)
/* cam_d2.gpio_101 */
+   OMAP3_CORE1_IOPAD(0x211c, PIN_INPUT | MUX_MODE4)
/* cam_d3.gpio_102 */
+   OMAP3_CORE1_IOPAD(0x211e, PIN_INPUT | MUX_MODE4)
/* cam_d4.gpio_103 */
+   OMAP3_CORE1_IOPAD(0x2120, PIN_INPUT | MUX_MODE4)
/* cam_d5.gpio_104 */
+   OMAP3_CORE1_IOPAD(0x2122, PIN_INPUT | MUX_MODE4)
/* cam_d6.gpio_105 */
+   OMAP3_CORE1_IOPAD(0x2124, PIN_INPUT | MUX_MODE4)
/* cam_d7.gpio_106 */
+   OMAP3_CORE1_IOPAD(0x2126, PIN_INPUT | MUX_MODE4)
/* cam_d8.gpio_107 */
+   OMAP3_CORE1_IOPAD(0x2128, PIN_INPUT | MUX_MODE4)
/* cam_d9.gpio_108 */
+   OMAP3_CORE1_IOPAD(0x212a, PIN_INPUT | MUX_MODE4)
/* cam_d10.gpio_109 */
>;
};
 
musb_pins: pinmux_musb_pins {
pinctrl-single,pins = <
-   0x172 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_clk.hsusb0_clk */
-   0x17a (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data0.hsusb0_data0 */
-   0x17c (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data1.hsusb0_data1 */
-   0x17e (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data2.hsusb0_data2 */
-   0x180 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data3.hsusb0_data3 */
-   0x182 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data4.hsusb0_data4 */
-   0x184 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data5.hsusb0_data5 */
-   0x186 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data6.hsusb0_data6 */
-   0x188 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_data7.hsusb0_data7 */
-   0x176 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_dir.hsusb0_dir */
-   0x178 (PIN_INPUT | MUX_MODE0)   /* 
hsusb0_nxt.hsusb0_nxt */
-   0x174 (PIN_OUTPUT | MUX_MODE0)  /* 
hsusb0_stp.hsusb0_stp */
+   OMAP3_CORE1_IOPAD(0x21a2, PIN_INPUT | MUX_MODE0)
/* hsusb0_clk.hsusb0_clk */
+   OMAP3_CORE1_IOPAD(0x21aa, PIN_INPUT | MUX_MODE0)
/* hsusb0_data0.hsusb0_data0 */
+   OMAP3_CORE1_IOPAD(0x21ac, PIN_INPUT | MUX_MODE0)
/* hsusb0_data1.hsusb0_data1 */
+   OMAP3_CORE1_IOPAD(0x21ae, PIN_INPUT | MUX_MODE0)
/* hsusb0_data2.hsusb0_data2 */
+   OMAP3_CORE1_IOPAD(0x21b0, PIN_INPUT | MUX_MODE0)
/* hsusb0_data3.hsusb0_data3 */
+   OMAP3_CORE1_IOPAD(0x21b2, PIN_INPUT | MUX_MODE0)
/* hsusb0_data4.hsusb0_data4 */
+   OMAP3_CORE1_IOPAD(0x21b4, PIN_INPUT | MUX_MODE0)
/* hsusb0_data5.hsusb0_data5 */
+   OMAP3_CORE1_IOPAD(0x21b6, PIN_INPUT | MUX_MODE0)
/* hsusb0_data6.hsusb0_data6 */
+   OMAP3_CORE1_IOPAD(0x21b8, PIN_INPUT | MUX_MODE0)
/* hsusb0_data7.hsusb0_data7 */
+   OMAP3_CORE1_IOPAD(0x21a6, PIN_INPUT | MUX_MODE0)
/* hsusb0_dir.hsusb0_dir */
+   OMAP3_CORE1_IOPAD(0x21a8, PIN_INPUT | MUX_MODE0)
/* hsusb0_nxt.hsusb0_nxt */
+   OMAP3_CORE1_IOPAD(0x21a4, PIN_OUTPUT | MUX_MODE0)   
/* hsusb0_stp.hsusb0_stp */
>;
};
 
-- 
2.4.3

--
To unsubscribe from this list: send the line 

[PATCH 29/39] ARM: dts: omap3-zoom3: Use OMAP3_*_IOPAD pinmux macros

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macros to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-zoom3.dts | 60 +++
 1 file changed, 30 insertions(+), 30 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-zoom3.dts 
b/arch/arm/boot/dts/omap3-zoom3.dts
index 7bc5fdd6981e..f19170bdcc1f 100644
--- a/arch/arm/boot/dts/omap3-zoom3.dts
+++ b/arch/arm/boot/dts/omap3-zoom3.dts
@@ -54,27 +54,27 @@
/* REVISIT: twl gpio0 is mmc0_cd */
mmc1_pins: pinmux_mmc1_pins {
pinctrl-single,pins = <
-   0x114 (PIN_OUTPUT_PULLUP | MUX_MODE0)   /* 
sdmmc1_clk.sdmmc1_clk */
-   0x116 (PIN_OUTPUT_PULLUP | MUX_MODE0)   /* 
sdmmc1_cmd.sdmmc1_cmd */
-   0x118 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat0.sdmmc1_dat0 */
-   0x11a (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat1.sdmmc1_dat1 */
-   0x11c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat2.sdmmc1_dat2 */
-   0x11e (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc1_dat3.sdmmc1_dat3 */
+   OMAP3_CORE1_IOPAD(0x2144, PIN_OUTPUT_PULLUP | 
MUX_MODE0)/* sdmmc1_clk.sdmmc1_clk */
+   OMAP3_CORE1_IOPAD(0x2146, PIN_OUTPUT_PULLUP | 
MUX_MODE0)/* sdmmc1_cmd.sdmmc1_cmd */
+   OMAP3_CORE1_IOPAD(0x2148, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat0.sdmmc1_dat0 */
+   OMAP3_CORE1_IOPAD(0x214a, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat1.sdmmc1_dat1 */
+   OMAP3_CORE1_IOPAD(0x214c, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat2.sdmmc1_dat2 */
+   OMAP3_CORE1_IOPAD(0x214e, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat3.sdmmc1_dat3 */
>;
};
 
mmc2_pins: pinmux_mmc2_pins {
pinctrl-single,pins = <
-   0x128 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_clk.sdmmc2_clk */
-   0x12a (PIN_INPUT_PULLUP | MUX_MODE0)/* 
sdmmc2_cmd.sdmmc2_cmd */
-   0x12c (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat0.sdmmc2_dat0 */
-   0x12e (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat1.sdmmc2_dat1 */
-   0x130 (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat2.sdmmc2_dat2 */
-   0x132 (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat3.sdmmc2_dat3 */
-   0x134 (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat4.sdmmc2_dat4 */
-   0x136 (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat5.sdmmc2_dat5 */
-   0x138 (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat6.sdmmc2_dat6 */
-   0x13a (PIN_INPUT | MUX_MODE0)   /* 
sdmmc2_dat7.sdmmc2_dat7 */
+   OMAP3_CORE1_IOPAD(0x2158, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_clk.sdmmc2_clk */
+   OMAP3_CORE1_IOPAD(0x215a, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc2_cmd.sdmmc2_cmd */
+   OMAP3_CORE1_IOPAD(0x215c, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat0.sdmmc2_dat0 */
+   OMAP3_CORE1_IOPAD(0x215e, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat1.sdmmc2_dat1 */
+   OMAP3_CORE1_IOPAD(0x2160, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat2.sdmmc2_dat2 */
+   OMAP3_CORE1_IOPAD(0x2162, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat3.sdmmc2_dat3 */
+   OMAP3_CORE1_IOPAD(0x2164, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat4.sdmmc2_dat4 */
+   OMAP3_CORE1_IOPAD(0x2166, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat5.sdmmc2_dat5 */
+   OMAP3_CORE1_IOPAD(0x2168, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat6.sdmmc2_dat6 */
+   OMAP3_CORE1_IOPAD(0x216a, PIN_INPUT | MUX_MODE0)
/* sdmmc2_dat7.sdmmc2_dat7 */
>;
};
 
@@ -87,35 +87,35 @@
 
uart1_pins: pinmux_uart1_pins {
pinctrl-single,pins = <
-0x150 (PIN_INPUT | MUX_MODE0)  /* 
uart1_cts.uart1_cts */
-0x14e (PIN_OUTPUT | MUX_MODE0) /* 
uart1_rts.uart1_rts */
-0x152 (WAKEUP_EN | PIN_INPUT | MUX_MODE0) /* 
uart1_rx.uart1_rx */
-0x14c (PIN_OUTPUT | MUX_MODE0) /* 
uart1_tx.uart1_tx */
+OMAP3_CORE1_IOPAD(0x2180, PIN_INPUT | MUX_MODE0)   
/* uart1_cts.uart1_cts */
+OMAP3_CORE1_IOPAD(0x217e, PIN_OUTPUT | MUX_MODE0)  
/

[PATCH 27/39] ARM: dts: omap3-n900: Use OMAP3_CORE1_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-n900.dts | 106 +++
 1 file changed, 53 insertions(+), 53 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-n900.dts b/arch/arm/boot/dts/omap3-n900.dts
index 5f5e0f3d5b64..f8a20f32e26c 100644
--- a/arch/arm/boot/dts/omap3-n900.dts
+++ b/arch/arm/boot/dts/omap3-n900.dts
@@ -149,15 +149,15 @@
 
uart2_pins: pinmux_uart2_pins {
pinctrl-single,pins = <
-   0x14a (PIN_INPUT | MUX_MODE0)   /* uart2_rx */
-   0x148 (PIN_OUTPUT | MUX_MODE0)  /* uart2_tx */
+   OMAP3_CORE1_IOPAD(0x217a, PIN_INPUT | MUX_MODE0)
/* uart2_rx */
+   OMAP3_CORE1_IOPAD(0x2178, PIN_OUTPUT | MUX_MODE0)   
/* uart2_tx */
>;
};
 
uart3_pins: pinmux_uart3_pins {
pinctrl-single,pins = <
-   0x16e (PIN_INPUT | MUX_MODE0)   /* uart3_rx */
-   0x170 (PIN_OUTPUT | MUX_MODE0)  /* uart3_tx */
+   OMAP3_CORE1_IOPAD(0x219e, PIN_INPUT | MUX_MODE0)
/* uart3_rx */
+   OMAP3_CORE1_IOPAD(0x21a0, PIN_OUTPUT | MUX_MODE0)   
/* uart3_tx */
>;
};
 
@@ -198,22 +198,22 @@
 
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
-   0x18a (PIN_INPUT | MUX_MODE0)   /* i2c1_scl */
-   0x18c (PIN_INPUT | MUX_MODE0)   /* i2c1_sda */
+   OMAP3_CORE1_IOPAD(0x21ba, PIN_INPUT | MUX_MODE0)
/* i2c1_scl */
+   OMAP3_CORE1_IOPAD(0x21bc, PIN_INPUT | MUX_MODE0)
/* i2c1_sda */
>;
};
 
i2c2_pins: pinmux_i2c2_pins {
pinctrl-single,pins = <
-   0x18e (PIN_INPUT | MUX_MODE0)   /* i2c2_scl */
-   0x190 (PIN_INPUT | MUX_MODE0)   /* i2c2_sda */
+   OMAP3_CORE1_IOPAD(0x21be, PIN_INPUT | MUX_MODE0)
/* i2c2_scl */
+   OMAP3_CORE1_IOPAD(0x21c0, PIN_INPUT | MUX_MODE0)
/* i2c2_sda */
>;
};
 
i2c3_pins: pinmux_i2c3_pins {
pinctrl-single,pins = <
-   0x192 (PIN_INPUT | MUX_MODE0)   /* i2c3_scl */
-   0x194 (PIN_INPUT | MUX_MODE0)   /* i2c3_sda */
+   OMAP3_CORE1_IOPAD(0x21c2, PIN_INPUT | MUX_MODE0)
/* i2c3_scl */
+   OMAP3_CORE1_IOPAD(0x21c4, PIN_INPUT | MUX_MODE0)
/* i2c3_sda */
>;
};
 
@@ -225,85 +225,85 @@
 
mcspi4_pins: pinmux_mcspi4_pins {
pinctrl-single,pins = <
-   0x15c (PIN_INPUT_PULLDOWN | MUX_MODE1) /* mcspi4_clk */
-   0x162 (PIN_INPUT_PULLDOWN | MUX_MODE1) /* mcspi4_somi */
-   0x160 (PIN_OUTPUT | MUX_MODE1) /* mcspi4_simo */
-   0x166 (PIN_OUTPUT | MUX_MODE1) /* mcspi4_cs0 */
+   OMAP3_CORE1_IOPAD(0x218c, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mcspi4_clk */
+   OMAP3_CORE1_IOPAD(0x2192, PIN_INPUT_PULLDOWN | 
MUX_MODE1) /* mcspi4_somi */
+   OMAP3_CORE1_IOPAD(0x2190, PIN_OUTPUT | MUX_MODE1) /* 
mcspi4_simo */
+   OMAP3_CORE1_IOPAD(0x2196, PIN_OUTPUT | MUX_MODE1) /* 
mcspi4_cs0 */
>;
};
 
mmc1_pins: pinmux_mmc1_pins {
pinctrl-single,pins = <
-   0x114 (PIN_INPUT_PULLUP | MUX_MODE0)/* sdmmc1_clk */
-   0x116 (PIN_INPUT_PULLUP | MUX_MODE0)/* sdmmc1_cmd */
-   0x118 (PIN_INPUT_PULLUP | MUX_MODE0)/* sdmmc1_dat0 
*/
-   0x11a (PIN_INPUT_PULLUP | MUX_MODE0)/* sdmmc1_dat1 
*/
-   0x11c (PIN_INPUT_PULLUP | MUX_MODE0)/* sdmmc1_dat2 
*/
-   0x11e (PIN_INPUT_PULLUP | MUX_MODE0)/* sdmmc1_dat3 
*/
+   OMAP3_CORE1_IOPAD(0x2144, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_clk */
+   OMAP3_CORE1_IOPAD(0x2146, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_cmd */
+   OMAP3_CORE1_IOPAD(0x2148, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat0 */
+   OMAP3_CORE1_IOPAD(0x214a, PIN_INPUT_PULLUP | MUX_MODE0) 
/* sdmmc1_dat1 */
+   OMAP3_CORE1_IOPAD(0x214c, 

[PATCH 12/39] ARM: dts: am335x-pepper: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-pepper.dts | 200 ++--
 1 file changed, 100 insertions(+), 100 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-pepper.dts 
b/arch/arm/boot/dts/am335x-pepper.dts
index 7106114c7464..f9d7239ebdaf 100644
--- a/arch/arm/boot/dts/am335x-pepper.dts
+++ b/arch/arm/boot/dts/am335x-pepper.dts
@@ -93,14 +93,14 @@
 _pinmux {
i2c0_pins: pinmux_i2c0 {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_scl.i2c0_scl */
>;
};
i2c1_pins: pinmux_i2c1 {
pinctrl-single,pins = <
-   0x10C (PIN_INPUT_PULLUP | MUX_MODE3)/* 
mii1_crs,i2c1_sda */
-   0x110 (PIN_INPUT_PULLUP | MUX_MODE3)/* 
mii1_rxerr,i2c1_scl */
+   AM33XX_IOPAD(0x90C, PIN_INPUT_PULLUP | MUX_MODE3)   
/* mii1_crs,i2c1_sda */
+   AM33XX_IOPAD(0x910, PIN_INPUT_PULLUP | MUX_MODE3)   
/* mii1_rxerr,i2c1_scl */
>;
};
 };
@@ -130,7 +130,7 @@
 _pinmux {
accel_pins: pinmux_accel {
pinctrl-single,pins = <
-   0x98 (PIN_INPUT | MUX_MODE7)   /* gpmc_wen.gpio2_4 */
+   AM33XX_IOPAD(0x898, PIN_INPUT | MUX_MODE7)   /* 
gpmc_wen.gpio2_4 */
>;
};
 };
@@ -177,12 +177,12 @@
 _pinmux {
audio_pins: pinmux_audio {
pinctrl-single,pins = <
-   0x1AC (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
mcasp0_ahcklx.mcasp0_ahclkx */
-   0x194 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
mcasp0_fsx.mcasp0_fsx */
-   0x190 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
mcasp0_aclkx.mcasp0_aclkx */
-   0x198 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
mcasp0_axr0.mcasp0_axr0 */
-   0x1A8 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* 
mcasp0_axr1.mcasp0_axr1 */
-   0x40 (PIN_OUTPUT | MUX_MODE7)   /* gpmc_a0.gpio1_16 */
+   AM33XX_IOPAD(0x9ac, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* mcasp0_ahcklx.mcasp0_ahclkx */
+   AM33XX_IOPAD(0x994, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* mcasp0_fsx.mcasp0_fsx */
+   AM33XX_IOPAD(0x990, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* mcasp0_aclkx.mcasp0_aclkx */
+   AM33XX_IOPAD(0x998, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* mcasp0_axr0.mcasp0_axr0 */
+   AM33XX_IOPAD(0x9a8, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* mcasp0_axr1.mcasp0_axr1 */
+   AM33XX_IOPAD(0x840, PIN_OUTPUT | MUX_MODE7) /* 
gpmc_a0.gpio1_16 */
>;
};
 };
@@ -228,36 +228,36 @@
 _pinmux {
lcd_pins: pinmux_lcd {
pinctrl-single,pins = <
-   0xa0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data0.lcd_data0 
*/
-   0xa4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data1.lcd_data1 
*/
-   0xa8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data2.lcd_data2 
*/
-   0xac (PIN_OUTPUT | MUX_MODE0)   /* lcd_data3.lcd_data3 
*/
-   0xb0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data4.lcd_data4 
*/
-   0xb4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data5.lcd_data5 
*/
-   0xb8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data6.lcd_data6 
*/
-   0xbc (PIN_OUTPUT | MUX_MODE0)   /* lcd_data7.lcd_data7 
*/
-   0xc0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data8.lcd_data8 
*/
-   0xc4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data9.lcd_data9 
*/
-   0xc8 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data10.lcd_data10 */
-   0xcc (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data11.lcd_data11 */
-   0xd0 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data12.lcd_data12 */
-   0xd4 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data13.lcd_data13 */
-   0xd8 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data14.lcd_data14 */
-   0xdc (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data15.lcd_data15 */
-   0x20 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad8.lcd_data16 
*/
-   0x24 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad9.lcd_data17 
*/
-  

[PATCH 10/39] ARM: dts: am335x-lxm: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-lxm.dts | 120 +++
 1 file changed, 60 insertions(+), 60 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-lxm.dts b/arch/arm/boot/dts/am335x-lxm.dts
index 5c5667a3624d..d97b0efa43f3 100644
--- a/arch/arm/boot/dts/am335x-lxm.dts
+++ b/arch/arm/boot/dts/am335x-lxm.dts
@@ -46,109 +46,109 @@
 _pinmux {
mmc1_pins: pinmux_mmc1_pins {
pinctrl-single,pins = <
-   0xf0 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat3 */
-   0xf4 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat2 */
-   0xf8 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat1 */
-   0xfc (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat0 */
-   0x100 (PIN_INPUT_PULLUP | MUX_MODE0)/* mmc0_clk */
-   0x104 (PIN_INPUT_PULLUP | MUX_MODE0)/* mmc0_cmd */
+   AM33XX_IOPAD(0x8f0, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_dat3 */
+   AM33XX_IOPAD(0x8f4, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_dat2 */
+   AM33XX_IOPAD(0x8f8, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_dat1 */
+   AM33XX_IOPAD(0x8fc, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_dat0 */
+   AM33XX_IOPAD(0x900, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_clk */
+   AM33XX_IOPAD(0x904, PIN_INPUT_PULLUP | MUX_MODE0)   
/* mmc0_cmd */
>;
};
 
i2c0_pins: pinmux_i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT | MUX_MODE0)   /* i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT | MUX_MODE0)   /* i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT | MUX_MODE0)  /* 
i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT | MUX_MODE0)  /* 
i2c0_scl.i2c0_scl */
>;
};
 
cpsw_default: cpsw_default {
pinctrl-single,pins = <
/* Slave 1 */
-   0x64 (PIN_INPUT_PULLDOWN | MUX_MODE7)   /* rmii1_int */
-   0x10c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* rmii1_crs_dv 
*/
-   0x110 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* rmii1_rxer */
-   0x114 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* rmii1_txen */
-   0x124 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* rmii1_td1 */
-   0x128 (PIN_OUTPUT_PULLDOWN | MUX_MODE1) /* rmii1_td0 */
-   0x13c (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* rmii1_rd1 */
-   0x140 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* rmii1_rd0 */
-   0x144 (PIN_INPUT_PULLDOWN | MUX_MODE0)  /* rmii1_refclk 
*/
+   AM33XX_IOPAD(0x864, PIN_INPUT_PULLDOWN | MUX_MODE7) 
/* rmii1_int */
+   AM33XX_IOPAD(0x90c, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* rmii1_crs_dv */
+   AM33XX_IOPAD(0x910, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* rmii1_rxer */
+   AM33XX_IOPAD(0x914, PIN_OUTPUT_PULLDOWN | MUX_MODE1)
/* rmii1_txen */
+   AM33XX_IOPAD(0x924, PIN_OUTPUT_PULLDOWN | MUX_MODE1)
/* rmii1_td1 */
+   AM33XX_IOPAD(0x928, PIN_OUTPUT_PULLDOWN | MUX_MODE1)
/* rmii1_td0 */
+   AM33XX_IOPAD(0x93c, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* rmii1_rd1 */
+   AM33XX_IOPAD(0x940, PIN_INPUT_PULLDOWN | MUX_MODE1) 
/* rmii1_rd0 */
+   AM33XX_IOPAD(0x944, PIN_INPUT_PULLDOWN | MUX_MODE0) 
/* rmii1_refclk */
 
/* Slave 2 */
-   0x40 (PIN_OUTPUT_PULLDOWN | MUX_MODE3)  /* rmii2_txen */
-   0x50 (PIN_OUTPUT_PULLDOWN | MUX_MODE3)  /* rmii2_td1 */
-   0x54 (PIN_OUTPUT_PULLDOWN | MUX_MODE3)  /* rmii2_td0 */
-   0x68 (PIN_INPUT_PULLDOWN | MUX_MODE3)   /* rmii2_rd1 */
-   0x6c (PIN_INPUT_PULLDOWN | MUX_MODE3)   /* rmii2_rd0 */
-   0x70 (PIN_INPUT_PULLDOWN | MUX_MODE3)   /* rmii2_crs_dv 
*/
-   0x74 (PIN_INPUT_PULLDOWN | MUX_MODE3)   /* rmii2_rxer */
-   0x78 (PIN_INPUT_PULLDOWN | MUX_MODE7)   /* rmii2_int */
-   0x108 (PIN_INPUT_PULLDOWN | MUX_MODE1)  /* rmii2_refclk 
*/
+   AM33XX_IOPAD(0x840, PIN_OUTPUT_PULLDOWN | MUX_MODE3)
/* rmii2_txen */
+   AM33XX_IOPAD(0x850, PIN_OUTPUT_PULLDOWN | MUX_MO

[PATCH 11/39] ARM: dts: am335x-nano: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-nano.dts | 140 +++---
 1 file changed, 70 insertions(+), 70 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-nano.dts 
b/arch/arm/boot/dts/am335x-nano.dts
index 5ed4ca6eaf55..f313999c503e 100644
--- a/arch/arm/boot/dts/am335x-nano.dts
+++ b/arch/arm/boot/dts/am335x-nano.dts
@@ -41,121 +41,121 @@
 
misc_pins: misc_pins {
pinctrl-single,pins = <
-   0x15c (PIN_OUTPUT | MUX_MODE7)  /* spi0_cs0.gpio0_5 */
+   AM33XX_IOPAD(0x95c, PIN_OUTPUT | MUX_MODE7) /* 
spi0_cs0.gpio0_5 */
>;
};
 
gpmc_pins: gpmc_pins {
pinctrl-single,pins = <
-   0x0 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad0.gpmc_ad0 */
-   0x4 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad1.gpmc_ad1 */
-   0x8 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad2.gpmc_ad2 */
-   0xc (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad3.gpmc_ad3 */
-   0x10 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad4.gpmc_ad4 */
-   0x14 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad5.gpmc_ad5 */
-   0x18 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad6.gpmc_ad6 */
-   0x1c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad7.gpmc_ad7 */
-   0x20 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad8.gpmc_ad8 */
-   0x24 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad9.gpmc_ad9 */
-   0x28 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad10.gpmc_ad10 */
-   0x2c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad11.gpmc_ad11 */
-   0x30 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad12.gpmc_ad12 */
-   0x34 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad13.gpmc_ad13 */
-   0x38 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad14.gpmc_ad14 */
-   0x3c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad15.gpmc_ad15 */
-
-   0x70 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_wait0.gpmc_wait0 */
-   0x7c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn0.gpmc_csn0 */
-   0x80 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn1.gpmc_csn1 */
-   0x84 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn2.gpmc_csn2 */
-   0x88 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn3.gpmc_csn3 */
-
-   0x90 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_advn_ale.gpmc_advn_ale */
-   0x94 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_oen_ren.gpmc_oen_ren */
-   0x98 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_wen.gpmc_wen */
-   0x9c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_ben0_cle.gpmc_ben0_cle */
-
-   0xa4 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data1.gpmc_a1 */
-   0xa8 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data2.gpmc_a2 */
-   0xac (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data3.gpmc_a3 */
-   0xb0 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data4.gpmc_a4 */
-   0xb4 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data5.gpmc_a5 */
-   0xb8 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data6.gpmc_a6 */
-   0xbc (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_data7.gpmc_a7 */
-
-   0xe0 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_vsync.gpmc_a8 */
-   0xe4 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_hsync.gpmc_a9 */
-   0xe8 (PIN_OUTPUT | MUX_MODE1)   /* 
lcd_pclk.gpmc_a10 */
+   AM33XX_IOPAD(0x800, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad0.gpmc_ad0 */
+   AM33XX_IOPAD(0x804, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad1.gpmc_ad1 */
+   AM33XX_IOPAD(0x808, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad2.gpmc_ad2 */
+   AM33XX_IOPAD(0x80c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad3.gpmc_ad3 */
+   AM33XX_IOPAD(0x810, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad4.gpmc_ad4 */
+   AM33XX_IOPAD(0x814, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad5.gpmc_ad5 */
+   AM33XX_IOPAD(0x818, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad6.gpmc_ad6 */
+   AM33XX_IOPAD(0x81c, PIN_INPUT_PUL

[PATCH 08/39] ARM: dts: am335x-evm: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Also, use the mux defines instead of magic numbers for the padconf
values when defining the pinctrl lines to make it more readable.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-evm.dts | 220 +++
 1 file changed, 110 insertions(+), 110 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-evm.dts b/arch/arm/boot/dts/am335x-evm.dts
index d9d00ab863a2..4caf074063fe 100644
--- a/arch/arm/boot/dts/am335x-evm.dts
+++ b/arch/arm/boot/dts/am335x-evm.dts
@@ -168,215 +168,215 @@
 
matrix_keypad_s0: matrix_keypad_s0 {
pinctrl-single,pins = <
-   0x54 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_a5.gpio1_21 */
-   0x58 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_a6.gpio1_22 */
-   0x64 (PIN_INPUT_PULLDOWN | MUX_MODE7)   /* 
gpmc_a9.gpio1_25 */
-   0x68 (PIN_INPUT_PULLDOWN | MUX_MODE7)   /* 
gpmc_a10.gpio1_26 */
-   0x6c (PIN_INPUT_PULLDOWN | MUX_MODE7)   /* 
gpmc_a11.gpio1_27 */
+   AM33XX_IOPAD(0x854, PIN_OUTPUT_PULLDOWN | MUX_MODE7)
/* gpmc_a5.gpio1_21 */
+   AM33XX_IOPAD(0x858, PIN_OUTPUT_PULLDOWN | MUX_MODE7)
/* gpmc_a6.gpio1_22 */
+   AM33XX_IOPAD(0x864, PIN_INPUT_PULLDOWN | MUX_MODE7) 
/* gpmc_a9.gpio1_25 */
+   AM33XX_IOPAD(0x868, PIN_INPUT_PULLDOWN | MUX_MODE7) 
/* gpmc_a10.gpio1_26 */
+   AM33XX_IOPAD(0x86c, PIN_INPUT_PULLDOWN | MUX_MODE7) 
/* gpmc_a11.gpio1_27 */
>;
};
 
volume_keys_s0: volume_keys_s0 {
pinctrl-single,pins = <
-   0x150 (PIN_INPUT_PULLDOWN | MUX_MODE7)  /* 
spi0_sclk.gpio0_2 */
-   0x154 (PIN_INPUT_PULLDOWN | MUX_MODE7)  /* 
spi0_d0.gpio0_3 */
+   AM33XX_IOPAD(0x950, PIN_INPUT_PULLDOWN | MUX_MODE7) 
/* spi0_sclk.gpio0_2 */
+   AM33XX_IOPAD(0x954, PIN_INPUT_PULLDOWN | MUX_MODE7) 
/* spi0_d0.gpio0_3 */
>;
};
 
i2c0_pins: pinmux_i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_scl.i2c0_scl */
>;
};
 
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
-   0x158 (PIN_INPUT_PULLUP | MUX_MODE2)/* 
spi0_d1.i2c1_sda */
-   0x15c (PIN_INPUT_PULLUP | MUX_MODE2)/* 
spi0_cs0.i2c1_scl */
+   AM33XX_IOPAD(0x958, PIN_INPUT_PULLUP | MUX_MODE2)   
/* spi0_d1.i2c1_sda */
+   AM33XX_IOPAD(0x95c, PIN_INPUT_PULLUP | MUX_MODE2)   
/* spi0_cs0.i2c1_scl */
>;
};
 
uart0_pins: pinmux_uart0_pins {
pinctrl-single,pins = <
-   0x170 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart0_rxd.uart0_rxd */
-   0x174 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart0_txd.uart0_txd */
+   AM33XX_IOPAD(0x970, PIN_INPUT_PULLUP | MUX_MODE0)   
/* uart0_rxd.uart0_rxd */
+   AM33XX_IOPAD(0x974, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart0_txd.uart0_txd */
>;
};
 
uart1_pins: pinmux_uart1_pins {
pinctrl-single,pins = <
-   0x178 (PIN_INPUT | MUX_MODE0)   /* 
uart1_ctsn.uart1_ctsn */
-   0x17C (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart1_rtsn.uart1_rtsn */
-   0x180 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart1_rxd.uart1_rxd */
-   0x184 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart1_txd.uart1_txd */
+   AM33XX_IOPAD(0x978, PIN_INPUT | MUX_MODE0)  
/* uart1_ctsn.uart1_ctsn */
+   AM33XX_IOPAD(0x97C, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart1_rtsn.uart1_rtsn */
+   AM33XX_IOPAD(0x980, PIN_INPUT_PULLUP | MUX_MODE0)   
/* uart1_rxd.uart1_rxd */
+   AM33XX_IOPAD(0x984, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart1_txd.uart1_txd */
>;
};
 
clkout2_pin: pinmux_clkout2_pin {
pinctrl-single,pins = <
-   0x1b4 (PIN_OUTPUT_PULLD

[PATCH 09/39] ARM: dts: am335x-evmsk: Use AM33XX_IOPAD pinmux macro

2015-11-12 Thread Javier Martinez Canillas
Use the pinmux IOPAD macro to define the register absolute physical
address instead of the offset from the padconf base address. This
makes the DTS easier to read since matches the addresses listed in
the Technical Reference Manual.

Also, use the mux defines instead of magic numbers for the padconf
values when defining the pinctrl lines to make it more readable.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-evmsk.dts | 278 ++---
 1 file changed, 139 insertions(+), 139 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-evmsk.dts 
b/arch/arm/boot/dts/am335x-evmsk.dts
index 89442e98a837..9609668919f1 100644
--- a/arch/arm/boot/dts/am335x-evmsk.dts
+++ b/arch/arm/boot/dts/am335x-evmsk.dts
@@ -204,234 +204,234 @@
 
lcd_pins_default: lcd_pins_default {
pinctrl-single,pins = <
-   0x20 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad8.lcd_data23 
*/
-   0x24 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad9.lcd_data22 
*/
-   0x28 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad10.lcd_data21 
*/
-   0x2c (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad11.lcd_data20 
*/
-   0x30 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad12.lcd_data19 
*/
-   0x34 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad13.lcd_data18 
*/
-   0x38 (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad14.lcd_data17 
*/
-   0x3c (PIN_OUTPUT | MUX_MODE1)   /* gpmc_ad15.lcd_data16 
*/
-   0xa0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data0.lcd_data0 
*/
-   0xa4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data1.lcd_data1 
*/
-   0xa8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data2.lcd_data2 
*/
-   0xac (PIN_OUTPUT | MUX_MODE0)   /* lcd_data3.lcd_data3 
*/
-   0xb0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data4.lcd_data4 
*/
-   0xb4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data5.lcd_data5 
*/
-   0xb8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data6.lcd_data6 
*/
-   0xbc (PIN_OUTPUT | MUX_MODE0)   /* lcd_data7.lcd_data7 
*/
-   0xc0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data8.lcd_data8 
*/
-   0xc4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data9.lcd_data9 
*/
-   0xc8 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data10.lcd_data10 */
-   0xcc (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data11.lcd_data11 */
-   0xd0 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data12.lcd_data12 */
-   0xd4 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data13.lcd_data13 */
-   0xd8 (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data14.lcd_data14 */
-   0xdc (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_data15.lcd_data15 */
-   0xe0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_vsync.lcd_vsync 
*/
-   0xe4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_hsync.lcd_hsync 
*/
-   0xe8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_pclk.lcd_pclk */
-   0xec (PIN_OUTPUT | MUX_MODE0)   /* 
lcd_ac_bias_en.lcd_ac_bias_en */
+   AM33XX_IOPAD(0x820, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad8.lcd_data23 */
+   AM33XX_IOPAD(0x824, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad9.lcd_data22 */
+   AM33XX_IOPAD(0x828, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad10.lcd_data21 */
+   AM33XX_IOPAD(0x82c, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad11.lcd_data20 */
+   AM33XX_IOPAD(0x830, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad12.lcd_data19 */
+   AM33XX_IOPAD(0x834, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad13.lcd_data18 */
+   AM33XX_IOPAD(0x838, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad14.lcd_data17 */
+   AM33XX_IOPAD(0x83c, PIN_OUTPUT | MUX_MODE1) /* 
gpmc_ad15.lcd_data16 */
+   AM33XX_IOPAD(0x8a0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data0.lcd_data0 */
+   AM33XX_IOPAD(0x8a4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data1.lcd_data1 */
+   AM33XX_IOPAD(0x8a8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data2.lcd_data2 */
+   AM33XX_IOPAD(0x8ac, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data3.lcd_data3 */
+   AM33XX_IOPAD(0x8b0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data4.lcd_data4 */
+   AM33XX_IOPAD(0x8b4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data5.lcd_data5 */
+   AM33XX_IOPAD(0x8b8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data6.lcd_data6 */
+   AM33XX_IOPAD(0x8bc, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data7.lcd_data7 */
+   AM33XX_IOPAD(0x8c0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data8.lcd_data8 */
+   AM33XX_IOPAD(0x8c4, PIN_OUTPUT | 

Re: [PATCH v2] ARM: dts: am335x-boneblack: Use pinctrl constants and AM33XX_IOPAD macro

2015-11-10 Thread Javier Martinez Canillas
Hello Andrew,

On Sat, Oct 24, 2015 at 2:05 PM, Andrew F. Davis  wrote:
> Using constants for pinctrl allows better readability and removes
> redundancy with comments. AM33XX_IOPAD allows us to use part of the
> pinctrl physical address as in the TRM instead of an offset.
>
> Signed-off-by: Andrew F. Davis 
> ---
>  arch/arm/boot/dts/am335x-boneblack.dts | 44 
> +-
>  1 file changed, 22 insertions(+), 22 deletions(-)
>
> diff --git a/arch/arm/boot/dts/am335x-boneblack.dts 
> b/arch/arm/boot/dts/am335x-boneblack.dts
> index eadbba3..346f529 100644
> --- a/arch/arm/boot/dts/am335x-boneblack.dts
> +++ b/arch/arm/boot/dts/am335x-boneblack.dts
> @@ -36,32 +36,32 @@
>  _pinmux {
> nxp_hdmi_bonelt_pins: nxp_hdmi_bonelt_pins {
> pinctrl-single,pins = <
> -   0x1b0 0x03  /* xdma_event_intr0, OMAP_MUX_MODE3 | 
> AM33XX_PIN_OUTPUT */
> -   0xa0 0x08   /* lcd_data0.lcd_data0, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xa4 0x08   /* lcd_data1.lcd_data1, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xa8 0x08   /* lcd_data2.lcd_data2, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xac 0x08   /* lcd_data3.lcd_data3, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xb0 0x08   /* lcd_data4.lcd_data4, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xb4 0x08   /* lcd_data5.lcd_data5, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xb8 0x08   /* lcd_data6.lcd_data6, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xbc 0x08   /* lcd_data7.lcd_data7, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xc0 0x08   /* lcd_data8.lcd_data8, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xc4 0x08   /* lcd_data9.lcd_data9, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xc8 0x08   /* lcd_data10.lcd_data10, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xcc 0x08   /* lcd_data11.lcd_data11, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xd0 0x08   /* lcd_data12.lcd_data12, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xd4 0x08   /* lcd_data13.lcd_data13, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xd8 0x08   /* lcd_data14.lcd_data14, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xdc 0x08   /* lcd_data15.lcd_data15, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT | AM33XX_PULL_DISA */
> -   0xe0 0x00   /* lcd_vsync.lcd_vsync, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT */
> -   0xe4 0x00   /* lcd_hsync.lcd_hsync, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT */
> -   0xe8 0x00   /* lcd_pclk.lcd_pclk, OMAP_MUX_MODE0 
> | AM33XX_PIN_OUTPUT */
> -   0xec 0x00   /* lcd_ac_bias_en.lcd_ac_bias_en, 
> OMAP_MUX_MODE0 | AM33XX_PIN_OUTPUT */
> +   AM33XX_IOPAD(0x9b0, (PIN_OUTPUT_PULLDOWN | 
> MUX_MODE3))  /* xdma_event_intr0 */

I missed when I first reviewed this patch but there is no need to
enclose the padconf values into parenthesis, for example the following
is easier to read and is preferred IMHO:

AM33XX_IOPAD(0x9b0, PIN_OUTPUT_PULLDOWN | MUX_MODE3)  /* xdma_event_intr0 */

Same for all the other pinctrl lines.

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2] ARM: dts: am335x-boneblack: Use pinctrl constants and AM33XX_IOPAD macro

2015-10-26 Thread Javier Martinez Canillas
Hello Andrew,

On Sun, Oct 25, 2015 at 2:05 AM, Andrew F. Davis <a...@ti.com> wrote:
> Using constants for pinctrl allows better readability and removes
> redundancy with comments. AM33XX_IOPAD allows us to use part of the
> pinctrl physical address as in the TRM instead of an offset.
>
> Signed-off-by: Andrew F. Davis <a...@ti.com>
> ---

I haven't verified the values against the TRM, but assuming there are correct:

Reviewed-by: Javier Martinez Canillas <jav...@osg.samsung.com>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: am335x-boneblack: Use pinctrl constants

2015-10-23 Thread Javier Martinez Canillas
Hello Andrew,

On Fri, Oct 23, 2015 at 3:08 PM, Andrew F. Davis  wrote:
> On 10/22/2015 04:23 PM, Tony Lindgren wrote:
>>
>> * Andrew F. Davis  [151022 09:21]:
>>>
>>> Using constants for pinctrl allows better readability and removes
>>> redundancy with comments.
>>
>>
>> You should use the include/dt-bindings/pinctrl/omap.h macro
>> AM33XX_IOPAD(pa, val) while at it. Otherwise we'll end up patching
>> the same things again later on.
>>
>
> Hmm, I haven't really been following this change, it kind of seems to add
> some unnecessary abstraction by using physical hardware addresses instead
> of offsets, then just converting them back to offsets. The offset style DT
> nodes are already auto-generated with existing tools anyway:
> https://dev.ti.com/pinmux
>
> I'm sure this has been discussed already so if this is a blocker I'll
> re-spin this.
>

The good thing about the IOPAD pinmux macros is that matches what is
in the TRM so it is easier to read the DTS and verify that is correct.

I've on my queue to migrate all the remaining DTS for TI SoCs to use
the IOPAD macros but is just that I didn't have time to do it this
week. Probably I'll do it at the end of the next week.

> Andrew
>
>
>> Regards,
>>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] ARM: dts: am335x-boneblack: Use pinctrl constants

2015-10-23 Thread Javier Martinez Canillas
Hello Andrew,

On Fri, Oct 23, 2015 at 4:36 PM, Andrew F. Davis <a...@ti.com> wrote:
> On 10/23/2015 09:29 AM, Javier Martinez Canillas wrote:
>>
>> Hello Andrew,
>>
>> On Fri, Oct 23, 2015 at 3:08 PM, Andrew F. Davis <a...@ti.com> wrote:
>>>
>>> On 10/22/2015 04:23 PM, Tony Lindgren wrote:
>>>>
>>>>
>>>> * Andrew F. Davis <a...@ti.com> [151022 09:21]:
>>>>>
>>>>>
>>>>> Using constants for pinctrl allows better readability and removes
>>>>> redundancy with comments.
>>>>
>>>>
>>>>
>>>> You should use the include/dt-bindings/pinctrl/omap.h macro
>>>> AM33XX_IOPAD(pa, val) while at it. Otherwise we'll end up patching
>>>> the same things again later on.
>>>>
>>>
>>> Hmm, I haven't really been following this change, it kind of seems to add
>>> some unnecessary abstraction by using physical hardware addresses instead
>>> of offsets, then just converting them back to offsets. The offset style
>>> DT
>>> nodes are already auto-generated with existing tools anyway:
>>> https://dev.ti.com/pinmux
>>>
>>> I'm sure this has been discussed already so if this is a blocker I'll
>>> re-spin this.
>>>
>>
>> The good thing about the IOPAD pinmux macros is that matches what is
>> in the TRM so it is easier to read the DTS and verify that is correct.
>>
>> I've on my queue to migrate all the remaining DTS for TI SoCs to use
>> the IOPAD macros but is just that I didn't have time to do it this
>> week. Probably I'll do it at the end of the next week.
>>
>
> Then this patch can probably be dropped, hopefully the converted constants
> in this patch can be of some help for you though.
>

Yes they are but feel free to re-spin your patch if you wish, it will
be one less DTS to convert :-)

But yes, if you don't then I'll do it when changing all DTS.

> Andrew
>
>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 0/3] ARM: dts: Use IOPAD pinmux for IGEP boards

2015-10-20 Thread Javier Martinez Canillas
Hello Tony,

On 10/20/2015 06:26 PM, Tony Lindgren wrote:
> * Javier Martinez Canillas <jav...@osg.samsung.com> [151019 08:39]:
>> Hello,
>>
>> This series use the IOPAD pinmux macros for the remaining IGEP boards that
>> still used the register offset instead of the physical address using these
>> macros so the DTS matches what is in the Technical Reference Manual.
>>
>> The changes are only cosmetic since they make the DTS easier to read but
>> does not change functionality. I built tested and compared the binary DTB
>> MD5 checksum and both matches before and after the series applied:
>>
>> Before
>>
>> d7a56205bdc54365d49d9a90dfe3fafb  am335x-base0033.dtb
>> fa272fcdee65d7bf4c03bd5a6c5ec4fd  omap3-igep0020.dtb
>> ba65bf74d8c6ea8e7bd8face17179e6e  omap3-igep0020-rev-f.dtb
>>
>> After
>>
>> d7a56205bdc54365d49d9a90dfe3fafb  am335x-base0033.dtb
>> fa272fcdee65d7bf4c03bd5a6c5ec4fd  omap3-igep0020.dtb
>> ba65bf74d8c6ea8e7bd8face17179e6e  omap3-igep0020-rev-f.dtb
> 
> Good idea to test the dtb checksums :)
>

:)
 
> Applying all into omap-for-v4.4/dt thanks.
>

Thanks, I'm planning to convert the remaining OMAP dts but I'm quite busy
this week and traveling the next one so that would have to wait for v4.5
 
> Tony
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 1/3] ARM: dts: omap3-igep0020: Use IOPAD pinmux macro

2015-10-19 Thread Javier Martinez Canillas
Use the OMAP3 pinmux IOPAD macro to define the physical address instead
of the offset from the padconf address. It makes the DTS easier to read
since matches the addresses listed in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/omap3-igep0020-common.dtsi | 58 ++--
 1 file changed, 29 insertions(+), 29 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-igep0020-common.dtsi 
b/arch/arm/boot/dts/omap3-igep0020-common.dtsi
index 5ad688c57a00..17bf58fb9520 100644
--- a/arch/arm/boot/dts/omap3-igep0020-common.dtsi
+++ b/arch/arm/boot/dts/omap3-igep0020-common.dtsi
@@ -111,40 +111,40 @@
 
tfp410_pins: pinmux_tfp410_pins {
pinctrl-single,pins = <
-   0x196 (PIN_OUTPUT | MUX_MODE4)   /* hdq_sio.gpio_170 */
+   OMAP3_CORE1_IOPAD(0x21c6, PIN_OUTPUT | MUX_MODE4)   /* 
hdq_sio.gpio_170 */
>;
};
 
dss_dpi_pins: pinmux_dss_dpi_pins {
pinctrl-single,pins = <
-   0x0a4 (PIN_OUTPUT | MUX_MODE0)   /* dss_pclk.dss_pclk */
-   0x0a6 (PIN_OUTPUT | MUX_MODE0)   /* dss_hsync.dss_hsync 
*/
-   0x0a8 (PIN_OUTPUT | MUX_MODE0)   /* dss_vsync.dss_vsync 
*/
-   0x0aa (PIN_OUTPUT | MUX_MODE0)   /* 
dss_acbias.dss_acbias */
-   0x0ac (PIN_OUTPUT | MUX_MODE0)   /* dss_data0.dss_data0 
*/
-   0x0ae (PIN_OUTPUT | MUX_MODE0)   /* dss_data1.dss_data1 
*/
-   0x0b0 (PIN_OUTPUT | MUX_MODE0)   /* dss_data2.dss_data2 
*/
-   0x0b2 (PIN_OUTPUT | MUX_MODE0)   /* dss_data3.dss_data3 
*/
-   0x0b4 (PIN_OUTPUT | MUX_MODE0)   /* dss_data4.dss_data4 
*/
-   0x0b6 (PIN_OUTPUT | MUX_MODE0)   /* dss_data5.dss_data5 
*/
-   0x0b8 (PIN_OUTPUT | MUX_MODE0)   /* dss_data6.dss_data6 
*/
-   0x0ba (PIN_OUTPUT | MUX_MODE0)   /* dss_data7.dss_data7 
*/
-   0x0bc (PIN_OUTPUT | MUX_MODE0)   /* dss_data8.dss_data8 
*/
-   0x0be (PIN_OUTPUT | MUX_MODE0)   /* dss_data9.dss_data9 
*/
-   0x0c0 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data10.dss_data10 */
-   0x0c2 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data11.dss_data11 */
-   0x0c4 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data12.dss_data12 */
-   0x0c6 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data13.dss_data13 */
-   0x0c8 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data14.dss_data14 */
-   0x0ca (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data15.dss_data15 */
-   0x0cc (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data16.dss_data16 */
-   0x0ce (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data17.dss_data17 */
-   0x0d0 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data18.dss_data18 */
-   0x0d2 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data19.dss_data19 */
-   0x0d4 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data20.dss_data20 */
-   0x0d6 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data21.dss_data21 */
-   0x0d8 (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data22.dss_data22 */
-   0x0da (PIN_OUTPUT | MUX_MODE0)   /* 
dss_data23.dss_data23 */
+   OMAP3_CORE1_IOPAD(0x20d4, PIN_OUTPUT | MUX_MODE0)   /* 
dss_pclk.dss_pclk */
+   OMAP3_CORE1_IOPAD(0x20d6, PIN_OUTPUT | MUX_MODE0)   /* 
dss_hsync.dss_hsync */
+   OMAP3_CORE1_IOPAD(0x20d8, PIN_OUTPUT | MUX_MODE0)   /* 
dss_vsync.dss_vsync */
+   OMAP3_CORE1_IOPAD(0x20da, PIN_OUTPUT | MUX_MODE0)   /* 
dss_acbias.dss_acbias */
+   OMAP3_CORE1_IOPAD(0x20dc, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data0.dss_data0 */
+   OMAP3_CORE1_IOPAD(0x20de, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data1.dss_data1 */
+   OMAP3_CORE1_IOPAD(0x20e0, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data2.dss_data2 */
+   OMAP3_CORE1_IOPAD(0x20e2, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data3.dss_data3 */
+   OMAP3_CORE1_IOPAD(0x20e4, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data4.dss_data4 */
+   OMAP3_CORE1_IOPAD(0x20e6, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data5.dss_data5 */
+   OMAP3_CORE1_IOPAD(0x20e8, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data6.dss_data6 */
+   OMAP3_CORE1_IOPAD(0x20ea, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data7.dss_data7 */
+   OMAP3_CORE1_IOPAD(0x20ec, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data8.dss_data8 */
+   OMAP3_CORE1_IOPAD(0x20ee, PIN_OUTPUT | MUX_MODE0)   /* 
dss_data9.dss_data9 */
+   OMAP3_CORE1_IOPAD(0x20f0, PIN_OUTPUT | MUX_MODE0)   /* 
dss_da

[PATCH 2/3] ARM: dts: am335x-igep0033: Use IOPAD pinmux macro

2015-10-19 Thread Javier Martinez Canillas
Use the AM33xx pinmux IOPAD macro to define the physical address instead
of the offset from the padconf address. It makes the DTS easier to read
since matches the addresses listed in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>
---

 arch/arm/boot/dts/am335x-igep0033.dtsi | 40 +-
 1 file changed, 20 insertions(+), 20 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-igep0033.dtsi 
b/arch/arm/boot/dts/am335x-igep0033.dtsi
index c0e1135256cc..54f113546ecc 100644
--- a/arch/arm/boot/dts/am335x-igep0033.dtsi
+++ b/arch/arm/boot/dts/am335x-igep0033.dtsi
@@ -56,41 +56,41 @@
 _pinmux {
i2c0_pins: pinmux_i2c0_pins {
pinctrl-single,pins = <
-   0x188 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_sda.i2c0_sda */
-   0x18c (PIN_INPUT_PULLUP | MUX_MODE0)/* 
i2c0_scl.i2c0_scl */
+   AM33XX_IOPAD(0x988, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_sda.i2c0_sda */
+   AM33XX_IOPAD(0x98c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* i2c0_scl.i2c0_scl */
>;
};
 
nandflash_pins: pinmux_nandflash_pins {
pinctrl-single,pins = <
-   0x0 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad0.gpmc_ad0 */
-   0x4 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad1.gpmc_ad1 */
-   0x8 (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad2.gpmc_ad2 */
-   0xc (PIN_INPUT_PULLUP | MUX_MODE0)  /* 
gpmc_ad3.gpmc_ad3 */
-   0x10 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad4.gpmc_ad4 */
-   0x14 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad5.gpmc_ad5 */
-   0x18 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad6.gpmc_ad6 */
-   0x1c (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_ad7.gpmc_ad7 */
-   0x70 (PIN_INPUT_PULLUP | MUX_MODE0) /* 
gpmc_wait0.gpmc_wait0 */
-   0x74 (PIN_INPUT_PULLUP | MUX_MODE7) /* 
gpmc_wpn.gpio0_30 */
-   0x7c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_csn0.gpmc_csn0 */
-   0x90 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_advn_ale.gpmc_advn_ale */
-   0x94 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_oen_ren.gpmc_oen_ren */
-   0x98 (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_wen.gpmc_wen */
-   0x9c (PIN_OUTPUT | MUX_MODE0)   /* 
gpmc_be0n_cle.gpmc_be0n_cle */
+   AM33XX_IOPAD(0x800, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad0.gpmc_ad0 */
+   AM33XX_IOPAD(0x804, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad1.gpmc_ad1 */
+   AM33XX_IOPAD(0x808, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad2.gpmc_ad2 */
+   AM33XX_IOPAD(0x80c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad3.gpmc_ad3 */
+   AM33XX_IOPAD(0x810, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad4.gpmc_ad4 */
+   AM33XX_IOPAD(0x814, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad5.gpmc_ad5 */
+   AM33XX_IOPAD(0x818, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad6.gpmc_ad6 */
+   AM33XX_IOPAD(0x81c, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_ad7.gpmc_ad7 */
+   AM33XX_IOPAD(0x870, PIN_INPUT_PULLUP | MUX_MODE0)   
/* gpmc_wait0.gpmc_wait0 */
+   AM33XX_IOPAD(0x874, PIN_INPUT_PULLUP | MUX_MODE7)   
/* gpmc_wpn.gpio0_30 */
+   AM33XX_IOPAD(0x87c, PIN_OUTPUT | MUX_MODE0) 
/* gpmc_csn0.gpmc_csn0 */
+   AM33XX_IOPAD(0x890, PIN_OUTPUT | MUX_MODE0) 
/* gpmc_advn_ale.gpmc_advn_ale */
+   AM33XX_IOPAD(0x894, PIN_OUTPUT | MUX_MODE0) 
/* gpmc_oen_ren.gpmc_oen_ren */
+   AM33XX_IOPAD(0x898, PIN_OUTPUT | MUX_MODE0) 
/* gpmc_wen.gpmc_wen */
+   AM33XX_IOPAD(0x89c, PIN_OUTPUT | MUX_MODE0) 
/* gpmc_be0n_cle.gpmc_be0n_cle */
>;
};
 
uart0_pins: pinmux_uart0_pins {
pinctrl-single,pins = <
-   0x170 (PIN_INPUT_PULLUP | MUX_MODE0)/* 
uart0_rxd.uart0_rxd */
-   0x174 (PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* 
uart0_txd.uart0_txd */
+   AM33XX_IOPAD(0x970, PIN_INPUT_PULLUP | MUX_MODE0)   
/* uart0_rxd.uart0_rxd */
+   AM33XX_IOPAD(0x974, PIN_OUTPUT_PULLDOWN | MUX_MODE0)
/* uart0_txd.uart0_txd */
>;
};
 
leds_pins: pinmux_leds_pins {
pinctrl-single,pins = <
-   0x5c (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_a7.gpio1_23 */
+  

[PATCH 0/3] ARM: dts: Use IOPAD pinmux for IGEP boards

2015-10-19 Thread Javier Martinez Canillas
Hello,

This series use the IOPAD pinmux macros for the remaining IGEP boards that
still used the register offset instead of the physical address using these
macros so the DTS matches what is in the Technical Reference Manual.

The changes are only cosmetic since they make the DTS easier to read but
does not change functionality. I built tested and compared the binary DTB
MD5 checksum and both matches before and after the series applied:

Before

d7a56205bdc54365d49d9a90dfe3fafb  am335x-base0033.dtb
fa272fcdee65d7bf4c03bd5a6c5ec4fd  omap3-igep0020.dtb
ba65bf74d8c6ea8e7bd8face17179e6e  omap3-igep0020-rev-f.dtb

After

d7a56205bdc54365d49d9a90dfe3fafb  am335x-base0033.dtb
fa272fcdee65d7bf4c03bd5a6c5ec4fd  omap3-igep0020.dtb
ba65bf74d8c6ea8e7bd8face17179e6e  omap3-igep0020-rev-f.dtb

Best regards,
Javier


Javier Martinez Canillas (3):
  ARM: dts: omap3-igep0020: Use IOPAD pinmux macro
  ARM: dts: am335x-igep0033: Use IOPAD pinmux macro
  ARM: dts: am335x-base0033: Use IOPAD pinmux macro

 arch/arm/boot/dts/am335x-base0033.dts| 48 +++
 arch/arm/boot/dts/am335x-igep0033.dtsi   | 40 +--
 arch/arm/boot/dts/omap3-igep0020-common.dtsi | 58 ++--
 3 files changed, 73 insertions(+), 73 deletions(-)

-- 
2.4.3

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


[PATCH 3/3] ARM: dts: am335x-base0033: Use IOPAD pinmux macro

2015-10-19 Thread Javier Martinez Canillas
Use the AM33XX pinmux IOPAD macro to define the physical address instead
of the offset from the padconf address. It makes the DTS easier to read
since matches the addresses listed in the Technical Reference Manual.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/am335x-base0033.dts | 48 +--
 1 file changed, 24 insertions(+), 24 deletions(-)

diff --git a/arch/arm/boot/dts/am335x-base0033.dts 
b/arch/arm/boot/dts/am335x-base0033.dts
index 72a9b3fc4251..58a05f7d0b7c 100644
--- a/arch/arm/boot/dts/am335x-base0033.dts
+++ b/arch/arm/boot/dts/am335x-base0033.dts
@@ -46,39 +46,39 @@
 _pinmux {
nxp_hdmi_pins: pinmux_nxp_hdmi_pins {
pinctrl-single,pins = <
-   0x1b0 (PIN_OUTPUT | MUX_MODE3)  /* 
xdma_event_intr0.clkout1 */
-   0xa0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data0 */
-   0xa4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data1 */
-   0xa8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data2 */
-   0xac (PIN_OUTPUT | MUX_MODE0)   /* lcd_data3 */
-   0xb0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data4 */
-   0xb4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data5 */
-   0xb8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data6 */
-   0xbc (PIN_OUTPUT | MUX_MODE0)   /* lcd_data7 */
-   0xc0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data8 */
-   0xc4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data9 */
-   0xc8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data10 */
-   0xcc (PIN_OUTPUT | MUX_MODE0)   /* lcd_data11 */
-   0xd0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data12 */
-   0xd4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data13 */
-   0xd8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_data14 */
-   0xdc (PIN_OUTPUT | MUX_MODE0)   /* lcd_data15 */
-   0xe0 (PIN_OUTPUT | MUX_MODE0)   /* lcd_vsync */
-   0xe4 (PIN_OUTPUT | MUX_MODE0)   /* lcd_hsync */
-   0xe8 (PIN_OUTPUT | MUX_MODE0)   /* lcd_pclk */
-   0xec (PIN_OUTPUT | MUX_MODE0)   /* lcd_ac_bias_en */
+   AM33XX_IOPAD(0x9b0, PIN_OUTPUT | MUX_MODE3) /* 
xdma_event_intr0.clkout1 */
+   AM33XX_IOPAD(0x8a0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data0 */
+   AM33XX_IOPAD(0x8a4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data1 */
+   AM33XX_IOPAD(0x8a8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data2 */
+   AM33XX_IOPAD(0x8ac, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data3 */
+   AM33XX_IOPAD(0x8b0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data4 */
+   AM33XX_IOPAD(0x8b4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data5 */
+   AM33XX_IOPAD(0x8b8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data6 */
+   AM33XX_IOPAD(0x8bc, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data7 */
+   AM33XX_IOPAD(0x8c0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data8 */
+   AM33XX_IOPAD(0x8c4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data9 */
+   AM33XX_IOPAD(0x8c8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data10 */
+   AM33XX_IOPAD(0x8cc, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data11 */
+   AM33XX_IOPAD(0x8d0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data12 */
+   AM33XX_IOPAD(0x8d4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data13 */
+   AM33XX_IOPAD(0x8d8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data14 */
+   AM33XX_IOPAD(0x8dc, PIN_OUTPUT | MUX_MODE0) /* 
lcd_data15 */
+   AM33XX_IOPAD(0x8e0, PIN_OUTPUT | MUX_MODE0) /* 
lcd_vsync */
+   AM33XX_IOPAD(0x8e4, PIN_OUTPUT | MUX_MODE0) /* 
lcd_hsync */
+   AM33XX_IOPAD(0x8e8, PIN_OUTPUT | MUX_MODE0) /* 
lcd_pclk */
+   AM33XX_IOPAD(0x8ec, PIN_OUTPUT | MUX_MODE0) /* 
lcd_ac_bias_en */
>;
};
nxp_hdmi_off_pins: pinmux_nxp_hdmi_off_pins {
pinctrl-single,pins = <
-   0x1b0 (PIN_OUTPUT | MUX_MODE3)  /* 
xdma_event_intr0.clkout1 */
+   AM33XX_IOPAD(0x9b0, PIN_OUTPUT | MUX_MODE3) /* 
xdma_event_intr0.clkout1 */
>;
};
 
leds_base_pins: pinmux_leds_base_pins {
pinctrl-single,pins = <
-   0x54 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_a5.gpio1_21 */
-   0x88 (PIN_OUTPUT_PULLDOWN | MUX_MODE7)  /* 
gpmc_csn3.gpio2_0 */
+   AM33XX_IOPAD(0x854, PIN_OUTPUT_PULLDOWN | MUX_MODE7)
/* gpmc_a5.gpio1_21 */
+   AM33XX_IOPAD(0x888, PIN_OUTPUT_PULLDOWN | MUX_MO

[PATCH] ARM: OMAP2+: Update Javier Martinez Canillas's email

2015-10-14 Thread Javier Martinez Canillas
I see that people are still sending emails to my old address (that no
longer exists) since is the one mentioned in the IGEP DTS. Replace it
with my current email address to avoid this.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/omap3-igep.dtsi| 2 +-
 arch/arm/boot/dts/omap3-igep0020-common.dtsi | 2 +-
 arch/arm/boot/dts/omap3-igep0020-rev-f.dts   | 2 +-
 arch/arm/boot/dts/omap3-igep0020.dts | 2 +-
 arch/arm/boot/dts/omap3-igep0030-common.dtsi | 2 +-
 arch/arm/boot/dts/omap3-igep0030-rev-g.dts   | 2 +-
 arch/arm/boot/dts/omap3-igep0030.dts | 2 +-
 7 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-igep.dtsi 
b/arch/arm/boot/dts/omap3-igep.dtsi
index 2230e1c03320..08f00bee8b86 100644
--- a/arch/arm/boot/dts/omap3-igep.dtsi
+++ b/arch/arm/boot/dts/omap3-igep.dtsi
@@ -1,7 +1,7 @@
 /*
  * Common device tree for IGEP boards based on AM/DM37x
  *
- * Copyright (C) 2012 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2012 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2012 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; you can redistribute it and/or modify
diff --git a/arch/arm/boot/dts/omap3-igep0020-common.dtsi 
b/arch/arm/boot/dts/omap3-igep0020-common.dtsi
index 5ad688c57a00..441999817285 100644
--- a/arch/arm/boot/dts/omap3-igep0020-common.dtsi
+++ b/arch/arm/boot/dts/omap3-igep0020-common.dtsi
@@ -1,7 +1,7 @@
 /*
  * Common Device Tree Source for IGEPv2
  *
- * Copyright (C) 2014 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2014 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2014 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; you can redistribute it and/or modify
diff --git a/arch/arm/boot/dts/omap3-igep0020-rev-f.dts 
b/arch/arm/boot/dts/omap3-igep0020-rev-f.dts
index 72f7cdc091fb..321c2b7a4e9f 100644
--- a/arch/arm/boot/dts/omap3-igep0020-rev-f.dts
+++ b/arch/arm/boot/dts/omap3-igep0020-rev-f.dts
@@ -1,7 +1,7 @@
 /*
  * Device Tree Source for IGEPv2 Rev. F (TI OMAP AM/DM37x)
  *
- * Copyright (C) 2012 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2012 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2012 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; you can redistribute it and/or modify
diff --git a/arch/arm/boot/dts/omap3-igep0020.dts 
b/arch/arm/boot/dts/omap3-igep0020.dts
index fea7f7edb45d..dbff1efd7fec 100644
--- a/arch/arm/boot/dts/omap3-igep0020.dts
+++ b/arch/arm/boot/dts/omap3-igep0020.dts
@@ -1,7 +1,7 @@
 /*
  * Device Tree Source for IGEPv2 Rev. C (TI OMAP AM/DM37x)
  *
- * Copyright (C) 2012 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2012 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2012 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; you can redistribute it and/or modify
diff --git a/arch/arm/boot/dts/omap3-igep0030-common.dtsi 
b/arch/arm/boot/dts/omap3-igep0030-common.dtsi
index 0cb1527c39d4..640f06603966 100644
--- a/arch/arm/boot/dts/omap3-igep0030-common.dtsi
+++ b/arch/arm/boot/dts/omap3-igep0030-common.dtsi
@@ -1,7 +1,7 @@
 /*
  * Common Device Tree Source for IGEP COM MODULE
  *
- * Copyright (C) 2014 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2014 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2014 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; you can redistribute it and/or modify
diff --git a/arch/arm/boot/dts/omap3-igep0030-rev-g.dts 
b/arch/arm/boot/dts/omap3-igep0030-rev-g.dts
index b899e341874a..76dc08868bfb 100644
--- a/arch/arm/boot/dts/omap3-igep0030-rev-g.dts
+++ b/arch/arm/boot/dts/omap3-igep0030-rev-g.dts
@@ -1,7 +1,7 @@
 /*
  * Device Tree Source for IGEP COM MODULE Rev. G (TI OMAP AM/DM37x)
  *
- * Copyright (C) 2014 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2014 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2014 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; you can redistribute it and/or modify
diff --git a/arch/arm/boot/dts/omap3-igep0030.dts 
b/arch/arm/boot/dts/omap3-igep0030.dts
index 8150f47ccdf5..468608dab30a 100644
--- a/arch/arm/boot/dts/omap3-igep0030.dts
+++ b/arch/arm/boot/dts/omap3-igep0030.dts
@@ -1,7 +1,7 @@
 /*
  * Device Tree Source for IGEP COM MODULE Rev. E (TI OMAP AM/DM37x)
  *
- * Copyright (C) 2012 Javier Martinez Canillas <jav...@collabora.co.uk>
+ * Copyright (C) 2012 Javier Martinez Canillas <jav...@osg.samsung.com>
  * Copyright (C) 2012 Enric Balletbo i Serra <eballe...@gmail.com>
  *
  * This program is free software; y

Re: [PATCH] ARM: dts: omap3-igep: Use OMAP3_CORE1_IOPAD pinmux macro

2015-10-13 Thread Javier Martinez Canillas
Hello Laurent,

Thanks a lot for the patch.

On Tue, Oct 13, 2015 at 7:31 PM, Laurent Pinchart
<laurent.pinch...@ideasonboard.com> wrote:
> Use the macro instead of absolute register offsets to make the code more
> readable as the values now match register addresses from the datasheet.
>
> Signed-off-by: Laurent Pinchart <laurent.pinch...@ideasonboard.com>
> ---

Agreed with the patch and in fact I had the same change in my TODO list.

I didn't double check the values against the TRM but I trust you ;-)

Acked-by: Javier Martinez Canillas <jav...@osg.samsung.com>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 00/37] ARM: dts: Fix fixed regulators enable GPIO polarity

2015-10-12 Thread Javier Martinez Canillas
Hello Tony,

On 10/12/2015 11:46 PM, Tony Lindgren wrote:
> * Laurent Pinchart <laurent.pinch...@ideasonboard.com> [151012 14:17]:
>> Hello,
>>
>> While working on regulators, GPIOs and DT I noticed that many of our DT 
>> source
>> files incorrectly describe fixed regulators. The common error patterns are
>>
>> - Usage of the undefined (and never parsed) enable-active-low property
>> - Usage of the enable-active-high property without specifying an enable GPIO
>> - Typos in the enabl GPIO property name (gpios instead of gpio)
>> - Mismatch between the enable-active-high property (or the lack thereof) and
>>   the enable GPIO flags
>>
>> This patch series fixes those issues in all the DT sources after locating the
>> errors using the following script.
>>
>> --
>> #!/bin/sh
>>
>> echo $1
>> cat $1 | awk '
>> BEGIN {
>>  open_drain = 0;
>>  active_high = 0;
>>  gpio = 0;
>>  flags = 0;
>> }
>>
>> match($0, /([a-zA-Z0-9@_-]*) {/, ary) {
>>  name = ary[1];
>> }
>>
>> /compatible.*"regulator-fixed"/ {
>>  found = 1;
>> }
>>
>> /enable-active-high/ {
>>  active_high = 1;
>> }
>>
>> /gpio-open-drain/ {
>>  open_drain = 1;
>> }
>>
>> match($0, /gpio += <.* ([^ ]*)>/, ary) {
>>  gpio = 1;
>>  flags = ary[1];
>>  if (flags == 0)
>>  flags = "GPIO_ACTIVE_HIGH";
>> }
>>
>> /}/ {
>>  if (found) {
>>  if (gpio) {
>>  print "\t" name ": active high " active_high " " flags 
>> " open drain " open_drain;
>>  if ((active_high && flags == "GPIO_ACTIVE_LOW") ||
>>  (!active_high && flags == "GPIO_ACTIVE_HIGH"))
>>  print "WARNING: enable-active-high and flags do 
>> not match"
>>  } else {
>>  if (active_high)
>>  print "WARNING: active high without GPIO"
>>  if (open_drain)
>>  print "WARNING: open drain without GPIO"
>>  }
>>  }
>>
>>  gpio = 0;
>>  found = 0;
>>  active_high = 0;
>>  open_drain = 0;
>>  flags = 0;
>> }
>> '
>> --
>>
>> All patches except for the ones touching omap3-beagle-xm and omap3-overo-base
>> are untested as I lack test hardware.
>>
>> As there's no dependency between the patches touching different source files
>> the appropriate maintainers could take their share of the patches in their
>> tree. Alternatively I could send a single pull request after collecting all
>> acks but that might be more complex.
> 
> Nice clean-up. For omaps, there's an earlier patch posted by
> Javier Martinez Canillas <jav...@osg.samsung.com> as "[PATCH] ARM: dts: Use
> defined GPIO constants in flags cell for OMAP2+ boards". Can you guys do some
> cross checking and let me know which combination I should appluy for omaps?
>

Since Laurent's changes for OMAP are part of a bigger series and my patch
was only for OMAP, probably makes sense for you to pick his patches and I
can re-spin mine on top of that.

BTW, I posted as a single patch since the changes were trivial but maybe
that made handling these conflicts harder and I should split the changes
instead, since I'll resend anyways.

What do you prefer? a patch per SoC family (i.e: OMAP{2,3,4,5}) or patch
per board DTS?
 
> Regards,
> 
> Tony
> --
> To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" 
> in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/2] ARM: dts: omap3-igep: Fix indentation

2015-10-12 Thread Javier Martinez Canillas
Hello Laurent,

Thanks for the patch.

On Mon, Oct 12, 2015 at 10:46 PM, Laurent Pinchart
<laurent.pinch...@ideasonboard.com> wrote:
> Use tabs instead of spaces for indentation.
>
> Signed-off-by: Laurent Pinchart <laurent.pinch...@ideasonboard.com>

Acked-by: Javier Martinez Canillas <jav...@osg.samsung.com>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/2] ARM: dts: omap3-igep0020: Remove duplicate uart2 pinmux

2015-10-12 Thread Javier Martinez Canillas
Hello Laurent,

Thanks for the patch.

On Mon, Oct 12, 2015 at 10:46 PM, Laurent Pinchart
<laurent.pinch...@ideasonboard.com> wrote:
> uart2 pinmux is already defined in omap3-igep0020-common.dtsi, remove
> the duplicate node.
>
> Signed-off-by: Laurent Pinchart <laurent.pinch...@ideasonboard.com>
> ---

Indeed, this is something that was overlooked when the common dtsi
file was introduced in commit ebc13bf2e0d2 ("ARM: dts:
omap3-igep0020-common: Introduce igep0020 common dtsi file").

Acked-by: Javier Martinez Canillas <jav...@osg.samsung.com>

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] ARM: dts: Use defined GPIO constants in flags cell for OMAP2+ boards

2015-10-06 Thread Javier Martinez Canillas
Many OMAP2+ DTS are not using the defined constants to express
the GPIO polarity. Replace these so the DTS are easier to read.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/omap2420-n8x0-common.dtsi|  6 +++---
 arch/arm/boot/dts/omap3-beagle-xm.dts  |  2 +-
 arch/arm/boot/dts/omap3-beagle.dts |  2 +-
 arch/arm/boot/dts/omap3-cm-t3x.dtsi|  2 +-
 arch/arm/boot/dts/omap3-devkit8000-lcd-common.dtsi |  2 +-
 arch/arm/boot/dts/omap3-evm-common.dtsi|  4 ++--
 arch/arm/boot/dts/omap3-gta04.dtsi | 10 +-
 arch/arm/boot/dts/omap3-gta04a5.dts|  2 +-
 arch/arm/boot/dts/omap3-ldp.dts|  2 +-
 arch/arm/boot/dts/omap3-lilly-a83x.dtsi|  2 +-
 arch/arm/boot/dts/omap3-lilly-dbb056.dts   |  4 ++--
 arch/arm/boot/dts/omap3-n950-n9.dtsi   |  2 +-
 arch/arm/boot/dts/omap3-overo-base.dtsi|  2 +-
 arch/arm/boot/dts/omap3-overo-common-lcd35.dtsi|  2 +-
 arch/arm/boot/dts/omap3-overo-common-lcd43.dtsi|  2 +-
 arch/arm/boot/dts/omap3-pandora-common.dtsi|  4 ++--
 arch/arm/boot/dts/omap3-tao3530.dtsi   |  4 ++--
 arch/arm/boot/dts/omap3-zoom3.dts  |  2 +-
 arch/arm/boot/dts/omap4-panda-common.dtsi  |  4 ++--
 arch/arm/boot/dts/omap4-sdp.dts|  6 +++---
 arch/arm/boot/dts/omap4-var-som-om44-wlan.dtsi |  2 +-
 arch/arm/boot/dts/omap4-var-som-om44.dtsi  |  2 +-
 arch/arm/boot/dts/omap4460.dtsi|  2 +-
 arch/arm/boot/dts/omap5-cm-t54.dts |  2 +-
 arch/arm/boot/dts/omap5-uevm.dts   |  2 +-
 25 files changed, 38 insertions(+), 38 deletions(-)

diff --git a/arch/arm/boot/dts/omap2420-n8x0-common.dtsi 
b/arch/arm/boot/dts/omap2420-n8x0-common.dtsi
index c9f1e93a95ae..8491f46c61b7 100644
--- a/arch/arm/boot/dts/omap2420-n8x0-common.dtsi
+++ b/arch/arm/boot/dts/omap2420-n8x0-common.dtsi
@@ -9,9 +9,9 @@
ocp {
i2c@0 {
compatible = "i2c-cbus-gpio";
-   gpios = < 2 0 /* gpio66 clk */
- 1 0 /* gpio65 dat */
- 0 0 /* gpio64 sel */
+   gpios = < 2 GPIO_ACTIVE_HIGH /* gpio66 clk */
+ 1 GPIO_ACTIVE_HIGH /* gpio65 dat */
+ 0 GPIO_ACTIVE_HIGH /* gpio64 sel */
>;
#address-cells = <1>;
#size-cells = <0>;
diff --git a/arch/arm/boot/dts/omap3-beagle-xm.dts 
b/arch/arm/boot/dts/omap3-beagle-xm.dts
index 7c4dca122a91..73f1e3a8f62c 100644
--- a/arch/arm/boot/dts/omap3-beagle-xm.dts
+++ b/arch/arm/boot/dts/omap3-beagle-xm.dts
@@ -80,7 +80,7 @@
regulator-name = "hsusb2_vbus";
regulator-min-microvolt = <330>;
regulator-max-microvolt = <330>;
-   gpio = <_gpio 18 0>;/* GPIO LEDA */
+   gpio = <_gpio 18 GPIO_ACTIVE_HIGH>; /* GPIO LEDA */
startup-delay-us = <7>;
};
 
diff --git a/arch/arm/boot/dts/omap3-beagle.dts 
b/arch/arm/boot/dts/omap3-beagle.dts
index 67659a0ed13e..274c2c482aaa 100644
--- a/arch/arm/boot/dts/omap3-beagle.dts
+++ b/arch/arm/boot/dts/omap3-beagle.dts
@@ -55,7 +55,7 @@
regulator-name = "hsusb2_vbus";
regulator-min-microvolt = <330>;
regulator-max-microvolt = <330>;
-   gpio = <_gpio 18 0>;/* GPIO LEDA */
+   gpio = <_gpio 18 GPIO_ACTIVE_HIGH>; /* GPIO LEDA */
startup-delay-us = <7>;
};
 
diff --git a/arch/arm/boot/dts/omap3-cm-t3x.dtsi 
b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
index 4d091ca43e25..8c813e77b17f 100644
--- a/arch/arm/boot/dts/omap3-cm-t3x.dtsi
+++ b/arch/arm/boot/dts/omap3-cm-t3x.dtsi
@@ -224,7 +224,7 @@
 
interrupt-parent = <>;
interrupts = <25 0>;/* gpio_57 */
-   pendown-gpio = < 25 0>;
+   pendown-gpio = < 25 GPIO_ACTIVE_HIGH>;
 
ti,x-min = /bits/ 16 <0x0>;
ti,x-max = /bits/ 16 <0x0fff>;
diff --git a/arch/arm/boot/dts/omap3-devkit8000-lcd-common.dtsi 
b/arch/arm/boot/dts/omap3-devkit8000-lcd-common.dtsi
index e84184de2a4a..4813e96157b3 100644
--- a/arch/arm/boot/dts/omap3-devkit8000-lcd-common.dtsi
+++ b/arch/arm/boot/dts/omap3-devkit8000-lcd-common.dtsi
@@ -54,7 +54,7 @@
 
interrupt-parent = <>;
interrupts = <27 0>;/* gpio_27 */
-   pendown-gpio = < 27 0>;
+   pendown-gpio = < 27 GPIO_ACTIVE_HIGH>;
 
ti,x-min = /

[PATCH] ARM: dts: omap3-lilly-a83x: Don't use IRQ level flag for a GPIO

2015-10-06 Thread Javier Martinez Canillas
The card detect GPIO is using IRQ_TYPE_LEVEL_LOW in the GPIO flag cells
but this defined constant is meant to be used for a IRQ and not a GPIO.
So instead use GPIO_ACTIVE_LOW that seems to be the original intention.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/omap3-lilly-a83x.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/omap3-lilly-a83x.dtsi 
b/arch/arm/boot/dts/omap3-lilly-a83x.dtsi
index 46f88f86a50b..57d7c93cc72b 100644
--- a/arch/arm/boot/dts/omap3-lilly-a83x.dtsi
+++ b/arch/arm/boot/dts/omap3-lilly-a83x.dtsi
@@ -284,7 +284,7 @@
 };
 
  {
-   cd-gpios = < 30 IRQ_TYPE_LEVEL_LOW>;
+   cd-gpios = < 30 GPIO_ACTIVE_LOW>;
cd-inverted;
vmmc-supply = <>;
bus-width = <4>;
-- 
2.4.3

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


Re: [PATCH 2/2] ARM: dts: Fix WLAN regression on omap5-uevm

2015-09-21 Thread Javier Martinez Canillas
[adding Ulf and Tomeu to cc list]

On Fri, Sep 18, 2015 at 10:27 PM, Tony Lindgren <t...@atomide.com> wrote:
> * Tony Lindgren <t...@atomide.com> [150918 10:54]:
>> * Javier Martinez Canillas <jav...@dowhile0.org> [150918 10:39]:
>> > Hello Tony,
>> >
>> > [snip]
>> >
>> > >
>> > > +   vmmcsdio_fixed: fixedregulator-mmcsdio {
>> > > +   compatible = "regulator-fixed";
>> > > +   regulator-name = "vmmcsdio_fixed";
>> > > +   regulator-min-microvolt = <180>;
>> > > +   regulator-max-microvolt = <180>;
>> > > +   gpio = < 12 GPIO_ACTIVE_HIGH>;/* gpio140 
>> > > WLAN_EN */
>> >
>> > I know that other OMAP boards use a fake fixed regulator to toggle the
>> > WiFi enable pin but now the MMC subsystem has proper support for power
>> > sequence providers so that should be used instead. For simple uses
>> > like this, Documentation/devicetree/bindings/mmc/mmc-pwrseq-simple.txt
>> > should be enough.
>>
>> Hmm OK great, I'll take a look. Looks like that might also provide a
>> nice solution for handling the 32k clock from palmas to the wl12xx.
>
> It seems it's not quite working yet.. It seems pwrseq_simple.c can't
> deal with delay on a power pin. It might be best to treat those using
> the regulator framework because of the refcounting and start-up delay.

Yes, pwrseq_simple does not support delaying a power pin. IIRC Tomeu
wanted to add a delay for power / reset pins at some point but then
the SDIO device he wanted to power up didn't need it so he dropped
that change at the end. I may be missremembering though.

> I don't think also having regulator handling in pwrseq_simple.c
> conflicts with the MMC regulators as they can be separate?
>

The original "mmc: add support for power-on sequencing through DT" [0]
patch from Olof that added just properties to the MMC controller slot
dev node had a "card-external-vcc-supply" for SDIO devices that needed
an external supply separate to vqmmc and vmmc supplies. The
pwrseq_simple does not support having an input supply regulator right
now but one can be added if that is needed.

> Also not related to wl12xx, the power pin on mwifiex_sdio 8787 wlan
> must be asserted low while reset is asserted and must stay low for
> 300ms after power pin has deasserted. Again using a regulator there
> for the power pin might make more sense.
>

Interesting, I've a patch queued on my tree to convert pwrseq_simple
to use the GPIO descriptors array API since all the code do now is to
set GPIO levels high or low for all the pins at the same time. But for
such a fine grained timing control as you said, I wonder if we should
just keep the code as it is now. Even when is open coding what
gpiod_{get,set,put}_array already do, it may make sense if we add
assert and deassert delay time for each pin.

Or maybe such a HW should have its own power sequence provider instead
of making pwrseq_simple more and more complex?

> Then getting the 32k clock from palmas is not working either, it
> seems some better deferred probe handling is needed there if
> omap_hsmmc is built-in and palmas-clk is a loadable module.
>

IIUC from another email, you already solved this.

> I think for the fix I'll stick with regulator fixed, let's update
> it later on unless you have better suggestions.
>

Yes, I didn't want to block your fixed regulator approach. I was just
pointing out that the MMC infrastructure already has support for power
sequence providers but if what is there doesn't fit your use case, I
agree that we can go with the regulator fixed for now and then change
it later.

>
> Cheers,
>
> Tony

[0]: http://patchwork.ozlabs.org/patch/312444/

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/2] ARM: dts: Fix WLAN regression on omap5-uevm

2015-09-18 Thread Javier Martinez Canillas
Hello Tony,

[snip]

>
> +   vmmcsdio_fixed: fixedregulator-mmcsdio {
> +   compatible = "regulator-fixed";
> +   regulator-name = "vmmcsdio_fixed";
> +   regulator-min-microvolt = <180>;
> +   regulator-max-microvolt = <180>;
> +   gpio = < 12 GPIO_ACTIVE_HIGH>;/* gpio140 WLAN_EN */

I know that other OMAP boards use a fake fixed regulator to toggle the
WiFi enable pin but now the MMC subsystem has proper support for power
sequence providers so that should be used instead. For simple uses
like this, Documentation/devicetree/bindings/mmc/mmc-pwrseq-simple.txt
should be enough.

Best regards,
Javier
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH] ARM: OMAP3: vc: Remove unused macros

2015-09-17 Thread Javier Martinez Canillas
The PRM_POLCTRL_TWL_MASK and PRM_POLCTRL_TWL_MASK
macros are not used so they can be deleted.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/mach-omap2/vc.c | 4 
 1 file changed, 4 deletions(-)

diff --git a/arch/arm/mach-omap2/vc.c b/arch/arm/mach-omap2/vc.c
index d44d311704ba..2028167fff31 100644
--- a/arch/arm/mach-omap2/vc.c
+++ b/arch/arm/mach-omap2/vc.c
@@ -280,10 +280,6 @@ void omap3_vc_set_pmic_signaling(int core_next_state)
}
 }
 
-#define PRM_POLCTRL_TWL_MASK   (OMAP3430_PRM_POLCTRL_CLKREQ_POL | \
-   OMAP3430_PRM_POLCTRL_CLKREQ_POL)
-#define PRM_POLCTRL_TWL_VALOMAP3430_PRM_POLCTRL_CLKREQ_POL
-
 /*
  * Configure signal polarity for sys_clkreq and sys_off_mode pins
  * as the default values are wrong and can cause the system to hang
-- 
2.4.3

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


[PATCH] ARM: OMAP: Remove duplicated operand in OR operation

2015-09-17 Thread Javier Martinez Canillas
Commit b483a4a5a711 ("ARM: OMAP4+: hwmod data: Don't prevent RESET of
USB Host module") added the SYSC_HAS_RESET_STATUS flag to both OMAP4
and OMAP5 USB host module hwmon sysconfig but that flag was already
set for OMAP5. So now the flag appears twice in the expression.

make coccicheck complains with the following message:

omap_hwmod_54xx_data.c:1846:37-58: duplicated argument to & or |

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/mach-omap2/omap_hwmod_54xx_data.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c 
b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
index 7c3fac035e93..8cdfd9b7ab4f 100644
--- a/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
+++ b/arch/arm/mach-omap2/omap_hwmod_54xx_data.c
@@ -1844,8 +1844,7 @@ static struct omap_hwmod_class_sysconfig 
omap54xx_usb_host_hs_sysc = {
.rev_offs   = 0x,
.sysc_offs  = 0x0010,
.sysc_flags = (SYSC_HAS_MIDLEMODE | SYSC_HAS_RESET_STATUS |
-  SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET |
-  SYSC_HAS_RESET_STATUS),
+  SYSC_HAS_SIDLEMODE | SYSC_HAS_SOFTRESET),
.idlemodes  = (SIDLE_FORCE | SIDLE_NO | SIDLE_SMART |
   SIDLE_SMART_WKUP | MSTANDBY_FORCE | MSTANDBY_NO |
   MSTANDBY_SMART | MSTANDBY_SMART_WKUP),
-- 
2.4.3

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


[PATCH] ARM: OMAP2+: Remove unneeded semicolons

2015-09-17 Thread Javier Martinez Canillas
Remove the unneded semicolons since they are clearly a typo error.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/mach-omap2/pm44xx.c| 2 +-
 arch/arm/mach-omap2/powerdomains3xxx_data.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/pm44xx.c b/arch/arm/mach-omap2/pm44xx.c
index d697cecf762b..178e22c146b7 100644
--- a/arch/arm/mach-omap2/pm44xx.c
+++ b/arch/arm/mach-omap2/pm44xx.c
@@ -210,7 +210,7 @@ static inline int omap4plus_init_static_deps(const struct 
static_dep_map *map)
}
 
map++;
-   };
+   }
 
return 0;
 }
diff --git a/arch/arm/mach-omap2/powerdomains3xxx_data.c 
b/arch/arm/mach-omap2/powerdomains3xxx_data.c
index d31c495175c1..2e00c7f1f471 100644
--- a/arch/arm/mach-omap2/powerdomains3xxx_data.c
+++ b/arch/arm/mach-omap2/powerdomains3xxx_data.c
@@ -582,7 +582,7 @@ void __init omap3xxx_powerdomains_init(void)
 
/* Only 81xx needs custom pwrdm_operations */
if (!cpu_is_ti81xx())
-   pwrdm_register_platform_funcs(_pwrdm_operations);;
+   pwrdm_register_platform_funcs(_pwrdm_operations);
 
rev = omap_rev();
 
-- 
2.4.3

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


[RESEND PATCH] OMAPDSS: panel-sony-acx565akm: Export OF module alias information

2015-09-16 Thread Javier Martinez Canillas
Drivers needs to export the OF id table and this be built into
the module or udev won't have the necessary information to autoload
the driver module when the device is registered via OF.

Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c 
b/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c
index 90cbc4c3406c..c581231c74a5 100644
--- a/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c
+++ b/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c
@@ -898,6 +898,7 @@ static const struct of_device_id acx565akm_of_match[] = {
{ .compatible = "omapdss,sony,acx565akm", },
{},
 };
+MODULE_DEVICE_TABLE(of, acx565akm_of_match);
 
 static struct spi_driver acx565akm_driver = {
.driver = {
-- 
2.4.3

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


[PATCH] ARM: dts: omap3-igep: Move eth IRQ pinmux to IGEPv2 common dtsi

2015-09-07 Thread Javier Martinez Canillas
Only the IGEPv2 boards have a LAN9221i chip connected to the GPMC
so the pinmux configuration for the GPIO connected to the IRQ line
of the LAN chip should not be defined in the IGEP common dtsi but
in the one common to the IGEPv2 boards.

While there, use the OMAP3_CORE1_IOPAD() macro for the padconf reg.

Suggested-by: Ladislav Michl <la...@linux-mips.org>
Signed-off-by: Javier Martinez Canillas <jav...@osg.samsung.com>

---

 arch/arm/boot/dts/omap3-igep.dtsi| 6 --
 arch/arm/boot/dts/omap3-igep0020-common.dtsi | 6 ++
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm/boot/dts/omap3-igep.dtsi 
b/arch/arm/boot/dts/omap3-igep.dtsi
index d5e5cd449b16..2230e1c03320 100644
--- a/arch/arm/boot/dts/omap3-igep.dtsi
+++ b/arch/arm/boot/dts/omap3-igep.dtsi
@@ -78,12 +78,6 @@
>;
};
 
-   smsc9221_pins: pinmux_smsc9221_pins {
-   pinctrl-single,pins = <
-   0x1a2 (PIN_INPUT | MUX_MODE4)   /* 
mcspi1_cs2.gpio_176 */
-   >;
-   };
-
i2c1_pins: pinmux_i2c1_pins {
pinctrl-single,pins = <
0x18a (PIN_INPUT | MUX_MODE0)   /* i2c1_scl.i2c1_scl */
diff --git a/arch/arm/boot/dts/omap3-igep0020-common.dtsi 
b/arch/arm/boot/dts/omap3-igep0020-common.dtsi
index e458c2185e3c..5ad688c57a00 100644
--- a/arch/arm/boot/dts/omap3-igep0020-common.dtsi
+++ b/arch/arm/boot/dts/omap3-igep0020-common.dtsi
@@ -156,6 +156,12 @@
OMAP3_CORE1_IOPAD(0x217a, PIN_INPUT | MUX_MODE0)
/* uart2_rx.uart2_rx */
>;
};
+
+   smsc9221_pins: pinmux_smsc9221_pins {
+   pinctrl-single,pins = <
+   OMAP3_CORE1_IOPAD(0x21d2, PIN_INPUT | MUX_MODE4)
/* mcspi1_cs2.gpio_176 */
+   >;
+   };
 };
 
 _pmx_core2 {
-- 
2.4.3

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


[PATCH 04/18] OMAPDSS: panel-sony-acx565akm: Export OF module alias information

2015-08-20 Thread Javier Martinez Canillas
The SPI core always reports the MODALIAS uevent as spi:modalias
regardless of the mechanism that was used to register the device
(i.e: OF or board code) and the table that is used later to match
the driver with the device (i.e: SPI id table or OF match table).

So drivers needs to export the SPI id table and this be built into
the module or udev won't have the necessary information to autoload
the needed driver module when the device is added.

But this means that OF-only drivers needs to have both OF and SPI id
tables that have to be kept in sync and also the dev node compatible
manufacturer prefix is stripped when reporting the MODALIAS. Which can
lead to issues if two vendors use the same SPI device name for example.

To avoid the above, the SPI core behavior may be changed in the future
to not require an SPI device table for OF-only drivers and report the
OF module alias. So, it's better to also export the OF table even when
is unused now to prevent breaking module loading when the core changes.

Signed-off-by: Javier Martinez Canillas jav...@osg.samsung.com
---

 drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c 
b/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c
index 90cbc4c3406c..c581231c74a5 100644
--- a/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c
+++ b/drivers/video/fbdev/omap2/displays-new/panel-sony-acx565akm.c
@@ -898,6 +898,7 @@ static const struct of_device_id acx565akm_of_match[] = {
{ .compatible = omapdss,sony,acx565akm, },
{},
 };
+MODULE_DEVICE_TABLE(of, acx565akm_of_match);
 
 static struct spi_driver acx565akm_driver = {
.driver = {
-- 
2.4.3

--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 00/18] Export SPI and OF module aliases in missing drivers

2015-08-20 Thread Javier Martinez Canillas
Hello,

Short version:

This patch series is the SPI equivalent of the I2C one posted before [0].

This series add the missing MODULE_DEVICE_TABLE() for OF and SPI tables
to export that information so modules have the correct aliases built-in
and autoloading works correctly.

Longer version:

The SPI core always reports the MODALIAS uevent as spi:modalias
regardless of the mechanism that was used to register the device (i.e:
OF or board code) and the table that is used later to match the driver
with the device (i.e: SPI id table or OF match table).

But this means that OF-only drivers needs to have both OF and SPI id
tables that have to be kept in sync and also the device node's compatible
manufacturer prefix is stripped when reporting the MODALIAS. Which can
lead to issues if two vendors use the same SPI device name for example.

Also, there are many SPI drivers whose module auto-loading is not working
because of this fact that the SPI core always reports the MODALIAS as
spi:modalias and many developers didn't expect this since is not how
other subsystems behave.

I've identified SPI drivers with 3 types of different issues:

a) Those that have an spi_table but are not exported. The match works
   if the driver is built-in but since the ID table is not exported,
   module auto-load won't work.

b) Those that have a of_table but are not exported. This is currently
   not an issue since even when the of_table is used to match the dev
   with the driver, an OF modalias is not reported by the SPI core.
   But if the SPI core is changed to report the MODALIAS of the form
   of:N*T*C as it's made by other subsystems, then module auto-load
   will break for these drivers.

c) Those that don't have an of_table but should since are OF drivers
   with DT bindings doc for them. Since the SPI core does not report
   a OF modalias and since spi_match_device() fallbacks to match the
   device part of the compatible string with the SPI device ID table,
   many OF drivers don't have an of_table to match. After all having
   a SPI device ID table is mandatory so it works without a of_table.

So, in order to not make mandatory to have a SPI device ID table, all
these three kind of issues have to be addressed. This series does that.

I split the changes so the patches in this series are independent and
can be picked individually by subsystem maintainers.

Patches #1 and #2 solves a), patches #3 to #8 solves b) and patches

Patch #18 changes the logic of spi_uevent() to report an OF modalias if
the device was registered using OF. But this patch is included in the
series only as an RFC for illustration purposes since changing that
without first applying all the other patches in this series, will break
module autoloading for the drivers of devices registered using OF but
that lacks an of_match_table. I'll repost patch #18 once all the patches
in this series have landed.

[0]: https://lkml.org/lkml/2015/7/30/519

Best regards,
Javier


Javier Martinez Canillas (18):
  iio: Export SPI module alias information in missing drivers
  staging: iio: hmc5843: Export missing SPI module alias information
  mtd: dataflash: Export OF module alias information
  OMAPDSS: panel-sony-acx565akm: Export OF module alias information
  mmc: mmc_spi: Export OF module alias information
  staging: mt29f_spinand: Export OF module alias information
  net: ks8851: Export OF module alias information
  [media] s5c73m3: Export OF module alias information
  mfd: cros_ec: spi: Add OF match table
  iio: dac: ad7303: Add OF match table
  iio: adc: max1027: Set struct spi_driver .of_match_table
  mfd: stmpe: Add OF match table
  iio: adc: mcp320x: Set struct spi_driver .of_match_table
  iio: as3935: Add OF match table
  iio: adc128s052: Add OF match table
  iio: frequency: adf4350: Add OF match table
  NFC: trf7970a: Add OF match table
  spi: (RFC, don't apply) report OF style modalias when probing using DT

 drivers/iio/adc/max1027.c   |  1 +
 drivers/iio/adc/mcp320x.c   |  1 +
 drivers/iio/adc/ti-adc128s052.c |  8 
 drivers/iio/amplifiers/ad8366.c |  1 +
 drivers/iio/dac/ad7303.c|  7 +++
 drivers/iio/frequency/adf4350.c |  9 +
 drivers/iio/proximity/as3935.c  |  7 +++
 drivers/media/i2c/s5c73m3/s5c73m3-spi.c |  1 +
 drivers/mfd/cros_ec_spi.c   |  7 +++
 drivers/mfd/stmpe-spi.c | 13 +
 drivers/mmc/host/mmc_spi.c  |  1 +
 drivers/mtd/devices/mtd_dataflash.c |  1 +
 drivers/net/ethernet/micrel/ks8851.c|  1 +
 drivers/nfc/trf7970a.c  |  7 +++
 drivers/spi/spi.c   |  8

Re: [PATCH 00/18] Export SPI and OF module aliases in missing drivers

2015-08-20 Thread Javier Martinez Canillas
Hello Brian,

On 08/20/2015 11:11 PM, Brian Norris wrote:
 On Thu, Aug 20, 2015 at 09:07:13AM +0200, Javier Martinez Canillas wrote:
 Patches #1 and #2 solves a), patches #3 to #8 solves b) and patches
 
 ^^^ I'm dying to know how this sentence ends :)


Sigh, I did some last minute restructuring of the cover letter and
seems I missed a sentence. I meant to said:

and patches #9 to #17 solves c).
 
 Patch #18 changes the logic of spi_uevent() to report an OF modalias if
 the device was registered using OF. But this patch is included in the
 series only as an RFC for illustration purposes since changing that
 without first applying all the other patches in this series, will break
 module autoloading for the drivers of devices registered using OF but
 that lacks an of_match_table. I'll repost patch #18 once all the patches
 in this series have landed.
 
 On a more productive note, the patches I've looked at look good to me.
 The missing aliases are a problem enough that should be fixed (i.e.,
 part (b)). I'll leave the SPI framework changes to others to comment on.


Great, thanks a lot for your feedback.
 
 Brian
 

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] memory: omap-gpmc: Don't try to save the GPMC context

2015-08-05 Thread Javier Martinez Canillas
Hello Tomeu,

On Wed, Aug 5, 2015 at 2:24 PM, Tomeu Vizoso tomeu.viz...@collabora.com wrote:
 ...if there isn't one already.


I think is better to instead splitting the subject line like this, to
change it for something that fits like memory: omap-gpmc: Don't try
to save uninitialized GPMC context  or memory: omap-gpmc: Fix
gpmc_base NULL pointer dereference

 If for some reason the GPMC device hasn't been probed yet, gpmc_base is
 going to be NULL. Because there's no context yet to be saved, just turn
 these functions into no-ops until that device gets probed.

 Unable to handle kernel NULL pointer dereference at virtual address 0010
 pgd = c0204000
 [0010] *pgd=
 Internal error: Oops: 5 [#1] SMP ARM
 Modules linked in:

Also, I don't know if the kernel backtrace makes the commit message
more readable. Maybe instead you can add an explanation of who is
calling this function? That this function is called from OMAP2+
CPUidle code that tries to save the state of several IP blocks but
omap3_gpmc_{save,restore}_context() assumes that it will be called
after the probe() function has initialized gpmc_base and that might
not be true?

The patch looks good to me though so after these changes feel free to
also add my:

Reviewed-by: Javier Martinez Canillas jav...@osg.samsung.com

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 00/27] Export I2C and OF module aliases in missing drivers

2015-07-30 Thread Javier Martinez Canillas
Hello Dmitry,

Thanks a lot for your feedback.

On 07/30/2015 06:37 PM, Dmitry Torokhov wrote:
 On Thu, Jul 30, 2015 at 09:35:17AM -0700, Dmitry Torokhov wrote:
 Hi Javier,

 On Thu, Jul 30, 2015 at 06:18:25PM +0200, Javier Martinez Canillas wrote:
 Hello,

 Short version:

 This series add the missing MODULE_DEVICE_TABLE() for OF and I2C tables
 to export that information so modules have the correct aliases built-in
 and autoloading works correctly.

 Longer version:

 Currently it's mandatory for I2C drivers to have an I2C device ID table
 regardless if the device was registered using platform data or OF. This
 is because the I2C core needs an I2C device ID table for two reasons:

 1) Match the I2C client with a I2C device ID so a struct i2c_device_id
is passed to the I2C driver probe() function.

 2) Export the module aliases from the I2C device ID table so userspace
can auto-load the correct module. This is because i2c_device_uevent
always reports a MODALIAS of the form i2c:client-name.

 Why are we not fixing this? We emit specially carved uevent for
 ACPI-based devices, why not the same for OF? Platform bus does this...
 
 Ah, now I see the 27/27 patch. I think it is exactly what we need. And

Yes, patch 27/27 is needed but the problem is as I explained before that
there are drivers relying on the current behavior. The item c) in the list
of issues that I mentioned. So those drivers need to be fixed before that
patch is merged...

 probably for SPI bus as well.


Yes, I didn't mention SPI because the cover letter became too long
already but it does indeed have the same issue and I discussed this
with  Mark already some time ago [0].

Once I2C uevent report is fixed, I plan to do the same for SPI.

 Thanks.
 

[0]: https://lkml.org/lkml/2014/9/11/458

Best regards,
-- 
Javier Martinez Canillas
Open Source Group
Samsung Research America
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 27/27] i2c: (RFC, don't apply) report OF style modalias when probing using DT

2015-07-30 Thread Javier Martinez Canillas
An I2C driver that supports both OF and legacy platforms, will have
both a OF and I2C ID table. This means that when built as a module,
the aliases will be filled from both tables but currently always an
alias of the form i2c:deviceId is reported, e.g:

$ cat /sys/class/i2c-adapter/i2c-8/8-004b/modalias
i2c:maxtouch

So if a device is probed by matching its compatible string, udev can
get a MODALIAS uevent env var that doesn't match with one of the valid
aliases so the module won't be auto-loaded.

This patch changes the I2C core to report a OF related MODALIAS uevent
(of:N*T*C) env var instead so the module can be auto-loaded and also
report the correct alias using sysfs:

$ cat /sys/class/i2c-adapter/i2c-8/8-004b/modalias
of:NtrackpadTNULLCatmel,maxtouch

Signed-off-by: Javier Martinez Canillas jav...@osg.samsung.com



---

 drivers/i2c/i2c-core.c | 8 
 1 file changed, 8 insertions(+)

diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
index 92dddfeb3f39..c0668c2ed9da 100644
--- a/drivers/i2c/i2c-core.c
+++ b/drivers/i2c/i2c-core.c
@@ -489,6 +489,10 @@ static int i2c_device_uevent(struct device *dev, struct 
kobj_uevent_env *env)
struct i2c_client   *client = to_i2c_client(dev);
int rc;
 
+   rc = of_device_uevent_modalias(dev, env);
+   if (rc != -ENODEV)
+   return rc;
+
rc = acpi_device_uevent_modalias(dev, env);
if (rc != -ENODEV)
return rc;
@@ -726,6 +730,10 @@ show_modalias(struct device *dev, struct device_attribute 
*attr, char *buf)
struct i2c_client *client = to_i2c_client(dev);
int len;
 
+   len = of_device_get_modalias(dev, buf, PAGE_SIZE - 1);
+   if (len != -ENODEV)
+   return len;
+
len = acpi_device_modalias(dev, buf, PAGE_SIZE -1);
if (len != -ENODEV)
return len;
-- 
2.4.3

--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 16/27] mfd: Export OF module alias information in missing drivers

2015-07-30 Thread Javier Martinez Canillas
The I2C core always reports the MODALIAS uevent as i2c:client name
regardless if the driver was matched using the I2C id_table or the
of_match_table. So technically there's no need for a driver to export
the OF table since currently it's not used.

In fact, the I2C device ID table is mandatory for I2C drivers since
a i2c_device_id is passed to the driver's probe function even if the
I2C core used the OF table to match the driver.

And since the I2C core uses different tables, OF-only drivers needs to
have duplicated data that has to be kept in sync and also the dev node
compatible manufacturer prefix is stripped when reporting the MODALIAS.

To avoid the above, the I2C core behavior may be changed in the future
to not require an I2C device table for OF-only drivers and report the
OF module alias. So, it's better to also export the OF table to prevent
breaking module autoloading if that happens.

Signed-off-by: Javier Martinez Canillas jav...@osg.samsung.com

---

 drivers/mfd/rt5033.c   | 1 +
 drivers/mfd/tps65217.c | 1 +
 drivers/mfd/tps65218.c | 1 +
 3 files changed, 3 insertions(+)

diff --git a/drivers/mfd/rt5033.c b/drivers/mfd/rt5033.c
index db395a6c52bc..d60f91619c4a 100644
--- a/drivers/mfd/rt5033.c
+++ b/drivers/mfd/rt5033.c
@@ -124,6 +124,7 @@ static const struct of_device_id rt5033_dt_match[] = {
{ .compatible = richtek,rt5033, },
{ }
 };
+MODULE_DEVICE_TABLE(of, rt5033_dt_match);
 
 static struct i2c_driver rt5033_driver = {
.driver = {
diff --git a/drivers/mfd/tps65217.c b/drivers/mfd/tps65217.c
index bc455feb42be..55add0453ae9 100644
--- a/drivers/mfd/tps65217.c
+++ b/drivers/mfd/tps65217.c
@@ -156,6 +156,7 @@ static const struct of_device_id tps65217_of_match[] = {
{ .compatible = ti,tps65217, .data = (void *)TPS65217 },
{ /* sentinel */ },
 };
+MODULE_DEVICE_TABLE(of, tps65217_of_match);
 
 static int tps65217_probe(struct i2c_client *client,
const struct i2c_device_id *ids)
diff --git a/drivers/mfd/tps65218.c b/drivers/mfd/tps65218.c
index cb38d725250f..80b9dc363cd8 100644
--- a/drivers/mfd/tps65218.c
+++ b/drivers/mfd/tps65218.c
@@ -211,6 +211,7 @@ static const struct of_device_id of_tps65218_match_table[] 
= {
{ .compatible = ti,tps65218, },
{}
 };
+MODULE_DEVICE_TABLE(of, of_tps65218_match_table);
 
 static int tps65218_probe(struct i2c_client *client,
const struct i2c_device_id *ids)
-- 
2.4.3

--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 00/27] Export I2C and OF module aliases in missing drivers

2015-07-30 Thread Javier Martinez Canillas
Hello,

Short version:

This series add the missing MODULE_DEVICE_TABLE() for OF and I2C tables
to export that information so modules have the correct aliases built-in
and autoloading works correctly.

Longer version:

Currently it's mandatory for I2C drivers to have an I2C device ID table
regardless if the device was registered using platform data or OF. This
is because the I2C core needs an I2C device ID table for two reasons:

1) Match the I2C client with a I2C device ID so a struct i2c_device_id
   is passed to the I2C driver probe() function.

2) Export the module aliases from the I2C device ID table so userspace
   can auto-load the correct module. This is because i2c_device_uevent
   always reports a MODALIAS of the form i2c:client-name.

Lee Jones posted a patch series [0] to solve 1) by allowing the I2C
drivers to have a probe() function that does not get a i2c_device_id.

The problem is that his series didn't take into account 2) so if that
was merged and the I2C ID table is removed from all the drivers that
don't needed it, module auto-loading will break for those.

But even now there are many I2C drivers were module auto-loading is
not working because of the fact that the I2C core always reports the
MODALIAS as i2c:client-name and many developers didn't expect this.

I've identified I2C drivers with 3 types of different issues:

a) Those that have an i2c_table but are not exported. The match works
   and the correct i2c_device_id is passed on probe but since the ID
   table is not exported, module auto-load won't work.

b) Those that have a of_table but are not exported. This is currently
   not an issue since even when the of_table is used to match the dev
   with the driver, an OF modalias is not reported by the I2C core.
   But if the I2C core is changed to report the MODALIAS of the form
   of:N*T*C as it's made by other subsystems, then module auto-load
   will break for these drivers.

c) Those that don't have a of_table but should since are OF drivers
   with DT bindings doc for them. Since the I2C core does not report
   a OF modalias and since i2c_device_match() fallbacks to match the
   device part of the compatible string with the I2C device ID table,
   many OF drivers don't have an of_table to match. After all having
   a I2C device ID table is mandatory so it works without a of_table.

So, in order to not make mandatory to have a I2C device ID table, at
least a) and b) needs to be addressed, this series does that.

c) should be fixed too since it seems wrong that a driver with a DT
binding document, does not have a OF table and export it to modules.

Also stripping the vendor part from the compatible string to match
with the I2C devices ID table and reporting only the device name to
user-space doesn't seem to be correct. I've identified at least two
drivers that have the same name on their I2C device ID table so the
manufacturer prefix is important. But I've not tried to fix c) yet
since that is not so easy to automate due drivers not having all the
information (i.e: the device name can match a documented compatible
string device part but without the vendor prefix is hard to tell).

I split the changes so the patches in this series are independent and
can be picked individually by subsystem maintainers. Patch #27 changes
the logic of i2c_device_uevent() to report an OF modalias if the device
was registered using OF. But this patch is included in the series only
as an RFC for illustration purposes since changing that without fixing
c) will break module auto-loading for the drivers of devices registered
with OF but that don't have a of_match_table.

Although arguably, those drivers were relying on the assumption that a
MODALIAS=i2c:foo would always be reported even for the OF case which
is not the true on other subsystems.

[0]: https://lkml.org/lkml/2014/8/28/283

Best regards,
Javier


Javier Martinez Canillas (27):
  mfd: stw481x: Export I2C module alias information
  spi: xcomm: Export I2C module alias information
  iio: Export I2C module alias information in missing drivers
  [media] Export I2C module alias information in missing drivers
  macintosh: therm_windtunnel: Export I2C module alias information
  misc: eeprom: Export I2C module alias information in missing drivers
  Input: Export I2C module alias information in missing drivers
  power: Export I2C module alias information in missing drivers
  i2c: core: Export I2C module alias information in dummy driver
  backlight: tosa: Export I2C module alias information
  [media] staging: media: lirc: Export I2C module alias information
  usb: phy: isp1301: Export I2C module alias information
  ALSA: ppc: keywest: Export I2C module alias information
  hwmon: (nct7904) Export I2C module alias information
  regulator: fan53555: Export I2C module alias information
  mfd: Export OF module alias information in missing drivers
  iio: Export OF module alias information in missing drivers
  hwmon: (g762) Export OF module alias information

Re: [PATCH REPOST] gpio: omap: use raw locks for locking

2015-06-19 Thread Javier Martinez Canillas
On Fri, Jun 19, 2015 at 7:42 PM, santosh shilimkar
santosh.shilim...@oracle.com wrote:
 On 6/19/2015 10:06 AM, Sebastian Andrzej Siewior wrote:

 This patch converts gpio_bank.lock from a spin_lock into a
 raw_spin_lock. The call path is to access this lock is always under a
 raw_spin_lock, for instance
 - __setup_irq() holds desc-lock with irq off
+ __irq_set_trigger()
 + omap_gpio_irq_type()

 - handle_level_irq() (runs with irqs off therefore raw locks)
+ mask_ack_irq()
 + omap_gpio_mask_irq()

 This fixes the obvious backtrace on -RT. However the locking vs context
 is not and this is not limited to -RT:
 - omap_gpio_irq_type() is called with IRQ off and has an conditional
call to pm_runtime_get_sync() which may sleep. Either it may happen or
it may not happen but pm_runtime_get_sync() should not be called with
irqs off.

 - omap_gpio_debounce() is holding the lock with IRQs off.
+ omap2_set_gpio_debounce()
 + clk_prepare_enable()
  + clk_prepare() this one might sleep.
The number of users of gpiod_set_debounce() / gpio_set_debounce()
looks low but still this is not good.

 Signed-off-by: Sebastian Andrzej Siewior bige...@linutronix.de
 ---

 Should be safe to do it.
 Acked-by: Santosh Shilimkar ssant...@kernel.org


Answered on the wrong thread, sorry for the noise.

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in


Re: [PATCH] gpio: omap: use raw locks for locking

2015-06-19 Thread Javier Martinez Canillas
Hello Sebastian,

On Thu, Feb 12, 2015 at 5:10 PM, Sebastian Andrzej Siewior
bige...@linutronix.de wrote:
 This patch converts gpio_bank.lock from a spin_lock into a
 raw_spin_lock. The call path to access this lock is always under a
 raw_spin_lock, for instance
 - __setup_irq() holds desc-lock with irq off
   + __irq_set_trigger()
+ omap_gpio_irq_type()

 - handle_level_irq() (runs with irqs off therefore raw locks)
   + mask_ack_irq()
+ omap_gpio_mask_irq()

 This fixes the obvious backtrace on -RT. However I noticed two cases
 where it looks wrong and this is not limited to -RT:
 - omap_gpio_irq_type() is called with IRQ off and has an conditional
   call to pm_runtime_get_sync() which may sleep. Either it may happen or
   it may not happen but pm_runtime_get_sync() should not be called in an
   atomic section.

 - omap_gpio_debounce() is holding the lock with IRQs off.
   + omap2_set_gpio_debounce()
+ clk_prepare_enable()
 + clk_prepare() this one might sleep.
   The number of users of gpiod_set_debounce() / gpio_set_debounce()
   looks low but still this is not good.

 Signed-off-by: Sebastian Andrzej Siewior bige...@linutronix.de
 ---

I had already acked the first time you posted this [0] but you didn't
carry the tag so here goes again:

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

Best regards,
Javier

[0]: https://patchwork.ozlabs.org/patch/439249/
--
To unsubscribe from this list: send the line unsubscribe linux-omap in


Re: [RFT v2 05/48] gpio: Use irq_desc_get_xxx() to avoid redundant lookup of irq_desc

2015-06-04 Thread Javier Martinez Canillas
Hello Jiang,

On Thu, Jun 4, 2015 at 6:13 AM, Jiang Liu jiang@linux.intel.com wrote:
 Use irq_desc_get_xxx() to avoid redundant lookup of irq_desc while we
 already have a pointer to corresponding irq_desc.

 Signed-off-by: Jiang Liu jiang@linux.intel.com
 Acked-by: Linus Walleij linus.wall...@linaro.org
 ---
  drivers/gpio/gpio-bcm-kona.c   |2 +-
  drivers/gpio/gpio-dwapb.c  |2 +-
  drivers/gpio/gpio-mvebu.c  |2 +-
  drivers/gpio/gpio-mxc.c|6 +++---
  drivers/gpio/gpio-mxs.c|2 +-
  drivers/gpio/gpio-omap.c   |2 +-

For gpio-omap:

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFT v2 45/48] genirq, gpio: Kill the first parameter 'irq' of irq_flow_handler_t

2015-06-04 Thread Javier Martinez Canillas
Hello Jiang,

On Thu, Jun 4, 2015 at 6:13 AM, Jiang Liu jiang@linux.intel.com wrote:
 Now most IRQ flow handlers make no use of the first parameter 'irq'.
 And for those who do make use of 'irq', we could easily get the irq
 number through irq_desc-irq_data-irq. So kill the first parameter
 'irq' of irq_flow_handler_t.

 To ease review, I have split the changes into several parts, though
 they should be merge as one to support bisecting.

 Signed-off-by: Jiang Liu jiang@linux.intel.com
 ---
  drivers/gpio/gpio-altera.c |6 ++
  drivers/gpio/gpio-bcm-kona.c   |2 +-
  drivers/gpio/gpio-davinci.c|2 +-
  drivers/gpio/gpio-dwapb.c  |2 +-
  drivers/gpio/gpio-ep93xx.c |4 ++--
  drivers/gpio/gpio-intel-mid.c  |2 +-
  drivers/gpio/gpio-lynxpoint.c  |2 +-
  drivers/gpio/gpio-mpc8xxx.c|2 +-
  drivers/gpio/gpio-msic.c   |2 +-
  drivers/gpio/gpio-msm-v2.c |2 +-
  drivers/gpio/gpio-mvebu.c  |2 +-
  drivers/gpio/gpio-mxc.c|4 ++--
  drivers/gpio/gpio-mxs.c|2 +-
  drivers/gpio/gpio-omap.c   |2 +-

For gpio-omap:

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/7] gpio: omap: fix omap_gpio_free to not clean up irq configuration

2015-06-02 Thread Javier Martinez Canillas
Hello Linus,

On Mon, Jun 1, 2015 at 3:11 PM, Linus Walleij linus.wall...@linaro.org wrote:
 On Fri, May 22, 2015 at 4:35 PM, Grygorii Strashko
 grygorii.stras...@linaro.org wrote:

 This patch fixes following issue:
 - GPIOn is used as IRQ by some dev, for example PCF8575.INT -  gpio6.11
 - PCFx driver knows nothing about type of IRQ line (GPIO or not)
   so it doesn't request gpio and just do request_irq()
 - If gpio6.11 will be exported through the sysfs and then un-xeported
 then IRQs from PCFx will not be received any more, because
 IRQ configuration for gpio6.11 will be cleaned up unconditionally
 in omap_gpio_free.

 Fix this by removing all GPIO IRQ specific code from omap_gpio_free()
 and also do GPIO clean up (change direction to 'in' and disable debounce)
 only if corresponding GPIO is not used as IRQ too.
 GPIO IRQ will be properly cleaned up by GPIO irqchip code.

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org

 Can I get an ACK or comment from one of the three (!) maintainers
 on atleast these non-RFC patches?


Sorry for the delay, the patch looks good to me.

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

 Yours,
 Linus Walleij

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/7] gpio: omap: fix error handling in omap_gpio_irq_type

2015-06-02 Thread Javier Martinez Canillas
Hello Grygorii,

On Fri, May 22, 2015 at 4:35 PM, Grygorii Strashko
grygorii.stras...@linaro.org wrote:
 The GPIO bank will be kept powered in case if input parameters
 are invalid or error occurred in omap_gpio_irq_type.

 Hence, fix it by ensuring that GPIO bank will be unpowered
 in case of errors and add additional check of value returned
 from omap_set_gpio_triggering().

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org
 ---
  drivers/gpio/gpio-omap.c | 16 
  1 file changed, 12 insertions(+), 4 deletions(-)

 diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c
 index bb60cbc..f6cc638 100644
 --- a/drivers/gpio/gpio-omap.c
 +++ b/drivers/gpio/gpio-omap.c
 @@ -488,9 +488,6 @@ static int omap_gpio_irq_type(struct irq_data *d, 
 unsigned type)
 unsigned long flags;
 unsigned offset = d-hwirq;

 -   if (!BANK_USED(bank))
 -   pm_runtime_get_sync(bank-dev);
 -
 if (type  ~IRQ_TYPE_SENSE_MASK)
 return -EINVAL;

 @@ -498,12 +495,18 @@ static int omap_gpio_irq_type(struct irq_data *d, 
 unsigned type)
 (type  (IRQ_TYPE_LEVEL_LOW|IRQ_TYPE_LEVEL_HIGH)))
 return -EINVAL;

 +   if (!BANK_USED(bank))
 +   pm_runtime_get_sync(bank-dev);
 +
 spin_lock_irqsave(bank-lock, flags);
 retval = omap_set_gpio_triggering(bank, offset, type);
 +   if (retval)

At this point the bank-lock spinlock is held so you need to add a
spin_unlock_irqrestore() in the error path.

 +   goto error;
 omap_gpio_init_irq(bank, offset);
 if (!omap_gpio_is_input(bank, offset)) {
 spin_unlock_irqrestore(bank-lock, flags);
 -   return -EINVAL;
 +   retval = -EINVAL;
 +   goto error;
 }
 spin_unlock_irqrestore(bank-lock, flags);

 @@ -512,6 +515,11 @@ static int omap_gpio_irq_type(struct irq_data *d, 
 unsigned type)
 else if (type  (IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING))
 __irq_set_handler_locked(d-irq, handle_edge_irq);

 +   return 0;
 +
 +error:
 +   if (!BANK_USED(bank))
 +   pm_runtime_put(bank-dev);
 return retval;
  }

 --

But you are correct about the runtime PM bug so after addressing the
above comment, feel free to add:

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCHv7] media: i2c/adp1653: fix includes

2015-04-13 Thread Javier Martinez Canillas
Hello Pali,

On Thu, Apr 9, 2015 at 2:59 PM, Pali Rohár pali.ro...@gmail.com wrote:
 On Thursday 09 April 2015 14:43:59 Javier Martinez Canillas wrote:

 Please re-spin your previous patch and submit it properly.

 Best regards,
 Javier

 Hi all! What about stopping this meaningless discussion about resending
 full patch series when everybody know how to fix is quickly in editor
 (e.g with sed under 5s) and not wasting another 10 minutes to generate
 new unified diff sent via SMTP protocol?


No, there is a reason why we have written rules on how patches should
be submitted. Everyone in the kernel community is expected to optimize
their workflow according to these rules to make life easier for people
reviewing and merging the patches.

As you said now someone has to fix this using an editor and that is an
error prone process. Besides, why it would take 10 minutes to generate
a proper patch-set? git is very good on this regard (i.e: git commit
---fixup  git rebase -i  git format-patch  git send-email).

I won't argue anymore but I find very sad that people who have been in
the kernel community for years don't follow the basic rules we have
documented it. So I wonder why we have the documentation in the first
place and how can we expect newcomers to follow if even experienced
kernel hackers don't.

 --
 Pali Rohár
 pali.ro...@gmail.com

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCHv7] media: i2c/adp1653: fix includes

2015-04-09 Thread Javier Martinez Canillas
Hello Pavel,

On Thu, Apr 9, 2015 at 2:31 PM, Pavel Machek pa...@ucw.cz wrote:
 Fix includes according to Sebastian.

 Signed-off-by: Pavel Machek pa...@ucw.cz

 ---

 On Thu 2015-04-09 14:19:14, Sebastian Reichel wrote:
 On Thu, Apr 09, 2015 at 01:29:43PM +0200, Pavel Machek wrote:
  On Thu 2015-04-09 11:10:17, Sebastian Reichel wrote:
   On Thu, Apr 09, 2015 at 09:42:38AM +0200, Pavel Machek wrote:
[...]
+#include linux/of_gpio.h
+#include linux/gpio.h
[...]
  
   This should probably be
  
   #include linux/of.h
   #include linux/gpio/consumer.h
 
  And I thought people would only bikesched paint on the
  Documentation. Sakari, feel free to change that, but

  a) I don't see why Sebastian's version is better

 You neither use linux/of_gpio.h nor linux/gpio.h.

 Well include/linux/gpio.h describes the old gpio API. The new
 gpiod gpiod API is described in include/linux/gpio/consumer.h and
 you use it, so the include should be included ;)

 You don't use anything from include/linux/of_gpio.h, but it
 includes include/linux/of.h, which you are using. So you should
 include linux/of.h instead ;)

 diff --git a/drivers/media/i2c/adp1653.c b/drivers/media/i2c/adp1653.c
 index d703636..7107ac2 100644
 --- a/drivers/media/i2c/adp1653.c
 +++ b/drivers/media/i2c/adp1653.c
 @@ -35,8 +35,8 @@
  #include linux/module.h
  #include linux/i2c.h
  #include linux/slab.h
 -#include linux/of_gpio.h
 -#include linux/gpio.h
 +#include linux/of.h
 +#include linux/gpio/consumer.h
  #include media/adp1653.h
  #include media/v4l2-device.h


Please re-spin your previous patch and submit it properly.

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCHv4] media: i2c/adp1653: devicetree support for adp1653

2015-04-03 Thread Javier Martinez Canillas
Hello Pavel,

On Fri, Apr 3, 2015 at 10:21 AM, Pavel Machek pa...@ucw.cz wrote:
 Hi!

  Fixed feedback by Sakari.
 
  Please apply,

 There is no need to ask for patches to be applied IMHO. It is expected
 that people post patches wanting them to be applied unless there is an
 RFC prefix in the subject or say explicitly that the patch is for
 testing and should not be picked.

 See history of this patch.

  diff --git a/Documentation/devicetree/bindings/media/i2c/adp1653.txt 
  b/Documentation/devicetree/bindings/media/i2c/adp1653.txt

 When adding DT bindings, the Documentation portion should be in a
 separate patch and should come in the series before the patch
 implementing the binding. That makes the change easier to review,
 please take a look to points 1 and 3 in
 Documentation/devicetree/bindings/submitting-patches.txt.

 Because actual patch at the end of email is too much eye clutter for
 the poor device tree people, I can prepare nice series... producing
 more work for me and more noise on the lists? No, thanks.


I wonder then what's the point of having written rules if people are
not going to follow...

  +Required Properties:
  +
  +  - compatible: Must contain be adi,adp1653
  +
  +  - reg: I2C slave address
  +
  +  - gpios: References to the GPIO that controls the power for the chip.

 The convention nowadays is to not use unnamed DT properties for GPIOs
 but instead use a prefix that explains what those GPIOs are used for.
 So something like power-gpios or power-gpio (if there is only one
 GPIO) will be more suitable. Please take a look to
 Documentation/gpio/board.txt for more details.

 Ok. Actually, reading docs below, power-gpio will not work, and it
 needs to be power-gpios, right?


No, the documentation is not updated. People used function-gpio so
at the end it was added as another supported suffix, see commit:
dd34c37aa3e8 (gpio: of: Allow -gpio suffix for property names).

But I guess it doesn't matter if -gpio or -gpios is used.

  +   if (!of_find_property(node, gpios, NULL)) {
  +   dev_err(client-dev, No gpio node\n);
  +   return -EINVAL;
  +   }
  +
  +   pd-power_gpio = of_get_gpio_flags(node, 0, flags);

 The old integer-based GPIO interface is deprecated and we want to get
 rid of it so please use the descriptor-based for new code. For example
 you want to use gpiod_get() instead of of_get_gpio_flags().
 Documentation/gpio/gpio.txt describes the new interface.

 Ok.
 Pavel
 --

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCHv4] media: i2c/adp1653: devicetree support for adp1653

2015-04-02 Thread Javier Martinez Canillas
Hello Pavel,

I haven't reviewed the patch since I'm not familiar with the hardware
but just wanted to point out a couple of things that I spot:

On Thu, Apr 2, 2015 at 10:34 PM, Pavel Machek pa...@ucw.cz wrote:


 We are moving to device tree support on OMAP3, but that currently
 breaks ADP1653 driver. This adds device tree support, plus required
 documentation.

 Signed-off-by: Pavel Machek pa...@ucw.cz

 ---

 Fixed feedback by Sakari.

 Please apply,

There is no need to ask for patches to be applied IMHO. It is expected
that people post patches wanting them to be applied unless there is an
RFC prefix in the subject or say explicitly that the patch is for
testing and should not be picked.

 Pavel

 diff --git a/Documentation/devicetree/bindings/media/i2c/adp1653.txt 
 b/Documentation/devicetree/bindings/media/i2c/adp1653.txt

When adding DT bindings, the Documentation portion should be in a
separate patch and should come in the series before the patch
implementing the binding. That makes the change easier to review,
please take a look to points 1 and 3 in
Documentation/devicetree/bindings/submitting-patches.txt.

 new file mode 100644
 index 000..0fc28a9
 --- /dev/null
 +++ b/Documentation/devicetree/bindings/media/i2c/adp1653.txt
 @@ -0,0 +1,37 @@
 +* Analog Devices ADP1653 flash LED driver
 +
 +Required Properties:
 +
 +  - compatible: Must contain be adi,adp1653
 +
 +  - reg: I2C slave address
 +
 +  - gpios: References to the GPIO that controls the power for the chip.

The convention nowadays is to not use unnamed DT properties for GPIOs
but instead use a prefix that explains what those GPIOs are used for.
So something like power-gpios or power-gpio (if there is only one
GPIO) will be more suitable. Please take a look to
Documentation/gpio/board.txt for more details.

 +
 +There are two led outputs available - flash and indicator. One led is
 +represented by one child node, nodes need to be named flash and 
 indicator.
 +
 +Required properties of the LED child node:
 +- max-microamp : see Documentation/devicetree/bindings/leds/common.txt
 +
 +Required properties of the flash LED child node:
 +
 +- flash-max-microamp : see Documentation/devicetree/bindings/leds/common.txt
 +- flash-timeout-us : see Documentation/devicetree/bindings/leds/common.txt
 +
 +Example:
 +
 +   adp1653: led-controller@30 {
 +   compatible = adi,adp1653;
 +   reg = 0x30;
 +   gpios = gpio3 24 GPIO_ACTIVE_HIGH; /* 88 */
 +
 +   flash {
 +   flash-timeout-us = 50;
 +   flash-max-microamp = 32;
 +   max-microamp = 5;
 +   };
 +   indicator {
 +   max-microamp = 17500;
 +   };
 +   };
 diff --git a/drivers/media/i2c/adp1653.c b/drivers/media/i2c/adp1653.c
 index 873fe19..6d57b16 100644
 --- a/drivers/media/i2c/adp1653.c
 +++ b/drivers/media/i2c/adp1653.c
 @@ -8,6 +8,7 @@
   * Contributors:
   * Sakari Ailus sakari.ai...@iki.fi
   * Tuukka Toivonen tuukka...@gmail.com
 + * Pavel Machek pa...@ucw.cz
   *
   * This program is free software; you can redistribute it and/or
   * modify it under the terms of the GNU General Public License
 @@ -34,6 +35,8 @@
  #include linux/module.h
  #include linux/i2c.h
  #include linux/slab.h
 +#include linux/of_gpio.h
 +#include linux/gpio.h
  #include media/adp1653.h
  #include media/v4l2-device.h

 @@ -306,9 +309,17 @@ adp1653_init_device(struct adp1653_flash *flash)
  static int
  __adp1653_set_power(struct adp1653_flash *flash, int on)
  {
 -   int ret;
 +   int ret = 0;
 +
 +   if (flash-platform_data-power) {
 +   ret = flash-platform_data-power(flash-subdev, on);
 +   } else {
 +   gpio_set_value(flash-platform_data-power_gpio, on);
 +   if (on)
 +   /* Some delay is apparently required. */
 +   udelay(20);
 +   }

 -   ret = flash-platform_data-power(flash-subdev, on);
 if (ret  0)
 return ret;

 @@ -316,8 +327,13 @@ __adp1653_set_power(struct adp1653_flash *flash, int on)
 return 0;

 ret = adp1653_init_device(flash);
 -   if (ret  0)
 +   if (ret = 0)
 +   return ret;
 +
 +   if (flash-platform_data-power)
 flash-platform_data-power(flash-subdev, 0);
 +   else
 +   gpio_set_value(flash-platform_data-power_gpio, 0);

 return ret;
  }
 @@ -407,21 +423,76 @@ static int adp1653_resume(struct device *dev)

  #endif /* CONFIG_PM */

 +static int adp1653_of_init(struct i2c_client *client,
 +  struct adp1653_flash *flash,
 +  struct device_node *node)
 +{
 +   u32 val;
 +   struct adp1653_platform_data *pd;
 +   enum of_gpio_flags flags;
 +   struct device_node *child;
 +
 + 

Re: [RFT OMAP1 PATCH 7/8] gpio: omap: get rid of omap_irq_to_gpio()

2015-03-20 Thread Javier Martinez Canillas
Hello Grygorii,

On Fri, Mar 20, 2015 at 9:39 PM, grygorii.stras...@linaro.org
grygorii.stras...@linaro.org wrote:
 On 03/20/2015 08:56 PM, Javier Martinez Canillas wrote:
 Hello Grygorii,

 On Thu, Mar 19, 2015 at 6:25 PM,  grygorii.stras...@linaro.org wrote:
 From: Grygorii Strashko grygorii.stras...@linaro.org

 Now OMAP GPIO driver prepared for omap_irq_to_gpio() removing.
 Do it ;)

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org

 I don't have access to OMAP1 boards to test but Tony did it o an
 osk5912 and Aaro can confirm that it doesn't cause regressions on
 other OMAP1 boards.

 Thanks. But could you clarify one point to me please?
 Aaro can confirm that it doesn't cause regressions on
 other OMAP1 boards - Does It mean I can add his Tested-by?
 Or I still have to wait for his direct reply?
 Just to avoid any confusions ;)


I meant that as far as I know Aaro has access to more OMAP1 systems so
he should be able to test that no regressions are added for those. But
I don't know if he would be able to test and I think your cleanups are
good so that's why I acked the patches.

Sorry for the confusion.

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 2/8] gpio: omap: simplify omap_set_gpio_dataout_x()

2015-03-20 Thread Javier Martinez Canillas
On Fri, Mar 20, 2015 at 5:45 PM, santosh.shilim...@oracle.com
santosh.shilim...@oracle.com wrote:
 On 3/19/15 10:25 AM, grygorii.stras...@linaro.org wrote:

 From: Grygorii Strashko grygorii.stras...@linaro.org

 Both functions omap_set_gpio_dataout_reg() and
 omap_set_gpio_dataout_mask() accept GPIO offset
 as 'gpio' input parameter, so rename it to 'offset' and
 drop usage of GPIO_BIT() macro.

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org
 ---

 Acked-by: Santosh Shilimkar ssant...@kernel.org

Acked-by: Javier Martinez Canillas jav...@dowhile0.org
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFT OMAP1 PATCH 7/8] gpio: omap: get rid of omap_irq_to_gpio()

2015-03-20 Thread Javier Martinez Canillas
Hello Grygorii,

On Thu, Mar 19, 2015 at 6:25 PM,  grygorii.stras...@linaro.org wrote:
 From: Grygorii Strashko grygorii.stras...@linaro.org

 Now OMAP GPIO driver prepared for omap_irq_to_gpio() removing.
 Do it ;)

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org

I don't have access to OMAP1 boards to test but Tony did it o an
osk5912 and Aaro can confirm that it doesn't cause regressions on
other OMAP1 boards.

Thanks a lot for the cleanup.

Acked-by: Javier Martinez Canillas jav...@dowhile0.org

Best regards,
Javier
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [RFT OMAP1 PATCH 8/8] gpio: omap: get rid of GPIO_INDEX() macro

2015-03-20 Thread Javier Martinez Canillas
On Thu, Mar 19, 2015 at 6:25 PM,  grygorii.stras...@linaro.org wrote:
 From: Grygorii Strashko grygorii.stras...@linaro.org

 Now OMAP GPIO driver prepared for GPIO_INDEX() macro removing.
 Do It ;)

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org

Acked-by: Javier Martinez Canillas jav...@dowhile0.org
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 3/8] gpio: omap: convert debounce functions switch to use gpio offset

2015-03-20 Thread Javier Martinez Canillas
On Thu, Mar 19, 2015 at 6:25 PM,  grygorii.stras...@linaro.org wrote:
 From: Grygorii Strashko grygorii.stras...@linaro.org

 Convert debounce functions to use GPIO offset instead of system
 GPIO numbers. This allows to drop unneeded conversations between
 system GPIO - GPIO offset which are done in many places and
 many times.
 It is safe to do now because:
 - gpiolib always passes GPIO offset to GPIO controller
 - OMAP GPIO driver converted to use IRQ domain

 This is preparation step before removing:
  #define GPIO_INDEX(bank, gpio)
  #define GPIO_BIT(bank, gpio)
  int omap_irq_to_gpio()

 Signed-off-by: Grygorii Strashko grygorii.stras...@linaro.org
 ---

Acked-by: Javier Martinez Canillas jav...@dowhile0.org
--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


  1   2   3   4   5   6   7   >