bcm63xx: Add support for D-Link DSL-2750u rev C1

This adds support for the D-Link DSL-2750u rev C1.
(https://deviwiki.com/wiki/D-Link_DSL-2750U_rev_C1)

It uses the same hardware as ADB P.DG A4001N.
CPU:   Broadcom BCM63281 (320 MHz)
RAM:   32M (Winbond W9725G6JB)
Flash:   8M (MXIC MX25L6445E)
Ethernet:   4x 100 Mbps
Wireless:   802.11b/g/n: BCM43225
USB:   1x 2.0

Flash instructions:

1.  Assign static IP 192.168.1.100 to PC
2.  Unplug the power source
3.  Press the RESET button at the router, don't release it yet!
4.  Plug the power source.Wait some seconds
5.  Release the RESET button
6.  Browse to http://192.168.1.1
7.  Send the openwrt-bcm63xx-generic-DSL2750U-C1-squashfs-cfe.bin and
    wait some minutes until the firmware upgrade finish.

Signed-off-by: Ahmed Naseef <naseefkm@gmail.com>
[DTS improvements, proper board patch, refresh patches]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
This commit is contained in:
Ahmed Naseef 2020-08-18 17:52:20 +05:30 committed by Álvaro Fernández Rojas
parent 0efbfef4f6
commit 8eeb57acb7
13 changed files with 171 additions and 9 deletions

View File

@ -16,6 +16,7 @@ actiontec,r1000h)
adb,a4001n|\
comtrend,ar-5315u|\
comtrend,vr-3032u|\
d-link,dsl-2750u-c1|\
huawei,hg253s-v2|\
nucom,r5010un-v2|\
sagem,fast-2704-v2)

View File

@ -31,6 +31,7 @@ comtrend,vr-3025u|\
comtrend,vr-3025un|\
comtrend,vr-3026e|\
d-link,dsl-274xb-f1|\
d-link,dsl-2750u-c1|\
d-link,dsl-275xb-d1|\
huawei,echolife-hg622|\
huawei,echolife-hg655b|\

View File

@ -0,0 +1,146 @@
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
#include "bcm6328.dtsi"
#include <dt-bindings/input/input.h>
/ {
model = "D-Link DSL-2750U rev C1";
compatible = "d-link,dsl-2750u-c1", "brcm,bcm6328";
aliases {
led-boot = &led_power_green;
led-failsafe = &led_power_green;
led-running = &led_power_green;
led-upgrade = &led_power_green;
};
chosen {
bootargs = "rootfstype=squashfs,jffs2 noinitrd console=ttyS0,115200";
stdout-path = "serial0:115200n8";
};
keys {
compatible = "gpio-keys-polled";
poll-interval = <20>;
wifi {
label = "wifi";
gpios = <&pinctrl 12 1>;
linux,code = <KEY_WLAN>;
debounce-interval = <60>;
};
reset {
label = "reset";
gpios = <&pinctrl 23 1>;
linux,code = <KEY_RESTART>;
debounce-interval = <60>;
};
wps {
label = "wps";
gpios = <&pinctrl 24 1>;
linux,code = <KEY_WPS_BUTTON>;
debounce-interval = <60>;
};
};
};
&hsspi {
status = "okay";
flash@0 {
compatible = "jedec,spi-nor";
spi-max-frequency = <16666667>;
spi-tx-bus-width = <2>;
spi-rx-bus-width = <2>;
reg = <0>;
partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
cfe@0 {
reg = <0x000000 0x010000>;
label = "cfe";
read-only;
};
linux@10000 {
reg = <0x010000 0x7e0000>;
label = "linux";
compatible = "brcm,bcm963xx-imagetag";
};
nvram@7f0000 {
reg = <0x7f0000 0x010000>;
label = "nvram";
};
};
};
};
&leds {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_leds>;
led@1 {
reg = <1>;
active-low;
label = "green:inet";
};
led_power_green: led@4 {
reg = <4>;
active-low;
label = "green:power";
default-state = "on";
};
led@7 {
reg = <7>;
active-low;
label = "red:inet";
};
led@8 {
reg = <8>;
active-low;
label = "red:power";
};
led@9 {
reg = <9>;
active-low;
label = "green:wps";
};
led@10 {
reg = <10>;
active-low;
label = "green:usb";
};
led@11 {
reg = <11>;
active-low;
label = "green:dsl";
};
};
&pinctrl {
pinctrl_leds: leds {
function = "led";
pins = "gpio1", "gpio4", "gpio7",
"gpio8", "gpio9", "gpio10",
"gpio11";
};
};
&uart0 {
status = "okay";
};

View File

@ -571,6 +571,19 @@ define Device/d-link_dsl-274xb-f1
endef
TARGET_DEVICES += d-link_dsl-274xb-f1
define Device/d-link_dsl-2750u-c1
$(Device/bcm63xx)
DEVICE_VENDOR := D-Link
DEVICE_MODEL := DSL-2750U
DEVICE_VARIANT := C1
IMAGES += sysupgrade.bin
CFE_BOARD_ID := 963281TAVNG
CHIP_ID := 6328
FLASH_MB := 8
DEVICE_PACKAGES := $(USB2_PACKAGES) $(B43_PACKAGES)
endef
TARGET_DEVICES += d-link_dsl-2750u-c1
define Device/d-link_dsl-275xb-d1
$(Device/bcm63xx)
DEVICE_VENDOR := D-Link

View File

@ -500,7 +500,7 @@
#endif /* CONFIG_BCM63XX_CPU_6328 */
#ifdef CONFIG_BCM63XX_CPU_6338
&board_96338gw,
@@ -742,7 +1228,18 @@ static struct of_device_id const bcm963x
@@ -742,7 +1228,19 @@ static struct of_device_id const bcm963x
{ .compatible = "sagem,fast-2704n", .data = &board_FAST2704N, },
#endif /* CONFIG_BCM63XX_CPU_6318 */
#ifdef CONFIG_BCM63XX_CPU_6328
@ -512,6 +512,7 @@
+ { .compatible = "comtrend,ar-5381u", .data = &board_AR5381u, },
+ { .compatible = "comtrend,ar-5387un", .data = &board_AR5387un, },
+ { .compatible = "d-link,dsl-274xb-f1", .data = &board_dsl_274xb_f1, },
+ { .compatible = "d-link,dsl-2750u-c1", .data = &board_A4001N, },
+ { .compatible = "nucom,r5010un-v2", .data = &board_R5010UNV2, },
+ { .compatible = "sagem,fast-2704-v2", .data = &board_FAST2704V2, },
+ { .compatible = "sercomm,ad1018", .data = &board_AD1018, },

View File

@ -42,7 +42,7 @@
#endif /* CONFIG_BCM63XX_CPU_6338 */
#ifdef CONFIG_BCM63XX_CPU_6345
&board_96345gw2,
@@ -1244,6 +1272,8 @@ static struct of_device_id const bcm963x
@@ -1245,6 +1273,8 @@ static struct of_device_id const bcm963x
#ifdef CONFIG_BCM63XX_CPU_6338
{ .compatible = "brcm,bcm96338gw", .data = &board_96338gw, },
{ .compatible = "brcm,bcm96338w", .data = &board_96338w, },

View File

@ -28,7 +28,7 @@
#endif /* CONFIG_BCM63XX_CPU_6345 */
#ifdef CONFIG_BCM63XX_CPU_6348
&board_96348r,
@@ -1277,6 +1291,8 @@ static struct of_device_id const bcm963x
@@ -1278,6 +1292,8 @@ static struct of_device_id const bcm963x
#endif /* CONFIG_BCM63XX_CPU_6338 */
#ifdef CONFIG_BCM63XX_CPU_6345
{ .compatible = "brcm,bcm96345gw2", .data = &board_96345gw2, },

View File

@ -296,7 +296,7 @@
#endif /* CONFIG_BCM63XX_CPU_6348 */
#ifdef CONFIG_BCM63XX_CPU_6358
&board_96358vw,
@@ -1295,15 +1577,29 @@ static struct of_device_id const bcm963x
@@ -1296,15 +1578,29 @@ static struct of_device_id const bcm963x
{ .compatible = "dynalink,rta770w", .data = &board_rta770w, },
#endif /* CONFIG_BCM63XX_CPU_6345 */
#ifdef CONFIG_BCM63XX_CPU_6348

View File

@ -357,7 +357,7 @@
#endif /* CONFIG_BCM63XX_CPU_6358 */
};
@@ -1607,11 +1935,24 @@ static struct of_device_id const bcm963x
@@ -1608,11 +1936,24 @@ static struct of_device_id const bcm963x
{ .compatible = "alcatel,rg100a", .data = &board_96358vw2, },
{ .compatible = "brcm,bcm96358vw", .data = &board_96358vw, },
{ .compatible = "brcm,bcm96358vw2", .data = &board_96358vw2, },

View File

@ -131,7 +131,7 @@
};
static struct of_device_id const bcm963xx_boards_dt[] = {
@@ -1955,6 +2072,10 @@ static struct of_device_id const bcm963x
@@ -1956,6 +2073,10 @@ static struct of_device_id const bcm963x
{ .compatible = "telsey,cpva642", .data = &board_CPVA642, },
#endif /* CONFIG_BCM63XX_CPU_6358 */
#ifdef CONFIG_BCM63XX_CPU_6362

View File

@ -681,7 +681,7 @@
};
static struct of_device_id const bcm963xx_boards_dt[] = {
@@ -2078,6 +2738,20 @@ static struct of_device_id const bcm963x
@@ -2079,6 +2739,20 @@ static struct of_device_id const bcm963x
{ .compatible = "sfr,neufbox-6-sercomm-r0", .data = &board_nb6, },
#endif /* CONFIG_BCM63XX_CPU_6362 */
#ifdef CONFIG_BCM63XX_CPU_6368

View File

@ -290,7 +290,7 @@
};
static struct of_device_id const bcm963xx_boards_dt[] = {
@@ -2754,6 +3030,14 @@ static struct of_device_id const bcm963x
@@ -2755,6 +3031,14 @@ static struct of_device_id const bcm963x
{ .compatible = "zyxel,p870hw-51a-v2", .data = &board_P870HW51A_V2, },
#endif /* CONFIG_BCM63XX_CPU_6368 */
#ifdef CONFIG_BCM63XX_CPU_63268

View File

@ -1,6 +1,6 @@
--- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
+++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
@@ -3066,6 +3066,22 @@ void __init board_bcm963xx_init(void)
@@ -3067,6 +3067,22 @@ void __init board_bcm963xx_init(void)
val &= MPI_CSBASE_BASE_MASK;
}
boot_addr = (u8 *)KSEG1ADDR(val);