Commit Graph

5 Commits

Author SHA1 Message Date
Filip Matijević e2b03c16eb ipq806x: add missing enclosing partitions block for TP-Link C2600
The partitions that have compatible property set are skipped by mtd if
they are not contained inside a partitions node and this breaks
fetching MAC address from "default-mac" partition.

Fix this by defining all the partitions inside partitions node with
compatible = "fixed-partitions" as nvmem requires the standard
partitions scheme to work correctly.

Fixes: FS#3945
Fixes: cd36d71655 ("ipq806x/dts: Add Archer C2600 DTS")
Fixes: 0458a8993c ("ipq806x: convert mtd-mac-address to nvmem
implementation")

Signed-off-by: Filip Matijević <filip.matijevic.pz@gmail.com>
Reviewed-by: Ansuel Smith <ansuelsmth@gmail.com>
[adjust commit title/message]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-08-30 00:37:35 +02:00
Ansuel Smith 0458a8993c ipq806x: convert mtd-mac-address to nvmem implementation
Define nvmem-cells and convert mtd-mac-address to nvmem implementation.
The conversion is done with an automated script.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2021-07-19 14:51:22 +02:00
Ansuel Smith d284e6ef0f treewide: convert mtd-mac-address-increment* to generic implementation
Rework patch 681-NET-add-mtd-mac-address-support to implement
only the function to read the mac-address from mtd.
Generalize mtd-mac-address-increment function so it can be applied
to any source of of_get_mac_address.
Rename any mtd-mac-address-increment to mac-address-increment.
Rename any mtd-mac-address-increment-byte to mac-address-increment-byte.

This should make simplify the conversion of target to nvmem implementation.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
2021-07-19 14:51:22 +02:00
Adrian Schmutzler 849d4b3940 ipq806x: add space before SPDX identifier (again)
Strictly, an SPDX identifier requires a space between the comment
marker and the identifier itself. This has been addressed in
b69c21738e ("treewide: add space before SPDX identifier"), but
some new malformatted identifiers were merged recently.

This could have been prevented by using checkpatch.pl earlier.

Fixes: 1a775a4fd0 ("ipq806x: add support for TP-Link Talon AD7200")
Fixes: 8ddaeaf642 ("ipq806x: create DTSI for TP-Link AD7200 and C2600")

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-01-06 23:53:25 +01:00
Adrian Schmutzler 8ddaeaf642 ipq806x: create DTSI for TP-Link AD7200 and C2600
Both devices share most of their setup except buttons and LEDs,
so having a common DTSI removes a lot of duplicate code.

In order to have a shared partitioning scheme, device-id and
product-info from AD7200 have been merged into a single
product-info partition like for C2600.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
2021-01-06 14:43:12 +01:00