linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] at91: mmc: fix minimum bus frequency
@ 2013-09-17  9:57 Jiri Prchal
  2013-09-17  9:57 ` [PATCH] at91: mmc: fix missing pinctrl in dt Jiri Prchal
  0 siblings, 1 reply; 4+ messages in thread
From: Jiri Prchal @ 2013-09-17  9:57 UTC (permalink / raw)
  To: linux-arm-kernel

In datasheet is mmc bus frequency divided by n+2. Uppon this maximum division is 513.

Signed-off-by: Jiri Prchal <jiri.prchal@aksignal.cz>
---
 drivers/mmc/host/atmel-mci.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/atmel-mci.c b/drivers/mmc/host/atmel-mci.c
index 69e438e..f61bbf6 100644
--- a/drivers/mmc/host/atmel-mci.c
+++ b/drivers/mmc/host/atmel-mci.c
@@ -2145,7 +2145,7 @@ static int __init atmci_init_slot(struct atmel_mci *host,
 		slot_data->wp_pin);
 
 	mmc->ops = &atmci_ops;
-	mmc->f_min = DIV_ROUND_UP(host->bus_hz, 512);
+	mmc->f_min = DIV_ROUND_UP(host->bus_hz, 513);
 	mmc->f_max = host->bus_hz / 2;
 	mmc->ocr_avail	= MMC_VDD_32_33 | MMC_VDD_33_34;
 	if (sdio_irq)
-- 
1.7.9.5

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

* [PATCH] at91: mmc: fix missing pinctrl in dt
  2013-09-17  9:57 [PATCH] at91: mmc: fix minimum bus frequency Jiri Prchal
@ 2013-09-17  9:57 ` Jiri Prchal
  2013-09-19 13:21   ` Nicolas Ferre
  0 siblings, 1 reply; 4+ messages in thread
From: Jiri Prchal @ 2013-09-17  9:57 UTC (permalink / raw)
  To: linux-arm-kernel

This patch adds pinctrl to soc dtsi file.

Signed-off-by: Jiri Prchal <jiri.prchal@aksignal.cz>
---
 arch/arm/boot/dts/at91sam9x5.dtsi |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boot/dts/at91sam9x5.dtsi b/arch/arm/boot/dts/at91sam9x5.dtsi
index cf78ac0..c5d26b0 100644
--- a/arch/arm/boot/dts/at91sam9x5.dtsi
+++ b/arch/arm/boot/dts/at91sam9x5.dtsi
@@ -556,6 +556,8 @@
 				interrupts = <12 IRQ_TYPE_LEVEL_HIGH 0>;
 				dmas = <&dma0 1 AT91_DMA_CFG_PER_ID(0)>;
 				dma-names = "rxtx";
+				pinctrl-names = "default";
+				pinctrl-0 = <&pinctrl_mmc0_slot0_clk_cmd_dat0>;
 				#address-cells = <1>;
 				#size-cells = <0>;
 				status = "disabled";
-- 
1.7.9.5

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

* [PATCH] at91: mmc: fix missing pinctrl in dt
  2013-09-17  9:57 ` [PATCH] at91: mmc: fix missing pinctrl in dt Jiri Prchal
@ 2013-09-19 13:21   ` Nicolas Ferre
  2013-09-19 13:24     ` Jiří Prchal
  0 siblings, 1 reply; 4+ messages in thread
From: Nicolas Ferre @ 2013-09-19 13:21 UTC (permalink / raw)
  To: linux-arm-kernel

On 17/09/2013 11:57, Jiri Prchal :
> This patch adds pinctrl to soc dtsi file.
>
> Signed-off-by: Jiri Prchal <jiri.prchal@aksignal.cz>


Jiri,

I will rework your patch by splitting the two lines. This will allow us 
to be consistent with other AT91 SoC/boards Device Tree descriptions.

+		pinctrl-names = "default";

This one is going in the SoC file, like you did.

+		pinctrl-0 = <&pinctrl_mmc0_slot0_clk_cmd_dat0>;

This one is under the responsibility of the board itself. The reason 
behind this is that the dat0 line can be multiplexed on another pin.

So, if you need a particular pinctrl configuration on the board side, 
please send another patch for this addition.

Thanks bye,


> ---
>   arch/arm/boot/dts/at91sam9x5.dtsi |    2 ++
>   1 file changed, 2 insertions(+)
>
> diff --git a/arch/arm/boot/dts/at91sam9x5.dtsi b/arch/arm/boot/dts/at91sam9x5.dtsi
> index cf78ac0..c5d26b0 100644
> --- a/arch/arm/boot/dts/at91sam9x5.dtsi
> +++ b/arch/arm/boot/dts/at91sam9x5.dtsi
> @@ -556,6 +556,8 @@
>   				interrupts = <12 IRQ_TYPE_LEVEL_HIGH 0>;
>   				dmas = <&dma0 1 AT91_DMA_CFG_PER_ID(0)>;
>   				dma-names = "rxtx";
> +				pinctrl-names = "default";
> +				pinctrl-0 = <&pinctrl_mmc0_slot0_clk_cmd_dat0>;
>   				#address-cells = <1>;
>   				#size-cells = <0>;
>   				status = "disabled";
>


-- 
Nicolas Ferre

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

* [PATCH] at91: mmc: fix missing pinctrl in dt
  2013-09-19 13:21   ` Nicolas Ferre
@ 2013-09-19 13:24     ` Jiří Prchal
  0 siblings, 0 replies; 4+ messages in thread
From: Jiří Prchal @ 2013-09-19 13:24 UTC (permalink / raw)
  To: linux-arm-kernel

OK.

Dne 19.9.2013 15:21, Nicolas Ferre napsal(a):
> On 17/09/2013 11:57, Jiri Prchal :
>> This patch adds pinctrl to soc dtsi file.
>>
>> Signed-off-by: Jiri Prchal <jiri.prchal@aksignal.cz>
>
>
> Jiri,
>
> I will rework your patch by splitting the two lines. This will allow us to be consistent with other AT91 SoC/boards
> Device Tree descriptions.
>
> +        pinctrl-names = "default";
>
> This one is going in the SoC file, like you did.
>
> +        pinctrl-0 = <&pinctrl_mmc0_slot0_clk_cmd_dat0>;
>
> This one is under the responsibility of the board itself. The reason behind this is that the dat0 line can be
> multiplexed on another pin.
>
> So, if you need a particular pinctrl configuration on the board side, please send another patch for this addition.
>
> Thanks bye,
>
>
>> ---
>>   arch/arm/boot/dts/at91sam9x5.dtsi |    2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/at91sam9x5.dtsi b/arch/arm/boot/dts/at91sam9x5.dtsi
>> index cf78ac0..c5d26b0 100644
>> --- a/arch/arm/boot/dts/at91sam9x5.dtsi
>> +++ b/arch/arm/boot/dts/at91sam9x5.dtsi
>> @@ -556,6 +556,8 @@
>>                   interrupts = <12 IRQ_TYPE_LEVEL_HIGH 0>;
>>                   dmas = <&dma0 1 AT91_DMA_CFG_PER_ID(0)>;
>>                   dma-names = "rxtx";
>> +                pinctrl-names = "default";
>> +                pinctrl-0 = <&pinctrl_mmc0_slot0_clk_cmd_dat0>;
>>                   #address-cells = <1>;
>>                   #size-cells = <0>;
>>                   status = "disabled";
>>
>
>

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

end of thread, other threads:[~2013-09-19 13:24 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-17  9:57 [PATCH] at91: mmc: fix minimum bus frequency Jiri Prchal
2013-09-17  9:57 ` [PATCH] at91: mmc: fix missing pinctrl in dt Jiri Prchal
2013-09-19 13:21   ` Nicolas Ferre
2013-09-19 13:24     ` Jiří Prchal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).