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


Groups > linux.kernel > #1517474

Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference

From Linus Torvalds <torvalds@linux-foundation.org>
Newsgroups linux.kernel
Subject Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference
Date 2016-11-08 19:50 +0100
Message-ID <sBjD3-4ES-35@gated-at.bofh.it> (permalink)
References <sAxRM-7gA-11@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sun, Nov 6, 2016 at 7:40 AM, Jörg Otte <jrg.otte@gmail.com> wrote:
> Since v4.9-rc4 I get following crash in dvb-usb-cinergyT2 module.

Looks like it's commit 5ef8ed0e5608f ("[media] cinergyT2-core: don't
do DMA on stack"), which movced the DMA data array from the stack to
the "private" pointer. In the process it also added serialization in
the form of "data_mutex", but and now it oopses on that mutex because
the private pointer is NULL.

It looks like the "->private" pointer is allocated in dvb_usb_adapter_init()

cinergyt2_usb_probe ->
  dvb_usb_device_init ->
    dvb_usb_init() ->
      dvb_usb_adapter_init()

but the dvb_usb_init() function calls dvb_usb_device_power_ctrl()
(which calls the "power_ctrl" function, which is
cinergyt2_power_ctrl() for that drive) *before* it initializes the
private field.

Mauro, Patrick, could dvb_usb_adapter_init() be called earlier, perhaps?

                    Linus

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Jörg Otte <jrg.otte@gmail.com> - 2016-11-06 16:50 +0100
  Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Linus Torvalds <torvalds@linux-foundation.org> - 2016-11-08 19:50 +0100
    Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Mauro Carvalho Chehab <mchehab@s-opensource.com> - 2016-11-08 21:30 +0100
      Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Benjamin Larsson <benjamin@southpole.se> - 2016-11-08 22:40 +0100
        Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Mauro Carvalho Chehab <mchehab@s-opensource.com> - 2016-11-08 22:40 +0100
          Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Malcolm Priestley <tvboxspy@gmail.com> - 2016-11-09 21:00 +0100
            Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Mauro Carvalho Chehab <mchehab@s-opensource.com> - 2016-11-09 21:30 +0100
      Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Jörg Otte <jrg.otte@gmail.com> - 2016-11-09 12:30 +0100
        Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Linus Torvalds <torvalds@linux-foundation.org> - 2016-11-09 20:10 +0100
          Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Mauro Carvalho Chehab <mchehab@s-opensource.com> - 2016-11-09 21:30 +0100
          Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Mauro Carvalho Chehab <mchehab@s-opensource.com> - 2016-11-10 09:50 +0100
            Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Jörg Otte <jrg.otte@gmail.com> - 2016-11-10 12:20 +0100
              Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Mauro Carvalho Chehab <mchehab@osg.samsung.com> - 2016-11-11 15:00 +0100
                Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference Jörg Otte <jrg.otte@gmail.com> - 2016-11-11 17:50 +0100

csiph-web