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]
Message-id: <56E2F225.3040109@samsung.com>
Date:	Fri, 11 Mar 2016 17:28:21 +0100
From:	Sylwester Nawrocki <s.nawrocki@...sung.com>
To:	Zhaoxiu Zeng <zhaoxiu.zeng@...il.com>
Cc:	kyungmin.park@...sung.com, mchehab@....samsung.com,
	kgene@...nel.org, k.kozlowski@...sung.com,
	linux-media@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
	linux-samsung-soc@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 05/10] exynos4-is: Replace "hweight32(mask) == 1" with
 "is_power_of_2(mask)"

On 12/06/2015 11:44 AM, Zhaoxiu Zeng wrote:
> From: Zeng Zhaoxiu <zhaoxiu.zeng@...il.com>

The patch looks OK, but could you also provide a proper commit
message?

> Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng@...il.com>
> ---
>  drivers/media/platform/exynos4-is/fimc-is-regs.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/media/platform/exynos4-is/fimc-is-regs.c b/drivers/media/platform/exynos4-is/fimc-is-regs.c
> index cfe4406..ec75a24 100644
> --- a/drivers/media/platform/exynos4-is/fimc-is-regs.c
> +++ b/drivers/media/platform/exynos4-is/fimc-is-regs.c
> @@ -11,6 +11,7 @@
>   * published by the Free Software Foundation.
>   */
>  #include <linux/delay.h>
> +#include <linux/log2.h>
>  
>  #include "fimc-is.h"
>  #include "fimc-is-command.h"
> @@ -107,7 +108,7 @@ int fimc_is_hw_get_params(struct fimc_is *is, unsigned int num_args)
>  
>  void fimc_is_hw_set_isp_buf_mask(struct fimc_is *is, unsigned int mask)
>  {
> -	if (hweight32(mask) == 1) {
> +	if (is_power_of_2(mask)) {
>  		dev_err(&is->pdev->dev, "%s(): not enough buffers (mask %#x)\n",
>  							__func__, mask);
>  		return;

-- 
Thanks,
Sylwester

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ