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: <4D68720C2E767A4AA6A8796D42C8EB591184C1@BGSMSX102.gar.corp.intel.com>
Date:	Mon, 7 May 2012 10:59:48 +0000
From:	"R, Durgadoss" <durgadoss.r@...el.com>
To:	"Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
	"Yu, Fenghua" <fenghua.yu@...el.com>,
	Guenter Roeck <guenter.roeck@...csson.com>
CC:	Andi Kleen <ak@...ux.intel.com>, Jean Delvare <khali@...ux-fr.org>,
	"lm-sensors@...sensors.org" <lm-sensors@...sensors.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH, v3] hwmon: coretemp: use list instead of fixed size
 array for temp data

Hi,


> -----Original Message-----
> From: Kirill A. Shutemov [mailto:kirill.shutemov@...ux.intel.com]
> Sent: Monday, May 07, 2012 4:04 PM
> To: Yu, Fenghua; Guenter Roeck; R, Durgadoss
> Cc: Andi Kleen; Jean Delvare; lm-sensors@...sensors.org; linux-
> kernel@...r.kernel.org; Kirill A. Shutemov
> Subject: [PATCH, v3] hwmon: coretemp: use list instead of fixed size array for
> temp data
> 
> From: "Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>
> 
> Let's rework code to allow arbitrary number of cores on a CPU, not
> limited by hardcoded array size.
> 
> Signed-off-by: Kirill A. Shutemov <kirill.shutemov@...ux.intel.com>
> ---
>  v3:
>    - drop redundant refcounting and checks;
>  v2:
>    - fix NULL pointer dereference. Thanks to R, Durgadoss;
>    - use mutex instead of spinlock for list locking.
> ---
>  drivers/hwmon/coretemp.c |  120 ++++++++++++++++++++++++++++-----------
> ------
>  1 files changed, 75 insertions(+), 45 deletions(-)
> 
> diff --git a/drivers/hwmon/coretemp.c b/drivers/hwmon/coretemp.c
> index b9d5123..fa082d5 100644
> --- a/drivers/hwmon/coretemp.c
> +++ b/drivers/hwmon/coretemp.c
> @@ -36,6 +36,8 @@
>  #include <linux/cpu.h>
>  #include <linux/pci.h>
>  #include <linux/smp.h>
> +#include <linux/list.h>
> +#include <linux/kref.h>

I think we don't need to include kref.h now :-)

BTW, at some places, looks like we are using 'tdata' obtained from get_temp_data,
without checking for NULL values. Other than that, looks Ok for me.

Acked-by: Durgadoss R <durgadoss.r@...el.com>

Thanks,
Durga
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ