lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240411153126.16201-334-axboe@kernel.dk>
Date: Thu, 11 Apr 2024 09:17:53 -0600
From: Jens Axboe <axboe@...nel.dk>
To: linux-kernel@...r.kernel.org
Cc: Jens Axboe <axboe@...nel.dk>
Subject: [PATCH 333/437] arch/arm: convert to read/write iterators

Signed-off-by: Jens Axboe <axboe@...nel.dk>
---
 arch/arm/common/bL_switcher_dummy_if.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/arm/common/bL_switcher_dummy_if.c b/arch/arm/common/bL_switcher_dummy_if.c
index cabc0659b329..f9794c4a6a40 100644
--- a/arch/arm/common/bL_switcher_dummy_if.c
+++ b/arch/arm/common/bL_switcher_dummy_if.c
@@ -15,9 +15,9 @@
 #include <linux/uaccess.h>
 #include <asm/bL_switcher.h>
 
-static ssize_t bL_switcher_write(struct file *file, const char __user *buf,
-			size_t len, loff_t *pos)
+static ssize_t bL_switcher_write(struct kiocb *iocb, struct iov_iter *from)
 {
+	size_t len = iov_iter_count(from);
 	unsigned char val[3];
 	unsigned int cpu, cluster;
 	int ret;
@@ -27,7 +27,7 @@ static ssize_t bL_switcher_write(struct file *file, const char __user *buf,
 	if (len < 3)
 		return -EINVAL;
 
-	if (copy_from_user(val, buf, 3))
+	if (!copy_from_iter_full(val, 3, fro))
 		return -EFAULT;
 
 	/* format: <cpu#>,<cluster#> */
@@ -44,7 +44,7 @@ static ssize_t bL_switcher_write(struct file *file, const char __user *buf,
 }
 
 static const struct file_operations bL_switcher_fops = {
-	.write		= bL_switcher_write,
+	.write_iter	= bL_switcher_write,
 	.owner	= THIS_MODULE,
 };
 
-- 
2.43.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ