From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754329AbcKITHw (ORCPT ); Wed, 9 Nov 2016 14:07:52 -0500 Received: from mail-yw0-f173.google.com ([209.85.161.173]:36047 "EHLO mail-yw0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751095AbcKITHg (ORCPT ); Wed, 9 Nov 2016 14:07:36 -0500 MIME-Version: 1.0 In-Reply-To: References: <20161108182215.41f1f3d2@vento.lan> From: Linus Torvalds Date: Wed, 9 Nov 2016 11:07:35 -0800 X-Google-Sender-Auth: USjCi4-E3UtEkqr-BKWruSD23ak Message-ID: Subject: Re: [v4.9-rc4] dvb-usb/cinergyT2 NULL pointer dereference To: =?UTF-8?Q?J=C3=B6rg_Otte?= Cc: Mauro Carvalho Chehab , Patrick Boettcher , Mauro Carvalho Chehab , Linux Kernel Mailing List , Linux Media Mailing List Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by mail.home.local id uA9J80cu018218 On Wed, Nov 9, 2016 at 3:09 AM, Jörg Otte wrote: > > Tried patch with no success. Again a NULL ptr dereferece. That patch was pure garbage, I think. Pretty much all the other drivers that use the same approach will have the same issue. Adding that init function just for the semaphore is crazy. I suspect a much simpler approach is to just miove the "data_mutex" away from the priv area and into "struct dvb_usb_device" and "dvb_usb_adapter". Sure, that grows those structures a tiny bit, and not every driver may need that mutex, but it simplifies things enormously. Mauro? Linus