aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/generic')
-rw-r--r--target/linux/generic/backport-5.4/750-v5.5-net-phy-add-support-for-clause-37-auto-negotiation.patch30
-rw-r--r--target/linux/generic/config-5.41
-rw-r--r--target/linux/generic/hack-5.4/550-loop-Report-EOPNOTSUPP-properly.patch4
-rw-r--r--target/linux/generic/hack-5.4/551-loop-Better-discard-support-for-block-devices.patch101
-rw-r--r--target/linux/generic/hack-5.4/702-phy_add_aneg_done_function.patch2
-rw-r--r--target/linux/generic/hack-5.4/902-debloat_proc.patch2
6 files changed, 18 insertions, 122 deletions
diff --git a/target/linux/generic/backport-5.4/750-v5.5-net-phy-add-support-for-clause-37-auto-negotiation.patch b/target/linux/generic/backport-5.4/750-v5.5-net-phy-add-support-for-clause-37-auto-negotiation.patch
index da76523730..855c4d2aac 100644
--- a/target/linux/generic/backport-5.4/750-v5.5-net-phy-add-support-for-clause-37-auto-negotiation.patch
+++ b/target/linux/generic/backport-5.4/750-v5.5-net-phy-add-support-for-clause-37-auto-negotiation.patch
@@ -18,15 +18,12 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/phy.h | 4 +
2 files changed, 143 insertions(+)
-diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c
-index f1f60bd4865a..fa71998fea51 100644
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
-@@ -1607,6 +1607,40 @@ static int genphy_config_advert(struct phy_device *phydev)
- return changed;
+@@ -1679,6 +1679,40 @@ static int genphy_config_advert(struct p
}
-+/**
+ /**
+ * genphy_c37_config_advert - sanitize and advertise auto-negotiation parameters
+ * @phydev: target phy_device struct
+ *
@@ -60,14 +57,14 @@ index f1f60bd4865a..fa71998fea51 100644
+ adv);
+}
+
- /**
++/**
* genphy_config_eee_advert - disable unwanted eee mode advertisement
* @phydev: target phy_device struct
-@@ -1715,6 +1749,54 @@ int __genphy_config_aneg(struct phy_device *phydev, bool changed)
- }
+ *
+@@ -1787,6 +1821,54 @@ int __genphy_config_aneg(struct phy_devi
EXPORT_SYMBOL(__genphy_config_aneg);
-+/**
+ /**
+ * genphy_c37_config_aneg - restart auto-negotiation or write BMCR
+ * @phydev: target phy_device struct
+ *
@@ -115,14 +112,14 @@ index f1f60bd4865a..fa71998fea51 100644
+}
+EXPORT_SYMBOL(genphy_c37_config_aneg);
+
- /**
++/**
* genphy_aneg_done - return auto-negotiation status
* @phydev: target phy_device struct
-@@ -1886,6 +1968,63 @@ int genphy_read_status(struct phy_device *phydev)
- }
+ *
+@@ -1958,6 +2040,63 @@ int genphy_read_status(struct phy_device
EXPORT_SYMBOL(genphy_read_status);
-+/**
+ /**
+ * genphy_c37_read_status - check the link status and update current link state
+ * @phydev: target phy_device struct
+ *
@@ -179,14 +176,13 @@ index f1f60bd4865a..fa71998fea51 100644
+}
+EXPORT_SYMBOL(genphy_c37_read_status);
+
- /**
++/**
* genphy_soft_reset - software reset the PHY via BMCR_RESET bit
* @phydev: target phy_device struct
-diff --git a/include/linux/phy.h b/include/linux/phy.h
-index 9a0e981df502..78436d58ce7c 100644
+ *
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
-@@ -1106,6 +1106,10 @@ int genphy_read_mmd_unsupported(struct phy_device *phdev, int devad,
+@@ -1120,6 +1120,10 @@ int genphy_read_mmd_unsupported(struct p
int genphy_write_mmd_unsupported(struct phy_device *phdev, int devnum,
u16 regnum, u16 val);
diff --git a/target/linux/generic/config-5.4 b/target/linux/generic/config-5.4
index 21dd447cdf..a4ff887aa1 100644
--- a/target/linux/generic/config-5.4
+++ b/target/linux/generic/config-5.4
@@ -306,6 +306,7 @@ CONFIG_ARCH_MMAP_RND_COMPAT_BITS_MIN=8
# CONFIG_ARM64_ERRATUM_843419 is not set
# CONFIG_ARM64_ERRATUM_845719 is not set
# CONFIG_ARM64_ERRATUM_858921 is not set
+# CONFIG_ARM64_ERRATUM_1542419 is not set
# CONFIG_ARM64_HW_AFDBM is not set
# CONFIG_ARM64_LSE_ATOMICS is not set
# CONFIG_ARM64_MODULE_PLTS is not set
diff --git a/target/linux/generic/hack-5.4/550-loop-Report-EOPNOTSUPP-properly.patch b/target/linux/generic/hack-5.4/550-loop-Report-EOPNOTSUPP-properly.patch
index 479513bf54..754c01be1b 100644
--- a/target/linux/generic/hack-5.4/550-loop-Report-EOPNOTSUPP-properly.patch
+++ b/target/linux/generic/hack-5.4/550-loop-Report-EOPNOTSUPP-properly.patch
@@ -18,7 +18,7 @@ Reviewed-by: Bart Van Assche <bvanassche@acm.org>
--- a/drivers/block/loop.c
+++ b/drivers/block/loop.c
-@@ -461,7 +461,7 @@ static void lo_complete_rq(struct reques
+@@ -462,7 +462,7 @@ static void lo_complete_rq(struct reques
if (!cmd->use_aio || cmd->ret < 0 || cmd->ret == blk_rq_bytes(rq) ||
req_op(rq) != REQ_OP_READ) {
if (cmd->ret < 0)
@@ -27,7 +27,7 @@ Reviewed-by: Bart Van Assche <bvanassche@acm.org>
goto end_io;
}
-@@ -1950,7 +1950,10 @@ static void loop_handle_cmd(struct loop_
+@@ -1970,7 +1970,10 @@ static void loop_handle_cmd(struct loop_
failed:
/* complete non-aio request */
if (!cmd->use_aio || ret) {
diff --git a/target/linux/generic/hack-5.4/551-loop-Better-discard-support-for-block-devices.patch b/target/linux/generic/hack-5.4/551-loop-Better-discard-support-for-block-devices.patch
deleted file mode 100644
index 38091290aa..0000000000
--- a/target/linux/generic/hack-5.4/551-loop-Better-discard-support-for-block-devices.patch
+++ /dev/null
@@ -1,101 +0,0 @@
-From 3117c3f45edbcc269baaebd3d13f39b7bf884aa6 Mon Sep 17 00:00:00 2001
-From: Evan Green <evgreen@chromium.org>
-Date: Thu, 14 Nov 2019 15:50:08 -0800
-Subject: loop: Better discard support for block devices
-
-If the backing device for a loop device is itself a block device,
-then mirror the "write zeroes" capabilities of the underlying
-block device into the loop device. Copy this capability into both
-max_write_zeroes_sectors and max_discard_sectors of the loop device.
-
-The reason for this is that REQ_OP_DISCARD on a loop device translates
-into blkdev_issue_zeroout(), rather than blkdev_issue_discard(). This
-presents a consistent interface for loop devices (that discarded data
-is zeroed), regardless of the backing device type of the loop device.
-There should be no behavior change for loop devices backed by regular
-files.
-
-This change fixes blktest block/003, and removes an extraneous
-error print in block/013 when testing on a loop device backed
-by a block device that does not support discard.
-
-Signed-off-by: Evan Green <evgreen@chromium.org>
-Reviewed-by: Gwendal Grignou <gwendal@chromium.org>
-Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
----
- drivers/block/loop.c | 40 +++++++++++++++++++++++++++++-----------
- 1 file changed, 29 insertions(+), 11 deletions(-)
-
---- a/drivers/block/loop.c
-+++ b/drivers/block/loop.c
-@@ -427,11 +427,12 @@ static int lo_fallocate(struct loop_devi
- * information.
- */
- struct file *file = lo->lo_backing_file;
-+ struct request_queue *q = lo->lo_queue;
- int ret;
-
- mode |= FALLOC_FL_KEEP_SIZE;
-
-- if ((!file->f_op->fallocate) || lo->lo_encrypt_key_size) {
-+ if (!blk_queue_discard(q)) {
- ret = -EOPNOTSUPP;
- goto out;
- }
-@@ -862,6 +863,21 @@ static void loop_config_discard(struct l
- struct file *file = lo->lo_backing_file;
- struct inode *inode = file->f_mapping->host;
- struct request_queue *q = lo->lo_queue;
-+ struct request_queue *backingq;
-+
-+ /*
-+ * If the backing device is a block device, mirror its zeroing
-+ * capability. REQ_OP_DISCARD translates to a zero-out even when backed
-+ * by block devices to keep consistent behavior with file-backed loop
-+ * devices.
-+ */
-+ if (S_ISBLK(inode->i_mode) && !lo->lo_encrypt_key_size) {
-+ backingq = bdev_get_queue(inode->i_bdev);
-+ blk_queue_max_discard_sectors(q,
-+ backingq->limits.max_write_zeroes_sectors);
-+
-+ blk_queue_max_write_zeroes_sectors(q,
-+ backingq->limits.max_write_zeroes_sectors);
-
- /*
- * We use punch hole to reclaim the free space used by the
-@@ -869,22 +885,24 @@ static void loop_config_discard(struct l
- * encryption is enabled, because it may give an attacker
- * useful information.
- */
-- if ((!file->f_op->fallocate) ||
-- lo->lo_encrypt_key_size) {
-+ } else if ((!file->f_op->fallocate) || lo->lo_encrypt_key_size) {
- q->limits.discard_granularity = 0;
- q->limits.discard_alignment = 0;
- blk_queue_max_discard_sectors(q, 0);
- blk_queue_max_write_zeroes_sectors(q, 0);
-- blk_queue_flag_clear(QUEUE_FLAG_DISCARD, q);
-- return;
-- }
-
-- q->limits.discard_granularity = inode->i_sb->s_blocksize;
-- q->limits.discard_alignment = 0;
-+ } else {
-+ q->limits.discard_granularity = inode->i_sb->s_blocksize;
-+ q->limits.discard_alignment = 0;
-
-- blk_queue_max_discard_sectors(q, UINT_MAX >> 9);
-- blk_queue_max_write_zeroes_sectors(q, UINT_MAX >> 9);
-- blk_queue_flag_set(QUEUE_FLAG_DISCARD, q);
-+ blk_queue_max_discard_sectors(q, UINT_MAX >> 9);
-+ blk_queue_max_write_zeroes_sectors(q, UINT_MAX >> 9);
-+ }
-+
-+ if (q->limits.max_write_zeroes_sectors)
-+ blk_queue_flag_set(QUEUE_FLAG_DISCARD, q);
-+ else
-+ blk_queue_flag_clear(QUEUE_FLAG_DISCARD, q);
- }
-
- static void loop_unprepare_queue(struct loop_device *lo)
diff --git a/target/linux/generic/hack-5.4/702-phy_add_aneg_done_function.patch b/target/linux/generic/hack-5.4/702-phy_add_aneg_done_function.patch
index f82cef1f94..f58b190025 100644
--- a/target/linux/generic/hack-5.4/702-phy_add_aneg_done_function.patch
+++ b/target/linux/generic/hack-5.4/702-phy_add_aneg_done_function.patch
@@ -15,7 +15,7 @@
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
-@@ -1827,6 +1827,9 @@ int genphy_update_link(struct phy_device
+@@ -1909,6 +1909,9 @@ int genphy_update_link(struct phy_device
if (bmcr & BMCR_ANRESTART)
goto done;
diff --git a/target/linux/generic/hack-5.4/902-debloat_proc.patch b/target/linux/generic/hack-5.4/902-debloat_proc.patch
index f652751339..d2acd40e19 100644
--- a/target/linux/generic/hack-5.4/902-debloat_proc.patch
+++ b/target/linux/generic/hack-5.4/902-debloat_proc.patch
@@ -235,7 +235,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (!pe)
--- a/mm/vmalloc.c
+++ b/mm/vmalloc.c
-@@ -3552,6 +3552,8 @@ static const struct seq_operations vmall
+@@ -3562,6 +3562,8 @@ static const struct seq_operations vmall
static int __init proc_vmalloc_init(void)
{