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: <aa79d98a0905132000g18629ebx7f260eca03a810fc@mail.gmail.com>
Date:	Thu, 14 May 2009 07:00:16 +0400
From:	Cyrill Gorcunov <gorcunov@...il.com>
To:	Jaswinder Singh Rajput <jaswinder@...nel.org>
Cc:	Ingo Molnar <mingo@...e.hu>, Joerg Roedel <joerg.roedel@....com>,
	x86 maintainers <x86@...nel.org>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH -tip] x86: amd_iommu_init.c use NULL pointer

On 5/14/09, Jaswinder Singh Rajput <jaswinder@...nel.org> wrote:
>
> Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@...il.com>
> ---
>  arch/x86/kernel/amd_iommu_init.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/kernel/amd_iommu_init.c
> b/arch/x86/kernel/amd_iommu_init.c
> index 8c0be09..f728b12 100644
> --- a/arch/x86/kernel/amd_iommu_init.c
> +++ b/arch/x86/kernel/amd_iommu_init.c
> @@ -898,7 +898,7 @@ static int __init init_exclusion_range(struct
> ivmd_header *m)
>  /* called for unity map ACPI definition */
>  static int __init init_unity_map_range(struct ivmd_header *m)
>  {
> -	struct unity_map_entry *e = 0;
> +	struct unity_map_entry *e = NULL;
>
>  	e = kzalloc(sizeof(*e), GFP_KERNEL);
>  	if (e == NULL)
> --
> 1.6.0.6
>
Hi Jaswinder,
I believe you could get rid of such init completely. We do check 'e'
after kzalloc anyway.
--
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