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] [day] [month] [year] [list]
Date:   Tue, 25 Apr 2023 18:22:05 +0200
From:   Hans de Goede <hdegoede@...hat.com>
To:     Srinivas Pandruvada <srinivas.pandruvada@...ux.intel.com>,
        markgross@...nel.org
Cc:     platform-driver-x86@...r.kernel.org, linux-kernel@...r.kernel.org,
        Zhang Rui <rui.zhang@...el.com>,
        Wendy Wang <wendy.wang@...el.com>
Subject: Re: [PATCH] platform/x86/intel-uncore-freq: Return error on write
 frequency

Hi,

On 4/18/23 17:32, Srinivas Pandruvada wrote:
> Currently when the uncore_write() returns error, it is silently
> ignored. Return error to user space when uncore_write() fails.
> 
> Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@...ux.intel.com>
> Reviewed-by: Zhang Rui <rui.zhang@...el.com>
> Tested-by: Wendy Wang <wendy.wang@...el.com>

Thank you for your patch, I've applied this patch to my review-hans 
branch:
https://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86.git/log/?h=review-hans

Note it will show up in my review-hans branch once I've pushed my
local branch there, which might take a while.

Patches which are added to review-hans now are intended for
the next rc1. This branch will get rebased to the next rc1 when
it is out and after the rebasing the contents of review-hans
will be pushed to the platform-drivers-x86/for-next branch.

Regards,

Hans



> ---
> This patch has no dependency on TPMI patches for uncore support.
> 
>  .../x86/intel/uncore-frequency/uncore-frequency-common.c    | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/platform/x86/intel/uncore-frequency/uncore-frequency-common.c b/drivers/platform/x86/intel/uncore-frequency/uncore-frequency-common.c
> index cb24de9e97dc..fa8f14c925ec 100644
> --- a/drivers/platform/x86/intel/uncore-frequency/uncore-frequency-common.c
> +++ b/drivers/platform/x86/intel/uncore-frequency/uncore-frequency-common.c
> @@ -44,14 +44,18 @@ static ssize_t store_min_max_freq_khz(struct uncore_data *data,
>  				      int min_max)
>  {
>  	unsigned int input;
> +	int ret;
>  
>  	if (kstrtouint(buf, 10, &input))
>  		return -EINVAL;
>  
>  	mutex_lock(&uncore_lock);
> -	uncore_write(data, input, min_max);
> +	ret = uncore_write(data, input, min_max);
>  	mutex_unlock(&uncore_lock);
>  
> +	if (ret)
> +		return ret;
> +
>  	return count;
>  }
>  

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ