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: <5B8DA87D05A7694D9FA63FD143655C1B9DD64927@hasmsx108.ger.corp.intel.com>
Date:   Thu, 9 Jan 2020 08:28:56 +0000
From:   "Winkler, Tomas" <tomas.winkler@...el.com>
To:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>
CC:     "Usyskin, Alexander" <alexander.usyskin@...el.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [char-misc-next] mei: bus: use simple sprintf for sysfs

> 
> Replace scnprintf with simple sprintf for sysfs files.
> it is implicitly known that the buffer is big enough for the variables to fit in.
> 
> Signed-off-by: Tomas Winkler <tomas.winkler@...el.com>

Hi Greg, hope you have great holiday,  has anything changed in the misc-char dev process,
no patches were staged including this one?
Thanks
Tomas


> ---
>  drivers/misc/mei/bus.c | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/misc/mei/bus.c b/drivers/misc/mei/bus.c index
> a0a495c95e3c..8d468e0a950a 100644
> --- a/drivers/misc/mei/bus.c
> +++ b/drivers/misc/mei/bus.c
> @@ -765,7 +765,7 @@ static ssize_t uuid_show(struct device *dev, struct
> device_attribute *a,
>  	struct mei_cl_device *cldev = to_mei_cl_device(dev);
>  	const uuid_le *uuid = mei_me_cl_uuid(cldev->me_cl);
> 
> -	return scnprintf(buf, PAGE_SIZE, "%pUl", uuid);
> +	return sprintf(buf, "%pUl", uuid);
>  }
>  static DEVICE_ATTR_RO(uuid);
> 
> @@ -775,7 +775,7 @@ static ssize_t version_show(struct device *dev, struct
> device_attribute *a,
>  	struct mei_cl_device *cldev = to_mei_cl_device(dev);
>  	u8 version = mei_me_cl_ver(cldev->me_cl);
> 
> -	return scnprintf(buf, PAGE_SIZE, "%02X", version);
> +	return sprintf(buf, "%02X", version);
>  }
>  static DEVICE_ATTR_RO(version);
> 
> @@ -797,7 +797,7 @@ static ssize_t max_conn_show(struct device *dev,
> struct device_attribute *a,
>  	struct mei_cl_device *cldev = to_mei_cl_device(dev);
>  	u8 maxconn = mei_me_cl_max_conn(cldev->me_cl);
> 
> -	return scnprintf(buf, PAGE_SIZE, "%d", maxconn);
> +	return sprintf(buf, "%d", maxconn);
>  }
>  static DEVICE_ATTR_RO(max_conn);
> 
> @@ -807,7 +807,7 @@ static ssize_t fixed_show(struct device *dev, struct
> device_attribute *a,
>  	struct mei_cl_device *cldev = to_mei_cl_device(dev);
>  	u8 fixed = mei_me_cl_fixed(cldev->me_cl);
> 
> -	return scnprintf(buf, PAGE_SIZE, "%d", fixed);
> +	return sprintf(buf, "%d", fixed);
>  }
>  static DEVICE_ATTR_RO(fixed);
> 
> @@ -817,7 +817,7 @@ static ssize_t max_len_show(struct device *dev, struct
> device_attribute *a,
>  	struct mei_cl_device *cldev = to_mei_cl_device(dev);
>  	u32 maxlen = mei_me_cl_max_len(cldev->me_cl);
> 
> -	return scnprintf(buf, PAGE_SIZE, "%u", maxlen);
> +	return sprintf(buf, "%u", maxlen);
>  }
>  static DEVICE_ATTR_RO(max_len);
> 
> --
> 2.21.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ