Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1244011 > unrolled thread

[BUG] x86: apic: Possible null pointer dereference by apic_ack_edge

Started byWilliam Breathitt Gray <vilhelm.gray@gmail.com>
First post2015-10-10 23:00 +0200
Last post2015-10-11 10:40 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [BUG] x86: apic: Possible null pointer dereference by apic_ack_edge William Breathitt Gray <vilhelm.gray@gmail.com> - 2015-10-10 23:00 +0200
    Re: [BUG] x86: apic: Possible null pointer dereference by  apic_ack_edge Thomas Gleixner <tglx@linutronix.de> - 2015-10-11 10:40 +0200

#1244011 — [BUG] x86: apic: Possible null pointer dereference by apic_ack_edge

FromWilliam Breathitt Gray <vilhelm.gray@gmail.com>
Date2015-10-10 23:00 +0200
Subject[BUG] x86: apic: Possible null pointer dereference by apic_ack_edge
Message-ID<qi9pg-3Oh-1@gated-at.bofh.it>
Hello,

In mainline kernel version 4.3-rc4, the following line located in the
apic_ack_edge function definition can result in a null pointer dereference:

        irq_complete_move(irqd_cfg(data));
        
The irqd_cfg function may return a value of NULL. If NULL is passed to the
irq_complete_move function, then the struct apic_chip_data pointer 'data' of
the __irq_complete_move function will be defined, and subsequently dereferenced,
based on this incorrect NULL value passed through the 'cfg' parameter:

        data = container_of(cfg, struct apic_chip_data, cfg);
        if (likely(!data->move_in_progress))
        
Sincerely,

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

[toc] | [next] | [standalone]


#1244073 — Re: [BUG] x86: apic: Possible null pointer dereference by apic_ack_edge

FromThomas Gleixner <tglx@linutronix.de>
Date2015-10-11 10:40 +0200
SubjectRe: [BUG] x86: apic: Possible null pointer dereference by apic_ack_edge
Message-ID<qikkG-2XG-15@gated-at.bofh.it>
In reply to#1244011
On Sat, 10 Oct 2015, William Breathitt Gray wrote:
> In mainline kernel version 4.3-rc4, the following line located in the
> apic_ack_edge function definition can result in a null pointer dereference:
> 
>         irq_complete_move(irqd_cfg(data));
>         
> The irqd_cfg function may return a value of NULL.

data is never NULL when apic_ack_edge() is called.

Thanks,

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

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web