Skip to content

Commit

Permalink
Merge branch 'openwrt:main' into BPI-R4-NIC-BE14-rmandrad
Browse files Browse the repository at this point in the history
  • Loading branch information
nextgen-networks authored Sep 26, 2024
2 parents b31eb18 + 38bb47c commit 9802f84
Show file tree
Hide file tree
Showing 10 changed files with 34 additions and 111 deletions.
2 changes: 1 addition & 1 deletion package/boot/uboot-kirkwood/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
include $(TOPDIR)/rules.mk

PKG_VERSION:=2020.04
PKG_RELEASE:=10
PKG_RELEASE:=11

PKG_HASH:=fe732aaf037d9cc3c0909bad8362af366ae964bbdac6913a34081ff4ad565372

Expand Down
3 changes: 2 additions & 1 deletion package/boot/uboot-kirkwood/patches/180-netgear-stora.patch
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@
+
--- /dev/null
+++ b/board/Marvell/netgear_ms2110/netgear_ms2110.c
@@ -0,0 +1,151 @@
@@ -0,0 +1,152 @@
+/*
+ * Copyright (C) 2014-2017 bodhi <[email protected]>
+ *
Expand Down Expand Up @@ -264,6 +264,7 @@
+#include <asm/arch/soc.h>
+#include <asm/arch/mpp.h>
+#include "netgear_ms2110.h"
+#include <asm/arch/cpu.h>
+#include <asm/mach-types.h>
+
+DECLARE_GLOBAL_DATA_PTR;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
--- a/arch/arm/mach-kirkwood/Kconfig
+++ b/arch/arm/mach-kirkwood/Kconfig
@@ -111,4 +111,7 @@ source "board/alliedtelesis/SBx81LIFXCAT
@@ -115,4 +115,7 @@ source "board/alliedtelesis/SBx81LIFXCAT
source "board/Marvell/db-88f6281-bp/Kconfig"
source "board/checkpoint/l-50/Kconfig"

Expand Down
12 changes: 4 additions & 8 deletions package/libs/openssl/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,9 @@ PKG_BUILD_PARALLEL:=1
PKG_BASE:=$(subst $(space),.,$(wordlist 1,2,$(subst .,$(space),$(PKG_VERSION))))
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:= \
http://www.openssl.org/source/ \
http://www.openssl.org/source/old/$(PKG_BASE)/ \
https://github.com/openssl/openssl/releases/download/$(PKG_NAME)-$(PKG_VERSION)/ \
http://ftp.fi.muni.cz/pub/openssl/source/ \
http://ftp.fi.muni.cz/pub/openssl/source/old/$(PKG_BASE)/ \
ftp://ftp.pca.dfn.de/pub/tools/net/openssl/source/ \
ftp://ftp.pca.dfn.de/pub/tools/net/openssl/source/old/$(PKG_BASE)/
https://www.openssl.org/source/ \
https://www.openssl.org/source/old/$(PKG_BASE)/ \
https://github.com/openssl/openssl/releases/download/$(PKG_NAME)-$(PKG_VERSION)/

PKG_HASH:=23c666d0edf20f14249b3d8f0368acaee9ab585b09e1de82107c66e1f3ec9533

Expand Down Expand Up @@ -74,7 +70,7 @@ endif

define Package/openssl/Default
TITLE:=Open source SSL toolkit
URL:=http://www.openssl.org/
URL:=https://www.openssl.org/
SECTION:=libs
CATEGORY:=Libraries
endef
Expand Down
41 changes: 9 additions & 32 deletions target/linux/ath79/files/drivers/gpio/gpio-latch-mikrotik.c
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ static int gpio_latch_probe(struct platform_device *pdev)
struct gpio_latch_chip *glc;
struct gpio_chip *gc;
struct device *dev = &pdev->dev;
struct fwnode_handle *fwnode = dev->fwnode;
int i, n;

glc = devm_kzalloc(dev, sizeof(*glc), GFP_KERNEL);
Expand All @@ -121,24 +120,19 @@ static int gpio_latch_probe(struct platform_device *pdev)
mutex_init(&glc->latch_mutex);

n = gpiod_count(dev, NULL);
if (n <= 0) {
dev_err(dev, "failed to get gpios: %d\n", n);
return n;
} else if (n != GPIO_LATCH_LINES) {
dev_err(dev, "expected %d gpios\n", GPIO_LATCH_LINES);
if (n <= 0)
return dev_err_probe(dev, n, "failed to get gpios");
if (n != GPIO_LATCH_LINES) {
dev_err(dev, "expected %d gpios", GPIO_LATCH_LINES);
return -EINVAL;
}

for (i = 0; i < n; i++) {
glc->gpios[i] = devm_gpiod_get_index_optional(dev, NULL, i,
GPIOD_OUT_LOW);
if (IS_ERR(glc->gpios[i])) {
if (PTR_ERR(glc->gpios[i]) != -EPROBE_DEFER) {
dev_err(dev, "failed to get gpio %d: %ld\n", i,
PTR_ERR(glc->gpios[i]));
}
return PTR_ERR(glc->gpios[i]);
}
if (IS_ERR(glc->gpios[i]))
return dev_err_probe(dev, PTR_ERR(glc->gpios[i]),
"failed to get gpio %d", i);
}

glc->le_gpio = 8;
Expand All @@ -152,31 +146,15 @@ static int gpio_latch_probe(struct platform_device *pdev)

gc = &glc->gc;
gc->label = GPIO_LATCH_DRIVER_NAME;
gc->parent = dev;
gc->can_sleep = true;
gc->base = -1;
gc->ngpio = GPIO_LATCH_LINES;
gc->get = gpio_latch_get;
gc->set = gpio_latch_set;
gc->direction_output = gpio_latch_direction_output;
gc->fwnode = fwnode;

platform_set_drvdata(pdev, glc);

i = gpiochip_add(&glc->gc);
if (i) {
dev_err(dev, "gpiochip_add() failed: %d\n", i);
return i;
}

return 0;
}

static int gpio_latch_remove(struct platform_device *pdev)
{
struct gpio_latch_chip *glc = platform_get_drvdata(pdev);

gpiochip_remove(&glc->gc);
return 0;
return devm_gpiochip_add_data(dev, gc, glc);
}

static const struct of_device_id gpio_latch_match[] = {
Expand All @@ -188,7 +166,6 @@ MODULE_DEVICE_TABLE(of, gpio_latch_match);

static struct platform_driver gpio_latch_driver = {
.probe = gpio_latch_probe,
.remove = gpio_latch_remove,
.driver = {
.name = GPIO_LATCH_DRIVER_NAME,
.owner = THIS_MODULE,
Expand Down
49 changes: 15 additions & 34 deletions target/linux/ramips/files/drivers/net/ethernet/ralink/mtk_eth_soc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1522,7 +1522,6 @@ static void fe_pending_work(struct work_struct *work)

static int fe_probe(struct platform_device *pdev)
{
struct resource *res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
const struct of_device_id *match;
struct fe_soc_data *soc;
struct net_device *netdev;
Expand All @@ -1542,17 +1541,14 @@ static int fe_probe(struct platform_device *pdev)
else
soc->reg_table = fe_reg_table;

fe_base = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(fe_base)) {
err = -EADDRNOTAVAIL;
goto err_out;
}
fe_base = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(fe_base))
return PTR_ERR(fe_base);

netdev = alloc_etherdev(sizeof(*priv));
netdev = devm_alloc_etherdev_mqs(&pdev->dev, sizeof(*priv), 4, 4);
if (!netdev) {
dev_err(&pdev->dev, "alloc_etherdev failed\n");
err = -ENOMEM;
goto err_iounmap;
return -ENOMEM;
}

SET_NETDEV_DEV(netdev, &pdev->dev);
Expand All @@ -1562,16 +1558,15 @@ static int fe_probe(struct platform_device *pdev)
netdev->irq = platform_get_irq(pdev, 0);
if (netdev->irq < 0) {
dev_err(&pdev->dev, "no IRQ resource found\n");
err = -ENXIO;
goto err_free_dev;
return -ENXIO;
}

priv = netdev_priv(netdev);
spin_lock_init(&priv->page_lock);
priv->resets = devm_reset_control_array_get_exclusive(&pdev->dev);
priv->resets = devm_reset_control_array_get_optional_exclusive(&pdev->dev);
if (IS_ERR(priv->resets)) {
dev_err(&pdev->dev, "Failed to get resets for FE and ESW cores: %pe\n", priv->resets);
priv->resets = NULL;
return PTR_ERR(priv->resets);
}

if (soc->init_data)
Expand All @@ -1589,11 +1584,9 @@ static int fe_probe(struct platform_device *pdev)
netdev->features |= NETIF_F_HW_VLAN_CTAG_FILTER;

if (fe_reg_table[FE_REG_FE_COUNTER_BASE]) {
priv->hw_stats = kzalloc(sizeof(*priv->hw_stats), GFP_KERNEL);
if (!priv->hw_stats) {
err = -ENOMEM;
goto err_free_dev;
}
priv->hw_stats = devm_kzalloc(&pdev->dev, sizeof(*priv->hw_stats), GFP_KERNEL);
if (!priv->hw_stats)
return -ENOMEM;
spin_lock_init(&priv->hw_stats->stats_lock);
u64_stats_init(&priv->hw_stats->syncp);
}
Expand All @@ -1603,15 +1596,13 @@ static int fe_probe(struct platform_device *pdev)
priv->sysclk = clk_get_rate(sysclk);
} else if ((priv->flags & FE_FLAG_CALIBRATE_CLK)) {
dev_err(&pdev->dev, "this soc needs a clk for calibration\n");
err = -ENXIO;
goto err_free_dev;
return -ENXIO;
}

priv->switch_np = of_parse_phandle(pdev->dev.of_node, "mediatek,switch", 0);
if ((priv->flags & FE_FLAG_HAS_SWITCH) && !priv->switch_np) {
dev_err(&pdev->dev, "failed to read switch phandle\n");
err = -ENODEV;
goto err_free_dev;
return -ENODEV;
}

priv->netdev = netdev;
Expand All @@ -1633,10 +1624,10 @@ static int fe_probe(struct platform_device *pdev)
netif_napi_add_weight(netdev, &priv->rx_napi, fe_poll, napi_weight);
fe_set_ethtool_ops(netdev);

err = register_netdev(netdev);
err = devm_register_netdev(&pdev->dev, netdev);
if (err) {
dev_err(&pdev->dev, "error bringing up device\n");
goto err_free_dev;
return err;
}

platform_set_drvdata(pdev, netdev);
Expand All @@ -1645,13 +1636,6 @@ static int fe_probe(struct platform_device *pdev)
netdev->base_addr, netdev->irq);

return 0;

err_free_dev:
free_netdev(netdev);
err_iounmap:
devm_iounmap(&pdev->dev, fe_base);
err_out:
return err;
}

static int fe_remove(struct platform_device *pdev)
Expand All @@ -1660,12 +1644,9 @@ static int fe_remove(struct platform_device *pdev)
struct fe_priv *priv = netdev_priv(dev);

netif_napi_del(&priv->rx_napi);
kfree(priv->hw_stats);

cancel_work_sync(&priv->pending_work);

unregister_netdev(dev);
free_netdev(dev);
platform_set_drvdata(pdev, NULL);

return 0;
Expand Down
3 changes: 2 additions & 1 deletion tools/e2fsprogs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ HOST_CONFIGURE_ARGS += \
--disable-tls \
--disable-nls \
--enable-threads=pth \
--disable-fuse2fs
--disable-fuse2fs \
--with-crond-dir=no

define Host/Prepare
$(call Host/Prepare/Default)
Expand Down
11 changes: 0 additions & 11 deletions tools/e2fsprogs/patches/001-exit_0_on_corrected_errors.patch

This file was deleted.

11 changes: 0 additions & 11 deletions tools/e2fsprogs/patches/002-dont-build-e4defrag.patch

This file was deleted.

11 changes: 0 additions & 11 deletions tools/e2fsprogs/patches/003-no-crond.patch

This file was deleted.

0 comments on commit 9802f84

Please sign in to comment.