All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [linux-sunxi] [PATCH] Add NFC register definitions for Allwinner A20 SoC
  2018-12-26 11:37 [U-Boot] [PATCH] Add NFC register definitions for Allwinner A20 SoC Nikolai Zhubr
@ 2018-12-26 11:28 ` Priit Laes
  2018-12-26 14:37   ` Nikolai Zhubr
  2018-12-29 20:42 ` [U-Boot] " Jagan Teki
  1 sibling, 1 reply; 4+ messages in thread
From: Priit Laes @ 2018-12-26 11:28 UTC (permalink / raw)
  To: u-boot

On Wed, Dec 26, 2018 at 02:37:26PM +0300, Nikolai Zhubr wrote:
> And while at it, why not finally add the DT register definitions for
> Allwinner A20 NFC. I'm certainly not the author of these, and they have been
> around for many years already. Its quite unlikely they will suddenly change,
> or vary between different A20-based devices. The A20 SoC is gradually
> becoming obsolete, so why wait any more. Note: one whould typically need to
> also add NFC node definition on top of this in order to actually use it.
> 
> Signed-off-by: Nikolai Zhubr <n-a-zhubr@yandex.ru>
> ---
> arch/arm/dts/sun7i-a20.dtsi | 69
> +++++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 69 insertions(+)
> 
> diff --git a/arch/arm/dts/sun7i-a20.dtsi b/arch/arm/dts/sun7i-a20.dtsi
> index e529e4f..6f96693 100644
> --- a/arch/arm/dts/sun7i-a20.dtsi
> +++ b/arch/arm/dts/sun7i-a20.dtsi
> @@ -920,6 +920,75 @@
> 				pins = "PI20", "PI21";
> 				function = "uart7";
> 			};
> +			nand_pins_a: nand_base0 at 0 {
> +				allwinner,pins = "PC0", "PC1", "PC2",
> +						"PC5", "PC8", "PC9", "PC10",
> +						"PC11", "PC12", "PC13", "PC14",
> +						"PC15", "PC16";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;

allwinner,{pins,function,drive,pull} syntax has been deprecated in
favor or general pinctrl syntax.

You can check how sun5i.dtsi defines these blocks.


> +			};
> +			nand_cs0_pins_a: nand_cs at 0 {
> +				allwinner,pins = "PC4";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs1_pins_a: nand_cs at 1 {
> +				allwinner,pins = "PC3";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs2_pins_a: nand_cs at 2 {
> +				allwinner,pins = "PC17";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs3_pins_a: nand_cs at 3 {
> +				allwinner,pins = "PC18";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs4_pins_a: nand_cs at 4 {
> +				allwinner,pins = "PC19";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs5_pins_a: nand_cs at 5 {
> +				allwinner,pins = "PC20";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs6_pins_a: nand_cs at 6 {
> +				allwinner,pins = "PC21";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_cs7_pins_a: nand_cs at 7 {
> +				allwinner,pins = "PC22";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_rb0_pins_a: nand_rb at 0 {
> +				allwinner,pins = "PC6";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> +			nand_rb1_pins_a: nand_rb at 1 {
> +				allwinner,pins = "PC7";
> +				allwinner,function = "nand0";
> +				allwinner,drive = <0>;
> +				allwinner,pull = <0>;
> +			};
> 		};
> 
> 		timer at 1c20c00 {
> -- 
> 2.1.2
> 
> -- 
> You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe at googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

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

* [U-Boot] [PATCH] Add NFC register definitions for Allwinner A20 SoC
@ 2018-12-26 11:37 Nikolai Zhubr
  2018-12-26 11:28 ` [U-Boot] [linux-sunxi] " Priit Laes
  2018-12-29 20:42 ` [U-Boot] " Jagan Teki
  0 siblings, 2 replies; 4+ messages in thread
From: Nikolai Zhubr @ 2018-12-26 11:37 UTC (permalink / raw)
  To: u-boot

And while at it, why not finally add the DT register definitions for 
Allwinner A20 NFC. I'm certainly not the author of these, and they have 
been around for many years already. Its quite unlikely they will 
suddenly change, or vary between different A20-based devices. The A20 
SoC is gradually becoming obsolete, so why wait any more. Note: one 
whould typically need to also add NFC node definition on top of this in 
order to actually use it.

Signed-off-by: Nikolai Zhubr <n-a-zhubr@yandex.ru>
---
arch/arm/dts/sun7i-a20.dtsi | 69 
+++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 69 insertions(+)

diff --git a/arch/arm/dts/sun7i-a20.dtsi b/arch/arm/dts/sun7i-a20.dtsi
index e529e4f..6f96693 100644
--- a/arch/arm/dts/sun7i-a20.dtsi
+++ b/arch/arm/dts/sun7i-a20.dtsi
@@ -920,6 +920,75 @@
				pins = "PI20", "PI21";
				function = "uart7";
			};
+			nand_pins_a: nand_base0 at 0 {
+				allwinner,pins = "PC0", "PC1", "PC2",
+						"PC5", "PC8", "PC9", "PC10",
+						"PC11", "PC12", "PC13", "PC14",
+						"PC15", "PC16";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs0_pins_a: nand_cs at 0 {
+				allwinner,pins = "PC4";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs1_pins_a: nand_cs at 1 {
+				allwinner,pins = "PC3";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs2_pins_a: nand_cs at 2 {
+				allwinner,pins = "PC17";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs3_pins_a: nand_cs at 3 {
+				allwinner,pins = "PC18";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs4_pins_a: nand_cs at 4 {
+				allwinner,pins = "PC19";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs5_pins_a: nand_cs at 5 {
+				allwinner,pins = "PC20";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs6_pins_a: nand_cs at 6 {
+				allwinner,pins = "PC21";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_cs7_pins_a: nand_cs at 7 {
+				allwinner,pins = "PC22";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_rb0_pins_a: nand_rb at 0 {
+				allwinner,pins = "PC6";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
+			nand_rb1_pins_a: nand_rb at 1 {
+				allwinner,pins = "PC7";
+				allwinner,function = "nand0";
+				allwinner,drive = <0>;
+				allwinner,pull = <0>;
+			};
		};

		timer at 1c20c00 {
-- 
2.1.2

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

* [U-Boot] [linux-sunxi] [PATCH] Add NFC register definitions for Allwinner A20 SoC
  2018-12-26 11:28 ` [U-Boot] [linux-sunxi] " Priit Laes
@ 2018-12-26 14:37   ` Nikolai Zhubr
  0 siblings, 0 replies; 4+ messages in thread
From: Nikolai Zhubr @ 2018-12-26 14:37 UTC (permalink / raw)
  To: u-boot

Hi,

26.12.2018 14:28, Priit Laes:
>> And while at it, why not finally add the DT register definitions for
>> Allwinner A20 NFC. I'm certainly not the author of these, and they have been
[...]
>> +			nand_pins_a: nand_base0 at 0 {
>> +				allwinner,pins = "PC0", "PC1", "PC2",
>> +						"PC5", "PC8", "PC9", "PC10",
>> +						"PC11", "PC12", "PC13", "PC14",
>> +						"PC15", "PC16";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>
> allwinner,{pins,function,drive,pull} syntax has been deprecated in
> favor or general pinctrl syntax.
>
> You can check how sun5i.dtsi defines these blocks.

Well, I could certainly do such editing, but I'm not sure if something 
related in the tree will also need to be updated accordingly, therefore 
I'd prefer to refrain.
I'm rather a u-boot user than a u-boot developer, I can do some simple 
searching and testing, but probably not refactoring.
Thing is, however, the original Allwinner's implementation of nand boot 
procedure for A20 appeared to be so messy and fragile and inconvenient 
that using u-boot's mainline approach is basically the only reasonable 
choice for this device. (And btw great thanks to all developers who 
implemented it!)


Regards,
Nikolai

>
>
>> +			};
>> +			nand_cs0_pins_a: nand_cs at 0 {
>> +				allwinner,pins = "PC4";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs1_pins_a: nand_cs at 1 {
>> +				allwinner,pins = "PC3";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs2_pins_a: nand_cs at 2 {
>> +				allwinner,pins = "PC17";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs3_pins_a: nand_cs at 3 {
>> +				allwinner,pins = "PC18";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs4_pins_a: nand_cs at 4 {
>> +				allwinner,pins = "PC19";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs5_pins_a: nand_cs at 5 {
>> +				allwinner,pins = "PC20";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs6_pins_a: nand_cs at 6 {
>> +				allwinner,pins = "PC21";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_cs7_pins_a: nand_cs at 7 {
>> +				allwinner,pins = "PC22";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_rb0_pins_a: nand_rb at 0 {
>> +				allwinner,pins = "PC6";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> +			nand_rb1_pins_a: nand_rb at 1 {
>> +				allwinner,pins = "PC7";
>> +				allwinner,function = "nand0";
>> +				allwinner,drive =<0>;
>> +				allwinner,pull =<0>;
>> +			};
>> 		};
>>
>> 		timer at 1c20c00 {
>> --
>> 2.1.2
>>
>> --
>> You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
>> To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe at googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>

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

* [U-Boot] [PATCH] Add NFC register definitions for Allwinner A20 SoC
  2018-12-26 11:37 [U-Boot] [PATCH] Add NFC register definitions for Allwinner A20 SoC Nikolai Zhubr
  2018-12-26 11:28 ` [U-Boot] [linux-sunxi] " Priit Laes
@ 2018-12-29 20:42 ` Jagan Teki
  1 sibling, 0 replies; 4+ messages in thread
From: Jagan Teki @ 2018-12-29 20:42 UTC (permalink / raw)
  To: u-boot

On Wed, Dec 26, 2018 at 4:49 PM Nikolai Zhubr <n-a-zhubr@yandex.ru> wrote:
>
> And while at it, why not finally add the DT register definitions for
> Allwinner A20 NFC. I'm certainly not the author of these, and they have
> been around for many years already. Its quite unlikely they will
> suddenly change, or vary between different A20-based devices. The A20
> SoC is gradually becoming obsolete, so why wait any more. Note: one
> whould typically need to also add NFC node definition on top of this in
> order to actually use it.
>
> Signed-off-by: Nikolai Zhubr <n-a-zhubr@yandex.ru>
> ---
> arch/arm/dts/sun7i-a20.dtsi | 69

dts(i) changes need to be synced from Linux,we don't encourage to add
them explicitly. Better sync from Linux if required.

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

end of thread, other threads:[~2018-12-29 20:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-26 11:37 [U-Boot] [PATCH] Add NFC register definitions for Allwinner A20 SoC Nikolai Zhubr
2018-12-26 11:28 ` [U-Boot] [linux-sunxi] " Priit Laes
2018-12-26 14:37   ` Nikolai Zhubr
2018-12-29 20:42 ` [U-Boot] " Jagan Teki

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.